This patch improves how components handle arrays that are updated in place. Svelte 5 encourages editing a $state array directly (rows.splice(...), ids.push(id)), and Svelte 3 and 4 code often does the same before reassigning (rows = rows). Several components now pick up those updates reliably.
- DataTable renders and sorts rows replaced in place (#5657).
- TreeView follows
nodes,selectedIds,expandedIds, andcheckedIdsedited in place. - MultiSelect follows
itemsandselectedIds. - DatePicker applies
disabledDates,enabledDates, andselectedDates. - CheckboxGroup and SelectableTileGroup follow
selected.
A new test contract checks every array prop this way on Svelte 3, 4, and 5, so these updates stay covered going forward.
This release also refines hover colors in Tabs, ListBox fields, Select, and NumberInput, draws inline CodeSnippet with layer tokens, and keeps an in-place Dropdown menu and side Tooltips inside the window.
Full Changelog: v0.114.0...v0.114.1
Changes without a breaking marker
- Tabs:
autoWidthis removed. Tabs already size to their label, so it did nothing, but passing it is now a type error. You can delete it, or usefullWidthto span the container (#5648). - TreeView keeps
checkedIdsin the order you passed when the checked set doesn't change, instead of reordering them to tree order. IncheckMode="deep", a cascade that adds ids still writes the prop, so bindcheckedIdsif you keep editing it in place (#5673).
Bug Fixes
- checkbox, tile: sync
selectedmutated in place to the group (7f56fd7) - code-snippet: draw the inline snippet with layer tokens (af0fe45)
- data-table: keep a row's field edit for refreshRow after a splice (b4fbbe1)
- data-table: render rows replaced in place (52fa6d4)
- data-table: sort rows added without reassigning
rows(af9652e) - date-picker: apply date arrays mutated in place (71e6eea)
- dropdown: keep an in-place menu inside the window (2b7a877), closes #5660
- list-box, select, number-input: hover fields with field-hover (67074e5)
- multi-select: list items added to
itemsin place (ff924e9) - multi-select: skip writing an unchanged
selectedIds(aba3263) - tabs: hover a contained tab with layer-accent-hover (7e06769)
- tabs: hover a vertical tab row with layer-accent-hover (81327e6)
- tabs: remove autoWidth, which has no effect (e9eb11e), closes #5648
- tooltip: keep side tooltips inside the window (fb02513), closes #5659
- tree-view: find nodes added to
nodesin place (525f204) - tree-view: keep reordered
checkedIdsas passed (c104269) - tree-view: sync id arrays mutated in place (c4b01a8)