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: option "key" for datalist option inside input #2663

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

nmerget
Copy link
Member

@nmerget nmerget commented May 21, 2024

Proposed changes

closes #2642

Types of changes

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Refactoring (fix on existing components or architectural decisions)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation Update (if none of the other choices apply)

Further comments

@nmerget nmerget enabled auto-merge (squash) May 21, 2024 09:57
@github-actions github-actions bot added the 🏘components Changes inside components folder label May 21, 2024
Copy link
Contributor

🔭🐙🐈 Test this branch here: https://db-ui.github.io/mono/review/fix-datalist-input-option

@milan-w
Copy link

milan-w commented May 21, 2024

Danke, dass du das so schnell angegangen bist, Nico!
Das umgeht einen Teil des Problems. Aber das Hauptding ist: in einer datalist will man nicht zwingend innerhalb einer <option key="Option Bla"></option> auch einen Text haben. Dieser Text wird in bisschen kleinere Schrift unter dem "Option Bla" angezeigt. Aber z.B. mobile lenkt das nur von den eigentlichen Auswahlmöglichkeiten ab.

Also es bräuchte ein, wenn option === key:value =>

<option
    key={state._dataListId + '-option-' + option.key}
    value={option.key}
>
    {option.value}
</option>

wenn option === string =>

<option
    key={state._dataListId + '-option-' + option}
    value={option}
></option>

@github-actions github-actions bot added the 📺showcases Changes to 1-n showcases label May 21, 2024
@nmerget nmerget requested a review from bruno-sch as a code owner June 27, 2024 12:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏘components Changes inside components folder 📺showcases Changes to 1-n showcases
Projects
None yet
Development

Successfully merging this pull request may close these issues.

DBInput datalist element renders value as textNode
3 participants