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(core/select): prevent list items to expand beyond screen width and add dropdown width properties #1669

Merged
merged 13 commits into from
Jan 30, 2025

Conversation

AndreasBerliner
Copy link
Collaborator

@AndreasBerliner AndreasBerliner commented Jan 28, 2025

💡 What is the current behavior?

  • For drop-down items with longer texts, the item width can be larger than the available space.
  • There is no way to set the width of the drop-down list.
  • There is no way to set the maximum width of the drop-down list.

GitHub Issue Number: #1570

🆕 What is the new behavior?

  • The default maximum width of drop-down list was set to 100%, which prevents the item width to be larger than the available space.
  • A property to set the width of the drop-down list was introduced.
  • A property to set the maximum width of the drop-down list was introduced.

🏁 Checklist

A pull request can only be merged if all of these conditions are met (where applicable):

  • 🦮 Accessibility (a11y) features were implemented
  • 🗺️ Internationalization (i18n) - no hard coded strings
  • 📲 Responsiveness - components handle viewport changes and content overflow gracefully
  • 📄 Documentation was reviewed/updated (pnpm run docs)
  • 🧪 Unit tests were added/updated and pass (pnpm test)
  • 📸 Visual regression tests were added/updated and pass (Guide)
  • 🧐 Static code analysis passes (pnpm lint)
  • 🏗️ Successful compilation (pnpm build, changes pushed)

👨‍💻 Help & support

Copy link

changeset-bot bot commented Jan 28, 2025

🦋 Changeset detected

Latest commit: 6dab386

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 5 packages
Name Type
@siemens/ix-angular Minor
@siemens/ix Minor
@siemens/ix-vue Minor
@siemens/ix-aggrid Patch
@siemens/ix-react Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@AndreasBerliner AndreasBerliner force-pushed the fix-ix-select-dropdown-width branch from ab369bb to ea16953 Compare January 28, 2025 09:51
@AndreasBerliner AndreasBerliner marked this pull request as ready for review January 28, 2025 12:17
@danielleroux
Copy link
Collaborator

@matthiashader
Copy link
Collaborator

On editable mode, this behavior looks a little strange, eventually we could consider adapting the width also based on the content?
image

@danielleroux danielleroux merged commit 6ce2929 into main Jan 30, 2025
15 checks passed
@danielleroux danielleroux deleted the fix-ix-select-dropdown-width branch January 30, 2025 09:34
@github-actions github-actions bot mentioned this pull request Jan 29, 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.

3 participants