Skip to content

Standardize Buttons#408

Merged
dewabisma merged 10 commits intomainfrom
beast/icon-button
Mar 2, 2026
Merged

Standardize Buttons#408
dewabisma merged 10 commits intomainfrom
beast/icon-button

Conversation

@dewabisma
Copy link
Copy Markdown
Collaborator

@dewabisma dewabisma commented Mar 2, 2026

Changes

  • Standardize icon button
  • Update button style to be more accurate
  • Swap buttons in home, send, and receive screen/sheet

Screenshots

  • Home screen
image
  • Send
image
  • Receive
image

@dewabisma dewabisma requested a review from n13 March 2, 2026 08:39
enum ButtonVariant { transparent, primary, secondary, danger }

enum IconPlacement { leading, trailing }
enum IconPlacement { leading, trailing, top, below }
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

lets delete the "below" case if we're not using it...

seems a weird design anyway with text above the icon?!

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Yeah, it's not used and seems weird 👍 I just added that for the sake of balance, I guess we don't need it at all

Copy link
Copy Markdown
Collaborator

@n13 n13 left a comment

Choose a reason for hiding this comment

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

If below is not used, lets remove this case

Otherwise nice and clean

mainAxisAlignment: MainAxisAlignment.center,
spacing: 8,
children: [
if (iconPlacement == IconPlacement.top && icon != null) icon!,
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

this if can also go now.. since it's the only case possible

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

this part iconPlacement == IconPlacement.top

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Ohh yeah, we can delete it

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

But wait, icon can be null, so we have to make sure icon is not null

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Wew so dart has new syntax for exactly this case

Copy link
Copy Markdown
Collaborator

@n13 n13 left a comment

Choose a reason for hiding this comment

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

Nice!!

@dewabisma dewabisma merged commit 6bf77e1 into main Mar 2, 2026
1 check passed
@dewabisma dewabisma deleted the beast/icon-button branch March 2, 2026 16:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants