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

chore(@clayui/form): add regular size to input storybook and make it … #5801

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

pat270
Copy link
Member

@pat270 pat270 commented Apr 9, 2024

@@ -12,7 +12,7 @@ export default {
argTypes: {
sizing: {
control: {type: 'select'},
options: ['lg', 'sm'],
options: ['lg', 'regular', 'sm'],
Copy link
Member

Choose a reason for hiding this comment

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

Maybe this could be an option in the API directly instead of just in the storybook? we can add regular and if it is passed, we leave it as the default value. What do you think?

Copy link
Member Author

Choose a reason for hiding this comment

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

I don't have a strong opinion on this. Do you think it will make it clearer for everyone to understand sizing if we add a regular value? I always thought the default was implied if the sizing attribute wasn't specified.

Copy link
Member

Choose a reason for hiding this comment

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

Well, I thought that too when sizing is not defined it would imply that it is using the regular value but I think that when you are defining the size it is strange for you to look at it and see that there is only lg and sm this is something else implicit than explicit so maybe we can just make it more explicit I think this is more aesthetic too.

Copy link
Member

Choose a reason for hiding this comment

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

I think adding regular may make sense, but if we want to add that we should probably be applying that consistently. For instance button currently has the options: null | xs | sm. @drakonux were you thinking the regular option should be applied everywhere?

Copy link
Member

Choose a reason for hiding this comment

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

Oh yes I agree with that, it makes a lot of sense to do this for all components.

Copy link
Member

Choose a reason for hiding this comment

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

@drakonux do you think it makes sense to make this change across all components?

Copy link
Member

@drakonux drakonux Apr 17, 2024

Choose a reason for hiding this comment

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

Yes @ethib137 . Let's make a decision and apply it consistently. We are using regular size for buttons and also for inputs in the Figma library as examples.

Our top priority is maintaining a consistent approach with Clay and ensuring one-to-one correspondence at all components.

Copy link
Member

Choose a reason for hiding this comment

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

Okay buttons and inputs sound good. Are there any other usages of regular that we should apply this too?

Copy link
Member

Choose a reason for hiding this comment

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

I went ahead and added it to the Input and Button. We have some other components with size as well:

  • Table
  • Sheet
  • LoadingIndicator
  • Modal
  • MultiSelect
  • Pagination
  • PaginationBar
  • Panel
  • Sticker

Does it make sense to add to these too? I would say yes since we are talk for consistency here but I will wait for other opinions to see if I'm missing something.

Copy link
Member

Choose a reason for hiding this comment

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

@drakonux what do you think?

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.

None yet

4 participants