Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/#38continue #55

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified fonts/WebIconApp.ttf
Binary file not shown.
28 changes: 28 additions & 0 deletions fonts/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,34 @@
"css": "google-1",
"code": 59393,
"src": "fontawesome5"
},
{
"uid": "566920198e655519b389880458f4a939",
"css": "mandara",
"code": 59394,
"src": "custom_icons",
"selected": true,
"svg": {
"path": "M52.6 93.7A93.7 93.7 0 0 1 146.3 0H957.9A93.7 93.7 0 0 1 1051.6 93.7V905.3A93.7 93.7 0 0 1 957.9 998.9H146.3A93.7 93.7 0 0 1 52.6 905.3ZM146.3 62.5A31.2 31.2 0 0 0 115.1 93.7V312.2H364.8V62.4ZM364.8 374.7H115.1V624.5H364.8ZM427.3 624.5V374.7H677.1V624.5ZM364.8 686.9H115.1V905.3A31.2 31.2 0 0 0 146.3 936.5H364.8ZM427.3 686.9H677.1V936.8H427.3ZM739.5 686.9V936.8H957.9A31.2 31.2 0 0 0 989.5 905.3V686.9ZM739.5 624.5H989.5V374.7H739.5ZM739.5 312.3H989.5V93.7A31.2 31.2 0 0 0 958.3 62.5H739.5ZM677.1 312.3H427.3V62.4H677.1Z",
"width": 1053
},
"search": [
"mandara"
]
},
{
"uid": "ac26eb40cae0a9602c05fa62fa6cb5b5",
"css": "mix",
"code": 59395,
"src": "custom_icons",
"selected": true,
"svg": {
"path": "M139.7 521.6H105.2A105.3 105.3 0 0 1 0 416.3V105.2A105.3 105.3 0 0 1 105.2 0H416.3A105.3 105.3 0 0 1 521.6 105.2V139.7A36 36 0 0 1 449.5 139.7V105.2A33.1 33.1 0 0 0 416.4 72H105.2A33.1 33.1 0 0 0 72 105.2V416.3A33.1 33.1 0 0 0 105.2 449.4H139.7A36 36 0 0 1 139.7 521.5ZM454.6 621.1A35.9 35.9 0 0 1 429.2 610.6 36 36 0 0 1 429.2 559.6L573.3 415.4A36 36 0 0 1 624.2 415.4 36 36 0 0 1 624.2 466.4L480.1 610.5A35.9 35.9 0 0 1 454.6 621.1ZM598.8 621.1A35.9 35.9 0 0 1 573.3 610.6L429.2 466.4A36 36 0 0 1 429.2 415.4 36 36 0 0 1 480.1 415.4L624.3 559.5A36 36 0 0 1 598.8 621ZM865.6 478.6H900.2A105.3 105.3 0 0 1 1005.4 583.7V894.8A105.3 105.3 0 0 1 900.2 1000H589.1A105.3 105.3 0 0 1 484 894.8L484 860.3A36 36 0 1 1 556.1 860.3V894.8A33.1 33.1 0 0 0 589.2 928H900.2A33.1 33.1 0 0 0 933.4 894.8L933.4 583.7A33.1 33.1 0 0 0 900.2 550.6L865.7 550.6A36 36 0 1 1 865.7 478.5Z",
"width": 1048
},
"search": [
"mix-(1)"
]
}
]
}
2 changes: 2 additions & 0 deletions lib/addIcon/web_icon_app_icons.dart
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ class WebIconApp {
static const IconData keyboardarrowdown =
IconData(0xe800, fontFamily: _kFontFam);
static const IconData google_1 = IconData(0xe801, fontFamily: _kFontFam);
static const IconData mandara = IconData(0xe802, fontFamily: _kFontFam);
static const IconData mix = IconData(0xe803, fontFamily: _kFontFam);
static const IconData favoriteborder =
IconData(0xe91e, fontFamily: _kFontFam);
static const IconData share = IconData(0xeaee, fontFamily: _kFontFam);
Expand Down
97 changes: 97 additions & 0 deletions lib/pages/accordion_button.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
import 'package:alexander/pages/theme/palette.dart';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';

class AccordionIconButton extends StatefulWidget {
final double _iconSize;
final String _label;
final double _maxWidth;

const AccordionIconButton(
{Key? key,
required double iconSize,
required String label,
required double maxWidth})
: _iconSize = iconSize,
_label = label,
_maxWidth = maxWidth,
super(key: key);

@override
// ignore: no_logic_in_create_state
State<StatefulWidget> createState() => _State(width: _iconSize);
}

class _State extends State<AccordionIconButton> {
// ignore: constant_identifier_names
static const double INITIAL_OPACITY = 0.0;
bool check = false;

double opacity;
double width;

_State({
required this.width,
}) : opacity = INITIAL_OPACITY,
super();

@override
Widget build(BuildContext context) {
const Duration duration = Duration(milliseconds: 2);

return AnimatedContainer(
constraints: BoxConstraints(maxWidth: widget._maxWidth),
width: width,
curve: Curves.easeIn,
duration: duration,
child: InkWell(
borderRadius: const BorderRadius.all(Radius.circular(10.0)),
onHover: (isHover) {
setState(() {
if (isHover) {
opacity = 1.0;
width = 100;
} else {
opacity = INITIAL_OPACITY;
width = widget._iconSize;
}
});
},
onTap: () {},
child: Wrap(
children: [
Container(
width: 32,
height: 32,
decoration: const BoxDecoration(
shape: BoxShape.circle,
color: Palette.loginleft,
),
),
Flexible(
child: AnimatedOpacity(
curve: Curves.easeIn,
duration: duration,
opacity: opacity,
child: Container(
width: 150,
height: 32,
decoration: BoxDecoration(
border: Border.all(color: Palette.borderColor, width: 3),
color: Palette.bgContentsLightColor),
child: Text(
widget._label,
softWrap: false,
overflow: TextOverflow.fade,
textAlign: TextAlign.center,
style: const TextStyle(color: Palette.mainTextColor),
),
),
),
),
],
),
),
);
}
}
Loading