Skip to content

Picker - enhance modalProps merging in useNewPickerProps #3719

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

Merged

Conversation

adids1221
Copy link
Contributor

Description

When passing customPickerProps with modalProps the default modal props are getting overridden.
This pr fixing the issue, by merging the default props with the user custom modal props to not override the animation unless the user passed the relevant props.

Snippet:

 <Picker
        placeholder="Favorite Language"
        value={language}
        onChange={item => setLanguage(item)}
        items={options}
        customPickerProps={{
          modalProps: {}
        }}
      />

Changelog

Picker merging default modal props with the user custom modal props.

Additional info

None

@nitzanyiz nitzanyiz assigned adids1221 and unassigned nitzanyiz May 8, 2025
@adids1221 adids1221 changed the title Picker enhance modalProps merging in useNewPickerProps Picker - enhance modalProps merging in useNewPickerProps May 8, 2025
@adids1221 adids1221 enabled auto-merge (squash) May 8, 2025 12:40
@adids1221 adids1221 merged commit 5f54bbb into master May 8, 2025
1 check passed
@adids1221 adids1221 deleted the fix/Picker_custom_modal_props_override_default_props branch May 8, 2025 12:42
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