Skip to content

Add Switch disabled state - #529

Open
Half-Shot wants to merge 6 commits into
mainfrom
hs/switch-disabled
Open

Add Switch disabled state#529
Half-Shot wants to merge 6 commits into
mainfrom
hs/switch-disabled

Conversation

@Half-Shot

@Half-Shot Half-Shot commented Jul 10, 2026

Copy link
Copy Markdown
Member

This is a types-only change to Switch. A subtlety in React.HTMLAttributes meant that it didn't provide disabled and other useful params.

Because this now allows you to disable the Switch, the styles need updating.

@Half-Shot
Half-Shot requested a review from a team as a code owner July 10, 2026 11:27
@Half-Shot
Half-Shot requested review from MidhunSureshR and dbkr and removed request for a team July 10, 2026 11:27
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 10, 2026

Copy link
Copy Markdown

Deploying compound-web with  Cloudflare Pages  Cloudflare Pages

Latest commit: 551fe01
Status: ✅  Deploy successful!
Preview URL: https://2c028c00.compound-web.pages.dev
Branch Preview URL: https://hs-switch-disabled.compound-web.pages.dev

View logs

@Half-Shot
Half-Shot marked this pull request as draft July 10, 2026 11:34
@Half-Shot

Copy link
Copy Markdown
Member Author

Not ready yet, needs to actually look disabled.

@Half-Shot
Half-Shot marked this pull request as ready for review July 10, 2026 13:13
@Half-Shot
Half-Shot requested a review from a team as a code owner July 10, 2026 13:13

@americanrefugee americanrefugee left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

@Half-Shot Half-Shot changed the title Fix Switch prop types extension Add Switch disabled state Jul 10, 2026

@americanrefugee americanrefugee left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Assuming that the border is applied to the selected disabled button, this LGTM

@Half-Shot

Copy link
Copy Markdown
Member Author

Assuming that the border is applied to the selected disabled button, this LGTM

No it's reversed 🤦 Let's fix that.

@Half-Shot Half-Shot self-assigned this Jul 29, 2026
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.

3 participants