Skip to content

add switch account icon #1180

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

Closed
wants to merge 1 commit into from
Closed
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 assets/icons/ZulipIcons.ttf
Binary file not shown.
4 changes: 4 additions & 0 deletions assets/icons/switch_account.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 1 addition & 3 deletions lib/widgets/home.dart
Original file line number Diff line number Diff line change
Expand Up @@ -540,10 +540,8 @@ class _SwitchAccountButton extends _MenuButton {

@override
// TODO(design): choose an icon
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now that we have chosen the icon, this comment can be removed.

IconData? get icon => null;
IconData? get icon => ZulipIcons.switch_account;

@override
Widget buildLeading(BuildContext context) => const SizedBox.shrink();

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should also remove this line, so we have 1 line between the two methods.

@override
String label(ZulipLocalizations zulipLocalizations) {
Expand Down
9 changes: 6 additions & 3 deletions lib/widgets/icons.dart
Original file line number Diff line number Diff line change
Expand Up @@ -117,14 +117,17 @@ abstract final class ZulipIcons {
/// The Zulip custom icon "star_filled".
static const IconData star_filled = IconData(0xf11f, fontFamily: "Zulip Icons");

/// The Zulip custom icon "switch_account".
static const IconData switch_account = IconData(0xf120, fontFamily: "Zulip Icons");

/// The Zulip custom icon "topic".
static const IconData topic = IconData(0xf120, fontFamily: "Zulip Icons");
static const IconData topic = IconData(0xf121, fontFamily: "Zulip Icons");

/// The Zulip custom icon "unmute".
static const IconData unmute = IconData(0xf121, fontFamily: "Zulip Icons");
static const IconData unmute = IconData(0xf122, fontFamily: "Zulip Icons");

/// The Zulip custom icon "user".
static const IconData user = IconData(0xf122, fontFamily: "Zulip Icons");
static const IconData user = IconData(0xf123, fontFamily: "Zulip Icons");

// END GENERATED ICON DATA
}
Expand Down
16 changes: 8 additions & 8 deletions pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1004,10 +1004,10 @@ packages:
dependency: transitive
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The change to this file doesn't look intentional. I think we don't want to update this as it is irrelevant to this commit.

description:
name: source_span
sha256: "53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c"
sha256: "254ee5351d6cb365c859e20ee823c3bb479bf4a293c22d17a9f1bf144ce86f7c"
url: "https://pub.dev"
source: hosted
version: "1.10.0"
version: "1.10.1"
sprintf:
dependency: transitive
description:
Expand Down Expand Up @@ -1092,26 +1092,26 @@ packages:
dependency: "direct dev"
description:
name: test
sha256: "713a8789d62f3233c46b4a90b174737b2c04cb6ae4500f2aa8b1be8f03f5e67f"
sha256: "43490fe4c0f5ecb898f3fa1cdcdad8d521d7f6ff17ebdc4e8cd32b2e99524a20"
url: "https://pub.dev"
source: hosted
version: "1.25.8"
version: "1.25.13"
test_api:
dependency: "direct dev"
description:
name: test_api
sha256: "664d3a9a64782fcdeb83ce9c6b39e78fd2971d4e37827b9b06c3aa1edc5e760c"
sha256: fb31f383e2ee25fbbfe06b40fe21e1e458d14080e3c67e7ba0acfde4df4e0bbd
url: "https://pub.dev"
source: hosted
version: "0.7.3"
version: "0.7.4"
test_core:
dependency: transitive
description:
name: test_core
sha256: "12391302411737c176b0b5d6491f466b0dd56d4763e347b6714efbaa74d7953d"
sha256: "84d17c3486c8dfdbe5e12a50c8ae176d15e2a771b96909a9442b40173649ccaa"
url: "https://pub.dev"
source: hosted
version: "0.6.5"
version: "0.6.8"
timing:
dependency: transitive
description:
Expand Down