element-hq / element-hq/compound

Make IconButton on compound-web fixed sizes

Open Beginner friendly
#409 0 comments 0 reactions 0 assignees View on GitHub
P-Web T-Defect
Dominant language
MDX
Stars
24
Forks
7
PR merge metrics
No merged PRs in 30d

Description

# Platform

P-Web

- ...

# Package version

- ...

# Description

IconButton calculates the size of the icon / padding from the total size given as the icon being 0.75 the size of the button, but that doesn't really work because of rounding because a 28px button ends up with a 21px icon where it should be 20px. In the EW room list icons, we actually override the padding to work around this.

We should just allow a fixed set of sizes, each with fixed icon / padding sizes. It should be (from aaron):

Global secondary buttons = 28px with 20px icon
Global primary buttons = 36px with 24px icon
Quick action buttons = 48px with 24px icon

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by locating IconButton in compound-web and inspect how its current total-size calculation derives the icon and padding. Implement the three fixed size combinations described in the issue, then verify that secondary, primary, and quick-action buttons use the stated dimensions.

Written by the indexing model from the issue text.

Assessment

Domain
design, frontend
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.