Skip to content

Commit

Permalink
Improve selected icons in settings
Browse files Browse the repository at this point in the history
  • Loading branch information
CodeDoctorDE committed Dec 13, 2023
1 parent 40170fd commit 1ddebc6
Show file tree
Hide file tree
Showing 6 changed files with 155 additions and 150 deletions.
18 changes: 11 additions & 7 deletions app/lib/settings/home.dart
Original file line number Diff line number Diff line change
Expand Up @@ -100,13 +100,17 @@ class _SettingsPageState extends State<SettingsPage> {
children: [
...SettingsView.values
.where((e) => e.isEnabled)
.map((view) => ListTile(
leading: PhosphorIcon(
view.icon(PhosphorIconsStyle.light)),
title: Text(view.getLocalizedName(context)),
onTap: () => navigateTo(view),
selected: _view == view && !isMobile,
)),
.map((view) {
final selected = _view == view && !isMobile;
return ListTile(
leading: PhosphorIcon(view.icon(selected
? PhosphorIconsStyle.fill
: PhosphorIconsStyle.light)),
title: Text(view.getLocalizedName(context)),
onTap: () => navigateTo(view),
selected: selected,
);
}),
if (kIsWeb) ...[
const Divider(),
Padding(
Expand Down
4 changes: 2 additions & 2 deletions app/pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -172,10 +172,10 @@ packages:
dependency: "direct main"
description:
name: camera
sha256: "71fb0e03618a8629a912bbf49bb664869bd16830c1d363b1096df99727b0bebb"
sha256: "7fa53bb1c2059e58bf86b7ab506e3b2a78e42f82d365b44b013239b975a166ef"
url: "https://pub.dev"
source: hosted
version: "0.10.5+6"
version: "0.10.5+7"
camera_android:
dependency: transitive
description:
Expand Down
2 changes: 1 addition & 1 deletion app/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ dependencies:
xml: ^6.5.0
collection: ^1.18.0
bloc_concurrency: ^0.2.2
camera: ^0.10.5+6
camera: ^0.10.5+7
camera_windows: ^0.2.1+8
window_manager: ^0.3.7
flex_color_scheme: ^7.3.1
Expand Down
2 changes: 1 addition & 1 deletion docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"last 1 safari version"
]
},
"packageManager": "[email protected].0",
"packageManager": "[email protected].1",
"devDependencies": {
"@docusaurus/module-type-aliases": "3.0.1",
"@docusaurus/tsconfig": "3.0.1",
Expand Down
Loading

0 comments on commit 1ddebc6

Please sign in to comment.