ITADN

[Dropdown] support HTML5 <datalist> as a source

#3480Openazmeuk 创建于 2026-04-19
type/featstate/awaiting-triage
A
azmeukcommented
# Feature Request It would be useful if dropdowns could initialize from an `<input list="my-list">` paired with a `<datalist id="my-list">`, the standard HTML5 pattern for suggestion-style inputs. Additionnaly, it would be a bliss if it stayed in sync when the referenced `<datalist>` changes at runtime. This would allow dynamic suggestions using frameworks like htmx. ## Example ```html <input id="city" class="ui input" list="cities" placeholder="Pick a city…"> <datalist id="cities"> <option value="Paris"> <option value="Berlin"> <option value="Madrid"> </datalist> ``` ```js $("input[list]").dropdown(); ```
0 条评论