@ni/fast-foundation 0.0.2
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/README.md +58 -0
- package/dist/dts/accordion/accordion.d.ts +65 -0
- package/dist/dts/accordion/accordion.template.d.ts +8 -0
- package/dist/dts/accordion/index.d.ts +2 -0
- package/dist/dts/accordion-item/accordion-item.d.ts +76 -0
- package/dist/dts/accordion-item/accordion-item.template.d.ts +8 -0
- package/dist/dts/accordion-item/index.d.ts +2 -0
- package/dist/dts/anchor/anchor.d.ts +128 -0
- package/dist/dts/anchor/anchor.template.d.ts +8 -0
- package/dist/dts/anchor/index.d.ts +2 -0
- package/dist/dts/anchored-region/anchored-region-config.d.ts +117 -0
- package/dist/dts/anchored-region/anchored-region.d.ts +389 -0
- package/dist/dts/anchored-region/anchored-region.template.d.ts +8 -0
- package/dist/dts/anchored-region/index.d.ts +3 -0
- package/dist/dts/avatar/avatar.d.ts +62 -0
- package/dist/dts/avatar/avatar.template.d.ts +8 -0
- package/dist/dts/avatar/index.d.ts +2 -0
- package/dist/dts/badge/badge.d.ts +36 -0
- package/dist/dts/badge/badge.template.d.ts +8 -0
- package/dist/dts/badge/index.d.ts +2 -0
- package/dist/dts/breadcrumb/breadcrumb.d.ts +27 -0
- package/dist/dts/breadcrumb/breadcrumb.template.d.ts +8 -0
- package/dist/dts/breadcrumb/index.d.ts +2 -0
- package/dist/dts/breadcrumb-item/breadcrumb-item.d.ts +36 -0
- package/dist/dts/breadcrumb-item/breadcrumb-item.template.d.ts +8 -0
- package/dist/dts/breadcrumb-item/index.d.ts +2 -0
- package/dist/dts/button/button.d.ts +167 -0
- package/dist/dts/button/button.form-associated.d.ts +16 -0
- package/dist/dts/button/button.template.d.ts +8 -0
- package/dist/dts/button/index.d.ts +2 -0
- package/dist/dts/calendar/calendar.d.ts +178 -0
- package/dist/dts/calendar/calendar.template.d.ts +58 -0
- package/dist/dts/calendar/date-formatter.d.ts +124 -0
- package/dist/dts/calendar/index.d.ts +3 -0
- package/dist/dts/card/card.d.ts +10 -0
- package/dist/dts/card/card.template.d.ts +8 -0
- package/dist/dts/card/index.d.ts +2 -0
- package/dist/dts/checkbox/checkbox.d.ts +58 -0
- package/dist/dts/checkbox/checkbox.form-associated.d.ts +16 -0
- package/dist/dts/checkbox/checkbox.template.d.ts +8 -0
- package/dist/dts/checkbox/index.d.ts +2 -0
- package/dist/dts/combobox/combobox.d.ts +341 -0
- package/dist/dts/combobox/combobox.form-associated.d.ts +16 -0
- package/dist/dts/combobox/combobox.options.d.ts +15 -0
- package/dist/dts/combobox/combobox.template.d.ts +8 -0
- package/dist/dts/combobox/index.d.ts +3 -0
- package/dist/dts/data-grid/data-grid-cell.d.ts +62 -0
- package/dist/dts/data-grid/data-grid-cell.template.d.ts +9 -0
- package/dist/dts/data-grid/data-grid-row.d.ts +119 -0
- package/dist/dts/data-grid/data-grid-row.template.d.ts +10 -0
- package/dist/dts/data-grid/data-grid.d.ts +218 -0
- package/dist/dts/data-grid/data-grid.options.d.ts +49 -0
- package/dist/dts/data-grid/data-grid.template.d.ts +10 -0
- package/dist/dts/data-grid/index.d.ts +6 -0
- package/dist/dts/design-system/component-presentation.d.ts +66 -0
- package/dist/dts/design-system/design-system.d.ts +104 -0
- package/dist/dts/design-system/index.d.ts +3 -0
- package/dist/dts/design-system/registration-context.d.ts +106 -0
- package/dist/dts/design-token/custom-property-manager.d.ts +35 -0
- package/dist/dts/design-token/design-token.d.ts +139 -0
- package/dist/dts/design-token/interfaces.d.ts +31 -0
- package/dist/dts/di/di.d.ts +858 -0
- package/dist/dts/di/index.d.ts +1 -0
- package/dist/dts/dialog/dialog.d.ts +153 -0
- package/dist/dts/dialog/dialog.template.d.ts +8 -0
- package/dist/dts/dialog/index.d.ts +2 -0
- package/dist/dts/directives/reflect-attributes.d.ts +18 -0
- package/dist/dts/disclosure/disclosure.d.ts +59 -0
- package/dist/dts/disclosure/disclosure.template.d.ts +8 -0
- package/dist/dts/disclosure/index.d.ts +2 -0
- package/dist/dts/divider/divider.d.ts +28 -0
- package/dist/dts/divider/divider.options.d.ts +19 -0
- package/dist/dts/divider/divider.template.d.ts +8 -0
- package/dist/dts/divider/index.d.ts +2 -0
- package/dist/dts/flipper/flipper.d.ts +57 -0
- package/dist/dts/flipper/flipper.options.d.ts +13 -0
- package/dist/dts/flipper/flipper.template.d.ts +8 -0
- package/dist/dts/flipper/index.d.ts +2 -0
- package/dist/dts/form-associated/form-associated.d.ts +177 -0
- package/dist/dts/form-associated/index.d.ts +1 -0
- package/dist/dts/foundation-element/foundation-element.d.ts +120 -0
- package/dist/dts/foundation-element/index.d.ts +1 -0
- package/dist/dts/horizontal-scroll/horizontal-scroll.d.ts +242 -0
- package/dist/dts/horizontal-scroll/horizontal-scroll.template.d.ts +7 -0
- package/dist/dts/horizontal-scroll/index.d.ts +2 -0
- package/dist/dts/index-rollup.d.ts +2 -0
- package/dist/dts/index.d.ts +53 -0
- package/dist/dts/interfaces.d.ts +4 -0
- package/dist/dts/listbox/index.d.ts +3 -0
- package/dist/dts/listbox/listbox.d.ts +314 -0
- package/dist/dts/listbox/listbox.element.d.ts +223 -0
- package/dist/dts/listbox/listbox.template.d.ts +8 -0
- package/dist/dts/listbox-option/index.d.ts +2 -0
- package/dist/dts/listbox-option/listbox-option.d.ts +176 -0
- package/dist/dts/listbox-option/listbox-option.template.d.ts +8 -0
- package/dist/dts/menu/index.d.ts +2 -0
- package/dist/dts/menu/menu.d.ts +78 -0
- package/dist/dts/menu/menu.template.d.ts +8 -0
- package/dist/dts/menu-item/index.d.ts +2 -0
- package/dist/dts/menu-item/menu-item.d.ts +160 -0
- package/dist/dts/menu-item/menu-item.options.d.ts +29 -0
- package/dist/dts/menu-item/menu-item.template.d.ts +10 -0
- package/dist/dts/number-field/index.d.ts +2 -0
- package/dist/dts/number-field/number-field.d.ts +227 -0
- package/dist/dts/number-field/number-field.form-associated.d.ts +16 -0
- package/dist/dts/number-field/number-field.template.d.ts +8 -0
- package/dist/dts/patterns/aria-global.d.ts +189 -0
- package/dist/dts/patterns/index.d.ts +2 -0
- package/dist/dts/patterns/start-end.d.ts +65 -0
- package/dist/dts/picker/index.d.ts +10 -0
- package/dist/dts/picker/picker-list-item.d.ts +38 -0
- package/dist/dts/picker/picker-list-item.template.d.ts +8 -0
- package/dist/dts/picker/picker-list.d.ts +8 -0
- package/dist/dts/picker/picker-list.template.d.ts +8 -0
- package/dist/dts/picker/picker-menu-option.d.ts +37 -0
- package/dist/dts/picker/picker-menu-option.template.d.ts +8 -0
- package/dist/dts/picker/picker-menu.d.ts +46 -0
- package/dist/dts/picker/picker-menu.template.d.ts +8 -0
- package/dist/dts/picker/picker.d.ts +390 -0
- package/dist/dts/picker/picker.form-associated.d.ts +16 -0
- package/dist/dts/picker/picker.template.d.ts +8 -0
- package/dist/dts/progress/base-progress.d.ts +71 -0
- package/dist/dts/progress/index.d.ts +2 -0
- package/dist/dts/progress/progress.template.d.ts +8 -0
- package/dist/dts/progress-ring/index.d.ts +1 -0
- package/dist/dts/progress-ring/progress-ring.template.d.ts +8 -0
- package/dist/dts/radio/index.d.ts +2 -0
- package/dist/dts/radio/radio.d.ts +70 -0
- package/dist/dts/radio/radio.form-associated.d.ts +16 -0
- package/dist/dts/radio/radio.template.d.ts +8 -0
- package/dist/dts/radio-group/index.d.ts +2 -0
- package/dist/dts/radio-group/radio-group.d.ts +101 -0
- package/dist/dts/radio-group/radio-group.template.d.ts +8 -0
- package/dist/dts/search/index.d.ts +2 -0
- package/dist/dts/search/search.d.ts +162 -0
- package/dist/dts/search/search.form-associated.d.ts +16 -0
- package/dist/dts/search/search.template.d.ts +8 -0
- package/dist/dts/select/index.d.ts +3 -0
- package/dist/dts/select/select.d.ts +289 -0
- package/dist/dts/select/select.form-associated.d.ts +16 -0
- package/dist/dts/select/select.options.d.ts +13 -0
- package/dist/dts/select/select.template.d.ts +8 -0
- package/dist/dts/skeleton/index.d.ts +2 -0
- package/dist/dts/skeleton/skeleton.d.ts +47 -0
- package/dist/dts/skeleton/skeleton.template.d.ts +8 -0
- package/dist/dts/slider/index.d.ts +2 -0
- package/dist/dts/slider/slider-utilities.d.ts +5 -0
- package/dist/dts/slider/slider.d.ts +230 -0
- package/dist/dts/slider/slider.form-associated.d.ts +16 -0
- package/dist/dts/slider/slider.template.d.ts +8 -0
- package/dist/dts/slider-label/index.d.ts +2 -0
- package/dist/dts/slider-label/slider-label.d.ts +81 -0
- package/dist/dts/slider-label/slider-label.template.d.ts +8 -0
- package/dist/dts/switch/index.d.ts +2 -0
- package/dist/dts/switch/switch.d.ts +60 -0
- package/dist/dts/switch/switch.form-associated.d.ts +16 -0
- package/dist/dts/switch/switch.template.d.ts +8 -0
- package/dist/dts/tab/index.d.ts +2 -0
- package/dist/dts/tab/tab.d.ts +17 -0
- package/dist/dts/tab/tab.template.d.ts +8 -0
- package/dist/dts/tab-panel/index.d.ts +2 -0
- package/dist/dts/tab-panel/tab-panel.d.ts +10 -0
- package/dist/dts/tab-panel/tab-panel.template.d.ts +8 -0
- package/dist/dts/tabs/index.d.ts +2 -0
- package/dist/dts/tabs/tabs.d.ts +140 -0
- package/dist/dts/tabs/tabs.template.d.ts +8 -0
- package/dist/dts/test-utilities/fixture.d.ts +89 -0
- package/dist/dts/test-utilities/timeout.d.ts +4 -0
- package/dist/dts/text-area/index.d.ts +2 -0
- package/dist/dts/text-area/text-area.d.ts +149 -0
- package/dist/dts/text-area/text-area.form-associated.d.ts +16 -0
- package/dist/dts/text-area/text-area.options.d.ts +27 -0
- package/dist/dts/text-area/text-area.template.d.ts +8 -0
- package/dist/dts/text-field/index.d.ts +2 -0
- package/dist/dts/text-field/text-field.d.ts +166 -0
- package/dist/dts/text-field/text-field.form-associated.d.ts +16 -0
- package/dist/dts/text-field/text-field.options.d.ts +31 -0
- package/dist/dts/text-field/text-field.template.d.ts +8 -0
- package/dist/dts/toolbar/index.d.ts +2 -0
- package/dist/dts/toolbar/toolbar.d.ts +167 -0
- package/dist/dts/toolbar/toolbar.template.d.ts +9 -0
- package/dist/dts/tooltip/index.d.ts +2 -0
- package/dist/dts/tooltip/tooltip.d.ts +239 -0
- package/dist/dts/tooltip/tooltip.options.d.ts +69 -0
- package/dist/dts/tooltip/tooltip.template.d.ts +8 -0
- package/dist/dts/tree-item/index.d.ts +2 -0
- package/dist/dts/tree-item/tree-item.d.ts +141 -0
- package/dist/dts/tree-item/tree-item.template.d.ts +8 -0
- package/dist/dts/tree-view/index.d.ts +2 -0
- package/dist/dts/tree-view/tree-view.d.ts +99 -0
- package/dist/dts/tree-view/tree-view.template.d.ts +8 -0
- package/dist/dts/utilities/apply-mixins.d.ts +6 -0
- package/dist/dts/utilities/composed-contains.d.ts +12 -0
- package/dist/dts/utilities/composed-parent.d.ts +10 -0
- package/dist/dts/utilities/direction.d.ts +7 -0
- package/dist/dts/utilities/index.d.ts +8 -0
- package/dist/dts/utilities/intersection-service.d.ts +30 -0
- package/dist/dts/utilities/match-media-stylesheet-behavior.d.ts +124 -0
- package/dist/dts/utilities/property-stylesheet-behavior.d.ts +38 -0
- package/dist/dts/utilities/resize-observer.d.ts +31 -0
- package/dist/dts/utilities/root-active-element.d.ts +1 -0
- package/dist/dts/utilities/style/disabled.d.ts +5 -0
- package/dist/dts/utilities/style/display.d.ts +17 -0
- package/dist/dts/utilities/style/focus.d.ts +8 -0
- package/dist/dts/utilities/style/index.d.ts +3 -0
- package/dist/dts/utilities/whitespace-filter.d.ts +9 -0
- package/dist/esm/accordion/accordion.js +185 -0
- package/dist/esm/accordion/accordion.template.js +11 -0
- package/dist/esm/accordion/index.js +2 -0
- package/dist/esm/accordion-item/accordion-item.js +72 -0
- package/dist/esm/accordion-item/accordion-item.template.js +49 -0
- package/dist/esm/accordion-item/index.js +2 -0
- package/dist/esm/anchor/anchor.js +85 -0
- package/dist/esm/anchor/anchor.template.js +47 -0
- package/dist/esm/anchor/index.js +2 -0
- package/dist/esm/anchored-region/anchored-region-config.js +59 -0
- package/dist/esm/anchored-region/anchored-region.js +964 -0
- package/dist/esm/anchored-region/anchored-region.template.js +12 -0
- package/dist/esm/anchored-region/index.js +3 -0
- package/dist/esm/avatar/avatar.js +39 -0
- package/dist/esm/avatar/avatar.template.js +23 -0
- package/dist/esm/avatar/index.js +2 -0
- package/dist/esm/badge/badge.js +40 -0
- package/dist/esm/badge/badge.template.js +12 -0
- package/dist/esm/badge/index.js +2 -0
- package/dist/esm/breadcrumb/breadcrumb.js +70 -0
- package/dist/esm/breadcrumb/breadcrumb.template.js +14 -0
- package/dist/esm/breadcrumb/index.js +2 -0
- package/dist/esm/breadcrumb-item/breadcrumb-item.js +23 -0
- package/dist/esm/breadcrumb-item/breadcrumb-item.template.js +24 -0
- package/dist/esm/breadcrumb-item/index.js +2 -0
- package/dist/esm/button/button.form-associated.js +15 -0
- package/dist/esm/button/button.js +183 -0
- package/dist/esm/button/button.template.js +51 -0
- package/dist/esm/button/index.js +2 -0
- package/dist/esm/calendar/calendar.js +280 -0
- package/dist/esm/calendar/calendar.template.js +191 -0
- package/dist/esm/calendar/date-formatter.js +144 -0
- package/dist/esm/calendar/index.js +3 -0
- package/dist/esm/card/card.js +10 -0
- package/dist/esm/card/card.template.js +8 -0
- package/dist/esm/card/index.js +2 -0
- package/dist/esm/checkbox/checkbox.form-associated.js +15 -0
- package/dist/esm/checkbox/checkbox.js +75 -0
- package/dist/esm/checkbox/checkbox.template.js +35 -0
- package/dist/esm/checkbox/index.js +2 -0
- package/dist/esm/combobox/combobox.form-associated.js +15 -0
- package/dist/esm/combobox/combobox.js +587 -0
- package/dist/esm/combobox/combobox.options.js +10 -0
- package/dist/esm/combobox/combobox.template.js +66 -0
- package/dist/esm/combobox/index.js +3 -0
- package/dist/esm/data-grid/data-grid-cell.js +229 -0
- package/dist/esm/data-grid/data-grid-cell.template.js +23 -0
- package/dist/esm/data-grid/data-grid-row.js +203 -0
- package/dist/esm/data-grid/data-grid-row.template.js +47 -0
- package/dist/esm/data-grid/data-grid.js +440 -0
- package/dist/esm/data-grid/data-grid.options.js +31 -0
- package/dist/esm/data-grid/data-grid.template.js +36 -0
- package/dist/esm/data-grid/index.js +6 -0
- package/dist/esm/design-system/component-presentation.js +86 -0
- package/dist/esm/design-system/design-system.js +207 -0
- package/dist/esm/design-system/index.js +3 -0
- package/dist/esm/design-system/registration-context.js +1 -0
- package/dist/esm/design-token/custom-property-manager.js +216 -0
- package/dist/esm/design-token/design-token.js +657 -0
- package/dist/esm/design-token/interfaces.js +1 -0
- package/dist/esm/di/di.js +1341 -0
- package/dist/esm/di/index.js +1 -0
- package/dist/esm/dialog/dialog.js +280 -0
- package/dist/esm/dialog/dialog.template.js +30 -0
- package/dist/esm/dialog/index.js +2 -0
- package/dist/esm/directives/reflect-attributes.js +88 -0
- package/dist/esm/disclosure/disclosure.js +72 -0
- package/dist/esm/disclosure/disclosure.template.js +20 -0
- package/dist/esm/disclosure/index.js +2 -0
- package/dist/esm/divider/divider.js +39 -0
- package/dist/esm/divider/divider.options.js +14 -0
- package/dist/esm/divider/divider.template.js +8 -0
- package/dist/esm/divider/index.js +2 -0
- package/dist/esm/flipper/flipper.js +65 -0
- package/dist/esm/flipper/flipper.options.js +8 -0
- package/dist/esm/flipper/flipper.template.js +30 -0
- package/dist/esm/flipper/index.js +2 -0
- package/dist/esm/form-associated/form-associated.js +464 -0
- package/dist/esm/form-associated/index.js +1 -0
- package/dist/esm/foundation-element/foundation-element.js +132 -0
- package/dist/esm/foundation-element/index.js +1 -0
- package/dist/esm/horizontal-scroll/horizontal-scroll.js +380 -0
- package/dist/esm/horizontal-scroll/horizontal-scroll.template.js +62 -0
- package/dist/esm/horizontal-scroll/index.js +2 -0
- package/dist/esm/index-rollup.js +2 -0
- package/dist/esm/index.js +54 -0
- package/dist/esm/interfaces.js +1 -0
- package/dist/esm/listbox/index.js +3 -0
- package/dist/esm/listbox/listbox.element.js +448 -0
- package/dist/esm/listbox/listbox.js +528 -0
- package/dist/esm/listbox/listbox.template.js +27 -0
- package/dist/esm/listbox-option/index.js +2 -0
- package/dist/esm/listbox-option/listbox-option.js +200 -0
- package/dist/esm/listbox-option/listbox-option.template.js +25 -0
- package/dist/esm/menu/index.js +2 -0
- package/dist/esm/menu/menu.js +290 -0
- package/dist/esm/menu/menu.template.js +15 -0
- package/dist/esm/menu-item/index.js +2 -0
- package/dist/esm/menu-item/menu-item.js +251 -0
- package/dist/esm/menu-item/menu-item.options.js +26 -0
- package/dist/esm/menu-item/menu-item.template.js +78 -0
- package/dist/esm/number-field/index.js +2 -0
- package/dist/esm/number-field/number-field.form-associated.js +15 -0
- package/dist/esm/number-field/number-field.js +288 -0
- package/dist/esm/number-field/number-field.template.js +84 -0
- package/dist/esm/patterns/aria-global.js +70 -0
- package/dist/esm/patterns/index.js +2 -0
- package/dist/esm/patterns/start-end.js +84 -0
- package/dist/esm/picker/index.js +10 -0
- package/dist/esm/picker/picker-list-item.js +71 -0
- package/dist/esm/picker/picker-list-item.template.js +17 -0
- package/dist/esm/picker/picker-list.js +8 -0
- package/dist/esm/picker/picker-list.template.js +13 -0
- package/dist/esm/picker/picker-menu-option.js +61 -0
- package/dist/esm/picker/picker-menu-option.template.js +16 -0
- package/dist/esm/picker/picker-menu.js +59 -0
- package/dist/esm/picker/picker-menu.template.js +29 -0
- package/dist/esm/picker/picker.form-associated.js +15 -0
- package/dist/esm/picker/picker.js +759 -0
- package/dist/esm/picker/picker.template.js +97 -0
- package/dist/esm/progress/base-progress.js +69 -0
- package/dist/esm/progress/index.js +2 -0
- package/dist/esm/progress/progress.template.js +31 -0
- package/dist/esm/progress-ring/index.js +1 -0
- package/dist/esm/progress-ring/progress-ring.template.js +45 -0
- package/dist/esm/radio/index.js +2 -0
- package/dist/esm/radio/radio.form-associated.js +15 -0
- package/dist/esm/radio/radio.js +108 -0
- package/dist/esm/radio/radio.template.js +31 -0
- package/dist/esm/radio-group/index.js +2 -0
- package/dist/esm/radio-group/radio-group.js +390 -0
- package/dist/esm/radio-group/radio-group.template.js +29 -0
- package/dist/esm/search/index.js +2 -0
- package/dist/esm/search/search.form-associated.js +15 -0
- package/dist/esm/search/search.js +157 -0
- package/dist/esm/search/search.template.js +93 -0
- package/dist/esm/select/index.js +3 -0
- package/dist/esm/select/select.form-associated.js +15 -0
- package/dist/esm/select/select.js +490 -0
- package/dist/esm/select/select.options.js +8 -0
- package/dist/esm/select/select.template.js +72 -0
- package/dist/esm/skeleton/index.js +2 -0
- package/dist/esm/skeleton/skeleton.js +35 -0
- package/dist/esm/skeleton/skeleton.template.js +20 -0
- package/dist/esm/slider/index.js +2 -0
- package/dist/esm/slider/slider-utilities.js +11 -0
- package/dist/esm/slider/slider.form-associated.js +15 -0
- package/dist/esm/slider/slider.js +452 -0
- package/dist/esm/slider/slider.template.js +40 -0
- package/dist/esm/slider-label/index.js +2 -0
- package/dist/esm/slider-label/slider-label.js +158 -0
- package/dist/esm/slider-label/slider-label.template.js +24 -0
- package/dist/esm/switch/index.js +2 -0
- package/dist/esm/switch/switch.form-associated.js +15 -0
- package/dist/esm/switch/switch.js +79 -0
- package/dist/esm/switch/switch.template.js +37 -0
- package/dist/esm/tab/index.js +2 -0
- package/dist/esm/tab/tab.js +15 -0
- package/dist/esm/tab/tab.template.js +10 -0
- package/dist/esm/tab-panel/index.js +2 -0
- package/dist/esm/tab-panel/tab-panel.js +10 -0
- package/dist/esm/tab-panel/tab-panel.template.js +10 -0
- package/dist/esm/tabs/index.js +2 -0
- package/dist/esm/tabs/tabs.js +375 -0
- package/dist/esm/tabs/tabs.template.js +26 -0
- package/dist/esm/test-utilities/fixture.js +90 -0
- package/dist/esm/test-utilities/timeout.js +13 -0
- package/dist/esm/text-area/index.js +2 -0
- package/dist/esm/text-area/text-area.form-associated.js +15 -0
- package/dist/esm/text-area/text-area.js +146 -0
- package/dist/esm/text-area/text-area.options.js +22 -0
- package/dist/esm/text-area/text-area.template.js +64 -0
- package/dist/esm/text-field/index.js +2 -0
- package/dist/esm/text-field/text-field.form-associated.js +15 -0
- package/dist/esm/text-field/text-field.js +183 -0
- package/dist/esm/text-field/text-field.options.js +26 -0
- package/dist/esm/text-field/text-field.template.js +70 -0
- package/dist/esm/toolbar/index.js +2 -0
- package/dist/esm/toolbar/toolbar.js +271 -0
- package/dist/esm/toolbar/toolbar.template.js +37 -0
- package/dist/esm/tooltip/index.js +2 -0
- package/dist/esm/tooltip/tooltip.js +512 -0
- package/dist/esm/tooltip/tooltip.options.js +63 -0
- package/dist/esm/tooltip/tooltip.template.js +32 -0
- package/dist/esm/tree-item/index.js +2 -0
- package/dist/esm/tree-item/tree-item.js +150 -0
- package/dist/esm/tree-item/tree-item.template.js +52 -0
- package/dist/esm/tree-view/index.js +2 -0
- package/dist/esm/tree-view/tree-view.js +268 -0
- package/dist/esm/tree-view/tree-view.template.js +18 -0
- package/dist/esm/utilities/apply-mixins.js +20 -0
- package/dist/esm/utilities/composed-contains.js +22 -0
- package/dist/esm/utilities/composed-parent.js +23 -0
- package/dist/esm/utilities/direction.js +10 -0
- package/dist/esm/utilities/index.js +8 -0
- package/dist/esm/utilities/intersection-service.js +91 -0
- package/dist/esm/utilities/match-media-stylesheet-behavior.js +140 -0
- package/dist/esm/utilities/property-stylesheet-behavior.js +52 -0
- package/dist/esm/utilities/resize-observer.js +5 -0
- package/dist/esm/utilities/root-active-element.js +8 -0
- package/dist/esm/utilities/style/disabled.js +5 -0
- package/dist/esm/utilities/style/display.js +14 -0
- package/dist/esm/utilities/style/focus.js +9 -0
- package/dist/esm/utilities/style/index.js +3 -0
- package/dist/esm/utilities/whitespace-filter.js +13 -0
- package/dist/fast-foundation.d.ts +9744 -0
- package/dist/fast-foundation.js +19097 -0
- package/dist/fast-foundation.min.js +19 -0
- package/dist/tsdoc-metadata.json +11 -0
- package/package.json +101 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./di.js";
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
import { FoundationElement } from "../foundation-element/foundation-element.js";
|
|
2
|
+
/**
|
|
3
|
+
* A Switch Custom HTML Element.
|
|
4
|
+
* Implements the {@link https://www.w3.org/TR/wai-aria-1.1/#dialog | ARIA dialog }.
|
|
5
|
+
*
|
|
6
|
+
* @slot - The default slot for the dialog content
|
|
7
|
+
* @csspart positioning-region - A wrapping element used to center the dialog and position the modal overlay
|
|
8
|
+
* @csspart overlay - The modal dialog overlay
|
|
9
|
+
* @csspart control - The dialog element
|
|
10
|
+
* @fires cancel - Fires a custom 'cancel' event when the modal overlay is clicked
|
|
11
|
+
* @fires close - Fires a custom 'close' event when the dialog is hidden
|
|
12
|
+
*
|
|
13
|
+
* @public
|
|
14
|
+
*/
|
|
15
|
+
export declare class Dialog extends FoundationElement {
|
|
16
|
+
/**
|
|
17
|
+
* Indicates the element is modal. When modal, user mouse interaction will be limited to the contents of the element by a modal
|
|
18
|
+
* overlay. Clicks on the overlay will cause the dialog to emit a "dismiss" event.
|
|
19
|
+
* @public
|
|
20
|
+
* @defaultValue - true
|
|
21
|
+
* @remarks
|
|
22
|
+
* HTML Attribute: modal
|
|
23
|
+
*/
|
|
24
|
+
modal: boolean;
|
|
25
|
+
/**
|
|
26
|
+
* The hidden state of the element.
|
|
27
|
+
*
|
|
28
|
+
* @public
|
|
29
|
+
* @defaultValue - false
|
|
30
|
+
* @remarks
|
|
31
|
+
* HTML Attribute: hidden
|
|
32
|
+
*/
|
|
33
|
+
hidden: boolean;
|
|
34
|
+
/**
|
|
35
|
+
* Indicates that the dialog should trap focus.
|
|
36
|
+
*
|
|
37
|
+
* @public
|
|
38
|
+
* @defaultValue - true
|
|
39
|
+
* @remarks
|
|
40
|
+
* HTML Attribute: trap-focus
|
|
41
|
+
*/
|
|
42
|
+
trapFocus: boolean;
|
|
43
|
+
private trapFocusChanged;
|
|
44
|
+
/**
|
|
45
|
+
* The id of the element describing the dialog.
|
|
46
|
+
* @public
|
|
47
|
+
* @remarks
|
|
48
|
+
* HTML Attribute: aria-describedby
|
|
49
|
+
*/
|
|
50
|
+
ariaDescribedby: string;
|
|
51
|
+
/**
|
|
52
|
+
* The id of the element labeling the dialog.
|
|
53
|
+
* @public
|
|
54
|
+
* @remarks
|
|
55
|
+
* HTML Attribute: aria-labelledby
|
|
56
|
+
*/
|
|
57
|
+
ariaLabelledby: string;
|
|
58
|
+
/**
|
|
59
|
+
* The label surfaced to assistive technologies.
|
|
60
|
+
*
|
|
61
|
+
* @public
|
|
62
|
+
* @remarks
|
|
63
|
+
* HTML Attribute: aria-label
|
|
64
|
+
*/
|
|
65
|
+
ariaLabel: string;
|
|
66
|
+
/**
|
|
67
|
+
* @internal
|
|
68
|
+
*/
|
|
69
|
+
dialog: HTMLDivElement;
|
|
70
|
+
/**
|
|
71
|
+
* @internal
|
|
72
|
+
*/
|
|
73
|
+
private isTrappingFocus;
|
|
74
|
+
/**
|
|
75
|
+
* @internal
|
|
76
|
+
*/
|
|
77
|
+
private notifier;
|
|
78
|
+
/**
|
|
79
|
+
* @internal
|
|
80
|
+
*/
|
|
81
|
+
dismiss(): void;
|
|
82
|
+
/**
|
|
83
|
+
* The method to show the dialog.
|
|
84
|
+
*
|
|
85
|
+
* @public
|
|
86
|
+
*/
|
|
87
|
+
show(): void;
|
|
88
|
+
/**
|
|
89
|
+
* The method to hide the dialog.
|
|
90
|
+
*
|
|
91
|
+
* @public
|
|
92
|
+
*/
|
|
93
|
+
hide(): void;
|
|
94
|
+
/**
|
|
95
|
+
* @internal
|
|
96
|
+
*/
|
|
97
|
+
connectedCallback(): void;
|
|
98
|
+
/**
|
|
99
|
+
* @internal
|
|
100
|
+
*/
|
|
101
|
+
disconnectedCallback(): void;
|
|
102
|
+
/**
|
|
103
|
+
* @internal
|
|
104
|
+
*/
|
|
105
|
+
handleChange(source: any, propertyName: string): void;
|
|
106
|
+
private handleDocumentKeydown;
|
|
107
|
+
private handleDocumentFocus;
|
|
108
|
+
private handleTabKeyDown;
|
|
109
|
+
private getTabQueueBounds;
|
|
110
|
+
/**
|
|
111
|
+
* focus on first element of tab queue
|
|
112
|
+
*/
|
|
113
|
+
private focusFirstElement;
|
|
114
|
+
/**
|
|
115
|
+
* we should only focus if focus has not already been brought to the dialog
|
|
116
|
+
*/
|
|
117
|
+
private shouldForceFocus;
|
|
118
|
+
/**
|
|
119
|
+
* we should we be active trapping focus
|
|
120
|
+
*/
|
|
121
|
+
private shouldTrapFocus;
|
|
122
|
+
/**
|
|
123
|
+
*
|
|
124
|
+
*
|
|
125
|
+
* @internal
|
|
126
|
+
*/
|
|
127
|
+
private updateTrapFocus;
|
|
128
|
+
/**
|
|
129
|
+
* Reduce a collection to only its focusable elements.
|
|
130
|
+
*
|
|
131
|
+
* @param elements - Collection of elements to reduce
|
|
132
|
+
* @param element - The current element
|
|
133
|
+
*
|
|
134
|
+
* @internal
|
|
135
|
+
*/
|
|
136
|
+
private static reduceTabbableItems;
|
|
137
|
+
/**
|
|
138
|
+
* Test if element is focusable fast element
|
|
139
|
+
*
|
|
140
|
+
* @param element - The element to check
|
|
141
|
+
*
|
|
142
|
+
* @internal
|
|
143
|
+
*/
|
|
144
|
+
private static isFocusableFastElement;
|
|
145
|
+
/**
|
|
146
|
+
* Test if the element has a focusable shadow
|
|
147
|
+
*
|
|
148
|
+
* @param element - The element to check
|
|
149
|
+
*
|
|
150
|
+
* @internal
|
|
151
|
+
*/
|
|
152
|
+
private static hasTabbableShadow;
|
|
153
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { ViewTemplate } from "@ni/fast-element";
|
|
2
|
+
import type { FoundationElementTemplate } from "../foundation-element/foundation-element.js";
|
|
3
|
+
import type { Dialog } from "./dialog.js";
|
|
4
|
+
/**
|
|
5
|
+
* The template for the {@link @ni/fast-foundation#Dialog} component.
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export declare const dialogTemplate: FoundationElementTemplate<ViewTemplate<Dialog>>;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { CaptureType } from "@ni/fast-element";
|
|
2
|
+
/**
|
|
3
|
+
* Reflects attributes from the host element to the target element of the directive.
|
|
4
|
+
* @param attributes - The attributes to reflect
|
|
5
|
+
*
|
|
6
|
+
* @beta
|
|
7
|
+
* @example
|
|
8
|
+
* ```ts
|
|
9
|
+
* const template = html`
|
|
10
|
+
* <button
|
|
11
|
+
* ${reflectAttributes("aria-label", "aria-describedby")}
|
|
12
|
+
* >
|
|
13
|
+
* hello world
|
|
14
|
+
* </button
|
|
15
|
+
* `
|
|
16
|
+
* ```
|
|
17
|
+
*/
|
|
18
|
+
export declare function reflectAttributes<T = any>(...attributes: string[]): CaptureType<T>;
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { FoundationElement } from "../foundation-element/foundation-element.js";
|
|
2
|
+
/**
|
|
3
|
+
* A Disclosure Custom HTML Element.
|
|
4
|
+
* Based largely on the {@link https://w3c.github.io/aria-practices/#disclosure | disclosure element }.
|
|
5
|
+
*
|
|
6
|
+
* @slot start - Content which can be provided before the summary content
|
|
7
|
+
* @slot end - Content which can be provided after the summary content
|
|
8
|
+
* @slot title - The summary content
|
|
9
|
+
* @slot - The default slot for the disclosure content
|
|
10
|
+
* @fires toggle - fires a toggle event when the summary is toggled
|
|
11
|
+
*
|
|
12
|
+
* @public
|
|
13
|
+
*/
|
|
14
|
+
export declare class Disclosure extends FoundationElement {
|
|
15
|
+
/**
|
|
16
|
+
* Determines if the element should show the extra content or not.
|
|
17
|
+
*
|
|
18
|
+
* @public
|
|
19
|
+
*/
|
|
20
|
+
expanded: boolean;
|
|
21
|
+
/**
|
|
22
|
+
* Invoker title
|
|
23
|
+
*
|
|
24
|
+
* @public
|
|
25
|
+
*/
|
|
26
|
+
title: string;
|
|
27
|
+
/**
|
|
28
|
+
* @internal
|
|
29
|
+
*/
|
|
30
|
+
details: HTMLDetailsElement;
|
|
31
|
+
/**
|
|
32
|
+
* @internal
|
|
33
|
+
*/
|
|
34
|
+
connectedCallback(): void;
|
|
35
|
+
/**
|
|
36
|
+
* @internal
|
|
37
|
+
*/
|
|
38
|
+
disconnectedCallback(): void;
|
|
39
|
+
/**
|
|
40
|
+
* Show extra content.
|
|
41
|
+
*/
|
|
42
|
+
show(): void;
|
|
43
|
+
/**
|
|
44
|
+
* Hide extra content.
|
|
45
|
+
*/
|
|
46
|
+
hide(): void;
|
|
47
|
+
/**
|
|
48
|
+
* Toggle the current(expanded/collapsed) state.
|
|
49
|
+
*/
|
|
50
|
+
toggle(): void;
|
|
51
|
+
/**
|
|
52
|
+
* Register listener and set default disclosure mode
|
|
53
|
+
*/
|
|
54
|
+
protected setup(): void;
|
|
55
|
+
/**
|
|
56
|
+
* Update the aria attr and fire `toggle` event
|
|
57
|
+
*/
|
|
58
|
+
protected onToggle(): void;
|
|
59
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { ViewTemplate } from "@ni/fast-element";
|
|
2
|
+
import type { FoundationElementTemplate } from "../foundation-element/foundation-element.js";
|
|
3
|
+
import type { Disclosure } from "./disclosure.js";
|
|
4
|
+
/**
|
|
5
|
+
* The template for the {@link @ni/fast-foundation#Disclosure} component.
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export declare const disclosureTemplate: FoundationElementTemplate<ViewTemplate<Disclosure>>;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { Orientation } from "@ni/fast-web-utilities";
|
|
2
|
+
import { FoundationElement } from "../foundation-element/foundation-element.js";
|
|
3
|
+
import { DividerRole } from "./divider.options.js";
|
|
4
|
+
export { DividerRole };
|
|
5
|
+
/**
|
|
6
|
+
* A Divider Custom HTML Element.
|
|
7
|
+
* Implements the {@link https://www.w3.org/TR/wai-aria-1.1/#separator | ARIA separator } or {@link https://www.w3.org/TR/wai-aria-1.1/#presentation | ARIA presentation}.
|
|
8
|
+
*
|
|
9
|
+
* @public
|
|
10
|
+
*/
|
|
11
|
+
export declare class Divider extends FoundationElement {
|
|
12
|
+
/**
|
|
13
|
+
* The role of the element.
|
|
14
|
+
*
|
|
15
|
+
* @public
|
|
16
|
+
* @remarks
|
|
17
|
+
* HTML Attribute: role
|
|
18
|
+
*/
|
|
19
|
+
role: DividerRole;
|
|
20
|
+
/**
|
|
21
|
+
* The orientation of the divider.
|
|
22
|
+
*
|
|
23
|
+
* @public
|
|
24
|
+
* @remarks
|
|
25
|
+
* HTML Attribute: orientation
|
|
26
|
+
*/
|
|
27
|
+
orientation: Orientation;
|
|
28
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Divider roles
|
|
3
|
+
* @public
|
|
4
|
+
*/
|
|
5
|
+
export declare const DividerRole: {
|
|
6
|
+
/**
|
|
7
|
+
* The divider semantically separates content
|
|
8
|
+
*/
|
|
9
|
+
readonly separator: "separator";
|
|
10
|
+
/**
|
|
11
|
+
* The divider has no semantic value and is for visual presentation only.
|
|
12
|
+
*/
|
|
13
|
+
readonly presentation: "presentation";
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* The types for Divider roles
|
|
17
|
+
* @public
|
|
18
|
+
*/
|
|
19
|
+
export type DividerRole = typeof DividerRole[keyof typeof DividerRole];
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { ViewTemplate } from "@ni/fast-element";
|
|
2
|
+
import type { FoundationElementTemplate } from "../foundation-element/foundation-element.js";
|
|
3
|
+
import type { Divider } from "./divider.js";
|
|
4
|
+
/**
|
|
5
|
+
* The template for the {@link @ni/fast-foundation#Divider} component.
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export declare const dividerTemplate: FoundationElementTemplate<ViewTemplate<Divider>>;
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { SyntheticViewTemplate } from "@ni/fast-element";
|
|
2
|
+
import { FoundationElement, FoundationElementDefinition } from "../foundation-element/foundation-element.js";
|
|
3
|
+
import { FlipperDirection } from "./flipper.options.js";
|
|
4
|
+
export { FlipperDirection };
|
|
5
|
+
/**
|
|
6
|
+
* Flipper configuration options
|
|
7
|
+
* @public
|
|
8
|
+
*/
|
|
9
|
+
export type FlipperOptions = FoundationElementDefinition & {
|
|
10
|
+
next?: string | SyntheticViewTemplate;
|
|
11
|
+
previous?: string | SyntheticViewTemplate;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* A Flipper Custom HTML Element.
|
|
15
|
+
* Flippers are a form of button that implies directional content navigation, such as in a carousel.
|
|
16
|
+
*
|
|
17
|
+
* @slot next - The next flipper content
|
|
18
|
+
* @slot previous - The previous flipper content
|
|
19
|
+
* @csspart next - Wraps the next flipper content
|
|
20
|
+
* @csspart previous - Wraps the previous flipper content
|
|
21
|
+
* @fires click - Fires a custom 'click' event when Enter or Space is invoked via keyboard and the flipper is exposed to assistive technologies.
|
|
22
|
+
*
|
|
23
|
+
* @public
|
|
24
|
+
*/
|
|
25
|
+
export declare class Flipper extends FoundationElement {
|
|
26
|
+
/**
|
|
27
|
+
* The disabled state of the flipper.
|
|
28
|
+
* @public
|
|
29
|
+
* @remarks
|
|
30
|
+
* HTML Attribute: disabled
|
|
31
|
+
*/
|
|
32
|
+
disabled: boolean;
|
|
33
|
+
/**
|
|
34
|
+
* Indicates the flipper should be hidden from assistive technology. Because flippers are often supplementary navigation, they are often hidden from assistive technology.
|
|
35
|
+
*
|
|
36
|
+
* @public
|
|
37
|
+
* @defaultValue - true
|
|
38
|
+
* @remarks
|
|
39
|
+
* HTML Attribute: aria-hidden
|
|
40
|
+
*/
|
|
41
|
+
hiddenFromAT: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* The direction that the flipper implies navigating.
|
|
44
|
+
*
|
|
45
|
+
* @public
|
|
46
|
+
* @remarks
|
|
47
|
+
* HTML Attribute: direction
|
|
48
|
+
*/
|
|
49
|
+
direction: FlipperDirection;
|
|
50
|
+
/**
|
|
51
|
+
* Simulate a click event when the flipper has focus and the user hits enter or space keys
|
|
52
|
+
* Blur focus if the user hits escape key
|
|
53
|
+
* @param e - Keyboard event
|
|
54
|
+
* @public
|
|
55
|
+
*/
|
|
56
|
+
keyupHandler(e: Event & KeyboardEvent): void;
|
|
57
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The direction options for flipper.
|
|
3
|
+
* @public
|
|
4
|
+
*/
|
|
5
|
+
export declare const FlipperDirection: {
|
|
6
|
+
readonly next: "next";
|
|
7
|
+
readonly previous: "previous";
|
|
8
|
+
};
|
|
9
|
+
/**
|
|
10
|
+
* The types for the flipper direction options.
|
|
11
|
+
* @public
|
|
12
|
+
*/
|
|
13
|
+
export type FlipperDirection = typeof FlipperDirection[keyof typeof FlipperDirection];
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { ViewTemplate } from "@ni/fast-element";
|
|
2
|
+
import type { FoundationElementTemplate } from "../foundation-element/foundation-element.js";
|
|
3
|
+
import type { Flipper, FlipperOptions } from "./flipper.js";
|
|
4
|
+
/**
|
|
5
|
+
* The template for the {@link @ni/fast-foundation#Flipper} component.
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export declare const flipperTemplate: FoundationElementTemplate<ViewTemplate<Flipper>, FlipperOptions>;
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
import type { Constructable, FASTElement } from "@ni/fast-element";
|
|
2
|
+
/**
|
|
3
|
+
* This file enables typing support for ElementInternals APIs.
|
|
4
|
+
* It is largely taken from https://github.com/microsoft/TSJS-lib-generator/pull/818/files.
|
|
5
|
+
*
|
|
6
|
+
* When TypeScript adds support for these APIs we can delete this file.
|
|
7
|
+
*/
|
|
8
|
+
interface ValidityStateFlags {
|
|
9
|
+
badInput?: boolean;
|
|
10
|
+
customError?: boolean;
|
|
11
|
+
patternMismatch?: boolean;
|
|
12
|
+
rangeOverflow?: boolean;
|
|
13
|
+
rangeUnderflow?: boolean;
|
|
14
|
+
stepMismatch?: boolean;
|
|
15
|
+
tooLong?: boolean;
|
|
16
|
+
tooShort?: boolean;
|
|
17
|
+
typeMismatch?: boolean;
|
|
18
|
+
valueMissing?: boolean;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Source:
|
|
22
|
+
* https://html.spec.whatwg.org/multipage/custom-elements.html#elementinternals
|
|
23
|
+
*/
|
|
24
|
+
interface ElementInternals {
|
|
25
|
+
/**
|
|
26
|
+
* Returns the form owner of internals target element.
|
|
27
|
+
*/
|
|
28
|
+
readonly form: HTMLFormElement | null;
|
|
29
|
+
/**
|
|
30
|
+
* Returns a NodeList of all the label elements that internals target element is associated with.
|
|
31
|
+
*/
|
|
32
|
+
readonly labels: NodeList;
|
|
33
|
+
/**
|
|
34
|
+
* Returns the error message that would be shown to the user if internals target element was to be checked for validity.
|
|
35
|
+
*/
|
|
36
|
+
readonly validationMessage: string;
|
|
37
|
+
/**
|
|
38
|
+
* Returns the ValidityState object for internals target element.
|
|
39
|
+
*/
|
|
40
|
+
readonly validity: ValidityState;
|
|
41
|
+
/**
|
|
42
|
+
* Returns true if internals target element will be validated when the form is submitted; false otherwise.
|
|
43
|
+
*/
|
|
44
|
+
readonly willValidate: boolean;
|
|
45
|
+
/**
|
|
46
|
+
* Returns true if internals target element has no validity problems; false otherwise. Fires an invalid event at the element in the latter case.
|
|
47
|
+
*/
|
|
48
|
+
checkValidity(): boolean;
|
|
49
|
+
/**
|
|
50
|
+
* Returns true if internals target element has no validity problems; otherwise,
|
|
51
|
+
* returns false, fires an invalid event at the element, and (if the event isn't canceled) reports the problem to the user.
|
|
52
|
+
*/
|
|
53
|
+
reportValidity(): boolean;
|
|
54
|
+
/**
|
|
55
|
+
* Sets both the state and submission value of internals target element to value.
|
|
56
|
+
*
|
|
57
|
+
* While "null" isn't enumerated as a argument type (here)[https://html.spec.whatwg.org/multipage/custom-elements.html#the-elementinternals-interface],
|
|
58
|
+
* In practice it appears to remove the value from the form data on submission. Adding it as a valid type here
|
|
59
|
+
* becuase that capability is required for checkbox and radio types
|
|
60
|
+
*/
|
|
61
|
+
setFormValue(value: File | string | FormData | null, state?: File | string | FormData | null): void;
|
|
62
|
+
/**
|
|
63
|
+
* Marks internals target element as suffering from the constraints indicated by the flags argument,
|
|
64
|
+
* and sets the element's validation message to message.
|
|
65
|
+
* If anchor is specified, the user agent might use
|
|
66
|
+
* it to indicate problems with the constraints of internals target
|
|
67
|
+
* element when the form owner is validated interactively or reportValidity() is called.
|
|
68
|
+
*/
|
|
69
|
+
setValidity(flags: ValidityStateFlags, message?: string, anchor?: HTMLElement): void;
|
|
70
|
+
}
|
|
71
|
+
declare let ElementInternals: {
|
|
72
|
+
prototype: ElementInternals;
|
|
73
|
+
new (): ElementInternals;
|
|
74
|
+
};
|
|
75
|
+
/**
|
|
76
|
+
* @alpha
|
|
77
|
+
*/
|
|
78
|
+
export declare const supportsElementInternals: boolean;
|
|
79
|
+
/**
|
|
80
|
+
* Base class for providing Custom Element Form Association.
|
|
81
|
+
*
|
|
82
|
+
* @alpha
|
|
83
|
+
*/
|
|
84
|
+
export interface FormAssociated extends Omit<ElementInternals, "labels"> {
|
|
85
|
+
dirtyValue: boolean;
|
|
86
|
+
disabled: boolean;
|
|
87
|
+
readonly elementInternals: ElementInternals | null;
|
|
88
|
+
readonly formAssociated: boolean;
|
|
89
|
+
initialValue: string;
|
|
90
|
+
readonly labels: ReadonlyArray<Node[]>;
|
|
91
|
+
name: string;
|
|
92
|
+
required: boolean;
|
|
93
|
+
value: string;
|
|
94
|
+
currentValue: string;
|
|
95
|
+
attachProxy(): void;
|
|
96
|
+
detachProxy(): void;
|
|
97
|
+
disabledChanged?(previous: boolean, next: boolean): void;
|
|
98
|
+
formDisabledCallback?(disabled: boolean): void;
|
|
99
|
+
formResetCallback(): void;
|
|
100
|
+
initialValueChanged?(previous: string, next: string): void;
|
|
101
|
+
nameChanged?(previous: string, next: string): void;
|
|
102
|
+
requiredChanged(prev: boolean, next: boolean): void;
|
|
103
|
+
stopPropagation(e: Event): void;
|
|
104
|
+
/**
|
|
105
|
+
* Sets the validity of the custom element. By default this uses the proxy element to determine
|
|
106
|
+
* validity, but this can be extended or replaced in implementation.
|
|
107
|
+
*
|
|
108
|
+
* @param anchor - The anchor element to provide to ElementInternals.setValidity for surfacing the browser's constraint validation UI
|
|
109
|
+
*/
|
|
110
|
+
validate(anchor?: HTMLElement): void;
|
|
111
|
+
valueChanged(previous: string, next: string): void;
|
|
112
|
+
}
|
|
113
|
+
/**
|
|
114
|
+
* Base class for providing Custom Element Form Association with checkable features.
|
|
115
|
+
*
|
|
116
|
+
* @alpha
|
|
117
|
+
*/
|
|
118
|
+
export interface CheckableFormAssociated extends FormAssociated {
|
|
119
|
+
currentChecked: boolean;
|
|
120
|
+
dirtyChecked: boolean;
|
|
121
|
+
checkedAttribute: boolean;
|
|
122
|
+
defaultChecked: boolean;
|
|
123
|
+
defaultCheckedChanged(oldValue: boolean | undefined, newValue: boolean): void;
|
|
124
|
+
checked: boolean;
|
|
125
|
+
checkedChanged(oldValue: boolean | undefined, newValue: boolean): void;
|
|
126
|
+
}
|
|
127
|
+
/**
|
|
128
|
+
* Avaiable types for the `proxy` property.
|
|
129
|
+
* @alpha
|
|
130
|
+
*/
|
|
131
|
+
export type ProxyElement = HTMLSelectElement | HTMLTextAreaElement | HTMLInputElement;
|
|
132
|
+
/**
|
|
133
|
+
* Identifies a class as having a proxy element and optional submethods related
|
|
134
|
+
* to the proxy element.
|
|
135
|
+
*
|
|
136
|
+
* @alpha
|
|
137
|
+
*/
|
|
138
|
+
export interface FormAssociatedProxy {
|
|
139
|
+
proxy: ProxyElement;
|
|
140
|
+
disabledChanged?(previous: boolean, next: boolean): void;
|
|
141
|
+
formDisabledCallback?(disabled: boolean): void;
|
|
142
|
+
formResetCallback?(): void;
|
|
143
|
+
initialValueChanged?(previous: string, next: string): void;
|
|
144
|
+
valueChanged?(previous: string, next: string): void;
|
|
145
|
+
nameChanged?(previous: string, next: string): void;
|
|
146
|
+
}
|
|
147
|
+
/**
|
|
148
|
+
* Combined type to describe a Form-associated element.
|
|
149
|
+
*
|
|
150
|
+
* @alpha
|
|
151
|
+
*/
|
|
152
|
+
export type FormAssociatedElement = FormAssociated & FASTElement & HTMLElement & FormAssociatedProxy;
|
|
153
|
+
/**
|
|
154
|
+
* Combined type to describe a checkable Form-associated element.
|
|
155
|
+
*
|
|
156
|
+
* @alpha
|
|
157
|
+
*/
|
|
158
|
+
export type CheckableFormAssociatedElement = FormAssociatedElement & CheckableFormAssociated & {
|
|
159
|
+
proxy: HTMLInputElement;
|
|
160
|
+
};
|
|
161
|
+
/**
|
|
162
|
+
* Combined type to describe a Constructable Form-Associated type.
|
|
163
|
+
*
|
|
164
|
+
* @alpha
|
|
165
|
+
*/
|
|
166
|
+
export type ConstructableFormAssociated = Constructable<HTMLElement & FASTElement>;
|
|
167
|
+
/**
|
|
168
|
+
* Base function for providing Custom Element Form Association.
|
|
169
|
+
*
|
|
170
|
+
* @alpha
|
|
171
|
+
*/
|
|
172
|
+
export declare function FormAssociated<T extends ConstructableFormAssociated>(BaseCtor: T): T;
|
|
173
|
+
/**
|
|
174
|
+
* @alpha
|
|
175
|
+
*/
|
|
176
|
+
export declare function CheckableFormAssociated<T extends ConstructableFormAssociated>(BaseCtor: T): T;
|
|
177
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./form-associated.js";
|