@proyecto-viviana/solidaria 0.3.0 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_chunk/DragManager.js +627 -0
- package/dist/_chunk/DragManager.js.map +1 -0
- package/dist/_chunk/DragManager.jsx +627 -0
- package/dist/_chunk/DragManager.jsx.map +1 -0
- package/dist/_chunk/FocusScope.js +400 -0
- package/dist/_chunk/FocusScope.js.map +1 -0
- package/dist/_chunk/FocusScope.jsx +375 -0
- package/dist/_chunk/FocusScope.jsx.map +1 -0
- package/dist/_chunk/actiongroup.js +141 -0
- package/dist/_chunk/actiongroup.js.map +1 -0
- package/dist/_chunk/actiongroup.jsx +141 -0
- package/dist/_chunk/actiongroup.jsx.map +1 -0
- package/dist/_chunk/announce.js +207 -0
- package/dist/_chunk/announce.js.map +1 -0
- package/dist/_chunk/announce.jsx +207 -0
- package/dist/_chunk/announce.jsx.map +1 -0
- package/dist/_chunk/ariaHideOutside.js +122 -0
- package/dist/_chunk/ariaHideOutside.js.map +1 -0
- package/dist/_chunk/ariaHideOutside.jsx +122 -0
- package/dist/_chunk/ariaHideOutside.jsx.map +1 -0
- package/dist/_chunk/autocomplete.js +244 -0
- package/dist/_chunk/autocomplete.js.map +1 -0
- package/dist/_chunk/autocomplete.jsx +244 -0
- package/dist/_chunk/autocomplete.jsx.map +1 -0
- package/dist/_chunk/breadcrumbs.js +121 -0
- package/dist/_chunk/breadcrumbs.js.map +1 -0
- package/dist/_chunk/breadcrumbs.jsx +121 -0
- package/dist/_chunk/breadcrumbs.jsx.map +1 -0
- package/dist/_chunk/button.js +275 -0
- package/dist/_chunk/button.js.map +1 -0
- package/dist/_chunk/button.jsx +275 -0
- package/dist/_chunk/button.jsx.map +1 -0
- package/dist/_chunk/calendar.js +1037 -0
- package/dist/_chunk/calendar.js.map +1 -0
- package/dist/_chunk/calendar.jsx +1037 -0
- package/dist/_chunk/calendar.jsx.map +1 -0
- package/dist/_chunk/checkbox.js +235 -0
- package/dist/_chunk/checkbox.js.map +1 -0
- package/dist/_chunk/checkbox.jsx +235 -0
- package/dist/_chunk/checkbox.jsx.map +1 -0
- package/dist/_chunk/color.js +1458 -0
- package/dist/_chunk/color.js.map +1 -0
- package/dist/_chunk/color.jsx +1458 -0
- package/dist/_chunk/color.jsx.map +1 -0
- package/dist/_chunk/combobox.js +1062 -0
- package/dist/_chunk/combobox.js.map +1 -0
- package/dist/_chunk/combobox.jsx +1062 -0
- package/dist/_chunk/combobox.jsx.map +1 -0
- package/dist/_chunk/constants.js +19 -0
- package/dist/_chunk/constants.js.map +1 -0
- package/dist/_chunk/constants.jsx +19 -0
- package/dist/_chunk/constants.jsx.map +1 -0
- package/dist/_chunk/createCollator.js +61 -0
- package/dist/_chunk/createCollator.js.map +1 -0
- package/dist/_chunk/createCollator.jsx +61 -0
- package/dist/_chunk/createCollator.jsx.map +1 -0
- package/dist/_chunk/createCollectionRowInteraction.js +133 -0
- package/dist/_chunk/createCollectionRowInteraction.js.map +1 -0
- package/dist/_chunk/createCollectionRowInteraction.jsx +133 -0
- package/dist/_chunk/createCollectionRowInteraction.jsx.map +1 -0
- package/dist/_chunk/createField.js +55 -0
- package/dist/_chunk/createField.js.map +1 -0
- package/dist/_chunk/createField.jsx +55 -0
- package/dist/_chunk/createField.jsx.map +1 -0
- package/dist/_chunk/createFocus.js +105 -0
- package/dist/_chunk/createFocus.js.map +1 -0
- package/dist/_chunk/createFocus.jsx +105 -0
- package/dist/_chunk/createFocus.jsx.map +1 -0
- package/dist/_chunk/createFocusRing.js +54 -0
- package/dist/_chunk/createFocusRing.js.map +1 -0
- package/dist/_chunk/createFocusRing.jsx +54 -0
- package/dist/_chunk/createFocusRing.jsx.map +1 -0
- package/dist/_chunk/createFocusWithin.js +120 -0
- package/dist/_chunk/createFocusWithin.js.map +1 -0
- package/dist/_chunk/createFocusWithin.jsx +120 -0
- package/dist/_chunk/createFocusWithin.jsx.map +1 -0
- package/dist/_chunk/createFocusable.js +131 -0
- package/dist/_chunk/createFocusable.js.map +1 -0
- package/dist/_chunk/createFocusable.jsx +131 -0
- package/dist/_chunk/createFocusable.jsx.map +1 -0
- package/dist/_chunk/createFormReset.js +39 -0
- package/dist/_chunk/createFormReset.js.map +1 -0
- package/dist/_chunk/createFormReset.jsx +39 -0
- package/dist/_chunk/createFormReset.jsx.map +1 -0
- package/dist/_chunk/createFormValidation.js +135 -0
- package/dist/_chunk/createFormValidation.js.map +1 -0
- package/dist/_chunk/createFormValidation.jsx +135 -0
- package/dist/_chunk/createFormValidation.jsx.map +1 -0
- package/dist/_chunk/createHover.js +131 -0
- package/dist/_chunk/createHover.js.map +1 -0
- package/dist/_chunk/createHover.jsx +131 -0
- package/dist/_chunk/createHover.jsx.map +1 -0
- package/dist/_chunk/createInteractionModality.js +268 -0
- package/dist/_chunk/createInteractionModality.js.map +1 -0
- package/dist/_chunk/createInteractionModality.jsx +268 -0
- package/dist/_chunk/createInteractionModality.jsx.map +1 -0
- package/dist/_chunk/createLabel.js +47 -0
- package/dist/_chunk/createLabel.js.map +1 -0
- package/dist/_chunk/createLabel.jsx +47 -0
- package/dist/_chunk/createLabel.jsx.map +1 -0
- package/dist/_chunk/createLabels.js +32 -0
- package/dist/_chunk/createLabels.js.map +1 -0
- package/dist/_chunk/createLabels.jsx +32 -0
- package/dist/_chunk/createLabels.jsx.map +1 -0
- package/dist/_chunk/createLandmark.js +198 -0
- package/dist/_chunk/createLandmark.js.map +1 -0
- package/dist/_chunk/createLandmark.jsx +198 -0
- package/dist/_chunk/createLandmark.jsx.map +1 -0
- package/dist/_chunk/createOverlay.js +327 -0
- package/dist/_chunk/createOverlay.js.map +1 -0
- package/dist/_chunk/createOverlay.jsx +327 -0
- package/dist/_chunk/createOverlay.jsx.map +1 -0
- package/dist/_chunk/createPress.js +526 -0
- package/dist/_chunk/createPress.js.map +1 -0
- package/dist/_chunk/createPress.jsx +526 -0
- package/dist/_chunk/createPress.jsx.map +1 -0
- package/dist/_chunk/createProgressBar.js +82 -0
- package/dist/_chunk/createProgressBar.js.map +1 -0
- package/dist/_chunk/createProgressBar.jsx +82 -0
- package/dist/_chunk/createProgressBar.jsx.map +1 -0
- package/dist/_chunk/createSelectableItem.js +302 -0
- package/dist/_chunk/createSelectableItem.js.map +1 -0
- package/dist/_chunk/createSelectableItem.jsx +302 -0
- package/dist/_chunk/createSelectableItem.jsx.map +1 -0
- package/dist/_chunk/createStringFormatter.js +61 -0
- package/dist/_chunk/createStringFormatter.js.map +1 -0
- package/dist/_chunk/createStringFormatter.jsx +61 -0
- package/dist/_chunk/createStringFormatter.jsx.map +1 -0
- package/dist/_chunk/createToggle.js +159 -0
- package/dist/_chunk/createToggle.js.map +1 -0
- package/dist/_chunk/createToggle.jsx +159 -0
- package/dist/_chunk/createToggle.jsx.map +1 -0
- package/dist/_chunk/createTypeSelect.js +125 -0
- package/dist/_chunk/createTypeSelect.js.map +1 -0
- package/dist/_chunk/createTypeSelect.jsx +125 -0
- package/dist/_chunk/createTypeSelect.jsx.map +1 -0
- package/dist/_chunk/datepicker.js +1706 -0
- package/dist/_chunk/datepicker.js.map +1 -0
- package/dist/_chunk/datepicker.jsx +1706 -0
- package/dist/_chunk/datepicker.jsx.map +1 -0
- package/dist/_chunk/dialog.js +62 -0
- package/dist/_chunk/dialog.js.map +1 -0
- package/dist/_chunk/dialog.jsx +62 -0
- package/dist/_chunk/dialog.jsx.map +1 -0
- package/dist/_chunk/disclosure.js +185 -0
- package/dist/_chunk/disclosure.js.map +1 -0
- package/dist/_chunk/disclosure.jsx +185 -0
- package/dist/_chunk/disclosure.jsx.map +1 -0
- package/dist/_chunk/dnd.js +2395 -0
- package/dist/_chunk/dnd.js.map +1 -0
- package/dist/_chunk/dnd.jsx +2395 -0
- package/dist/_chunk/dnd.jsx.map +1 -0
- package/dist/_chunk/env.js +87 -0
- package/dist/_chunk/env.js.map +1 -0
- package/dist/_chunk/env.jsx +87 -0
- package/dist/_chunk/env.jsx.map +1 -0
- package/dist/_chunk/filterDOMProps.js +82 -0
- package/dist/_chunk/filterDOMProps.js.map +1 -0
- package/dist/_chunk/filterDOMProps.jsx +82 -0
- package/dist/_chunk/filterDOMProps.jsx.map +1 -0
- package/dist/_chunk/focus.js +399 -0
- package/dist/_chunk/focus.js.map +1 -0
- package/dist/_chunk/focus.jsx +399 -0
- package/dist/_chunk/focus.jsx.map +1 -0
- package/dist/_chunk/focus2.js +631 -0
- package/dist/_chunk/focus2.js.map +1 -0
- package/dist/_chunk/focus2.jsx +631 -0
- package/dist/_chunk/focus2.jsx.map +1 -0
- package/dist/_chunk/grid.js +623 -0
- package/dist/_chunk/grid.js.map +1 -0
- package/dist/_chunk/grid.jsx +623 -0
- package/dist/_chunk/grid.jsx.map +1 -0
- package/dist/_chunk/gridlist.js +369 -0
- package/dist/_chunk/gridlist.js.map +1 -0
- package/dist/_chunk/gridlist.jsx +369 -0
- package/dist/_chunk/gridlist.jsx.map +1 -0
- package/dist/_chunk/i18n.js +199 -0
- package/dist/_chunk/i18n.js.map +1 -0
- package/dist/_chunk/i18n.jsx +199 -0
- package/dist/_chunk/i18n.jsx.map +1 -0
- package/dist/_chunk/interactions.js +331 -0
- package/dist/_chunk/interactions.js.map +1 -0
- package/dist/_chunk/interactions.jsx +325 -0
- package/dist/_chunk/interactions.jsx.map +1 -0
- package/dist/_chunk/link.js +97 -0
- package/dist/_chunk/link.js.map +1 -0
- package/dist/_chunk/link.jsx +97 -0
- package/dist/_chunk/link.jsx.map +1 -0
- package/dist/_chunk/listbox.js +356 -0
- package/dist/_chunk/listbox.js.map +1 -0
- package/dist/_chunk/listbox.jsx +356 -0
- package/dist/_chunk/listbox.jsx.map +1 -0
- package/dist/_chunk/locale.js +173 -0
- package/dist/_chunk/locale.js.map +1 -0
- package/dist/_chunk/locale.jsx +167 -0
- package/dist/_chunk/locale.jsx.map +1 -0
- package/dist/_chunk/menu.js +519 -0
- package/dist/_chunk/menu.js.map +1 -0
- package/dist/_chunk/menu.jsx +519 -0
- package/dist/_chunk/menu.jsx.map +1 -0
- package/dist/_chunk/meter.js +33 -0
- package/dist/_chunk/meter.js.map +1 -0
- package/dist/_chunk/meter.jsx +33 -0
- package/dist/_chunk/meter.jsx.map +1 -0
- package/dist/_chunk/numberfield.js +259 -0
- package/dist/_chunk/numberfield.js.map +1 -0
- package/dist/_chunk/numberfield.jsx +259 -0
- package/dist/_chunk/numberfield.jsx.map +1 -0
- package/dist/_chunk/overlays.js +186 -0
- package/dist/_chunk/overlays.js.map +1 -0
- package/dist/_chunk/overlays.jsx +162 -0
- package/dist/_chunk/overlays.jsx.map +1 -0
- package/dist/_chunk/popover.js +574 -0
- package/dist/_chunk/popover.js.map +1 -0
- package/dist/_chunk/popover.jsx +574 -0
- package/dist/_chunk/popover.jsx.map +1 -0
- package/dist/_chunk/radio.js +320 -0
- package/dist/_chunk/radio.js.map +1 -0
- package/dist/_chunk/radio.jsx +320 -0
- package/dist/_chunk/radio.jsx.map +1 -0
- package/dist/_chunk/reactivity.js +21 -0
- package/dist/_chunk/reactivity.js.map +1 -0
- package/dist/_chunk/reactivity.jsx +21 -0
- package/dist/_chunk/reactivity.jsx.map +1 -0
- package/dist/_chunk/searchfield.js +210 -0
- package/dist/_chunk/searchfield.js.map +1 -0
- package/dist/_chunk/searchfield.jsx +210 -0
- package/dist/_chunk/searchfield.jsx.map +1 -0
- package/dist/_chunk/select.js +406 -0
- package/dist/_chunk/select.js.map +1 -0
- package/dist/_chunk/select.jsx +397 -0
- package/dist/_chunk/select.jsx.map +1 -0
- package/dist/_chunk/selection.js +666 -0
- package/dist/_chunk/selection.js.map +1 -0
- package/dist/_chunk/selection.jsx +666 -0
- package/dist/_chunk/selection.jsx.map +1 -0
- package/dist/_chunk/separator.js +29 -0
- package/dist/_chunk/separator.js.map +1 -0
- package/dist/_chunk/separator.jsx +29 -0
- package/dist/_chunk/separator.jsx.map +1 -0
- package/dist/_chunk/slider.js +256 -0
- package/dist/_chunk/slider.js.map +1 -0
- package/dist/_chunk/slider.jsx +256 -0
- package/dist/_chunk/slider.jsx.map +1 -0
- package/dist/_chunk/spinbutton.js +153 -0
- package/dist/_chunk/spinbutton.js.map +1 -0
- package/dist/_chunk/spinbutton.jsx +153 -0
- package/dist/_chunk/spinbutton.jsx.map +1 -0
- package/dist/_chunk/steplist.js +66 -0
- package/dist/_chunk/steplist.js.map +1 -0
- package/dist/_chunk/steplist.jsx +66 -0
- package/dist/_chunk/steplist.jsx.map +1 -0
- package/dist/_chunk/switch.js +34 -0
- package/dist/_chunk/switch.js.map +1 -0
- package/dist/_chunk/switch.jsx +34 -0
- package/dist/_chunk/switch.jsx.map +1 -0
- package/dist/_chunk/table.js +1088 -0
- package/dist/_chunk/table.js.map +1 -0
- package/dist/_chunk/table.jsx +1088 -0
- package/dist/_chunk/table.jsx.map +1 -0
- package/dist/_chunk/tabs.js +263 -0
- package/dist/_chunk/tabs.js.map +1 -0
- package/dist/_chunk/tabs.jsx +263 -0
- package/dist/_chunk/tabs.jsx.map +1 -0
- package/dist/_chunk/tag.js +322 -0
- package/dist/_chunk/tag.js.map +1 -0
- package/dist/_chunk/tag.jsx +322 -0
- package/dist/_chunk/tag.jsx.map +1 -0
- package/dist/_chunk/textfield.js +110 -0
- package/dist/_chunk/textfield.js.map +1 -0
- package/dist/_chunk/textfield.jsx +110 -0
- package/dist/_chunk/textfield.jsx.map +1 -0
- package/dist/_chunk/toast.js +250 -0
- package/dist/_chunk/toast.js.map +1 -0
- package/dist/_chunk/toast.jsx +250 -0
- package/dist/_chunk/toast.jsx.map +1 -0
- package/dist/_chunk/toolbar.js +226 -0
- package/dist/_chunk/toolbar.js.map +1 -0
- package/dist/_chunk/toolbar.jsx +226 -0
- package/dist/_chunk/toolbar.jsx.map +1 -0
- package/dist/_chunk/tooltip.js +185 -0
- package/dist/_chunk/tooltip.js.map +1 -0
- package/dist/_chunk/tooltip.jsx +185 -0
- package/dist/_chunk/tooltip.jsx.map +1 -0
- package/dist/_chunk/tree.js +452 -0
- package/dist/_chunk/tree.js.map +1 -0
- package/dist/_chunk/tree.jsx +452 -0
- package/dist/_chunk/tree.jsx.map +1 -0
- package/dist/_chunk/utils.js +705 -0
- package/dist/_chunk/utils.js.map +1 -0
- package/dist/_chunk/utils.jsx +705 -0
- package/dist/_chunk/utils.jsx.map +1 -0
- package/dist/_chunk/visually-hidden.js +93 -0
- package/dist/_chunk/visually-hidden.js.map +1 -0
- package/dist/_chunk/visually-hidden.jsx +93 -0
- package/dist/_chunk/visually-hidden.jsx.map +1 -0
- package/dist/actiongroup/createActionGroup.d.ts.map +1 -1
- package/dist/actiongroup/index.js +2 -0
- package/dist/actiongroup/index.jsx +2 -0
- package/dist/autocomplete/createAutocomplete.d.ts +12 -7
- package/dist/autocomplete/createAutocomplete.d.ts.map +1 -1
- package/dist/autocomplete/index.js +2 -0
- package/dist/autocomplete/index.jsx +2 -0
- package/dist/breadcrumbs/createBreadcrumbs.d.ts.map +1 -1
- package/dist/breadcrumbs/index.js +2 -0
- package/dist/breadcrumbs/index.jsx +2 -0
- package/dist/button/createToggleButtonGroup.d.ts.map +1 -1
- package/dist/button/index.js +2 -0
- package/dist/button/index.jsx +2 -0
- package/dist/calendar/createCalendar.d.ts.map +1 -1
- package/dist/calendar/createCalendarCell.d.ts.map +1 -1
- package/dist/calendar/createCalendarGrid.d.ts.map +1 -1
- package/dist/calendar/createCalendarMonthPicker.d.ts +41 -0
- package/dist/calendar/createCalendarMonthPicker.d.ts.map +1 -0
- package/dist/calendar/createCalendarYearPicker.d.ts +49 -0
- package/dist/calendar/createCalendarYearPicker.d.ts.map +1 -0
- package/dist/calendar/createRangeCalendar.d.ts.map +1 -1
- package/dist/calendar/createRangeCalendarCell.d.ts.map +1 -1
- package/dist/calendar/index.d.ts +2 -0
- package/dist/calendar/index.d.ts.map +1 -1
- package/dist/calendar/index.js +2 -0
- package/dist/calendar/index.jsx +2 -0
- package/dist/calendar/intl/index.d.ts +1 -1
- package/dist/calendar/intl/index.d.ts.map +1 -1
- package/dist/calendar/utils.d.ts +4 -0
- package/dist/calendar/utils.d.ts.map +1 -1
- package/dist/checkbox/createCheckbox.d.ts +4 -0
- package/dist/checkbox/createCheckbox.d.ts.map +1 -1
- package/dist/checkbox/createCheckboxGroupItem.d.ts.map +1 -1
- package/dist/checkbox/index.js +2 -0
- package/dist/checkbox/index.jsx +2 -0
- package/dist/collections/index.js +160 -0
- package/dist/collections/index.js.map +1 -0
- package/dist/collections/index.jsx +160 -0
- package/dist/collections/index.jsx.map +1 -0
- package/dist/color/createColorArea.d.ts.map +1 -1
- package/dist/color/createColorField.d.ts.map +1 -1
- package/dist/color/createColorSlider.d.ts.map +1 -1
- package/dist/color/createColorSwatch.d.ts.map +1 -1
- package/dist/color/createColorWheel.d.ts.map +1 -1
- package/dist/color/index.js +2 -0
- package/dist/color/index.jsx +2 -0
- package/dist/color/intl/index.d.ts +30 -0
- package/dist/color/intl/index.d.ts.map +1 -0
- package/dist/combobox/createComboBox.d.ts.map +1 -1
- package/dist/combobox/index.js +2 -0
- package/dist/combobox/index.jsx +2 -0
- package/dist/combobox/intl/generated-locales.d.ts +16 -0
- package/dist/combobox/intl/generated-locales.d.ts.map +1 -0
- package/dist/combobox/intl/index.d.ts +2 -2
- package/dist/combobox/intl/index.d.ts.map +1 -1
- package/dist/datepicker/createDateField.d.ts +45 -23
- package/dist/datepicker/createDateField.d.ts.map +1 -1
- package/dist/datepicker/createDatePicker.d.ts +34 -6
- package/dist/datepicker/createDatePicker.d.ts.map +1 -1
- package/dist/datepicker/createDatePickerGroup.d.ts +13 -13
- package/dist/datepicker/createDatePickerGroup.d.ts.map +1 -1
- package/dist/datepicker/createDateRangePicker.d.ts +55 -7
- package/dist/datepicker/createDateRangePicker.d.ts.map +1 -1
- package/dist/datepicker/createDateSegment.d.ts +6 -15
- package/dist/datepicker/createDateSegment.d.ts.map +1 -1
- package/dist/datepicker/createDisplayNames.d.ts +17 -0
- package/dist/datepicker/createDisplayNames.d.ts.map +1 -0
- package/dist/datepicker/createTimeField.d.ts +12 -49
- package/dist/datepicker/createTimeField.d.ts.map +1 -1
- package/dist/datepicker/index.d.ts +3 -3
- package/dist/datepicker/index.d.ts.map +1 -1
- package/dist/datepicker/index.js +2 -0
- package/dist/datepicker/index.jsx +2 -0
- package/dist/datepicker/intl.d.ts +12 -0
- package/dist/datepicker/intl.d.ts.map +1 -0
- package/dist/dialog/index.js +2 -0
- package/dist/dialog/index.jsx +2 -0
- package/dist/disclosure/index.js +2 -0
- package/dist/disclosure/index.jsx +2 -0
- package/dist/dnd/DragManager.d.ts +86 -0
- package/dist/dnd/DragManager.d.ts.map +1 -0
- package/dist/dnd/DropTargetKeyboardNavigation.d.ts +42 -0
- package/dist/dnd/DropTargetKeyboardNavigation.d.ts.map +1 -0
- package/dist/dnd/createDrag.d.ts.map +1 -1
- package/dist/dnd/createDraggableCollection.d.ts.map +1 -1
- package/dist/dnd/createDraggableItem.d.ts +12 -7
- package/dist/dnd/createDraggableItem.d.ts.map +1 -1
- package/dist/dnd/createDroppableCollection.d.ts +7 -15
- package/dist/dnd/createDroppableCollection.d.ts.map +1 -1
- package/dist/dnd/index.d.ts +5 -1
- package/dist/dnd/index.d.ts.map +1 -1
- package/dist/dnd/index.js +3 -0
- package/dist/dnd/index.jsx +3 -0
- package/dist/dnd/intl/index.d.ts +39 -0
- package/dist/dnd/intl/index.d.ts.map +1 -0
- package/dist/dnd/utils.d.ts +7 -2
- package/dist/dnd/utils.d.ts.map +1 -1
- package/dist/focus/FocusScope.d.ts +7 -0
- package/dist/focus/FocusScope.d.ts.map +1 -1
- package/dist/focus/index.d.ts +2 -1
- package/dist/focus/index.d.ts.map +1 -1
- package/dist/focus/index.js +3 -0
- package/dist/focus/index.jsx +3 -0
- package/dist/focus/virtualFocus.d.ts +26 -0
- package/dist/focus/virtualFocus.d.ts.map +1 -0
- package/dist/form/createFormValidation.d.ts.map +1 -1
- package/dist/form/index.js +3 -0
- package/dist/form/index.jsx +3 -0
- package/dist/grid/index.js +2 -0
- package/dist/grid/index.jsx +2 -0
- package/dist/gridlist/createGridList.d.ts +7 -1
- package/dist/gridlist/createGridList.d.ts.map +1 -1
- package/dist/gridlist/createGridListItem.d.ts +1 -1
- package/dist/gridlist/createGridListItem.d.ts.map +1 -1
- package/dist/gridlist/createGridListSection.d.ts +15 -0
- package/dist/gridlist/createGridListSection.d.ts.map +1 -0
- package/dist/gridlist/index.d.ts +2 -1
- package/dist/gridlist/index.d.ts.map +1 -1
- package/dist/gridlist/index.js +2 -0
- package/dist/gridlist/index.jsx +2 -0
- package/dist/gridlist/types.d.ts +50 -0
- package/dist/gridlist/types.d.ts.map +1 -1
- package/dist/i18n/index.js +5 -0
- package/dist/i18n/index.jsx +5 -0
- package/dist/index.d.ts +10 -6
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +77 -18311
- package/dist/index.jsx +77 -18242
- package/dist/interactions/FocusableProvider.d.ts.map +1 -1
- package/dist/interactions/PressEvent.d.ts +11 -0
- package/dist/interactions/PressEvent.d.ts.map +1 -1
- package/dist/interactions/createFocus.d.ts.map +1 -1
- package/dist/interactions/createFocusWithin.d.ts.map +1 -1
- package/dist/interactions/createInteractionModality.d.ts +0 -1
- package/dist/interactions/createInteractionModality.d.ts.map +1 -1
- package/dist/interactions/createKeyboard.d.ts.map +1 -1
- package/dist/interactions/createPress.d.ts.map +1 -1
- package/dist/interactions/index.js +9 -0
- package/dist/interactions/index.jsx +9 -0
- package/dist/label/createLabels.d.ts.map +1 -1
- package/dist/label/index.js +4 -0
- package/dist/label/index.jsx +4 -0
- package/dist/landmark/index.js +2 -0
- package/dist/landmark/index.jsx +2 -0
- package/dist/link/index.js +2 -0
- package/dist/link/index.jsx +2 -0
- package/dist/listbox/createListBox.d.ts +37 -0
- package/dist/listbox/createListBox.d.ts.map +1 -1
- package/dist/listbox/createOption.d.ts +7 -1
- package/dist/listbox/createOption.d.ts.map +1 -1
- package/dist/listbox/index.js +2 -0
- package/dist/listbox/index.jsx +2 -0
- package/dist/live-announcer/index.js +2 -0
- package/dist/live-announcer/index.jsx +2 -0
- package/dist/menu/createMenu.d.ts +7 -4
- package/dist/menu/createMenu.d.ts.map +1 -1
- package/dist/menu/createMenuItem.d.ts +9 -1
- package/dist/menu/createMenuItem.d.ts.map +1 -1
- package/dist/menu/index.js +2 -0
- package/dist/menu/index.jsx +2 -0
- package/dist/meter/index.js +2 -0
- package/dist/meter/index.jsx +2 -0
- package/dist/numberfield/createNumberField.d.ts.map +1 -1
- package/dist/numberfield/index.js +2 -0
- package/dist/numberfield/index.jsx +2 -0
- package/dist/overlays/index.js +4 -0
- package/dist/overlays/index.jsx +4 -0
- package/dist/popover/calculatePosition.d.ts +2 -0
- package/dist/popover/calculatePosition.d.ts.map +1 -1
- package/dist/popover/createOverlayPosition.d.ts +8 -0
- package/dist/popover/createOverlayPosition.d.ts.map +1 -1
- package/dist/popover/index.js +2 -0
- package/dist/popover/index.jsx +2 -0
- package/dist/progress/index.js +2 -0
- package/dist/progress/index.jsx +2 -0
- package/dist/radio/createRadio.d.ts +2 -0
- package/dist/radio/createRadio.d.ts.map +1 -1
- package/dist/radio/index.js +2 -0
- package/dist/radio/index.jsx +2 -0
- package/dist/searchfield/index.js +2 -0
- package/dist/searchfield/index.jsx +2 -0
- package/dist/select/createSelect.d.ts +2 -0
- package/dist/select/createSelect.d.ts.map +1 -1
- package/dist/select/index.js +2 -0
- package/dist/select/index.jsx +2 -0
- package/dist/selection/DOMLayoutDelegate.d.ts +58 -0
- package/dist/selection/DOMLayoutDelegate.d.ts.map +1 -0
- package/dist/selection/ListKeyboardDelegate.d.ts +95 -0
- package/dist/selection/ListKeyboardDelegate.d.ts.map +1 -0
- package/dist/selection/constants.d.ts +15 -0
- package/dist/selection/constants.d.ts.map +1 -0
- package/dist/selection/createCollectionRowInteraction.d.ts +13 -0
- package/dist/selection/createCollectionRowInteraction.d.ts.map +1 -0
- package/dist/selection/createScrollIntoViewOnFocus.d.ts +31 -0
- package/dist/selection/createScrollIntoViewOnFocus.d.ts.map +1 -0
- package/dist/selection/createSelectableCollection.d.ts +69 -0
- package/dist/selection/createSelectableCollection.d.ts.map +1 -0
- package/dist/selection/createSelectableItem.d.ts +154 -0
- package/dist/selection/createSelectableItem.d.ts.map +1 -0
- package/dist/selection/createSelectableList.d.ts +43 -0
- package/dist/selection/createSelectableList.d.ts.map +1 -0
- package/dist/selection/createTypeSelect.d.ts.map +1 -1
- package/dist/selection/index.d.ts +9 -0
- package/dist/selection/index.d.ts.map +1 -1
- package/dist/selection/index.js +5 -0
- package/dist/selection/index.jsx +5 -0
- package/dist/selection/selectItem.d.ts +29 -0
- package/dist/selection/selectItem.d.ts.map +1 -0
- package/dist/selection/utils.d.ts +40 -0
- package/dist/selection/utils.d.ts.map +1 -0
- package/dist/separator/index.js +2 -0
- package/dist/separator/index.jsx +2 -0
- package/dist/slider/createSlider.d.ts.map +1 -1
- package/dist/slider/index.js +2 -0
- package/dist/slider/index.jsx +2 -0
- package/dist/spinbutton/createSpinButton.d.ts +41 -0
- package/dist/spinbutton/createSpinButton.d.ts.map +1 -0
- package/dist/spinbutton/index.d.ts +3 -0
- package/dist/spinbutton/index.d.ts.map +1 -0
- package/dist/spinbutton/index.js +2 -0
- package/dist/spinbutton/index.jsx +2 -0
- package/dist/spinbutton/intl.d.ts +5 -0
- package/dist/spinbutton/intl.d.ts.map +1 -0
- package/dist/ssr/index.d.ts +17 -0
- package/dist/ssr/index.d.ts.map +1 -1
- package/dist/ssr/index.js +299 -0
- package/dist/ssr/index.js.map +1 -0
- package/dist/ssr/index.jsx +292 -0
- package/dist/ssr/index.jsx.map +1 -0
- package/dist/steplist/index.js +2 -0
- package/dist/steplist/index.jsx +2 -0
- package/dist/switch/createSwitch.d.ts +4 -0
- package/dist/switch/createSwitch.d.ts.map +1 -1
- package/dist/switch/index.js +2 -0
- package/dist/switch/index.jsx +2 -0
- package/dist/table/createTable.d.ts.map +1 -1
- package/dist/table/createTableColumnHeader.d.ts.map +1 -1
- package/dist/table/createTableRow.d.ts +1 -1
- package/dist/table/createTableRow.d.ts.map +1 -1
- package/dist/table/createTableSelectAllCheckbox.d.ts.map +1 -1
- package/dist/table/createTableSelectionCheckbox.d.ts.map +1 -1
- package/dist/table/index.js +2 -0
- package/dist/table/index.jsx +2 -0
- package/dist/table/types.d.ts +35 -1
- package/dist/table/types.d.ts.map +1 -1
- package/dist/table/utils.d.ts +15 -0
- package/dist/table/utils.d.ts.map +1 -0
- package/dist/tabs/createTabs.d.ts +5 -3
- package/dist/tabs/createTabs.d.ts.map +1 -1
- package/dist/tabs/index.js +2 -0
- package/dist/tabs/index.jsx +2 -0
- package/dist/tag/createTag.d.ts +2 -0
- package/dist/tag/createTag.d.ts.map +1 -1
- package/dist/tag/createTagGroup.d.ts +7 -0
- package/dist/tag/createTagGroup.d.ts.map +1 -1
- package/dist/tag/index.js +2 -0
- package/dist/tag/index.jsx +2 -0
- package/dist/textfield/index.js +2 -0
- package/dist/textfield/index.jsx +2 -0
- package/dist/toast/createToast.d.ts.map +1 -1
- package/dist/toast/index.js +2 -0
- package/dist/toast/index.jsx +2 -0
- package/dist/toggle/createToggle.d.ts +4 -0
- package/dist/toggle/createToggle.d.ts.map +1 -1
- package/dist/toggle/index.js +3 -0
- package/dist/toggle/index.jsx +3 -0
- package/dist/toolbar/createToolbar.d.ts +1 -1
- package/dist/toolbar/createToolbar.d.ts.map +1 -1
- package/dist/toolbar/index.js +2 -0
- package/dist/toolbar/index.jsx +2 -0
- package/dist/tooltip/index.js +2 -0
- package/dist/tooltip/index.jsx +2 -0
- package/dist/tree/createTree.d.ts +5 -1
- package/dist/tree/createTree.d.ts.map +1 -1
- package/dist/tree/createTreeItem.d.ts +1 -1
- package/dist/tree/createTreeItem.d.ts.map +1 -1
- package/dist/tree/createTreeSelectionCheckbox.d.ts.map +1 -1
- package/dist/tree/index.js +2 -0
- package/dist/tree/index.jsx +2 -0
- package/dist/tree/types.d.ts +10 -0
- package/dist/tree/types.d.ts.map +1 -1
- package/dist/utils/animation.d.ts +60 -0
- package/dist/utils/animation.d.ts.map +1 -0
- package/dist/utils/dom.d.ts +49 -2
- package/dist/utils/dom.d.ts.map +1 -1
- package/dist/utils/index.d.ts +4 -1
- package/dist/utils/index.d.ts.map +1 -1
- package/dist/utils/index.js +6 -0
- package/dist/utils/index.jsx +6 -0
- package/dist/utils/keyboard.d.ts +17 -0
- package/dist/utils/keyboard.d.ts.map +1 -0
- package/dist/utils/mergeProps.d.ts.map +1 -1
- package/dist/utils/scrollIntoView.d.ts +30 -0
- package/dist/utils/scrollIntoView.d.ts.map +1 -0
- package/dist/visually-hidden/index.js +2 -0
- package/dist/visually-hidden/index.jsx +2 -0
- package/package.json +304 -3
- package/src/actiongroup/createActionGroup.ts +26 -109
- package/src/autocomplete/createAutocomplete.ts +202 -35
- package/src/breadcrumbs/createBreadcrumbs.ts +12 -4
- package/src/button/createToggleButtonGroup.ts +19 -14
- package/src/calendar/createCalendar.ts +5 -4
- package/src/calendar/createCalendarCell.ts +36 -5
- package/src/calendar/createCalendarGrid.ts +47 -12
- package/src/calendar/createCalendarMonthPicker.ts +105 -0
- package/src/calendar/createCalendarYearPicker.ts +144 -0
- package/src/calendar/createRangeCalendar.ts +27 -15
- package/src/calendar/createRangeCalendarCell.ts +17 -3
- package/src/calendar/index.ts +17 -0
- package/src/calendar/intl/index.ts +8 -0
- package/src/calendar/utils.ts +4 -0
- package/src/checkbox/createCheckbox.ts +10 -0
- package/src/checkbox/createCheckboxGroupItem.ts +12 -16
- package/src/color/createColorArea.ts +17 -10
- package/src/color/createColorField.ts +8 -1
- package/src/color/createColorSlider.ts +1 -2
- package/src/color/createColorSwatch.ts +4 -2
- package/src/color/createColorWheel.ts +0 -6
- package/src/color/intl/index.ts +316 -0
- package/src/combobox/createComboBox.ts +35 -4
- package/src/combobox/intl/generated-locales.ts +635 -0
- package/src/combobox/intl/index.ts +8 -2
- package/src/datepicker/createDateField.ts +228 -213
- package/src/datepicker/createDatePicker.ts +157 -146
- package/src/datepicker/createDatePickerGroup.ts +88 -82
- package/src/datepicker/createDateRangePicker.ts +230 -179
- package/src/datepicker/createDateSegment.ts +386 -384
- package/src/datepicker/createDisplayNames.ts +45 -0
- package/src/datepicker/createTimeField.ts +36 -129
- package/src/datepicker/index.ts +13 -14
- package/src/datepicker/intl.ts +633 -0
- package/src/dnd/DragManager.ts +693 -0
- package/src/dnd/DropTargetKeyboardNavigation.ts +337 -0
- package/src/dnd/createDrag.ts +31 -5
- package/src/dnd/createDraggableCollection.ts +33 -15
- package/src/dnd/createDraggableItem.ts +92 -5
- package/src/dnd/createDroppableCollection.ts +488 -371
- package/src/dnd/index.ts +11 -0
- package/src/dnd/intl/ar-AE.json +29 -0
- package/src/dnd/intl/bg-BG.json +29 -0
- package/src/dnd/intl/cs-CZ.json +29 -0
- package/src/dnd/intl/da-DK.json +29 -0
- package/src/dnd/intl/de-DE.json +29 -0
- package/src/dnd/intl/el-GR.json +29 -0
- package/src/dnd/intl/en-US.json +29 -0
- package/src/dnd/intl/es-ES.json +29 -0
- package/src/dnd/intl/et-EE.json +29 -0
- package/src/dnd/intl/fi-FI.json +29 -0
- package/src/dnd/intl/fr-FR.json +29 -0
- package/src/dnd/intl/he-IL.json +29 -0
- package/src/dnd/intl/hr-HR.json +29 -0
- package/src/dnd/intl/hu-HU.json +29 -0
- package/src/dnd/intl/index.ts +139 -0
- package/src/dnd/intl/it-IT.json +29 -0
- package/src/dnd/intl/ja-JP.json +29 -0
- package/src/dnd/intl/ko-KR.json +29 -0
- package/src/dnd/intl/lt-LT.json +29 -0
- package/src/dnd/intl/lv-LV.json +29 -0
- package/src/dnd/intl/nb-NO.json +29 -0
- package/src/dnd/intl/nl-NL.json +29 -0
- package/src/dnd/intl/pl-PL.json +29 -0
- package/src/dnd/intl/pt-BR.json +29 -0
- package/src/dnd/intl/pt-PT.json +29 -0
- package/src/dnd/intl/ro-RO.json +29 -0
- package/src/dnd/intl/ru-RU.json +29 -0
- package/src/dnd/intl/sk-SK.json +29 -0
- package/src/dnd/intl/sl-SI.json +29 -0
- package/src/dnd/intl/sr-SP.json +29 -0
- package/src/dnd/intl/sv-SE.json +29 -0
- package/src/dnd/intl/tr-TR.json +29 -0
- package/src/dnd/intl/uk-UA.json +29 -0
- package/src/dnd/intl/zh-CN.json +29 -0
- package/src/dnd/intl/zh-TW.json +29 -0
- package/src/dnd/utils.ts +63 -3
- package/src/focus/FocusScope.tsx +266 -24
- package/src/focus/index.ts +8 -0
- package/src/focus/virtualFocus.ts +55 -0
- package/src/form/createFormValidation.ts +8 -1
- package/src/gridlist/createGridList.ts +187 -48
- package/src/gridlist/createGridListItem.ts +87 -155
- package/src/gridlist/createGridListSection.ts +54 -0
- package/src/gridlist/index.ts +3 -0
- package/src/gridlist/types.ts +47 -0
- package/src/index.ts +51 -3
- package/src/interactions/FocusableProvider.tsx +11 -6
- package/src/interactions/PressEvent.ts +14 -0
- package/src/interactions/createFocus.ts +26 -21
- package/src/interactions/createFocusWithin.ts +23 -24
- package/src/interactions/createInteractionModality.ts +26 -15
- package/src/interactions/createKeyboard.ts +10 -0
- package/src/interactions/createPress.ts +29 -6
- package/src/label/createLabels.ts +7 -4
- package/src/listbox/createListBox.ts +203 -10
- package/src/listbox/createOption.ts +84 -74
- package/src/menu/createMenu.ts +93 -16
- package/src/menu/createMenuItem.ts +253 -41
- package/src/numberfield/createNumberField.ts +82 -14
- package/src/popover/calculatePosition.ts +19 -7
- package/src/popover/createOverlayPosition.ts +9 -0
- package/src/radio/createRadio.ts +19 -2
- package/src/select/createSelect.ts +41 -4
- package/src/selection/DOMLayoutDelegate.ts +102 -0
- package/src/selection/ListKeyboardDelegate.ts +398 -0
- package/src/selection/constants.ts +16 -0
- package/src/selection/createCollectionRowInteraction.ts +209 -0
- package/src/selection/createScrollIntoViewOnFocus.ts +65 -0
- package/src/selection/createSelectableCollection.ts +645 -0
- package/src/selection/createSelectableItem.ts +512 -0
- package/src/selection/createSelectableList.ts +93 -0
- package/src/selection/createTypeSelect.ts +112 -51
- package/src/selection/index.ts +31 -0
- package/src/selection/selectItem.ts +80 -0
- package/src/selection/utils.ts +82 -0
- package/src/slider/createSlider.ts +48 -1
- package/src/spinbutton/createSpinButton.ts +163 -0
- package/src/spinbutton/index.ts +10 -0
- package/src/spinbutton/intl.ts +115 -0
- package/src/ssr/index.tsx +31 -0
- package/src/switch/createSwitch.ts +10 -0
- package/src/table/createTable.ts +82 -27
- package/src/table/createTableColumnHeader.ts +10 -0
- package/src/table/createTableRow.ts +208 -203
- package/src/table/createTableSelectAllCheckbox.ts +3 -4
- package/src/table/createTableSelectionCheckbox.ts +24 -1
- package/src/table/types.ts +37 -1
- package/src/table/utils.ts +41 -0
- package/src/tabs/createTabs.ts +95 -24
- package/src/tag/createTag.ts +30 -36
- package/src/tag/createTagGroup.ts +92 -0
- package/src/toast/createToast.ts +1 -0
- package/src/toggle/createToggle.ts +20 -0
- package/src/toolbar/createToolbar.ts +43 -94
- package/src/tree/createTree.ts +165 -52
- package/src/tree/createTreeItem.ts +105 -120
- package/src/tree/createTreeSelectionCheckbox.ts +14 -1
- package/src/tree/types.ts +10 -0
- package/src/utils/animation.ts +243 -0
- package/src/utils/dom.ts +216 -25
- package/src/utils/index.ts +10 -0
- package/src/utils/keyboard.ts +25 -0
- package/src/utils/mergeProps.ts +8 -1
- package/src/utils/scrollIntoView.ts +181 -0
- package/dist/datepicker/createTimeSegment.d.ts +0 -29
- package/dist/datepicker/createTimeSegment.d.ts.map +0 -1
- package/dist/index.js.map +0 -1
- package/dist/index.jsx.map +0 -1
- package/src/datepicker/createTimeSegment.ts +0 -352
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* createSpinButton hook for Solidaria
|
|
3
|
+
*
|
|
4
|
+
* Provides the ARIA spinbutton props and live-region announcement behaviour for
|
|
5
|
+
* a single spinbutton (e.g. a date-field segment). Port of the keyboard/announce
|
|
6
|
+
* portion of @react-aria/spinbutton `useSpinButton`. The pointer press-and-hold
|
|
7
|
+
* button machinery (increment/decrement buttons) is intentionally omitted — date
|
|
8
|
+
* segments drive value changes through the keyboard only.
|
|
9
|
+
*/
|
|
10
|
+
|
|
11
|
+
import { createMemo, createEffect } from "solid-js";
|
|
12
|
+
import { access, type MaybeAccessor } from "../utils/reactivity";
|
|
13
|
+
import { createStringFormatter } from "../i18n";
|
|
14
|
+
import { announce, clearAnnouncer } from "../live-announcer";
|
|
15
|
+
import { spinButtonStrings, type SpinButtonStringKey } from "./intl";
|
|
16
|
+
|
|
17
|
+
export interface SpinButtonProps {
|
|
18
|
+
/** The current value of the spinbutton. */
|
|
19
|
+
value?: number;
|
|
20
|
+
/** A human-readable text alternative for the value. */
|
|
21
|
+
textValue?: string;
|
|
22
|
+
/** The smallest value allowed. */
|
|
23
|
+
minValue?: number;
|
|
24
|
+
/** The largest value allowed. */
|
|
25
|
+
maxValue?: number;
|
|
26
|
+
/** Whether the spinbutton is disabled. */
|
|
27
|
+
isDisabled?: boolean;
|
|
28
|
+
/** Whether the spinbutton is read only. */
|
|
29
|
+
isReadOnly?: boolean;
|
|
30
|
+
/** Whether the spinbutton is required. */
|
|
31
|
+
isRequired?: boolean;
|
|
32
|
+
onIncrement?: () => void;
|
|
33
|
+
onIncrementPage?: () => void;
|
|
34
|
+
onDecrement?: () => void;
|
|
35
|
+
onDecrementPage?: () => void;
|
|
36
|
+
onDecrementToMin?: () => void;
|
|
37
|
+
onIncrementToMax?: () => void;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export interface SpinButtonAria {
|
|
41
|
+
/** Props for the spinbutton element. */
|
|
42
|
+
spinButtonProps: Record<string, unknown>;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* Provides the behaviour and accessibility implementation for a spinbutton.
|
|
47
|
+
*/
|
|
48
|
+
export function createSpinButton(props: MaybeAccessor<SpinButtonProps>): SpinButtonAria {
|
|
49
|
+
const getProps = () => access(props);
|
|
50
|
+
const stringFormatter = createStringFormatter<SpinButtonStringKey>(
|
|
51
|
+
spinButtonStrings,
|
|
52
|
+
"@react-aria/spinbutton",
|
|
53
|
+
);
|
|
54
|
+
|
|
55
|
+
const onKeyDown = (e: KeyboardEvent) => {
|
|
56
|
+
const p = getProps();
|
|
57
|
+
if (e.ctrlKey || e.metaKey || e.shiftKey || e.altKey || p.isReadOnly || e.isComposing) {
|
|
58
|
+
return;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
switch (e.key) {
|
|
62
|
+
// Upstream deliberately falls through PageUp → ArrowUp when no page
|
|
63
|
+
// handler exists; our tsconfig forbids lexical fallthrough, so the
|
|
64
|
+
// PageUp case mirrors that branch inline instead.
|
|
65
|
+
case "PageUp":
|
|
66
|
+
if (p.onIncrementPage) {
|
|
67
|
+
e.preventDefault();
|
|
68
|
+
p.onIncrementPage();
|
|
69
|
+
} else if (p.onIncrement) {
|
|
70
|
+
e.preventDefault();
|
|
71
|
+
p.onIncrement();
|
|
72
|
+
}
|
|
73
|
+
break;
|
|
74
|
+
case "ArrowUp":
|
|
75
|
+
case "Up":
|
|
76
|
+
if (p.onIncrement) {
|
|
77
|
+
e.preventDefault();
|
|
78
|
+
p.onIncrement();
|
|
79
|
+
}
|
|
80
|
+
break;
|
|
81
|
+
// Same faithful fallthrough as PageUp, mirrored inline (PageDown → ArrowDown).
|
|
82
|
+
case "PageDown":
|
|
83
|
+
if (p.onDecrementPage) {
|
|
84
|
+
e.preventDefault();
|
|
85
|
+
p.onDecrementPage();
|
|
86
|
+
} else if (p.onDecrement) {
|
|
87
|
+
e.preventDefault();
|
|
88
|
+
p.onDecrement();
|
|
89
|
+
}
|
|
90
|
+
break;
|
|
91
|
+
case "ArrowDown":
|
|
92
|
+
case "Down":
|
|
93
|
+
if (p.onDecrement) {
|
|
94
|
+
e.preventDefault();
|
|
95
|
+
p.onDecrement();
|
|
96
|
+
}
|
|
97
|
+
break;
|
|
98
|
+
case "Home":
|
|
99
|
+
if (p.onDecrementToMin) {
|
|
100
|
+
e.preventDefault();
|
|
101
|
+
p.onDecrementToMin();
|
|
102
|
+
}
|
|
103
|
+
break;
|
|
104
|
+
case "End":
|
|
105
|
+
if (p.onIncrementToMax) {
|
|
106
|
+
e.preventDefault();
|
|
107
|
+
p.onIncrementToMax();
|
|
108
|
+
}
|
|
109
|
+
break;
|
|
110
|
+
}
|
|
111
|
+
};
|
|
112
|
+
|
|
113
|
+
// Non-reactive focus flag — matches upstream's `isFocused` ref. Toggling it must
|
|
114
|
+
// NOT re-run the announce effect; only a change in `ariaTextValue` announces.
|
|
115
|
+
let isFocused = false;
|
|
116
|
+
const onFocus = () => {
|
|
117
|
+
isFocused = true;
|
|
118
|
+
};
|
|
119
|
+
const onBlur = () => {
|
|
120
|
+
isFocused = false;
|
|
121
|
+
};
|
|
122
|
+
|
|
123
|
+
// Replace Unicode hyphen-minus (U+002D) with minus sign (U+2212) so VoiceOver
|
|
124
|
+
// announces it as "minus". Replace the empty string with the word "Empty".
|
|
125
|
+
const ariaTextValue = createMemo(() => {
|
|
126
|
+
const p = getProps();
|
|
127
|
+
return p.textValue === ""
|
|
128
|
+
? stringFormatter().format("Empty")
|
|
129
|
+
: (p.textValue || `${p.value}`).replace("-", "−");
|
|
130
|
+
});
|
|
131
|
+
|
|
132
|
+
createEffect(() => {
|
|
133
|
+
const value = ariaTextValue();
|
|
134
|
+
if (isFocused) {
|
|
135
|
+
clearAnnouncer("assertive");
|
|
136
|
+
announce(value, "assertive");
|
|
137
|
+
}
|
|
138
|
+
});
|
|
139
|
+
|
|
140
|
+
const spinButtonProps = createMemo(() => {
|
|
141
|
+
const p = getProps();
|
|
142
|
+
const value = p.value;
|
|
143
|
+
return {
|
|
144
|
+
role: "spinbutton",
|
|
145
|
+
"aria-valuenow": value !== undefined && !isNaN(value) ? value : undefined,
|
|
146
|
+
"aria-valuetext": ariaTextValue(),
|
|
147
|
+
"aria-valuemin": p.minValue,
|
|
148
|
+
"aria-valuemax": p.maxValue,
|
|
149
|
+
"aria-disabled": p.isDisabled || undefined,
|
|
150
|
+
"aria-readonly": p.isReadOnly || undefined,
|
|
151
|
+
"aria-required": p.isRequired || undefined,
|
|
152
|
+
onKeyDown,
|
|
153
|
+
onFocus,
|
|
154
|
+
onBlur,
|
|
155
|
+
};
|
|
156
|
+
});
|
|
157
|
+
|
|
158
|
+
return {
|
|
159
|
+
get spinButtonProps() {
|
|
160
|
+
return spinButtonProps();
|
|
161
|
+
},
|
|
162
|
+
};
|
|
163
|
+
}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
// Spinbutton announcement catalog, ported verbatim from @react-aria/spinbutton's
|
|
2
|
+
// intl/*.json (34 locales). Keep in sync with the vendored react-spectrum source on
|
|
3
|
+
// every pin bump.
|
|
4
|
+
import { LocalizedStringDictionary } from "@internationalized/string";
|
|
5
|
+
|
|
6
|
+
export type SpinButtonStringKey = "Empty";
|
|
7
|
+
|
|
8
|
+
export const spinButtonStrings: Record<string, Record<SpinButtonStringKey, string>> = {
|
|
9
|
+
"ar-AE": {
|
|
10
|
+
"Empty": `\u{641}\u{627}\u{631}\u{63A}`
|
|
11
|
+
},
|
|
12
|
+
"bg-BG": {
|
|
13
|
+
"Empty": `\u{418}\u{437}\u{43F}\u{440}\u{430}\u{437}\u{43D}\u{438}`
|
|
14
|
+
},
|
|
15
|
+
"cs-CZ": {
|
|
16
|
+
"Empty": `Pr\xe1zdn\xe9`
|
|
17
|
+
},
|
|
18
|
+
"da-DK": {
|
|
19
|
+
"Empty": `Tom`
|
|
20
|
+
},
|
|
21
|
+
"de-DE": {
|
|
22
|
+
"Empty": `Leer`
|
|
23
|
+
},
|
|
24
|
+
"el-GR": {
|
|
25
|
+
"Empty": `\u{386}\u{3B4}\u{3B5}\u{3B9}\u{3BF}`
|
|
26
|
+
},
|
|
27
|
+
"en-US": {
|
|
28
|
+
"Empty": `Empty`
|
|
29
|
+
},
|
|
30
|
+
"es-ES": {
|
|
31
|
+
"Empty": `Vac\xedo`
|
|
32
|
+
},
|
|
33
|
+
"et-EE": {
|
|
34
|
+
"Empty": `T\xfchjenda`
|
|
35
|
+
},
|
|
36
|
+
"fi-FI": {
|
|
37
|
+
"Empty": `Tyhj\xe4`
|
|
38
|
+
},
|
|
39
|
+
"fr-FR": {
|
|
40
|
+
"Empty": `Vide`
|
|
41
|
+
},
|
|
42
|
+
"he-IL": {
|
|
43
|
+
"Empty": `\u{5E8}\u{5D9}\u{5E7}`
|
|
44
|
+
},
|
|
45
|
+
"hr-HR": {
|
|
46
|
+
"Empty": `Prazno`
|
|
47
|
+
},
|
|
48
|
+
"hu-HU": {
|
|
49
|
+
"Empty": `\xdcres`
|
|
50
|
+
},
|
|
51
|
+
"it-IT": {
|
|
52
|
+
"Empty": `Vuoto`
|
|
53
|
+
},
|
|
54
|
+
"ja-JP": {
|
|
55
|
+
"Empty": `\u{7A7A}`
|
|
56
|
+
},
|
|
57
|
+
"ko-KR": {
|
|
58
|
+
"Empty": `\u{BE44}\u{C5B4} \u{C788}\u{C74C}`
|
|
59
|
+
},
|
|
60
|
+
"lt-LT": {
|
|
61
|
+
"Empty": `Tu\u{161}\u{10D}ias`
|
|
62
|
+
},
|
|
63
|
+
"lv-LV": {
|
|
64
|
+
"Empty": `Tuk\u{161}s`
|
|
65
|
+
},
|
|
66
|
+
"nb-NO": {
|
|
67
|
+
"Empty": `Tom`
|
|
68
|
+
},
|
|
69
|
+
"nl-NL": {
|
|
70
|
+
"Empty": `Leeg`
|
|
71
|
+
},
|
|
72
|
+
"pl-PL": {
|
|
73
|
+
"Empty": `Pusty`
|
|
74
|
+
},
|
|
75
|
+
"pt-BR": {
|
|
76
|
+
"Empty": `Vazio`
|
|
77
|
+
},
|
|
78
|
+
"pt-PT": {
|
|
79
|
+
"Empty": `Vazio`
|
|
80
|
+
},
|
|
81
|
+
"ro-RO": {
|
|
82
|
+
"Empty": `Gol`
|
|
83
|
+
},
|
|
84
|
+
"ru-RU": {
|
|
85
|
+
"Empty": `\u{41D}\u{435} \u{437}\u{430}\u{43F}\u{43E}\u{43B}\u{43D}\u{435}\u{43D}\u{43E}`
|
|
86
|
+
},
|
|
87
|
+
"sk-SK": {
|
|
88
|
+
"Empty": `Pr\xe1zdne`
|
|
89
|
+
},
|
|
90
|
+
"sl-SI": {
|
|
91
|
+
"Empty": `Prazen`
|
|
92
|
+
},
|
|
93
|
+
"sr-SP": {
|
|
94
|
+
"Empty": `Prazno`
|
|
95
|
+
},
|
|
96
|
+
"sv-SE": {
|
|
97
|
+
"Empty": `Tomt`
|
|
98
|
+
},
|
|
99
|
+
"tr-TR": {
|
|
100
|
+
"Empty": `Bo\u{15F}`
|
|
101
|
+
},
|
|
102
|
+
"uk-UA": {
|
|
103
|
+
"Empty": `\u{41F}\u{443}\u{441}\u{442}\u{43E}`
|
|
104
|
+
},
|
|
105
|
+
"zh-CN": {
|
|
106
|
+
"Empty": `\u{7A7A}`
|
|
107
|
+
},
|
|
108
|
+
"zh-TW": {
|
|
109
|
+
"Empty": `\u{7A7A}\u{767D}`
|
|
110
|
+
},
|
|
111
|
+
};
|
|
112
|
+
|
|
113
|
+
export const spinButtonDictionary = new LocalizedStringDictionary<SpinButtonStringKey, string>(
|
|
114
|
+
spinButtonStrings,
|
|
115
|
+
);
|
package/src/ssr/index.tsx
CHANGED
|
@@ -80,6 +80,37 @@ export function createId(defaultId?: string): string {
|
|
|
80
80
|
return ctx.prefix ? `solidaria-${ctx.prefix}-${uniqueId}` : `solidaria-${uniqueId}`;
|
|
81
81
|
}
|
|
82
82
|
|
|
83
|
+
/**
|
|
84
|
+
* Generates an id, but only resolves to it once an element with that id is
|
|
85
|
+
* actually present in the DOM. Returns `undefined` otherwise.
|
|
86
|
+
*
|
|
87
|
+
* This is a 1:1 port of @react-aria/utils's `useSlotId`. It exists so that an
|
|
88
|
+
* `aria-labelledby` can point at an optional slot (e.g. a section header) and
|
|
89
|
+
* automatically fall back to `undefined` when the slot is not rendered, instead
|
|
90
|
+
* of leaving a dangling reference to a non-existent id.
|
|
91
|
+
*
|
|
92
|
+
* The initial value is the generated id so that server and first client render
|
|
93
|
+
* agree (no hydration mismatch); a client-only effect then probes the DOM and
|
|
94
|
+
* clears the value when no matching element exists.
|
|
95
|
+
*
|
|
96
|
+
* @param deps - Accessors re-probed when their values change (mirrors the
|
|
97
|
+
* dependency array of the upstream hook).
|
|
98
|
+
*/
|
|
99
|
+
export function createSlotId(deps: Array<Accessor<unknown>> = []): Accessor<string | undefined> {
|
|
100
|
+
const id = createId();
|
|
101
|
+
const [resolvedId, setResolvedId] = createSignal<string | undefined>(id);
|
|
102
|
+
|
|
103
|
+
createEffect(() => {
|
|
104
|
+
// Re-probe when any explicit dependency changes.
|
|
105
|
+
for (const dep of deps) {
|
|
106
|
+
dep();
|
|
107
|
+
}
|
|
108
|
+
setResolvedId(document.getElementById(id) ? id : undefined);
|
|
109
|
+
});
|
|
110
|
+
|
|
111
|
+
return resolvedId;
|
|
112
|
+
}
|
|
113
|
+
|
|
83
114
|
/**
|
|
84
115
|
* Provides SSR context to the component tree.
|
|
85
116
|
*
|
|
@@ -21,6 +21,10 @@ export interface SwitchAria {
|
|
|
21
21
|
labelProps: JSX.LabelHTMLAttributes<HTMLLabelElement>;
|
|
22
22
|
/** Props for the input element. */
|
|
23
23
|
inputProps: JSX.InputHTMLAttributes<HTMLInputElement>;
|
|
24
|
+
/** Props for the switch description element, if any. */
|
|
25
|
+
descriptionProps: JSX.HTMLAttributes<HTMLElement>;
|
|
26
|
+
/** Props for the switch error message element, if any. */
|
|
27
|
+
errorMessageProps: JSX.HTMLAttributes<HTMLElement>;
|
|
24
28
|
/** Whether the switch is selected. */
|
|
25
29
|
isSelected: Accessor<boolean>;
|
|
26
30
|
/** Whether the switch is in a pressed state. */
|
|
@@ -56,6 +60,12 @@ export function createSwitch(
|
|
|
56
60
|
checked: toggle.isSelected(),
|
|
57
61
|
};
|
|
58
62
|
},
|
|
63
|
+
get descriptionProps() {
|
|
64
|
+
return toggle.descriptionProps;
|
|
65
|
+
},
|
|
66
|
+
get errorMessageProps() {
|
|
67
|
+
return toggle.errorMessageProps;
|
|
68
|
+
},
|
|
59
69
|
isSelected: toggle.isSelected,
|
|
60
70
|
isPressed: toggle.isPressed,
|
|
61
71
|
isDisabled: toggle.isDisabled,
|
package/src/table/createTable.ts
CHANGED
|
@@ -10,6 +10,9 @@ import type { TableState, TableCollection, Key, GridNode } from "@proyecto-vivia
|
|
|
10
10
|
import type { AriaTableProps, TableAria } from "./types";
|
|
11
11
|
import { useLocale } from "../i18n";
|
|
12
12
|
import { announce } from "../live-announcer";
|
|
13
|
+
import { createDescription } from "../utils/createDescription";
|
|
14
|
+
import { scrollIntoViewport } from "../utils";
|
|
15
|
+
import { getInteractionModality } from "../interactions/createInteractionModality";
|
|
13
16
|
|
|
14
17
|
// Global map to store table metadata for child components
|
|
15
18
|
const tableMap = new WeakMap<
|
|
@@ -63,13 +66,6 @@ function isRow<T>(node: GridNode<T> | null): boolean {
|
|
|
63
66
|
return node?.type === "item";
|
|
64
67
|
}
|
|
65
68
|
|
|
66
|
-
function focusCurrentElement(el: HTMLElement | null | undefined) {
|
|
67
|
-
const target = el?.querySelector<HTMLElement>(
|
|
68
|
-
'[role="row"][tabindex="0"], [role="rowheader"][tabindex="0"], [role="gridcell"][tabindex="0"], [role="columnheader"][tabindex="0"]',
|
|
69
|
-
);
|
|
70
|
-
target?.focus();
|
|
71
|
-
}
|
|
72
|
-
|
|
73
69
|
/**
|
|
74
70
|
* Creates accessibility props for a table component.
|
|
75
71
|
*/
|
|
@@ -146,13 +142,20 @@ export function createTable<T extends object>(
|
|
|
146
142
|
const isRTL = locale().direction === "rtl";
|
|
147
143
|
const setFocusedKey = (key: Key) => {
|
|
148
144
|
s.setFocusedKey(key);
|
|
149
|
-
queueMicrotask(() => focusCurrentElement(ref()));
|
|
150
145
|
};
|
|
151
146
|
const runTypeahead = (focusedKey: Key, focusedItem: GridNode<T>) => {
|
|
152
147
|
if (e.key.length !== 1 || e.ctrlKey || e.metaKey || e.altKey) {
|
|
153
148
|
return false;
|
|
154
149
|
}
|
|
155
150
|
|
|
151
|
+
// A leading Spacebar is a selection/action key, not the start of a type-ahead
|
|
152
|
+
// search. Mirror upstream useTypeSelect (`search.length === 0 && character === ' '`)
|
|
153
|
+
// and let it fall through so the focused row's own Space handler toggles selection.
|
|
154
|
+
// Once a search is active, Space continues the query as normal.
|
|
155
|
+
if (e.key === " " && typeaheadBuffer.length === 0) {
|
|
156
|
+
return false;
|
|
157
|
+
}
|
|
158
|
+
|
|
156
159
|
typeaheadBuffer += e.key.toLocaleLowerCase();
|
|
157
160
|
if (typeaheadTimeout) {
|
|
158
161
|
clearTimeout(typeaheadTimeout);
|
|
@@ -478,24 +481,12 @@ export function createTable<T extends object>(
|
|
|
478
481
|
}
|
|
479
482
|
return;
|
|
480
483
|
|
|
481
|
-
|
|
482
|
-
case
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
const keyToSelect =
|
|
488
|
-
isCell(focusedItem) && focusedItem.parentKey != null
|
|
489
|
-
? focusedItem.parentKey
|
|
490
|
-
: focusedKey;
|
|
491
|
-
|
|
492
|
-
if (e.shiftKey && s.selectionMode === "multiple") {
|
|
493
|
-
s.extendSelection(keyToSelect);
|
|
494
|
-
} else {
|
|
495
|
-
s.toggleSelection(keyToSelect);
|
|
496
|
-
}
|
|
497
|
-
}
|
|
498
|
-
return;
|
|
484
|
+
// NOTE: Space/Enter selection is intentionally NOT handled here. Upstream
|
|
485
|
+
// useSelectableCollection has no ' '/Enter case — keyboard selection is owned
|
|
486
|
+
// by the row (useSelectableItem, ported in createTableRow). Handling it here too
|
|
487
|
+
// double-toggled the selection (row toggles on, grid toggles back off → no-op),
|
|
488
|
+
// since the row handler does not stop propagation. Space/Enter fall through to
|
|
489
|
+
// the type-ahead path below, which ignores a leading Space and bails on Enter.
|
|
499
490
|
|
|
500
491
|
default:
|
|
501
492
|
if (runTypeahead(focusedKey, focusedItem)) {
|
|
@@ -552,6 +543,46 @@ export function createTable<T extends object>(
|
|
|
552
543
|
}
|
|
553
544
|
};
|
|
554
545
|
|
|
546
|
+
// Mirror React Aria's useSelectableCollection: once the roving tabindex for
|
|
547
|
+
// the focused key has been committed to the DOM, move browser focus onto that
|
|
548
|
+
// element from a post-commit effect — looking it up by its stable data-key
|
|
549
|
+
// rather than by transient tabindex. Doing this imperatively during the key
|
|
550
|
+
// handler (in a microtask) raced Solid's reconciliation and dropped focus to
|
|
551
|
+
// <body>, so Space/Enter never reached the grid's selection handler.
|
|
552
|
+
createEffect(() => {
|
|
553
|
+
const s = state();
|
|
554
|
+
const key = s.focusedKey;
|
|
555
|
+
const el = ref();
|
|
556
|
+
if (!el || key == null) {
|
|
557
|
+
return;
|
|
558
|
+
}
|
|
559
|
+
|
|
560
|
+
// Only manage focus while it already lives inside the table — i.e. the user
|
|
561
|
+
// is navigating with the keyboard. We gate on the *physical* position of
|
|
562
|
+
// browser focus rather than the grid's logical `isFocused` signal: focus can
|
|
563
|
+
// land directly on a row (a pointer click, or programmatic row focus) without
|
|
564
|
+
// ever firing the grid's own non-bubbling focus handler, so `isFocused` stays
|
|
565
|
+
// false even though the table genuinely holds focus. The contains() check is
|
|
566
|
+
// also what keeps us from pulling focus back from elsewhere on the page when
|
|
567
|
+
// the focused key changes from a background interaction.
|
|
568
|
+
const active = document.activeElement;
|
|
569
|
+
if (!active || (active !== el && !el.contains(active))) {
|
|
570
|
+
return;
|
|
571
|
+
}
|
|
572
|
+
|
|
573
|
+
const target = el.querySelector<HTMLElement>(`[data-key="${key}"]`);
|
|
574
|
+
if (target && target !== active) {
|
|
575
|
+
target.focus();
|
|
576
|
+
|
|
577
|
+
// Reveal the newly focused row/cell when navigating with the keyboard,
|
|
578
|
+
// mirroring useSelectableCollection. Pointer-driven focus changes should
|
|
579
|
+
// not shift the scroll position under the user's finger.
|
|
580
|
+
if (getInteractionModality() !== "pointer") {
|
|
581
|
+
scrollIntoViewport(target, { containingElement: el });
|
|
582
|
+
}
|
|
583
|
+
}
|
|
584
|
+
});
|
|
585
|
+
|
|
555
586
|
// Warn if no label is provided
|
|
556
587
|
createMemo(() => {
|
|
557
588
|
const p = props();
|
|
@@ -560,16 +591,40 @@ export function createTable<T extends object>(
|
|
|
560
591
|
}
|
|
561
592
|
});
|
|
562
593
|
|
|
594
|
+
// A sorted table exposes a persistent sort description on the grid ("sorted by
|
|
595
|
+
// column {name} in {direction} order"), mirroring `useTable`'s
|
|
596
|
+
// `useDescription(sortDescription)` — separate from the transient live-region
|
|
597
|
+
// announcement above. `columnName` follows upstream exactly
|
|
598
|
+
// (`columns.find(c => c.key === column)?.textValue ?? ''`) so a header with no
|
|
599
|
+
// plain-text value yields an empty name, matching the S2 oracle.
|
|
600
|
+
const sortDescription = () => {
|
|
601
|
+
const s = state();
|
|
602
|
+
const descriptor = s.sortDescriptor;
|
|
603
|
+
const column = descriptor?.column;
|
|
604
|
+
const direction = descriptor?.direction;
|
|
605
|
+
if (!direction || column == null) {
|
|
606
|
+
return undefined;
|
|
607
|
+
}
|
|
608
|
+
const columnName = s.collection.columns.find((c) => c.key === column)?.textValue ?? "";
|
|
609
|
+
return `sorted by column ${columnName} in ${direction} order`;
|
|
610
|
+
};
|
|
611
|
+
const sortDescriptionProps = createDescription(sortDescription);
|
|
612
|
+
|
|
563
613
|
const gridProps = createMemo(() => {
|
|
564
614
|
const p = props();
|
|
565
615
|
const s = state();
|
|
566
616
|
|
|
617
|
+
const describedBy =
|
|
618
|
+
[sortDescriptionProps["aria-describedby"], p["aria-describedby"]]
|
|
619
|
+
.filter(Boolean)
|
|
620
|
+
.join(" ") || undefined;
|
|
621
|
+
|
|
567
622
|
const baseProps: Record<string, unknown> = {
|
|
568
623
|
role: "grid",
|
|
569
624
|
id,
|
|
570
625
|
"aria-label": p["aria-label"],
|
|
571
626
|
"aria-labelledby": p["aria-labelledby"],
|
|
572
|
-
"aria-describedby":
|
|
627
|
+
"aria-describedby": describedBy,
|
|
573
628
|
"aria-multiselectable": s.selectionMode === "multiple" ? "true" : undefined,
|
|
574
629
|
// Keep the grid itself tabbable so keyboard users can enter
|
|
575
630
|
// row/cell navigation without requiring a prior pointer interaction.
|
|
@@ -8,6 +8,7 @@ import type { JSX } from "solid-js";
|
|
|
8
8
|
import type { TableState, TableCollection } from "@proyecto-viviana/solid-stately";
|
|
9
9
|
import type { AriaTableColumnHeaderProps, TableColumnHeaderAria } from "./types";
|
|
10
10
|
import { getTableData } from "./createTable";
|
|
11
|
+
import { createDescription } from "../utils/createDescription";
|
|
11
12
|
|
|
12
13
|
/**
|
|
13
14
|
* Creates accessibility props for a table column header.
|
|
@@ -27,6 +28,14 @@ export function createTableColumnHeader<T extends object>(
|
|
|
27
28
|
return s.focusedKey === p.node.key;
|
|
28
29
|
});
|
|
29
30
|
|
|
31
|
+
// A sortable column header is described as "sortable column" — mirrors
|
|
32
|
+
// `useTableColumnHeader`'s `useDescription(stringFormatter.format('sortable'))`.
|
|
33
|
+
// Backed by a shared hidden element (ref-counted) and referenced via
|
|
34
|
+
// aria-describedby.
|
|
35
|
+
const sortDescriptionProps = createDescription(() =>
|
|
36
|
+
props().allowsSorting ? "sortable column" : undefined,
|
|
37
|
+
);
|
|
38
|
+
|
|
30
39
|
const sortColumn = () => {
|
|
31
40
|
const s = state();
|
|
32
41
|
const p = props();
|
|
@@ -125,6 +134,7 @@ export function createTableColumnHeader<T extends object>(
|
|
|
125
134
|
role: "columnheader",
|
|
126
135
|
id: tableData ? `${tableData.tableId}-${node.key}` : undefined,
|
|
127
136
|
"aria-sort": ariaSort,
|
|
137
|
+
"aria-describedby": sortDescriptionProps["aria-describedby"],
|
|
128
138
|
tabIndex: isFocused() ? 0 : -1,
|
|
129
139
|
onFocus,
|
|
130
140
|
};
|