Skip to content
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

fix: add lemon switch story and fix spacing #28575

Closed
wants to merge 4 commits into from

Conversation

pauldambra
Copy link
Member

lemon switch only responds to the size prop in styling when bordered

  • adds a story
  • moves some of the styling so it applies to non-bordered too

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

This PR fixes the LemonSwitch component's size prop functionality and improves its documentation by ensuring size-specific styles apply consistently across all variants.

  • Moved size-specific gap and padding styles from .LemonSwitch--bordered to main .LemonSwitch block in /frontend/src/lib/lemon-ui/LemonSwitch/LemonSwitch.scss
  • Added comprehensive size comparison table in /frontend/src/lib/lemon-ui/LemonSwitch/LemonSwitch.stories.tsx showing xsmall/small/medium variants
  • Maintained min-height calculations specifically for bordered switches while making other size styles universal

2 file(s) reviewed, 1 comment(s)
Edit PR Review Bot Settings | Greptile

Copy link
Contributor

github-actions bot commented Feb 11, 2025

Size Change: 0 B

Total Size: 1.18 MB

ℹ️ View Unchanged
Filename Size
frontend/dist/toolbar.js 1.18 MB

compressed-size-action

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

1 snapshot changes in total. 0 added, 1 modified, 0 deleted:

  • chromium: 0 added, 1 modified, 0 deleted (diff for shard 1)
  • webkit: 0 added, 0 modified, 0 deleted

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

1 snapshot changes in total. 0 added, 1 modified, 0 deleted:

  • chromium: 0 added, 1 modified, 0 deleted (diff for shard 1)
  • webkit: 0 added, 0 modified, 0 deleted

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@pauldambra
Copy link
Member Author

superseded by #28579

@pauldambra pauldambra closed this Feb 12, 2025
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