@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,167 @@
|
|
|
1
|
+
import { ARIAGlobalStatesAndProperties, StartEnd, StartEndOptions } from "../patterns/index.js";
|
|
2
|
+
import type { FoundationElementDefinition } from "../foundation-element/foundation-element.js";
|
|
3
|
+
import { FormAssociatedButton } from "./button.form-associated.js";
|
|
4
|
+
/**
|
|
5
|
+
* Button configuration options
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export type ButtonOptions = FoundationElementDefinition & StartEndOptions;
|
|
9
|
+
/**
|
|
10
|
+
* A Button Custom HTML Element.
|
|
11
|
+
* Based largely on the {@link https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button | <button> element }.
|
|
12
|
+
*
|
|
13
|
+
* @slot start - Content which can be provided before the button content
|
|
14
|
+
* @slot end - Content which can be provided after the button content
|
|
15
|
+
* @slot - The default slot for button content
|
|
16
|
+
* @csspart control - The button element
|
|
17
|
+
* @csspart content - The element wrapping button content
|
|
18
|
+
*
|
|
19
|
+
* @public
|
|
20
|
+
*/
|
|
21
|
+
export declare class Button extends FormAssociatedButton {
|
|
22
|
+
/**
|
|
23
|
+
* Determines if the element should receive document focus on page load.
|
|
24
|
+
*
|
|
25
|
+
* @public
|
|
26
|
+
* @remarks
|
|
27
|
+
* HTML Attribute: autofocus
|
|
28
|
+
*/
|
|
29
|
+
autofocus: boolean;
|
|
30
|
+
/**
|
|
31
|
+
* The id of a form to associate the element to.
|
|
32
|
+
*
|
|
33
|
+
* @public
|
|
34
|
+
* @remarks
|
|
35
|
+
* HTML Attribute: form
|
|
36
|
+
*/
|
|
37
|
+
formId: string;
|
|
38
|
+
/**
|
|
39
|
+
* See {@link https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button | <button> element} for more details.
|
|
40
|
+
*
|
|
41
|
+
* @public
|
|
42
|
+
* @remarks
|
|
43
|
+
* HTML Attribute: formaction
|
|
44
|
+
*/
|
|
45
|
+
formaction: string;
|
|
46
|
+
private formactionChanged;
|
|
47
|
+
/**
|
|
48
|
+
* See {@link https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button | <button> element} for more details.
|
|
49
|
+
*
|
|
50
|
+
* @public
|
|
51
|
+
* @remarks
|
|
52
|
+
* HTML Attribute: formenctype
|
|
53
|
+
*/
|
|
54
|
+
formenctype: string;
|
|
55
|
+
private formenctypeChanged;
|
|
56
|
+
/**
|
|
57
|
+
* See {@link https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button | <button> element} for more details.
|
|
58
|
+
*
|
|
59
|
+
* @public
|
|
60
|
+
* @remarks
|
|
61
|
+
* HTML Attribute: formmethod
|
|
62
|
+
*/
|
|
63
|
+
formmethod: string;
|
|
64
|
+
private formmethodChanged;
|
|
65
|
+
/**
|
|
66
|
+
* See {@link https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button | <button> element} for more details.
|
|
67
|
+
*
|
|
68
|
+
* @public
|
|
69
|
+
* @remarks
|
|
70
|
+
* HTML Attribute: formnovalidate
|
|
71
|
+
*/
|
|
72
|
+
formnovalidate: boolean;
|
|
73
|
+
private formnovalidateChanged;
|
|
74
|
+
/**
|
|
75
|
+
* See {@link https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button | <button> element} for more details.
|
|
76
|
+
*
|
|
77
|
+
* @public
|
|
78
|
+
* @remarks
|
|
79
|
+
* HTML Attribute: formtarget
|
|
80
|
+
*/
|
|
81
|
+
formtarget: "_self" | "_blank" | "_parent" | "_top";
|
|
82
|
+
private formtargetChanged;
|
|
83
|
+
/**
|
|
84
|
+
* The button type.
|
|
85
|
+
*
|
|
86
|
+
* @public
|
|
87
|
+
* @remarks
|
|
88
|
+
* HTML Attribute: type
|
|
89
|
+
*/
|
|
90
|
+
type: "submit" | "reset" | "button";
|
|
91
|
+
private typeChanged;
|
|
92
|
+
/**
|
|
93
|
+
*
|
|
94
|
+
* Default slotted content
|
|
95
|
+
*
|
|
96
|
+
* @public
|
|
97
|
+
* @remarks
|
|
98
|
+
*/
|
|
99
|
+
defaultSlottedContent: HTMLElement[];
|
|
100
|
+
/** {@inheritDoc (FormAssociated:interface).validate} */
|
|
101
|
+
validate(): void;
|
|
102
|
+
/**
|
|
103
|
+
* @internal
|
|
104
|
+
*/
|
|
105
|
+
connectedCallback(): void;
|
|
106
|
+
/**
|
|
107
|
+
* @internal
|
|
108
|
+
*/
|
|
109
|
+
disconnectedCallback(): void;
|
|
110
|
+
/**
|
|
111
|
+
* Prevent events to propagate if disabled and has no slotted content wrapped in HTML elements
|
|
112
|
+
* @internal
|
|
113
|
+
*/
|
|
114
|
+
private handleClick;
|
|
115
|
+
/**
|
|
116
|
+
* Submits the parent form
|
|
117
|
+
*/
|
|
118
|
+
private handleSubmission;
|
|
119
|
+
/**
|
|
120
|
+
* Resets the parent form
|
|
121
|
+
*/
|
|
122
|
+
private handleFormReset;
|
|
123
|
+
control: HTMLButtonElement;
|
|
124
|
+
/**
|
|
125
|
+
* Overrides the focus call for where delegatesFocus is unsupported.
|
|
126
|
+
* This check works for Chrome, Edge Chromium, FireFox, and Safari
|
|
127
|
+
* Relevant PR on the Firefox browser: https://phabricator.services.mozilla.com/D123858
|
|
128
|
+
*/
|
|
129
|
+
private handleUnsupportedDelegatesFocus;
|
|
130
|
+
}
|
|
131
|
+
/**
|
|
132
|
+
* Includes ARIA states and properties relating to the ARIA button role
|
|
133
|
+
*
|
|
134
|
+
* @public
|
|
135
|
+
*/
|
|
136
|
+
export declare class DelegatesARIAButton {
|
|
137
|
+
/**
|
|
138
|
+
* See {@link https://www.w3.org/WAI/PF/aria/roles#button} for more information
|
|
139
|
+
* @public
|
|
140
|
+
* @remarks
|
|
141
|
+
* HTML Attribute: aria-expanded
|
|
142
|
+
*/
|
|
143
|
+
ariaExpanded: "true" | "false" | string | null;
|
|
144
|
+
/**
|
|
145
|
+
* See {@link https://www.w3.org/WAI/PF/aria/roles#button} for more information
|
|
146
|
+
* @public
|
|
147
|
+
* @remarks
|
|
148
|
+
* HTML Attribute: aria-pressed
|
|
149
|
+
*/
|
|
150
|
+
ariaPressed: "true" | "false" | "mixed" | string | null;
|
|
151
|
+
}
|
|
152
|
+
/**
|
|
153
|
+
* Mark internal because exporting class and interface of the same name
|
|
154
|
+
* confuses API documenter.
|
|
155
|
+
* TODO: https://github.com/microsoft/fast/issues/3317
|
|
156
|
+
* @internal
|
|
157
|
+
*/
|
|
158
|
+
export interface DelegatesARIAButton extends ARIAGlobalStatesAndProperties {
|
|
159
|
+
}
|
|
160
|
+
/**
|
|
161
|
+
* Mark internal because exporting class and interface of the same name
|
|
162
|
+
* confuses API documenter.
|
|
163
|
+
* TODO: https://github.com/microsoft/fast/issues/3317
|
|
164
|
+
* @internal
|
|
165
|
+
*/
|
|
166
|
+
export interface Button extends StartEnd, DelegatesARIAButton {
|
|
167
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { FormAssociated } from "../form-associated/form-associated.js";
|
|
2
|
+
import { FoundationElement } from "../foundation-element/foundation-element.js";
|
|
3
|
+
declare class _Button extends FoundationElement {
|
|
4
|
+
}
|
|
5
|
+
interface _Button extends FormAssociated {
|
|
6
|
+
}
|
|
7
|
+
declare const FormAssociatedButton_base: typeof _Button;
|
|
8
|
+
/**
|
|
9
|
+
* A form-associated base class for the {@link @ni/fast-foundation#(Button:class)} component.
|
|
10
|
+
*
|
|
11
|
+
* @internal
|
|
12
|
+
*/
|
|
13
|
+
export declare class FormAssociatedButton extends FormAssociatedButton_base {
|
|
14
|
+
proxy: HTMLInputElement;
|
|
15
|
+
}
|
|
16
|
+
export {};
|
|
@@ -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 { Button, ButtonOptions } from "./button.js";
|
|
4
|
+
/**
|
|
5
|
+
* The template for the {@link @ni/fast-foundation#(Button:class)} component.
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export declare const buttonTemplate: FoundationElementTemplate<ViewTemplate<Button>, ButtonOptions>;
|
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
import { SyntheticViewTemplate } from "@ni/fast-element";
|
|
2
|
+
import type { StartEndOptions } from "../patterns/start-end.js";
|
|
3
|
+
import { FoundationElement } from "../foundation-element/foundation-element.js";
|
|
4
|
+
import type { FoundationElementDefinition, FoundationElementTemplate } from "../foundation-element/foundation-element.js";
|
|
5
|
+
import type { DayFormat, MonthFormat, WeekdayFormat, YearFormat } from "./date-formatter.js";
|
|
6
|
+
import { DateFormatter } from "./date-formatter.js";
|
|
7
|
+
/**
|
|
8
|
+
* Information about a month
|
|
9
|
+
* @public
|
|
10
|
+
*/
|
|
11
|
+
export type MonthInfo = {
|
|
12
|
+
month: number;
|
|
13
|
+
year: number;
|
|
14
|
+
length: number;
|
|
15
|
+
start: number;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Calendar information needed for rendering
|
|
19
|
+
* including the next and previous months
|
|
20
|
+
* @public
|
|
21
|
+
*/
|
|
22
|
+
export type CalendarInfo = MonthInfo & {
|
|
23
|
+
previous: MonthInfo;
|
|
24
|
+
next: MonthInfo;
|
|
25
|
+
};
|
|
26
|
+
/**
|
|
27
|
+
* Caldendar date info
|
|
28
|
+
* used to represent a date
|
|
29
|
+
* @public
|
|
30
|
+
*/
|
|
31
|
+
export type CalendarDateInfo = {
|
|
32
|
+
day: number;
|
|
33
|
+
month: number;
|
|
34
|
+
year: number;
|
|
35
|
+
disabled?: boolean;
|
|
36
|
+
selected?: boolean;
|
|
37
|
+
};
|
|
38
|
+
/**
|
|
39
|
+
* Calendar configuration options
|
|
40
|
+
* @public
|
|
41
|
+
*/
|
|
42
|
+
export type CalendarOptions = FoundationElementDefinition & StartEndOptions & {
|
|
43
|
+
title?: FoundationElementTemplate<SyntheticViewTemplate<any, Calendar>, CalendarOptions> | SyntheticViewTemplate | string;
|
|
44
|
+
};
|
|
45
|
+
/**
|
|
46
|
+
* Calendar component
|
|
47
|
+
*
|
|
48
|
+
* @slot - The default slot for calendar content
|
|
49
|
+
* @fires dateselected - Fires a custom 'dateselected' event when Enter is invoked via keyboard on a date
|
|
50
|
+
*
|
|
51
|
+
* @public
|
|
52
|
+
*/
|
|
53
|
+
export declare class Calendar extends FoundationElement {
|
|
54
|
+
/**
|
|
55
|
+
* date formatter utitlity for getting localized strings
|
|
56
|
+
* @public
|
|
57
|
+
*/
|
|
58
|
+
dateFormatter: DateFormatter;
|
|
59
|
+
/**
|
|
60
|
+
* Readonly attribute for turning off data-grid
|
|
61
|
+
* @public
|
|
62
|
+
*/
|
|
63
|
+
readonly: boolean;
|
|
64
|
+
/**
|
|
65
|
+
* String repesentation of the full locale including market, calendar type and numbering system
|
|
66
|
+
* @public
|
|
67
|
+
*/
|
|
68
|
+
locale: string;
|
|
69
|
+
private localeChanged;
|
|
70
|
+
/**
|
|
71
|
+
* Month to display
|
|
72
|
+
* @public
|
|
73
|
+
*/
|
|
74
|
+
month: number;
|
|
75
|
+
/**
|
|
76
|
+
* Year of the month to display
|
|
77
|
+
* @public
|
|
78
|
+
*/
|
|
79
|
+
year: number;
|
|
80
|
+
/**
|
|
81
|
+
* Format style for the day
|
|
82
|
+
* @public
|
|
83
|
+
*/
|
|
84
|
+
dayFormat: DayFormat;
|
|
85
|
+
private dayFormatChanged;
|
|
86
|
+
/**
|
|
87
|
+
* Format style for the week day labels
|
|
88
|
+
* @public
|
|
89
|
+
*/
|
|
90
|
+
weekdayFormat: WeekdayFormat;
|
|
91
|
+
private weekdayFormatChanged;
|
|
92
|
+
/**
|
|
93
|
+
* Format style for the month label
|
|
94
|
+
* @public
|
|
95
|
+
*/
|
|
96
|
+
monthFormat: MonthFormat;
|
|
97
|
+
private monthFormatChanged;
|
|
98
|
+
/**
|
|
99
|
+
* Format style for the year used in the title
|
|
100
|
+
* @public
|
|
101
|
+
*/
|
|
102
|
+
yearFormat: YearFormat;
|
|
103
|
+
private yearFormatChanged;
|
|
104
|
+
/**
|
|
105
|
+
* Minimum number of weeks to show for the month
|
|
106
|
+
* This can be used to normalize the calendar view
|
|
107
|
+
* when changing or across multiple calendars
|
|
108
|
+
* @public
|
|
109
|
+
*/
|
|
110
|
+
minWeeks: number;
|
|
111
|
+
/**
|
|
112
|
+
* A list of dates that should be shown as disabled
|
|
113
|
+
* @public
|
|
114
|
+
*/
|
|
115
|
+
disabledDates: string;
|
|
116
|
+
/**
|
|
117
|
+
* A list of dates that should be shown as highlighted
|
|
118
|
+
* @public
|
|
119
|
+
*/
|
|
120
|
+
selectedDates: string;
|
|
121
|
+
/**
|
|
122
|
+
* The number of miliseconds in a day
|
|
123
|
+
* @internal
|
|
124
|
+
*/
|
|
125
|
+
private oneDayInMs;
|
|
126
|
+
/**
|
|
127
|
+
* Gets data needed to render about a calendar month as well as the previous and next months
|
|
128
|
+
* @param year - year of the calendar
|
|
129
|
+
* @param month - month of the calendar
|
|
130
|
+
* @returns - an object with data about the current and 2 surrounding months
|
|
131
|
+
* @public
|
|
132
|
+
*/
|
|
133
|
+
getMonthInfo(month?: number, year?: number): CalendarInfo;
|
|
134
|
+
/**
|
|
135
|
+
* A list of calendar days
|
|
136
|
+
* @param info - an object containing the information needed to render a calendar month
|
|
137
|
+
* @param minWeeks - minimum number of weeks to show
|
|
138
|
+
* @returns a list of days in a calendar month
|
|
139
|
+
* @public
|
|
140
|
+
*/
|
|
141
|
+
getDays(info?: CalendarInfo, minWeeks?: number): CalendarDateInfo[][];
|
|
142
|
+
/**
|
|
143
|
+
* A helper function that checks if a date exists in a list of dates
|
|
144
|
+
* @param date - A date objec that includes the day, month and year
|
|
145
|
+
* @param datesString - a comma separated list of dates
|
|
146
|
+
* @returns - Returns true if it found the date in the list of dates
|
|
147
|
+
* @public
|
|
148
|
+
*/
|
|
149
|
+
dateInString(date: Date | string, datesString: string): boolean;
|
|
150
|
+
/**
|
|
151
|
+
* Creates a class string for the day container
|
|
152
|
+
* @param date - date of the calendar cell
|
|
153
|
+
* @returns - string of class names
|
|
154
|
+
* @public
|
|
155
|
+
*/
|
|
156
|
+
getDayClassNames(date: CalendarDateInfo, todayString?: string): string;
|
|
157
|
+
/**
|
|
158
|
+
* Returns a list of weekday labels
|
|
159
|
+
* @returns An array of weekday text and full text if abbreviated
|
|
160
|
+
* @public
|
|
161
|
+
*/
|
|
162
|
+
getWeekdayText(): {
|
|
163
|
+
text: string;
|
|
164
|
+
abbr?: string;
|
|
165
|
+
}[];
|
|
166
|
+
/**
|
|
167
|
+
* Emits the "date-select" event with the day, month and year.
|
|
168
|
+
* @param date - Date cell
|
|
169
|
+
* @public
|
|
170
|
+
*/
|
|
171
|
+
handleDateSelect(event: Event, day: CalendarDateInfo): void;
|
|
172
|
+
/**
|
|
173
|
+
* Handles keyboard events on a cell
|
|
174
|
+
* @param event - Keyboard event
|
|
175
|
+
* @param date - Date of the cell selected
|
|
176
|
+
*/
|
|
177
|
+
handleKeydown(event: KeyboardEvent, date: CalendarDateInfo): boolean;
|
|
178
|
+
}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import type { ViewTemplate } from "@ni/fast-element";
|
|
2
|
+
import type { FoundationElementTemplate } from "../foundation-element/foundation-element.js";
|
|
3
|
+
import type { ElementDefinitionContext } from "../design-system/registration-context.js";
|
|
4
|
+
import type { Calendar, CalendarDateInfo, CalendarOptions } from "./calendar.js";
|
|
5
|
+
/**
|
|
6
|
+
* A basic Calendar title template that includes the month and year
|
|
7
|
+
* @returns - A calendar title template
|
|
8
|
+
* @public
|
|
9
|
+
*/
|
|
10
|
+
export declare const CalendarTitleTemplate: ViewTemplate<Calendar>;
|
|
11
|
+
/**
|
|
12
|
+
* Calendar weekday label template
|
|
13
|
+
* @returns - The weekday labels template
|
|
14
|
+
* @public
|
|
15
|
+
*/
|
|
16
|
+
export declare const calendarWeekdayTemplate: (context: ElementDefinitionContext) => ViewTemplate;
|
|
17
|
+
/**
|
|
18
|
+
* A calendar day template
|
|
19
|
+
* @param context - Element definition context for getting the cell tag for calendar-cell
|
|
20
|
+
* @param todayString - A string representation for todays date
|
|
21
|
+
* @returns - A calendar cell template for a given date
|
|
22
|
+
* @public
|
|
23
|
+
*/
|
|
24
|
+
export declare const calendarCellTemplate: (context: ElementDefinitionContext, todayString: string) => ViewTemplate<CalendarDateInfo>;
|
|
25
|
+
/**
|
|
26
|
+
*
|
|
27
|
+
* @param context - Element definition context for getting the cell tag for calendar-cell
|
|
28
|
+
* @param todayString - A string representation for todays date
|
|
29
|
+
* @returns - A template for a week of days
|
|
30
|
+
* @public
|
|
31
|
+
*/
|
|
32
|
+
export declare const calendarRowTemplate: (context: ElementDefinitionContext, todayString: string) => ViewTemplate;
|
|
33
|
+
/**
|
|
34
|
+
* Interactive template using DataGrid
|
|
35
|
+
* @param context - The templates context
|
|
36
|
+
* @param todayString - string representation of todays date
|
|
37
|
+
* @returns - interactive calendar template
|
|
38
|
+
*
|
|
39
|
+
* @internal
|
|
40
|
+
*/
|
|
41
|
+
export declare const interactiveCalendarGridTemplate: (context: ElementDefinitionContext, todayString: string) => ViewTemplate;
|
|
42
|
+
/**
|
|
43
|
+
* Non-interactive calendar template used for a readonly calendar
|
|
44
|
+
* @param todayString - string representation of todays date
|
|
45
|
+
* @returns - non-interactive calendar template
|
|
46
|
+
*
|
|
47
|
+
* @internal
|
|
48
|
+
*/
|
|
49
|
+
export declare const noninteractiveCalendarTemplate: (todayString: string) => ViewTemplate;
|
|
50
|
+
/**
|
|
51
|
+
* The template for the {@link @ni/fast-foundation#(Calendar:class)} component.
|
|
52
|
+
*
|
|
53
|
+
* @param context - Element definition context for getting the cell tag for calendar-cell
|
|
54
|
+
* @param definition - Foundation element definition
|
|
55
|
+
* @returns - a template for a calendar month
|
|
56
|
+
* @public
|
|
57
|
+
*/
|
|
58
|
+
export declare const calendarTemplate: FoundationElementTemplate<ViewTemplate<Calendar>, CalendarOptions>;
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A type representing the different day formats
|
|
3
|
+
* @public
|
|
4
|
+
*/
|
|
5
|
+
export type DayFormat = "2-digit" | "numeric";
|
|
6
|
+
/**
|
|
7
|
+
* A type representing the different weekday formats
|
|
8
|
+
* @public
|
|
9
|
+
*/
|
|
10
|
+
export type WeekdayFormat = "long" | "narrow" | "short";
|
|
11
|
+
/**
|
|
12
|
+
* A type representing the different month formats
|
|
13
|
+
* @public
|
|
14
|
+
*/
|
|
15
|
+
export type MonthFormat = "2-digit" | "long" | "narrow" | "numeric" | "short";
|
|
16
|
+
/**
|
|
17
|
+
* A type representing the different year formats
|
|
18
|
+
* @public
|
|
19
|
+
*/
|
|
20
|
+
export type YearFormat = "2-digit" | "numeric";
|
|
21
|
+
/**
|
|
22
|
+
* Date formatting utility
|
|
23
|
+
* @public
|
|
24
|
+
*/
|
|
25
|
+
export declare class DateFormatter {
|
|
26
|
+
/**
|
|
27
|
+
* Localization settings to use for formatting
|
|
28
|
+
* @public
|
|
29
|
+
*/
|
|
30
|
+
locale: string;
|
|
31
|
+
/**
|
|
32
|
+
* Formatting for the day
|
|
33
|
+
* @public
|
|
34
|
+
*/
|
|
35
|
+
dayFormat: DayFormat;
|
|
36
|
+
/**
|
|
37
|
+
* Formatting for the weekday labels
|
|
38
|
+
* @public
|
|
39
|
+
*/
|
|
40
|
+
weekdayFormat: WeekdayFormat;
|
|
41
|
+
/**
|
|
42
|
+
* Formatting for the month
|
|
43
|
+
* @public
|
|
44
|
+
*/
|
|
45
|
+
monthFormat: MonthFormat;
|
|
46
|
+
/**
|
|
47
|
+
* Formatting for the year
|
|
48
|
+
* @public
|
|
49
|
+
*/
|
|
50
|
+
yearFormat: YearFormat;
|
|
51
|
+
/**
|
|
52
|
+
* Date used for formatting
|
|
53
|
+
*/
|
|
54
|
+
date: Date;
|
|
55
|
+
constructor(config?: {});
|
|
56
|
+
/**
|
|
57
|
+
* Helper function to make sure that the DateFormatter is working with an instance of Date
|
|
58
|
+
* @param date - The date as an object, string or Date insance
|
|
59
|
+
* @returns - A Date instance
|
|
60
|
+
* @public
|
|
61
|
+
*/
|
|
62
|
+
getDateObject(date: {
|
|
63
|
+
day: number;
|
|
64
|
+
month: number;
|
|
65
|
+
year: number;
|
|
66
|
+
} | string | Date): Date;
|
|
67
|
+
/**
|
|
68
|
+
*
|
|
69
|
+
* @param date - a valide date as either a Date, string, objec or a DateFormatter
|
|
70
|
+
* @param format - The formatting for the string
|
|
71
|
+
* @param locale - locale data used for formatting
|
|
72
|
+
* @returns A localized string of the date provided
|
|
73
|
+
* @public
|
|
74
|
+
*/
|
|
75
|
+
getDate(date?: {
|
|
76
|
+
day: number;
|
|
77
|
+
month: number;
|
|
78
|
+
year: number;
|
|
79
|
+
} | string | Date, format?: Intl.DateTimeFormatOptions, locale?: string): string;
|
|
80
|
+
/**
|
|
81
|
+
*
|
|
82
|
+
* @param day - Day to localize
|
|
83
|
+
* @param format - The formatting for the day
|
|
84
|
+
* @param locale - The locale data used for formatting
|
|
85
|
+
* @returns - A localized number for the day
|
|
86
|
+
* @public
|
|
87
|
+
*/
|
|
88
|
+
getDay(day?: number, format?: DayFormat, locale?: string): string;
|
|
89
|
+
/**
|
|
90
|
+
*
|
|
91
|
+
* @param month - The month to localize
|
|
92
|
+
* @param format - The formatting for the month
|
|
93
|
+
* @param locale - The locale data used for formatting
|
|
94
|
+
* @returns - A localized name of the month
|
|
95
|
+
* @public
|
|
96
|
+
*/
|
|
97
|
+
getMonth(month?: number, format?: MonthFormat, locale?: string): string;
|
|
98
|
+
/**
|
|
99
|
+
*
|
|
100
|
+
* @param year - The year to localize
|
|
101
|
+
* @param format - The formatting for the year
|
|
102
|
+
* @param locale - The locale data used for formatting
|
|
103
|
+
* @returns - A localized string for the year
|
|
104
|
+
* @public
|
|
105
|
+
*/
|
|
106
|
+
getYear(year?: number, format?: YearFormat, locale?: string): string;
|
|
107
|
+
/**
|
|
108
|
+
*
|
|
109
|
+
* @param weekday - The number of the weekday, defaults to Sunday
|
|
110
|
+
* @param format - The formatting for the weekday label
|
|
111
|
+
* @param locale - The locale data used for formatting
|
|
112
|
+
* @returns - A formatted weekday label
|
|
113
|
+
* @public
|
|
114
|
+
*/
|
|
115
|
+
getWeekday(weekday?: number, format?: WeekdayFormat, locale?: string): string;
|
|
116
|
+
/**
|
|
117
|
+
*
|
|
118
|
+
* @param format - The formatting for the weekdays
|
|
119
|
+
* @param locale - The locale data used for formatting
|
|
120
|
+
* @returns - An array of the weekday labels
|
|
121
|
+
* @public
|
|
122
|
+
*/
|
|
123
|
+
getWeekdays(format?: WeekdayFormat, locale?: string): string[];
|
|
124
|
+
}
|
|
@@ -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 { Card } from "./card.js";
|
|
4
|
+
/**
|
|
5
|
+
* The template for the {@link @ni/fast-foundation#Card} component.
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export declare const cardTemplate: FoundationElementTemplate<ViewTemplate<Card>>;
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { SyntheticViewTemplate } from "@ni/fast-element";
|
|
2
|
+
import type { FoundationElementDefinition } from "../foundation-element/foundation-element.js";
|
|
3
|
+
import { FormAssociatedCheckbox } from "./checkbox.form-associated.js";
|
|
4
|
+
/**
|
|
5
|
+
* Checkbox configuration options
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export type CheckboxOptions = FoundationElementDefinition & {
|
|
9
|
+
checkedIndicator?: string | SyntheticViewTemplate;
|
|
10
|
+
indeterminateIndicator?: string | SyntheticViewTemplate;
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* A Checkbox Custom HTML Element.
|
|
14
|
+
* Implements the {@link https://www.w3.org/TR/wai-aria-1.1/#checkbox | ARIA checkbox }.
|
|
15
|
+
*
|
|
16
|
+
* @slot checked-indicator - The checked indicator
|
|
17
|
+
* @slot indeterminate-indicator - The indeterminate indicator
|
|
18
|
+
* @slot - The default slot for the label
|
|
19
|
+
* @csspart control - The element representing the visual checkbox control
|
|
20
|
+
* @csspart label - The label
|
|
21
|
+
* @fires change - Emits a custom change event when the checked state changes
|
|
22
|
+
*
|
|
23
|
+
* @public
|
|
24
|
+
*/
|
|
25
|
+
export declare class Checkbox extends FormAssociatedCheckbox {
|
|
26
|
+
/**
|
|
27
|
+
* When true, the control will be immutable by user interaction. See {@link https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/readonly | readonly HTML attribute} for more information.
|
|
28
|
+
* @public
|
|
29
|
+
* @remarks
|
|
30
|
+
* HTML Attribute: readonly
|
|
31
|
+
*/
|
|
32
|
+
readOnly: boolean;
|
|
33
|
+
private readOnlyChanged;
|
|
34
|
+
/**
|
|
35
|
+
* The element's value to be included in form submission when checked.
|
|
36
|
+
* Default to "on" to reach parity with input[type="checkbox"]
|
|
37
|
+
*
|
|
38
|
+
* @internal
|
|
39
|
+
*/
|
|
40
|
+
initialValue: string;
|
|
41
|
+
/**
|
|
42
|
+
* @internal
|
|
43
|
+
*/
|
|
44
|
+
defaultSlottedNodes: Node[];
|
|
45
|
+
/**
|
|
46
|
+
* The indeterminate state of the control
|
|
47
|
+
*/
|
|
48
|
+
indeterminate: boolean;
|
|
49
|
+
constructor();
|
|
50
|
+
/**
|
|
51
|
+
* @internal
|
|
52
|
+
*/
|
|
53
|
+
keypressHandler: (e: KeyboardEvent) => void;
|
|
54
|
+
/**
|
|
55
|
+
* @internal
|
|
56
|
+
*/
|
|
57
|
+
clickHandler: (e: MouseEvent) => void;
|
|
58
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { CheckableFormAssociated } from "../form-associated/form-associated.js";
|
|
2
|
+
import { FoundationElement } from "../foundation-element/foundation-element.js";
|
|
3
|
+
declare class _Checkbox extends FoundationElement {
|
|
4
|
+
}
|
|
5
|
+
interface _Checkbox extends CheckableFormAssociated {
|
|
6
|
+
}
|
|
7
|
+
declare const FormAssociatedCheckbox_base: typeof _Checkbox;
|
|
8
|
+
/**
|
|
9
|
+
* A form-associated base class for the {@link @ni/fast-foundation#(Checkbox:class)} component.
|
|
10
|
+
*
|
|
11
|
+
* @internal
|
|
12
|
+
*/
|
|
13
|
+
export declare class FormAssociatedCheckbox extends FormAssociatedCheckbox_base {
|
|
14
|
+
proxy: HTMLInputElement;
|
|
15
|
+
}
|
|
16
|
+
export {};
|
|
@@ -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 { Checkbox, CheckboxOptions } from "./checkbox.js";
|
|
4
|
+
/**
|
|
5
|
+
* The template for the {@link @ni/fast-foundation#(Checkbox:class)} component.
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
8
|
+
export declare const checkboxTemplate: FoundationElementTemplate<ViewTemplate<Checkbox>, CheckboxOptions>;
|