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

Clean Input component & create NumberInput #1548

Merged
merged 15 commits into from
Oct 29, 2024
Merged

Conversation

robines
Copy link
Member

@robines robines commented Oct 25, 2024

With the way the Input component has evolved, it's not possible to use for file inputs. Nor is it possible to access the event object, which isn't great.

Converting values shouldn't be the concern of this component. It should be as simple as possible. For converting, wrapper components should be used. I've therefore created a NumberInput component, which should be easy to use.

Internally, the NumberInput component uses a text input, meaning we lose the browser-specific stepper buttons. This isn't really a big deal, we can add custom ones later if we wish.

This PR also fixes RecruitmentFormAdminPage by fixing the max_applications schema field and by using the new NumberInput component.

@robines robines self-assigned this Oct 25, 2024
@robines robines changed the title Fix input component Clean Input component & create NumberInput Oct 25, 2024
@robines robines added the frontend Task related to frontend. label Oct 25, 2024
Copy link
Contributor

@Snorre98 Snorre98 left a comment

Choose a reason for hiding this comment

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

5f4847f87edf4-3740580125

@robines robines merged commit 9d8031e into master Oct 29, 2024
5 checks passed
@robines robines deleted the robin/fix-input-component branch October 29, 2024 22:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
frontend Task related to frontend.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants