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

Add class, id and placeholder properties to Select #1187

Merged
merged 3 commits into from
May 6, 2020

Conversation

Stigjb
Copy link
Contributor

@Stigjb Stigjb commented May 5, 2020

Add three new properties to the Select component to enable more customization.

  • id is necessary to associate a <label> with the component.
  • classes lets users apply custom CSS classes to the component. The reason for
    choosing classes over class as the name of the property is to mirror yew-router's components: https://github.com/yewstack/yew/blob/0.15.0/yew-router/src/components/mod.rs#L37
  • placeholder allows users to choose a value for the disabled, empty option shown before making a selection. The original "↪" is kept as default.

@jstarry
Copy link
Member

jstarry commented May 6, 2020

Just one comment, otherwise looks good! thanks 😊

@jstarry jstarry merged commit 41643b6 into yewstack:master May 6, 2020
@Stigjb Stigjb deleted the select-component-attributes branch May 6, 2020 12:13
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