@lion/ui 0.20.0-menu-system.0 → 0.21.0
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/calendar-suites.js +1 -0
- package/collapsible.js +0 -1
- package/components/button/src/LionButton.js +0 -4
- package/components/button/test-suites/LionButton.suite.js +0 -1
- package/components/calendar/src/LionCalendar.js +1 -3
- package/components/calendar/test/lion-calendar.test.js +67 -47
- package/components/calendar/test-suites/LionCalendar.suite.js +79 -0
- package/components/combobox/test/lion-combobox.test.js +0 -1
- package/components/form-core/src/FormatMixin.js +17 -7
- package/components/form-core/src/form-group/FormGroupMixin.js +0 -7
- package/components/form-core/src/registration/FormRegistrarMixin.js +0 -11
- package/components/form-core/test/FormControlMixin.test.js +0 -1
- package/components/form-core/test/FormatMixin.test.js +4 -1
- package/components/form-core/test/validate/Validator.test.js +0 -2
- package/components/form-core/test-helpers/mimicUserInput.js +1 -0
- package/components/form-core/test-suites/FormatMixin.suite.js +273 -79
- package/components/form-core/test-suites/ValidateMixin.suite.js +0 -2
- package/components/form-core/test-suites/ValidateMixinFeedbackPart.suite.js +0 -1
- package/components/input/test/input-integrations.test.js +3 -2
- package/components/input/test/lion-input-integrations.test.js +2 -1
- package/components/input-amount/test/lion-input-amount-integrations.test.js +1 -1
- package/components/input-amount-dropdown/src/LionInputAmountDropdown.js +72 -11
- package/components/input-amount-dropdown/test/lion-input-amount-dropdown-integrations.test.js +27 -0
- package/components/input-amount-dropdown/test-suites/LionInputAmountDropdown.suite.js +60 -3
- package/components/input-date/test/lion-input-date-integrations.test.js +1 -1
- package/components/input-datepicker/src/LionInputDatepicker.js +4 -0
- package/components/input-datepicker/src/localizeNamespaceLoader.js +0 -1
- package/components/input-datepicker/test/lion-input-datepicker-integrations.test.js +1 -1
- package/components/input-datepicker/test/lion-input-datepicker.test.js +74 -9
- package/components/input-datepicker/test-suites/LionInputDatepicker.suite.js +35 -0
- package/components/input-email/src/LionInputEmail.js +2 -0
- package/components/input-email/test/lion-input-email-integrations.test.js +1 -1
- package/components/input-email/test/lion-input-email.test.js +6 -0
- package/components/input-file/src/validators.js +31 -1
- package/components/input-file/test/FileValidators.test.js +31 -0
- package/components/input-file/translations/bg.js +1 -0
- package/components/input-file/translations/cs.js +1 -0
- package/components/input-file/translations/de.js +2 -0
- package/components/input-file/translations/en.js +1 -0
- package/components/input-file/translations/es.js +1 -0
- package/components/input-file/translations/fr.js +1 -0
- package/components/input-file/translations/hu.js +1 -0
- package/components/input-file/translations/id.js +1 -0
- package/components/input-file/translations/it.js +1 -0
- package/components/input-file/translations/nl.js +1 -0
- package/components/input-file/translations/pl.js +1 -0
- package/components/input-file/translations/ro.js +1 -0
- package/components/input-file/translations/ru.js +1 -0
- package/components/input-file/translations/sk.js +1 -0
- package/components/input-file/translations/uk.js +1 -0
- package/components/input-file/translations/zh.js +1 -0
- package/components/input-iban/test/lion-input-iban-integrations.test.js +1 -1
- package/components/input-range/src/LionInputRange.js +51 -8
- package/components/input-range/test/lion-input-range.test.js +114 -0
- package/components/input-stepper/test-suites/lion-input-stepper.integration.suite.js +2 -2
- package/components/input-tel/src/LionInputTel.js +1 -1
- package/components/input-tel/test-suites/LionInputTel.suite.js +7 -0
- package/components/localize/test/date/formatDate.test.js +0 -1
- package/components/overlays/src/OverlayController.js +110 -278
- package/components/overlays/src/OverlayMixin.js +11 -58
- package/components/overlays/src/OverlaysManager.js +2 -2
- package/components/overlays/src/configurations/visibility-trigger-partials/withHoverInteraction.js +41 -9
- package/components/overlays/src/utils/adopt-styles.js +2 -3
- package/components/overlays/src/utils/get-focusable-elements.js +0 -4
- package/components/overlays/src/utils/is-equal-config.js +6 -10
- package/components/overlays/test/OverlayController.test.js +14 -127
- package/components/overlays/test/utils-tests/is-equal-config.test.js +1 -1
- package/components/overlays/test-suites/OverlayMixin.suite.js +8 -8
- package/components/overlays/test-suites/WithHoverInteraction.suite.js +212 -0
- package/components/overlays/types/ArrowMixinTypes.ts +1 -3
- package/components/overlays/types/OverlayConfig.ts +5 -20
- package/components/overlays/types/OverlayMixinTypes.ts +0 -2
- package/components/select-rich/test/lion-select-rich.test.js +0 -3
- package/components/textarea/test/lion-textarea-integrations.test.js +2 -1
- package/components/tooltip/test/lion-tooltip.test.js +9 -1
- package/custom-elements.json +20629 -32907
- package/dist-types/components/button/src/LionButton.d.ts +0 -1
- package/dist-types/components/button/src/LionButton.d.ts.map +1 -1
- package/dist-types/components/button/test-suites/LionButton.suite.d.ts.map +1 -1
- package/dist-types/components/calendar/src/LionCalendar.d.ts.map +1 -1
- package/dist-types/components/calendar/test/lion-calendar.test.d.ts.map +1 -1
- package/dist-types/components/calendar/test-suites/LionCalendar.suite.d.ts +5 -0
- package/dist-types/components/calendar/test-suites/LionCalendar.suite.d.ts.map +1 -0
- package/dist-types/components/combobox/src/LionCombobox.d.ts +1 -1
- package/dist-types/components/dialog/src/LionDialog.d.ts +2 -6
- package/dist-types/components/dialog/src/LionDialog.d.ts.map +1 -1
- package/dist-types/components/form-core/src/FormatMixin.d.ts.map +1 -1
- package/dist-types/components/form-core/src/form-group/FormGroupMixin.d.ts.map +1 -1
- package/dist-types/components/form-core/src/registration/FormRegistrarMixin.d.ts.map +1 -1
- package/dist-types/components/form-core/test-helpers/mimicUserInput.d.ts.map +1 -1
- package/dist-types/components/form-core/test-suites/FormatMixin.suite.d.ts +58 -5
- package/dist-types/components/form-core/test-suites/FormatMixin.suite.d.ts.map +1 -1
- package/dist-types/components/form-core/test-suites/ValidateMixin.suite.d.ts.map +1 -1
- package/dist-types/components/form-core/test-suites/ValidateMixinFeedbackPart.suite.d.ts.map +1 -1
- package/dist-types/components/icon/src/LionIcon.d.ts +2 -2
- package/dist-types/components/input-amount-dropdown/src/LionInputAmountDropdown.d.ts +24 -6
- package/dist-types/components/input-amount-dropdown/src/LionInputAmountDropdown.d.ts.map +1 -1
- package/dist-types/components/input-amount-dropdown/test/lion-input-amount-dropdown-integrations.test.d.ts +2 -0
- package/dist-types/components/input-amount-dropdown/test/lion-input-amount-dropdown-integrations.test.d.ts.map +1 -0
- package/dist-types/components/input-amount-dropdown/test-suites/LionInputAmountDropdown.suite.d.ts.map +1 -1
- package/dist-types/components/input-datepicker/src/LionInputDatepicker.d.ts +2 -1
- package/dist-types/components/input-datepicker/src/LionInputDatepicker.d.ts.map +1 -1
- package/dist-types/components/input-datepicker/src/localizeNamespaceLoader.d.ts.map +1 -1
- package/dist-types/components/input-datepicker/test/lion-input-datepicker.test.d.ts.map +1 -1
- package/dist-types/components/input-datepicker/test-suites/LionInputDatepicker.suite.d.ts +7 -0
- package/dist-types/components/input-datepicker/test-suites/LionInputDatepicker.suite.d.ts.map +1 -0
- package/dist-types/components/input-email/src/LionInputEmail.d.ts.map +1 -1
- package/dist-types/components/input-file/src/validators.d.ts +11 -0
- package/dist-types/components/input-file/src/validators.d.ts.map +1 -1
- package/dist-types/components/input-file/translations/bg-BG.d.ts +1 -0
- package/dist-types/components/input-file/translations/bg.d.ts +1 -0
- package/dist-types/components/input-file/translations/cs-CZ.d.ts +1 -0
- package/dist-types/components/input-file/translations/cs.d.ts +1 -0
- package/dist-types/components/input-file/translations/de-DE.d.ts +1 -0
- package/dist-types/components/input-file/translations/de.d.ts +1 -0
- package/dist-types/components/input-file/translations/en-AU.d.ts +1 -0
- package/dist-types/components/input-file/translations/en-GB.d.ts +1 -0
- package/dist-types/components/input-file/translations/en-PH.d.ts +1 -0
- package/dist-types/components/input-file/translations/en-US.d.ts +1 -0
- package/dist-types/components/input-file/translations/en.d.ts +1 -0
- package/dist-types/components/input-file/translations/es-ES.d.ts +1 -0
- package/dist-types/components/input-file/translations/es.d.ts +1 -0
- package/dist-types/components/input-file/translations/fr-BE.d.ts +1 -0
- package/dist-types/components/input-file/translations/fr-FR.d.ts +1 -0
- package/dist-types/components/input-file/translations/fr.d.ts +1 -0
- package/dist-types/components/input-file/translations/hu-HU.d.ts +1 -0
- package/dist-types/components/input-file/translations/hu.d.ts +1 -0
- package/dist-types/components/input-file/translations/id-ID.d.ts +1 -0
- package/dist-types/components/input-file/translations/id.d.ts +1 -0
- package/dist-types/components/input-file/translations/it-IT.d.ts +1 -0
- package/dist-types/components/input-file/translations/it.d.ts +1 -0
- package/dist-types/components/input-file/translations/nl-BE.d.ts +1 -0
- package/dist-types/components/input-file/translations/nl-NL.d.ts +1 -0
- package/dist-types/components/input-file/translations/nl.d.ts +1 -0
- package/dist-types/components/input-file/translations/pl-PL.d.ts +1 -0
- package/dist-types/components/input-file/translations/pl.d.ts +1 -0
- package/dist-types/components/input-file/translations/ro-RO.d.ts +1 -0
- package/dist-types/components/input-file/translations/ro.d.ts +1 -0
- package/dist-types/components/input-file/translations/ru-RU.d.ts +1 -0
- package/dist-types/components/input-file/translations/ru.d.ts +1 -0
- package/dist-types/components/input-file/translations/sk-SK.d.ts +1 -0
- package/dist-types/components/input-file/translations/sk.d.ts +1 -0
- package/dist-types/components/input-file/translations/uk-UA.d.ts +1 -0
- package/dist-types/components/input-file/translations/uk.d.ts +1 -0
- package/dist-types/components/input-file/translations/zh-CN.d.ts +1 -0
- package/dist-types/components/input-file/translations/zh.d.ts +1 -0
- package/dist-types/components/input-range/src/LionInputRange.d.ts +11 -0
- package/dist-types/components/input-range/src/LionInputRange.d.ts.map +1 -1
- package/dist-types/components/input-tel/src/LionInputTel.d.ts.map +1 -1
- package/dist-types/components/input-tel/test-suites/LionInputTel.suite.d.ts.map +1 -1
- package/dist-types/components/overlays/src/OverlayController.d.ts +12 -24
- package/dist-types/components/overlays/src/OverlayController.d.ts.map +1 -1
- package/dist-types/components/overlays/src/OverlayMixin.d.ts.map +1 -1
- package/dist-types/components/overlays/src/configurations/visibility-trigger-partials/withHoverInteraction.d.ts.map +1 -1
- package/dist-types/components/overlays/src/utils/get-focusable-elements.d.ts.map +1 -1
- package/dist-types/components/overlays/src/utils/is-equal-config.d.ts.map +1 -1
- package/dist-types/components/overlays/test-suites/WithHoverInteraction.suite.d.ts +17 -0
- package/dist-types/components/overlays/test-suites/WithHoverInteraction.suite.d.ts.map +1 -0
- package/dist-types/components/overlays/types/ArrowMixinTypes.d.ts.map +1 -1
- package/dist-types/components/overlays/types/OverlayConfig.d.ts +2 -12
- package/dist-types/components/overlays/types/OverlayConfig.d.ts.map +1 -1
- package/dist-types/components/overlays/types/OverlayMixinTypes.d.ts +0 -1
- package/dist-types/components/overlays/types/OverlayMixinTypes.d.ts.map +1 -1
- package/dist-types/components/select-rich/src/LionSelectRich.d.ts +3 -11
- package/dist-types/components/select-rich/src/LionSelectRich.d.ts.map +1 -1
- package/dist-types/components/tooltip/src/LionTooltip.d.ts +1 -1
- package/dist-types/components/tooltip/test/lion-tooltip.test.d.ts.map +1 -1
- package/dist-types/exports/calendar-suites.d.ts +2 -0
- package/dist-types/exports/calendar-suites.d.ts.map +1 -0
- package/dist-types/exports/input-datepicker-suites.d.ts +2 -0
- package/dist-types/exports/input-datepicker-suites.d.ts.map +1 -0
- package/dist-types/exports/input-file.d.ts +1 -1
- package/dist-types/exports/overlays-test-suites.d.ts +1 -0
- package/dist-types/exports/overlays.d.ts +0 -3
- package/dist-types/exports/overlays.d.ts.map +1 -1
- package/dist-types/tsconfig.tsbuildinfo +1 -1
- package/docs/components/checkbox-group/api-table.md +4 -2
- package/docs/components/checkbox-group/overview.md +2 -2
- package/docs/components/collapsible/overview.md +1 -1
- package/docs/components/combobox/api-table.md +8 -21
- package/docs/components/combobox/overview.md +1 -1
- package/docs/components/combobox/use-cases.md +1 -1
- package/docs/components/dialog/api-table.md +6 -31
- package/docs/components/dialog/overview.md +1 -1
- package/docs/components/fieldset/overview.md +5 -5
- package/docs/components/form/overview.md +3 -3
- package/docs/components/form/use-cases.md +2 -2
- package/docs/components/icon/use-cases.md +1 -1
- package/docs/components/input/api-table.md +2 -1
- package/docs/components/input/overview.md +1 -1
- package/docs/components/input-amount/api-table.md +2 -1
- package/docs/components/input-amount/overview.md +3 -3
- package/docs/components/input-amount-dropdown/api-table.md +3 -2
- package/docs/components/input-date/api-table.md +2 -1
- package/docs/components/input-date/overview.md +3 -3
- package/docs/components/input-datepicker/api-table.md +6 -22
- package/docs/components/input-datepicker/overview.md +5 -5
- package/docs/components/input-email/api-table.md +3 -2
- package/docs/components/input-email/overview.md +2 -2
- package/docs/components/input-file/api-table.md +2 -1
- package/docs/components/input-file/overview.md +1 -1
- package/docs/components/input-file/use-cases.md +18 -0
- package/docs/components/input-iban/api-table.md +2 -1
- package/docs/components/input-iban/overview.md +2 -2
- package/docs/components/input-range/api-table.md +7 -1
- package/docs/components/input-range/overview.md +2 -2
- package/docs/components/input-range/use-cases.md +14 -0
- package/docs/components/input-stepper/api-table.md +2 -1
- package/docs/components/input-stepper/overview.md +1 -1
- package/docs/components/input-tel/api-table.md +3 -2
- package/docs/components/input-tel/overview.md +1 -1
- package/docs/components/input-tel/use-cases.md +6 -6
- package/docs/components/input-tel-dropdown/api-table.md +3 -2
- package/docs/components/input-tel-dropdown/overview.md +1 -1
- package/docs/components/listbox/api-table.md +2 -1
- package/docs/components/listbox/use-cases.md +1 -1
- package/docs/components/radio-group/api-table.md +2 -1
- package/docs/components/radio-group/overview.md +3 -3
- package/docs/components/select/api-table.md +2 -1
- package/docs/components/select/use-cases.md +1 -1
- package/docs/components/select-rich/api-table.md +5 -21
- package/docs/components/select-rich/use-cases.md +2 -2
- package/docs/components/switch/api-table.md +2 -1
- package/docs/components/tabs/examples.md +1 -1
- package/docs/components/textarea/api-table.md +2 -1
- package/docs/components/tooltip/api-table.md +11 -36
- package/docs/components/tooltip/use-cases.md +34 -1
- package/docs/fundamentals/index.md +4 -4
- package/docs/fundamentals/node-tools/publish-docs/overview.md +3 -3
- package/docs/fundamentals/node-tools/rocket-preset-extend-lion-docs/overview.md +2 -2
- package/docs/fundamentals/rationales/accessibility.md +1 -1
- package/docs/fundamentals/systems/core/SlotMixin.md +1 -1
- package/docs/fundamentals/systems/core/overview.md +1 -1
- package/docs/fundamentals/systems/form/api-table.md +2 -1
- package/docs/fundamentals/systems/form/formatting-and-parsing.md +4 -4
- package/docs/fundamentals/systems/form/model-value.md +1 -1
- package/docs/fundamentals/systems/form/overview.md +28 -28
- package/docs/fundamentals/systems/form/validate.md +2 -2
- package/docs/fundamentals/systems/localize/overview.md +4 -4
- package/docs/fundamentals/systems/overlays/api-table.md +34 -36
- package/docs/fundamentals/systems/overlays/configuration.md +2 -2
- package/docs/fundamentals/systems/overlays/overview.md +5 -5
- package/docs/fundamentals/systems/overlays/use-cases.md +2 -2
- package/docs/fundamentals/tools/helpers/overview.md +1 -1
- package/docs/fundamentals/tools/singleton-manager/overview.md +4 -4
- package/docs/guides/how-to/create-a-custom-field.md +5 -5
- package/docs/guides/how-to/create-a-form.md +4 -4
- package/docs/guides/how-to/extend-a-native-input.md +2 -2
- package/docs/guides/how-to/index.md +1 -1
- package/docs/guides/index.md +8 -8
- package/docs/guides/principles/index.md +5 -5
- package/docs/guides/principles/styling.md +1 -1
- package/exports/calendar-suites.js +1 -0
- package/exports/collapsible.js +0 -1
- package/exports/input-datepicker-suites.js +1 -0
- package/exports/input-file.js +5 -1
- package/exports/overlays-test-suites.js +1 -0
- package/exports/overlays.js +0 -6
- package/input-datepicker-suites.js +1 -0
- package/input-file.js +5 -1
- package/overlays-test-suites.js +1 -0
- package/overlays.js +0 -6
- package/package.json +2 -2
- package/components/collapsible/src/DisclosureMixin.js +0 -313
- package/components/collapsible/test-suites/DisclosureMixin.suite.js +0 -30
- package/components/collapsible/types/DisclosureMixinTypes.ts +0 -48
- package/components/menu/CHANGELOG.md +0 -37
- package/components/menu/README.md +0 -335
- package/components/menu/index.js +0 -2
- package/components/menu/lion-menu-overlay.js +0 -3
- package/components/menu/lion-menu.js +0 -3
- package/components/menu/lion-spinbutton.js +0 -3
- package/components/menu/lion-toolbar.js +0 -3
- package/components/menu/lion-tree.js +0 -3
- package/components/menu/package.json +0 -46
- package/components/menu/requirements.temp.md +0 -12
- package/components/menu/src/InteractiveListMixin.js +0 -840
- package/components/menu/src/LionMenu.js +0 -250
- package/components/menu/src/LionMenuHybrid.js +0 -46
- package/components/menu/src/LionMenuOverlay.js +0 -155
- package/components/menu/src/LionSpinbutton.js +0 -213
- package/components/menu/src/LionToolbar.js +0 -94
- package/components/menu/src/LionTree.js +0 -52
- package/components/menu/src/MoreButtonMenuMixin.js +0 -278
- package/components/menu/src/MultiLevelListMixin.js +0 -311
- package/components/menu/src/utils/isInView.js +0 -26
- package/components/menu/src/utils/listItemInteractions.js +0 -124
- package/components/menu/test/InteractiveListMixin.test.js +0 -3
- package/components/menu/test/MoreButtonMenuMixin.test.js +0 -4
- package/components/menu/test/MultiLevelListMixin.test.js +0 -3
- package/components/menu/test/lion-menu-hybrid.test.js +0 -3
- package/components/menu/test/lion-menu.test.js +0 -11
- package/components/menu/test/lion-toolbar.test.js +0 -8
- package/components/menu/test/lion-tree.test.js +0 -7
- package/components/menu/test-helpers/mimicKeyPress.js +0 -9
- package/components/menu/test-suites/InteractiveListMixin.suite.js +0 -454
- package/components/menu/test-suites/LionMenu.suite.js +0 -113
- package/components/menu/test-suites/LionMenuHybrid.suite.js +0 -583
- package/components/menu/test-suites/MoreButtonMenuMixin.suite.js +0 -372
- package/components/menu/test-suites/MultiLevelListMixin.suite.js +0 -303
- package/components/menu/types/InteractiveListMixinTypes.d.ts +0 -84
- package/components/navigation-bar/README.md +0 -1
- package/components/navigation-bar/src/LionNavigationBar.js +0 -439
- package/components/navigation-bar/src/types.js +0 -41
- package/components/overlays/NEXT.md +0 -49
- package/components/overlays/test/withHoverInteraction.test.js +0 -90
- package/dist-types/components/collapsible/src/DisclosureMixin.d.ts +0 -3
- package/dist-types/components/collapsible/src/DisclosureMixin.d.ts.map +0 -1
- package/dist-types/components/collapsible/test-suites/DisclosureMixin.suite.d.ts +0 -2
- package/dist-types/components/collapsible/test-suites/DisclosureMixin.suite.d.ts.map +0 -1
- package/dist-types/components/collapsible/types/DisclosureMixinTypes.d.ts +0 -24
- package/dist-types/components/collapsible/types/DisclosureMixinTypes.d.ts.map +0 -1
- package/dist-types/components/menu/index.d.ts +0 -3
- package/dist-types/components/menu/index.d.ts.map +0 -1
- package/dist-types/components/menu/lion-menu-overlay.d.ts +0 -2
- package/dist-types/components/menu/lion-menu-overlay.d.ts.map +0 -1
- package/dist-types/components/menu/lion-menu.d.ts +0 -2
- package/dist-types/components/menu/lion-menu.d.ts.map +0 -1
- package/dist-types/components/menu/lion-spinbutton.d.ts +0 -2
- package/dist-types/components/menu/lion-spinbutton.d.ts.map +0 -1
- package/dist-types/components/menu/lion-toolbar.d.ts +0 -2
- package/dist-types/components/menu/lion-toolbar.d.ts.map +0 -1
- package/dist-types/components/menu/lion-tree.d.ts +0 -2
- package/dist-types/components/menu/lion-tree.d.ts.map +0 -1
- package/dist-types/components/menu/src/InteractiveListMixin.d.ts +0 -617
- package/dist-types/components/menu/src/InteractiveListMixin.d.ts.map +0 -1
- package/dist-types/components/menu/src/LionMenu.d.ts +0 -635
- package/dist-types/components/menu/src/LionMenu.d.ts.map +0 -1
- package/dist-types/components/menu/src/LionMenuHybrid.d.ts +0 -19
- package/dist-types/components/menu/src/LionMenuHybrid.d.ts.map +0 -1
- package/dist-types/components/menu/src/LionMenuOverlay.d.ts +0 -1015
- package/dist-types/components/menu/src/LionMenuOverlay.d.ts.map +0 -1
- package/dist-types/components/menu/src/LionSpinbutton.d.ts +0 -58
- package/dist-types/components/menu/src/LionSpinbutton.d.ts.map +0 -1
- package/dist-types/components/menu/src/LionToolbar.d.ts +0 -8
- package/dist-types/components/menu/src/LionToolbar.d.ts.map +0 -1
- package/dist-types/components/menu/src/LionTree.d.ts +0 -447
- package/dist-types/components/menu/src/LionTree.d.ts.map +0 -1
- package/dist-types/components/menu/src/MoreButtonMenuMixin.d.ts +0 -39
- package/dist-types/components/menu/src/MoreButtonMenuMixin.d.ts.map +0 -1
- package/dist-types/components/menu/src/MultiLevelListMixin.d.ts +0 -503
- package/dist-types/components/menu/src/MultiLevelListMixin.d.ts.map +0 -1
- package/dist-types/components/menu/src/utils/isInView.d.ts +0 -9
- package/dist-types/components/menu/src/utils/isInView.d.ts.map +0 -1
- package/dist-types/components/menu/src/utils/listItemInteractions.d.ts +0 -48
- package/dist-types/components/menu/src/utils/listItemInteractions.d.ts.map +0 -1
- package/dist-types/components/menu/test/InteractiveListMixin.test.d.ts +0 -2
- package/dist-types/components/menu/test/InteractiveListMixin.test.d.ts.map +0 -1
- package/dist-types/components/menu/test/MoreButtonMenuMixin.test.d.ts +0 -2
- package/dist-types/components/menu/test/MoreButtonMenuMixin.test.d.ts.map +0 -1
- package/dist-types/components/menu/test/MultiLevelListMixin.test.d.ts +0 -2
- package/dist-types/components/menu/test/MultiLevelListMixin.test.d.ts.map +0 -1
- package/dist-types/components/menu/test/lion-menu-hybrid.test.d.ts +0 -2
- package/dist-types/components/menu/test/lion-menu-hybrid.test.d.ts.map +0 -1
- package/dist-types/components/menu/test/lion-menu.test.d.ts +0 -2
- package/dist-types/components/menu/test/lion-menu.test.d.ts.map +0 -1
- package/dist-types/components/menu/test/lion-toolbar.test.d.ts +0 -2
- package/dist-types/components/menu/test/lion-toolbar.test.d.ts.map +0 -1
- package/dist-types/components/menu/test/lion-tree.test.d.ts +0 -2
- package/dist-types/components/menu/test/lion-tree.test.d.ts.map +0 -1
- package/dist-types/components/menu/test-helpers/mimicKeyPress.d.ts +0 -7
- package/dist-types/components/menu/test-helpers/mimicKeyPress.d.ts.map +0 -1
- package/dist-types/components/menu/test-suites/InteractiveListMixin.suite.d.ts +0 -14
- package/dist-types/components/menu/test-suites/InteractiveListMixin.suite.d.ts.map +0 -1
- package/dist-types/components/menu/test-suites/LionMenu.suite.d.ts +0 -9
- package/dist-types/components/menu/test-suites/LionMenu.suite.d.ts.map +0 -1
- package/dist-types/components/menu/test-suites/LionMenuHybrid.suite.d.ts +0 -5
- package/dist-types/components/menu/test-suites/LionMenuHybrid.suite.d.ts.map +0 -1
- package/dist-types/components/menu/test-suites/MoreButtonMenuMixin.suite.d.ts +0 -14
- package/dist-types/components/menu/test-suites/MoreButtonMenuMixin.suite.d.ts.map +0 -1
- package/dist-types/components/menu/test-suites/MultiLevelListMixin.suite.d.ts +0 -11
- package/dist-types/components/menu/test-suites/MultiLevelListMixin.suite.d.ts.map +0 -1
- package/dist-types/components/navigation-bar/src/LionNavigationBar.d.ts +0 -238
- package/dist-types/components/navigation-bar/src/LionNavigationBar.d.ts.map +0 -1
- package/dist-types/components/navigation-bar/src/types.d.ts +0 -85
- package/dist-types/components/navigation-bar/src/types.d.ts.map +0 -1
- package/dist-types/components/overlays/test/withHoverInteraction.test.d.ts +0 -2
- package/dist-types/components/overlays/test/withHoverInteraction.test.d.ts.map +0 -1
- package/dist-types/exports/define/lion-item.d.ts +0 -2
- package/dist-types/exports/define/lion-item.d.ts.map +0 -1
- package/dist-types/exports/define/lion-menu-overlay.d.ts +0 -2
- package/dist-types/exports/define/lion-menu-overlay.d.ts.map +0 -1
- package/dist-types/exports/define/lion-menu.d.ts +0 -2
- package/dist-types/exports/define/lion-menu.d.ts.map +0 -1
- package/dist-types/exports/define/lion-navigation-bar.d.ts +0 -2
- package/dist-types/exports/define/lion-navigation-bar.d.ts.map +0 -1
- package/dist-types/exports/define/lion-toolbar.d.ts +0 -2
- package/dist-types/exports/define/lion-toolbar.d.ts.map +0 -1
- package/dist-types/exports/define/lion-tree.d.ts +0 -2
- package/dist-types/exports/define/lion-tree.d.ts.map +0 -1
- package/dist-types/exports/menu-test-suites.d.ts +0 -4
- package/dist-types/exports/menu-test-suites.d.ts.map +0 -1
- package/dist-types/exports/menu.d.ts +0 -7
- package/dist-types/exports/menu.d.ts.map +0 -1
- package/dist-types/exports/navigation-bar.d.ts +0 -2
- package/dist-types/exports/navigation-bar.d.ts.map +0 -1
- package/docs/components/menu/api-table.md +0 -460
- package/docs/components/menu/applyMenuDemoStyles.js +0 -173
- package/docs/components/menu/extensions.md +0 -262
- package/docs/components/menu/index.md +0 -13
- package/docs/components/menu/overview.md +0 -422
- package/docs/components/menu/use-cases.md +0 -77
- package/exports/define/lion-item.js +0 -3
- package/exports/define/lion-menu-overlay.js +0 -3
- package/exports/define/lion-menu.js +0 -3
- package/exports/define/lion-navigation-bar.js +0 -3
- package/exports/define/lion-toolbar.js +0 -3
- package/exports/define/lion-tree.js +0 -3
- package/exports/menu-test-suites.js +0 -4
- package/exports/menu.js +0 -7
- package/exports/navigation-bar.js +0 -1
- package/menu-test-suites.js +0 -4
- package/menu.js +0 -7
- package/navigation-bar.js +0 -1
|
@@ -22,7 +22,6 @@ eleventyNavigation:
|
|
|
22
22
|
| `autocomplete` | public | `string \| undefined` | `undefined` | Delegates this property to input/textarea/select. | NativeTextFieldMixin |
|
|
23
23
|
| `autofocus` | public | `boolean` | `false` | | LionField |
|
|
24
24
|
| `calendarHeading` | public | `string` | | The heading to be added on top of the calendar overlay.
Naming chosen from an Application Developer perspective.
For a Subclasser 'calendarOverlayHeading' would be more appropriate. | |
|
|
25
|
-
| `config` | public | `Partial<OverlayConfig>` | `{}` | Configure the many options of the \`OverlayController\` | OverlayMixin |
|
|
26
25
|
| `defaultValidators` | public | `Validator[]` | `[]` | Used by Subclassers to add default Validators to a particular FormControl.
A date input for instance, always needs the isDate validator. | LionField |
|
|
27
26
|
| `dirty` | public | `boolean` | `false` | True when user has changed the value of the field. | LionField |
|
|
28
27
|
| `disabled` | public | `boolean` | `false` | | LionField |
|
|
@@ -42,7 +41,6 @@ eleventyNavigation:
|
|
|
42
41
|
| `labelSrOnly` | public | `boolean` | `false` | The label will only be visible for srceen readers when true | LionField |
|
|
43
42
|
| `modelValue` | public | | | | LionField |
|
|
44
43
|
| `name` | public | `string` | `''` | The name the element will be registered with to the .formElements collection
of the parent. Also, it serves as the key of key/value pairs in
 modelValue/serializedValue objects | LionField |
|
|
45
|
-
| `opened` | public | `boolean` | `false` | If you add the opened attribute a dialog will be opened on page load. The invoker can be left out
in case the user does not need to be able to reopen the dialog. | OverlayMixin |
|
|
46
44
|
| `operationMode` | public | `OperationMode` | | Types of input interaction of the FormControl (for instance 'enter'\|'select'\|'upload') | LionField |
|
|
47
45
|
| `parser` | public | | | Converts viewValue to modelValue
For instance, a localized date to a Date Object | LionField |
|
|
48
46
|
| `placeholder` | public | `string` | `''` | | LionInput |
|
|
@@ -74,17 +72,15 @@ eleventyNavigation:
|
|
|
74
72
|
| `_inputId` | protected | `string` | | Unique id that can be used in all light dom | LionField |
|
|
75
73
|
| `_inputNode` | protected | `HTMLInputElement \| HTMLTextAreaElement` | | The interactive (form) element. Can be a native element like input/textarea/select or
an element with tabindex > -1 | LionField |
|
|
76
74
|
| `_invokerNode` | protected | | | | |
|
|
75
|
+
| `_isEditingTextField` | protected | | | | LionField |
|
|
77
76
|
| `_isHandlingCalendarUserInput` | protected | `boolean` | `false` | | |
|
|
78
77
|
| `_isHandlingUserInput` | protected | `boolean` | `false` | Flag that will be set when user interaction takes place (for instance after an 'input'
event). Will be added as meta info to the \`model-value-changed\` event. Depending on
whether a user is interacting, formatting logic will be handled differently. | LionField |
|
|
79
78
|
| `_isPasting` | protected | `boolean` | `false` | Whether the user is pasting content. Allows Subclassers to do this in their subclass: | LionField |
|
|
80
79
|
| `_isRepropagationEndpoint` | public | `boolean` | `false` | By default, a field with \_repropagationRole 'choice-group' will act as an
'endpoint'. This means it will be considered as an individual field: for
a select, individual options will not be part of the formPath. They
will.
Similarly, components that (a11y wise) need to be fieldsets, but 'interaction wise'
(from Application Developer perspective) need to be more like fields
(think of an amount-input with a currency select box next to it), can set this
to true to hide private internals in the formPath. | LionField |
|
|
81
80
|
| `_labelNode` | protected | | | Element where label will be rendered to | LionField |
|
|
82
81
|
| `_leaveEvent` | protected | `string` | `'blur'` | The event that triggers the touched state | LionField |
|
|
83
|
-
| `
|
|
84
|
-
| `
|
|
85
|
-
| `_overlayContentWrapperNode` | protected | | | | OverlayMixin |
|
|
86
|
-
| `_overlayInvokerNode` | protected | | | | OverlayMixin |
|
|
87
|
-
| `_overlayReferenceNode` | protected | | | | OverlayMixin |
|
|
82
|
+
| `_overlayContentNode` | protected | | | | |
|
|
83
|
+
| `_overlayInvokerNode` | protected | | | | |
|
|
88
84
|
| `_parentFormGroup` | protected | `FormRegistrarHost \| undefined` | `undefined` | The registrar this FormControl registers to, Usually a descendant of FormGroup or
ChoiceGroup | LionField |
|
|
89
85
|
| `_repropagationRole` | public | `'child'\|'choice-group'\|'fieldset'` | `'child'` | Based on the role, details of handling model-value-changed repropagation differ. | LionField |
|
|
90
86
|
| `_requestedToBeDisabled` | protected | `boolean` | `false` | | LionField |
|
|
@@ -102,7 +98,6 @@ eleventyNavigation:
|
|
|
102
98
|
| `blur` | public | Calls \`blur()\` on focusable element within | | | LionField |
|
|
103
99
|
| `clear` | public | Clears modelValue.
Interaction states are not cleared (use resetInteractionState for this) | | | LionField |
|
|
104
100
|
| `click` | public | | | | LionField |
|
|
105
|
-
| `close` | public | Hides the overlay | | | OverlayMixin |
|
|
106
101
|
| `createScopedElement` | public | | `tagName` | | LionField |
|
|
107
102
|
| `defineScopedElement` | public | Defines a scoped element. | `tagName: string, classToBeRegistered: typeof HTMLElement` | | LionField |
|
|
108
103
|
| `deserializer` | public | Converts \`.serializedValue\` to \`.modelValue\`
For instance, an iso formatted date string to a Date object | `serializedValue: string` | `?` | LionField |
|
|
@@ -110,16 +105,13 @@ eleventyNavigation:
|
|
|
110
105
|
| `focus` | public | Calls \`focus()\` on focusable element within | | | LionField |
|
|
111
106
|
| `initInteractionState` | public | Evaluations performed on connectedCallback.
This method is public, so it can be called at a later moment (when we need to wait for
registering children for instance) as well.
Since this method will be called twice in last mentioned scenario, it must stay idempotent. | | | LionField |
|
|
112
107
|
| `makeRequestToBeDisabled` | public | | | | LionField |
|
|
113
|
-
| `
|
|
114
|
-
| `preprocessor` | public | Preprocessors could be considered 'live formatters'. Their result is shown to the user
on keyup instead of after blurring the field. The biggest difference between preprocessors
and formatters is their moment of execution: preprocessors are run before modelValue is
computed (and work based on view value), whereas formatters are run after the parser (and
are based on modelValue)
Automatically formats code while typing. It depends on a preprocessro that smartly
updates the viewValue and caret position for best UX. | `v: string, opts: FormatOptions & { prevViewValue: string; currentCaretIndex: number }` | `{ viewValue:string; caretIndex:number; }\|string\|undefined` | LionField |
|
|
108
|
+
| `preprocessor` | public | Preprocessors could be considered 'live formatters'. Their result is shown to the user
on keyup instead of after blurring the field. The biggest difference between preprocessors
and formatters is their moment of execution: preprocessors are run before modelValue is
computed (and work based on view value), whereas formatters are run after the parser (and
are based on modelValue)
Automatically formats code while typing. It depends on a preprocessor that smartly
updates the viewValue and caret position for best UX. | `v: string, opts: FormatOptions & { prevViewValue: string; currentCaretIndex: number }` | `{ viewValue:string; caretIndex:number; }\|string\|undefined` | LionField |
|
|
115
109
|
| `removeFromAriaDescribedBy` | public | Allows to remove element references from aria-describedby attribute. | `element: HTMLElement` | | LionField |
|
|
116
110
|
| `removeFromAriaLabelledBy` | public | Allows to remove element references from aria-labelledby attribute. | `element: HTMLElement` | | LionField |
|
|
117
|
-
| `repositionOverlay` | public | Sometimes it's needed to recompute Popper position of an overlay, for instance when we have
an opened combobox and the surrounding context changes (the space consumed by the textbox
increases vertically) | | | OverlayMixin |
|
|
118
111
|
| `reset` | public | Resets modelValue to initial value.
Interaction states are cleared | | | LionField |
|
|
119
112
|
| `resetInteractionState` | public | Resets touched and dirty, and recomputes prefilled | | | LionField |
|
|
120
113
|
| `retractRequestToBeDisabled` | public | | | | LionField |
|
|
121
114
|
| `serializer` | public | Converts \`.modelValue\` to \`.serializedValue\`
For instance, a Date object to an iso formatted date string | `modelValue: Date` | `string` | LionField |
|
|
122
|
-
| `toggle` | public | Toggles the overlay | | | OverlayMixin |
|
|
123
115
|
| `updateSync` | public | An abstraction that has the exact same api as \`requestUpdate\`, but taking
into account:
- \[member order independence]\(https\://github.com/webcomponents/gold-standard/wiki/Member-Order-Independence)
- property effects start when all (light) dom has initialized (on firstUpdated)
- property effects don't interrupt the first meaningful paint
- compatible with propertyAccessor.\`hasChanged\`: no manual checks needed or accidentally
run property effects / events when no change happened
effects when values didn't change
All code previously present in requestUpdate can be placed in this method. | `name: string, oldValue: ?` | | LionField |
|
|
124
116
|
| `validate` | public | Triggered by:
 \- modelValue change
 \- change in the 'validators' array
 \- change in the config of an individual Validator

Three situations are handled:
- a1) the FormControl is empty: further execution is halted. When the Required Validator
(being mutually exclusive to the other Validators) is applied, it will end up in the
validation result (as the only Validator, since further execution was halted).
- a2) there are synchronous Validators: this is the most common flow. When modelValue hasn't
changed since last async results were generated, 'sync results' are merged with the
'async results'.
- a3) there are asynchronous Validators: for instance when server side evaluation is needed.
Executions are scheduled and awaited and the 'async results' are merged with the
'sync results'.

- b) there are MetaValidators. After steps a1, a2, or a3 are finished, the holistic
MetaValidators (evaluating the total result of the 'regular' (a1, a2 and a3) validators)
will be run...

Situations a2 and a3 are not mutually exclusive and can be triggered within one \`validate()\`
call. Situation b will occur after every call. | `{ clearCurrentResult = false }, opts: { clearCurrentResult?: boolean }` | | LionField |
|
|
125
117
|
| `_arrowNodeTemplate` | protected | | | | ArrowMixin |
|
|
@@ -127,8 +119,7 @@ eleventyNavigation:
|
|
|
127
119
|
| `_calculateValues` | protected | Responsible for storing all representations(modelValue, serializedValue, formattedValue
and value) of the input value. Prevents infinite loops, so all value observers can be
treated like they will only be called once, without indirectly calling other observers.
(in fact, some are called twice, but the \_\_preventRecursiveTrigger lock prevents the
second call from having effect). | `{ source }, config: {source:'model'\|'serialized'\|'formatted'\|null}` | | LionField |
|
|
128
120
|
| `_calendarTemplate` | protected | Subclassers can replace this with their custom extension of
LionCalendar, like \`\<my-calendar id="calendar">\</my-calendar>\` | | | |
|
|
129
121
|
| `_connectSlotMixin` | protected | | | | LionField |
|
|
130
|
-
| `
|
|
131
|
-
| `_defineOverlayConfig` | protected | Overrides arrow and keepTogether modifier to be enabled,
and adds onCreate and onUpdate hooks to sync from popper state | | `Object` | OverlayMixin |
|
|
122
|
+
| `_defineOverlayConfig` | protected | Overrides arrow and keepTogether modifier to be enabled,
and adds onCreate and onUpdate hooks to sync from popper state | | `Object` | ArrowMixin |
|
|
132
123
|
| `_dispatchInitialModelValueChangedEvent` | protected | | | | LionField |
|
|
133
124
|
| `_dispatchModelValueChangedEvent` | protected | This is wrapped in a distinct method, so that parents can control when the changed event
is fired. For objects, a deep comparison might be needed. | `args: { modelValue: unknown; }[]` | | LionField |
|
|
134
125
|
| `_enhanceLightDomA11y` | protected | | | | LionField |
|
|
@@ -150,7 +141,6 @@ eleventyNavigation:
|
|
|
150
141
|
| `_invokerIconTemplate` | protected | Subclassers can replace this with their custom extension invoker icon | | | |
|
|
151
142
|
| `_invokerTemplate` | protected | Subclassers can replace this with their custom extension invoker,
like \`\<my-button>\<calendar-icon>\</calendar-icon>\</my-button>\` | | | |
|
|
152
143
|
| `_isEmpty` | protected | Used for Required validation and computation of interaction states | `modelValue: any` | `boolean` | LionField |
|
|
153
|
-
| `_isPermanentlyDisconnected` | protected | When we're moving around in dom, disconnectedCallback gets called.
Before we decide to teardown, let's wait to see if we were not just moving nodes around. | | `Promise<boolean>` | OverlayMixin |
|
|
154
144
|
| `_isPrivateSlot` | protected | | `slotName: string` | `boolean` | LionField |
|
|
155
145
|
| `_iStateOnLeave` | protected | Sets touched value to true and reevaluates prefilled state.
When false, on next interaction, user will start with a clean state. | | | LionField |
|
|
156
146
|
| `_iStateOnValueChange` | protected | Sets dirty value and validates when already touched or invalid | | | LionField |
|
|
@@ -172,14 +162,10 @@ eleventyNavigation:
|
|
|
172
162
|
| `_reflectBackFormattedValueToUser` | protected | Note: Overrides the implementation from FormatMixin | | | LionField |
|
|
173
163
|
| `_reflectBackOn` | protected | Every time .formattedValue is attempted to sync to the view value (on change/blur and on
modelValue change), this condition is checked. When enhancing it, it's recommended to
call via \`return this.\_myExtraCondition && super.\_reflectBackOn()\` | | `boolean` | LionField |
|
|
174
164
|
| `_repropagationCondition` | protected | Based on provided target, this condition determines whether received model-value-changed
event should be repropagated | `target: FormControlHost` | | LionField |
|
|
175
|
-
| `
|
|
176
|
-
| `_setupOpenCloseListeners` | protected | | | | OverlayMixin |
|
|
177
|
-
| `_setupOverlayCtrl` | protected | | | | OverlayMixin |
|
|
165
|
+
| `_setupOverlayCtrl` | protected | | | | |
|
|
178
166
|
| `_setValueAndPreserveCaret` | protected | Restores the cursor to its original position after updating the value. | `newValue: string` | | NativeTextFieldMixin |
|
|
179
167
|
| `_showFeedbackConditionFor` | protected | Default feedbackCondition condition, used by Subclassers, that will be used when
\`feedbackCondition()\` is not overridden by Application Developer.
Show the validity feedback when returning true, don't show when false | `type: string, meta: InteractionStates` | | LionField |
|
|
180
168
|
| `_syncValueUpwards` | protected | Synchronization from \`.\_inputNode.value\` to \`LionField\` (flow \[2])
Downwards syncing should only happen for \`LionField\`.value changes from 'above'.
This triggers \_onModelValueChanged and connects user input
to the parsing/formatting/serializing loop. | | | LionField |
|
|
181
|
-
| `_teardownOpenCloseListeners` | protected | | | | OverlayMixin |
|
|
182
|
-
| `_teardownOverlayCtrl` | protected | | | | OverlayMixin |
|
|
183
169
|
| `_triggerInitialModelValueChangedEvent` | protected | | | | LionField |
|
|
184
170
|
| `_updateFeedbackComponent` | protected | Responsible for retrieving messages from Validators and
(delegation of) rendering them.

For \`.\_feedbackNode\` (extension of LionValidationFeedback):
- retrieve messages from highest prio Validators
- provide the result to custom feedback node and let the
custom node decide on their renderings

In both cases:
- we compute the 'show' flag (like 'hasErrorVisible') for all types
- we set the customValidity message of the highest prio Validator
- we set aria-invalid="true" in case hasErrorVisible is true | | | LionField |
|
|
185
171
|
| `_updateShouldShowFeedbackFor` | protected | | | | LionField |
|
|
@@ -188,7 +174,6 @@ eleventyNavigation:
|
|
|
188
174
|
|
|
189
175
|
| Name | Type | Description | Inherited From |
|
|
190
176
|
| ------------------------------ | ------------- | -------------------------------------------------------- | -------------- |
|
|
191
|
-
| `opened-changed` | `CustomEvent` | | OverlayMixin |
|
|
192
177
|
| `model-value-changed` | `CustomEvent` | | LionField |
|
|
193
178
|
| `user-input-changed` | `Event` | | LionField |
|
|
194
179
|
| `focus` | `Event` | | LionField |
|
|
@@ -210,7 +195,6 @@ eleventyNavigation:
|
|
|
210
195
|
| ------------------------------- | -------------------------- | -------------------- |
|
|
211
196
|
| `calendar-heading` | calendarHeading | |
|
|
212
197
|
| `has-arrow` | hasArrow | ArrowMixin |
|
|
213
|
-
| `opened` | opened | OverlayMixin |
|
|
214
198
|
| `modelValue` | modelValue | LionInputDate |
|
|
215
199
|
| `autocomplete` | autocomplete | NativeTextFieldMixin |
|
|
216
200
|
| `focused` | focused | LionField |
|
|
@@ -14,7 +14,7 @@ eleventyNavigation:
|
|
|
14
14
|
|
|
15
15
|
A web component based on the date text input field. Its purpose is to provide a way for users to fill in a date with a datepicker.
|
|
16
16
|
For an input field with a big range, such as `birthday-input`, a datepicker is not the best choice due to the high variance between possible inputs.
|
|
17
|
-
We encourage using our standard [input-date](https://github.com/ing-bank/lion/blob/
|
|
17
|
+
We encourage using our standard [input-date](https://github.com/ing-bank/lion/blob/5c228561a361a8ed95aabcacf735f87fb2746a5f/docs/components/input-date/overview.md) for this.
|
|
18
18
|
|
|
19
19
|
```js script
|
|
20
20
|
import { html } from '@mdjs/mdjs-preview';
|
|
@@ -30,11 +30,11 @@ export const main = () => {
|
|
|
30
30
|
## Features
|
|
31
31
|
|
|
32
32
|
- Input field with a datepicker to help to choose a date
|
|
33
|
-
- Based on our [input-date](https://github.com/ing-bank/lion/blob/
|
|
34
|
-
- Makes use of our [calendar](https://github.com/ing-bank/lion/blob/
|
|
35
|
-
- Makes use of [formatDate](https://github.com/ing-bank/lion/blob/
|
|
33
|
+
- Based on our [input-date](https://github.com/ing-bank/lion/blob/5c228561a361a8ed95aabcacf735f87fb2746a5f/docs/components/input-date/overview.md)
|
|
34
|
+
- Makes use of our [calendar](https://github.com/ing-bank/lion/blob/5c228561a361a8ed95aabcacf735f87fb2746a5f/docs/components/calendar/overview.md) inside the datepicker
|
|
35
|
+
- Makes use of [formatDate](https://github.com/ing-bank/lion/blob/5c228561a361a8ed95aabcacf735f87fb2746a5f/docs/fundamentals/systems/localize/dates.md) for formatting and parsing.
|
|
36
36
|
- Option to overwrite locale to change the formatting and parsing
|
|
37
|
-
- Can make use of date specific [validators](https://github.com/ing-bank/lion/blob/
|
|
37
|
+
- Can make use of date specific [validators](https://github.com/ing-bank/lion/blob/5c228561a361a8ed95aabcacf735f87fb2746a5f/docs/fundamentals/systems/form/validate.md) with corresponding error messages in different languages
|
|
38
38
|
- IsDate (default)
|
|
39
39
|
- MinDate
|
|
40
40
|
- MaxDate
|
|
@@ -19,7 +19,7 @@ eleventyNavigation:
|
|
|
19
19
|
| Name | Privacy | Type | Default | Description | Inherited From |
|
|
20
20
|
| ---------------------------- | --------- | ----------------------------------------- | ----------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------- |
|
|
21
21
|
| `allowCrossRootRegistration` | public | `boolean` | `false` | To encourage accessibility best practices, \`form-element-register\` events
do not pierce through shadow roots. This forces the developer to create form groups and fieldsets that automatically allow the creation of accessible relationships in the same dom tree.
Use this option if you know what you're doing. It will then be possible to nest FormControls
inside shadow dom. See https\://lion.js.org/fundamentals/rationales/accessibility/#shadow-roots-and-accessibility | LionField |
|
|
22
|
-
| `autocomplete` | public | `string \| undefined` | `
|
|
22
|
+
| `autocomplete` | public | `string \| undefined` | `'email'` | Delegates this property to input/textarea/select. | NativeTextFieldMixin |
|
|
23
23
|
| `autofocus` | public | `boolean` | `false` | | LionField |
|
|
24
24
|
| `defaultValidators` | public | `Validator[]` | `[]` | Used by Subclassers to add default Validators to a particular FormControl.
A date input for instance, always needs the isDate validator. | LionField |
|
|
25
25
|
| `dirty` | public | `boolean` | `false` | True when user has changed the value of the field. | LionField |
|
|
@@ -62,6 +62,7 @@ eleventyNavigation:
|
|
|
62
62
|
| `_helpTextNode` | protected | | | Element where help text will be rendered to | LionField |
|
|
63
63
|
| `_inputId` | protected | `string` | | Unique id that can be used in all light dom | LionField |
|
|
64
64
|
| `_inputNode` | protected | `HTMLInputElement \| HTMLTextAreaElement` | | The interactive (form) element. Can be a native element like input/textarea/select or
an element with tabindex > -1 | LionField |
|
|
65
|
+
| `_isEditingTextField` | protected | | | | LionField |
|
|
65
66
|
| `_isHandlingUserInput` | protected | `boolean` | `false` | Flag that will be set when user interaction takes place (for instance after an 'input'
event). Will be added as meta info to the \`model-value-changed\` event. Depending on
whether a user is interacting, formatting logic will be handled differently. | LionField |
|
|
66
67
|
| `_isPasting` | protected | `boolean` | `false` | Whether the user is pasting content. Allows Subclassers to do this in their subclass: | LionField |
|
|
67
68
|
| `_isRepropagationEndpoint` | public | `boolean` | `false` | By default, a field with \_repropagationRole 'choice-group' will act as an
'endpoint'. This means it will be considered as an individual field: for
a select, individual options will not be part of the formPath. They
will.
Similarly, components that (a11y wise) need to be fieldsets, but 'interaction wise'
(from Application Developer perspective) need to be more like fields
(think of an amount-input with a currency select box next to it), can set this
to true to hide private internals in the formPath. | LionField |
|
|
@@ -92,7 +93,7 @@ eleventyNavigation:
|
|
|
92
93
|
| `initInteractionState` | public | Evaluations performed on connectedCallback.
This method is public, so it can be called at a later moment (when we need to wait for
registering children for instance) as well.
Since this method will be called twice in last mentioned scenario, it must stay idempotent. | | | LionField |
|
|
93
94
|
| `makeRequestToBeDisabled` | public | | | | LionField |
|
|
94
95
|
| `parser` | public | Converts viewValue to modelValue
For instance, a localized date to a Date Object | `v: string, opts: FormatOptions` | `*` | LionField |
|
|
95
|
-
| `preprocessor` | public | Preprocessors could be considered 'live formatters'. Their result is shown to the user
on keyup instead of after blurring the field. The biggest difference between preprocessors
and formatters is their moment of execution: preprocessors are run before modelValue is
computed (and work based on view value), whereas formatters are run after the parser (and
are based on modelValue)
Automatically formats code while typing. It depends on a
|
|
96
|
+
| `preprocessor` | public | Preprocessors could be considered 'live formatters'. Their result is shown to the user
on keyup instead of after blurring the field. The biggest difference between preprocessors
and formatters is their moment of execution: preprocessors are run before modelValue is
computed (and work based on view value), whereas formatters are run after the parser (and
are based on modelValue)
Automatically formats code while typing. It depends on a preprocessor that smartly
updates the viewValue and caret position for best UX. | `v: string, opts: FormatOptions & { prevViewValue: string; currentCaretIndex: number }` | `{ viewValue:string; caretIndex:number; }\|string\|undefined` | LionField |
|
|
96
97
|
| `removeFromAriaDescribedBy` | public | Allows to remove element references from aria-describedby attribute. | `element: HTMLElement` | | LionField |
|
|
97
98
|
| `removeFromAriaLabelledBy` | public | Allows to remove element references from aria-labelledby attribute. | `element: HTMLElement` | | LionField |
|
|
98
99
|
| `reset` | public | Resets modelValue to initial value.
Interaction states are cleared | | | LionField |
|
|
@@ -27,8 +27,8 @@ export const main = () => {
|
|
|
27
27
|
|
|
28
28
|
## Features
|
|
29
29
|
|
|
30
|
-
- Based on our [input](https://github.com/ing-bank/lion/blob/
|
|
31
|
-
- Makes use of email [validators](https://github.com/ing-bank/lion/blob/
|
|
30
|
+
- Based on our [input](https://github.com/ing-bank/lion/blob/5c228561a361a8ed95aabcacf735f87fb2746a5f/docs/components/input/overview.md)
|
|
31
|
+
- Makes use of email [validators](https://github.com/ing-bank/lion/blob/5c228561a361a8ed95aabcacf735f87fb2746a5f/docs/fundamentals/systems/form/validate.md) with corresponding error messages in different languages
|
|
32
32
|
- IsEmail (default)
|
|
33
33
|
|
|
34
34
|
## Installation
|
|
@@ -92,6 +92,7 @@ eleventyNavigation:
|
|
|
92
92
|
| `_inputId` | protected | `string` | | Unique id that can be used in all light dom | LionField |
|
|
93
93
|
| `_inputNode` | protected | `HTMLInputElement` | | The interactive (form) element. Can be a native element like input/textarea/select or
an element with tabindex > -1 | LionField |
|
|
94
94
|
| `_isDragAndDropSupported` | protected | | | | |
|
|
95
|
+
| `_isEditingTextField` | protected | | | | LionField |
|
|
95
96
|
| `_isHandlingUserInput` | protected | `boolean` | `false` | Flag that will be set when user interaction takes place (for instance after an 'input'
event). Will be added as meta info to the \`model-value-changed\` event. Depending on
whether a user is interacting, formatting logic will be handled differently. | LionField |
|
|
96
97
|
| `_isPasting` | protected | `boolean` | `false` | Whether the user is pasting content. Allows Subclassers to do this in their subclass: | LionField |
|
|
97
98
|
| `_isRepropagationEndpoint` | public | `boolean` | `false` | By default, a field with \_repropagationRole 'choice-group' will act as an
'endpoint'. This means it will be considered as an individual field: for
a select, individual options will not be part of the formPath. They
will.
Similarly, components that (a11y wise) need to be fieldsets, but 'interaction wise'
(from Application Developer perspective) need to be more like fields
(think of an amount-input with a currency select box next to it), can set this
to true to hide private internals in the formPath. | LionField |
|
|
@@ -123,7 +124,7 @@ eleventyNavigation:
|
|
|
123
124
|
| `initInteractionState` | public | Evaluations performed on connectedCallback.
This method is public, so it can be called at a later moment (when we need to wait for
registering children for instance) as well.
Since this method will be called twice in last mentioned scenario, it must stay idempotent. | | | LionField |
|
|
124
125
|
| `makeRequestToBeDisabled` | public | | | | LionField |
|
|
125
126
|
| `parser` | public | Converts viewValue to modelValue
For instance, a localized date to a Date Object | `v: string, opts: FormatOptions` | `InputFile[]` | LionField |
|
|
126
|
-
| `preprocessor` | public | Preprocessors could be considered 'live formatters'. Their result is shown to the user
on keyup instead of after blurring the field. The biggest difference between preprocessors
and formatters is their moment of execution: preprocessors are run before modelValue is
computed (and work based on view value), whereas formatters are run after the parser (and
are based on modelValue)
Automatically formats code while typing. It depends on a
|
|
127
|
+
| `preprocessor` | public | Preprocessors could be considered 'live formatters'. Their result is shown to the user
on keyup instead of after blurring the field. The biggest difference between preprocessors
and formatters is their moment of execution: preprocessors are run before modelValue is
computed (and work based on view value), whereas formatters are run after the parser (and
are based on modelValue)
Automatically formats code while typing. It depends on a preprocessor that smartly
updates the viewValue and caret position for best UX. | `v: string, opts: FormatOptions & { prevViewValue: string; currentCaretIndex: number }` | `{ viewValue:string; caretIndex:number; }\|string\|undefined` | LionField |
|
|
127
128
|
| `removeFromAriaDescribedBy` | public | Allows to remove element references from aria-describedby attribute. | `element: HTMLElement` | | LionField |
|
|
128
129
|
| `removeFromAriaLabelledBy` | public | Allows to remove element references from aria-labelledby attribute. | `element: HTMLElement` | | LionField |
|
|
129
130
|
| `reset` | public | Resets modelValue to initial value.
Interaction states are cleared | | | LionField |
|
|
@@ -27,7 +27,7 @@ export const main = () => {
|
|
|
27
27
|
|
|
28
28
|
## Features
|
|
29
29
|
|
|
30
|
-
- Based on our [input](https://github.com/ing-bank/lion/blob/
|
|
30
|
+
- Based on our [input](https://github.com/ing-bank/lion/blob/5c228561a361a8ed95aabcacf735f87fb2746a5f/docs/components/input/overview.md)
|
|
31
31
|
- Default labels and validation messages in different languages
|
|
32
32
|
- Options for multi file upload and drop-zone.
|
|
33
33
|
|
|
@@ -173,6 +173,24 @@ export const sizeValidator = () => {
|
|
|
173
173
|
};
|
|
174
174
|
```
|
|
175
175
|
|
|
176
|
+
### Maximum File Count
|
|
177
|
+
|
|
178
|
+
```js preview-story
|
|
179
|
+
export const fileCountValidator = () => {
|
|
180
|
+
return html`
|
|
181
|
+
<lion-input-file
|
|
182
|
+
label="Passport"
|
|
183
|
+
max-file-size="1024000"
|
|
184
|
+
accept=".jpg,.svg,.xml,image/svg+xml"
|
|
185
|
+
.validators=${[
|
|
186
|
+
new MaxFileCount(2, { getMessage: () => 'You must not select more than 2 files' }),
|
|
187
|
+
]}
|
|
188
|
+
>
|
|
189
|
+
</lion-input-file>
|
|
190
|
+
`;
|
|
191
|
+
};
|
|
192
|
+
```
|
|
193
|
+
|
|
176
194
|
### Multiple file upload
|
|
177
195
|
|
|
178
196
|
When file has to be uploaded as soon as it is selected by the user. Use `file-list-changed` event to get the newly added files, upload it to your server and set the response back to component via `uploadResponse` property for each file.
|
|
@@ -64,6 +64,7 @@ eleventyNavigation:
|
|
|
64
64
|
| `_helpTextNode` | protected | | | Element where help text will be rendered to | LionField |
|
|
65
65
|
| `_inputId` | protected | `string` | | Unique id that can be used in all light dom | LionField |
|
|
66
66
|
| `_inputNode` | protected | `HTMLInputElement \| HTMLTextAreaElement` | | The interactive (form) element. Can be a native element like input/textarea/select or
an element with tabindex > -1 | LionField |
|
|
67
|
+
| `_isEditingTextField` | protected | | | | LionField |
|
|
67
68
|
| `_isHandlingUserInput` | protected | `boolean` | `false` | Flag that will be set when user interaction takes place (for instance after an 'input'
event). Will be added as meta info to the \`model-value-changed\` event. Depending on
whether a user is interacting, formatting logic will be handled differently. | LionField |
|
|
68
69
|
| `_isPasting` | protected | `boolean` | `false` | Whether the user is pasting content. Allows Subclassers to do this in their subclass: | LionField |
|
|
69
70
|
| `_isRepropagationEndpoint` | public | `boolean` | `false` | By default, a field with \_repropagationRole 'choice-group' will act as an
'endpoint'. This means it will be considered as an individual field: for
a select, individual options will not be part of the formPath. They
will.
Similarly, components that (a11y wise) need to be fieldsets, but 'interaction wise'
(from Application Developer perspective) need to be more like fields
(think of an amount-input with a currency select box next to it), can set this
to true to hide private internals in the formPath. | LionField |
|
|
@@ -92,7 +93,7 @@ eleventyNavigation:
|
|
|
92
93
|
| `focus` | public | Calls \`focus()\` on focusable element within | | | LionField |
|
|
93
94
|
| `initInteractionState` | public | Evaluations performed on connectedCallback.
This method is public, so it can be called at a later moment (when we need to wait for
registering children for instance) as well.
Since this method will be called twice in last mentioned scenario, it must stay idempotent. | | | LionField |
|
|
94
95
|
| `makeRequestToBeDisabled` | public | | | | LionField |
|
|
95
|
-
| `preprocessor` | public | Preprocessors could be considered 'live formatters'. Their result is shown to the user
on keyup instead of after blurring the field. The biggest difference between preprocessors
and formatters is their moment of execution: preprocessors are run before modelValue is
computed (and work based on view value), whereas formatters are run after the parser (and
are based on modelValue)
Automatically formats code while typing. It depends on a
|
|
96
|
+
| `preprocessor` | public | Preprocessors could be considered 'live formatters'. Their result is shown to the user
on keyup instead of after blurring the field. The biggest difference between preprocessors
and formatters is their moment of execution: preprocessors are run before modelValue is
computed (and work based on view value), whereas formatters are run after the parser (and
are based on modelValue)
Automatically formats code while typing. It depends on a preprocessor that smartly
updates the viewValue and caret position for best UX. | `v: string, opts: FormatOptions & { prevViewValue: string; currentCaretIndex: number }` | `{ viewValue:string; caretIndex:number; }\|string\|undefined` | LionField |
|
|
96
97
|
| `removeFromAriaDescribedBy` | public | Allows to remove element references from aria-describedby attribute. | `element: HTMLElement` | | LionField |
|
|
97
98
|
| `removeFromAriaLabelledBy` | public | Allows to remove element references from aria-labelledby attribute. | `element: HTMLElement` | | LionField |
|
|
98
99
|
| `reset` | public | Resets modelValue to initial value.
Interaction states are cleared | | | LionField |
|