@public-ui/components 1.2.0-rc.3 → 1.2.0-rc.5
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/cheat-sheet.html +6 -6
- package/custom-elements.json +1 -1
- package/dist/cjs/{app-globals-b5f9ed21.js → app-globals-4d8fc232.js} +1 -1
- package/dist/cjs/{button-link-20e45777.js → button-link-0fd6230e.js} +1 -1
- package/dist/cjs/{controller-d49fe656.js → controller-07758d49.js} +1 -1
- package/dist/cjs/{controller-80542a84.js → controller-27f1673e.js} +1 -1
- package/dist/cjs/{controller-82db9ece.js → controller-38da3f37.js} +1 -1
- package/dist/cjs/{controller-8bc782fe.js → controller-497f1ea8.js} +1 -1
- package/dist/cjs/{controller-1e7fded2.js → controller-76206599.js} +1 -1
- package/dist/cjs/{controller-05cf81d5.js → controller-e1ac2199.js} +1 -1
- package/dist/cjs/{devtools-e1da1fdd.js → devtools-c15b4b51.js} +1 -1
- package/dist/cjs/index-2fff4c22.js +4 -0
- package/dist/cjs/index-77965f6f.js +5 -0
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/kol-abbr.cjs.entry.js +1 -1
- package/dist/cjs/kol-accordion.cjs.entry.js +1 -1
- package/dist/cjs/kol-alert.cjs.entry.js +1 -1
- package/dist/cjs/kol-badge.cjs.entry.js +1 -1
- package/dist/cjs/kol-breadcrumb.cjs.entry.js +1 -1
- package/dist/cjs/kol-button-group-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-button-group.cjs.entry.js +1 -1
- package/dist/cjs/kol-button-link.cjs.entry.js +1 -1
- package/dist/cjs/kol-button-wc_2.cjs.entry.js +1 -1
- package/dist/cjs/kol-button.cjs.entry.js +1 -1
- package/dist/cjs/kol-card.cjs.entry.js +1 -1
- package/dist/cjs/kol-color.cjs.entry.js +1 -1
- package/dist/cjs/kol-counter.cjs.entry.js +1 -1
- package/dist/cjs/kol-details.cjs.entry.js +1 -1
- package/dist/cjs/kol-form.cjs.entry.js +1 -1
- package/dist/cjs/kol-heading-wc_2.cjs.entry.js +1 -1
- package/dist/cjs/kol-heading.cjs.entry.js +1 -1
- package/dist/cjs/kol-icon-font-awesome.cjs.entry.js +1 -1
- package/dist/cjs/kol-icon-icofont.cjs.entry.js +1 -1
- package/dist/cjs/kol-icon.cjs.entry.js +1 -1
- package/dist/cjs/kol-indented-text.cjs.entry.js +1 -1
- package/dist/cjs/kol-input-adapter-leanup.cjs.entry.js +1 -1
- package/dist/cjs/kol-input-checkbox.cjs.entry.js +1 -1
- package/dist/cjs/kol-input-color.cjs.entry.js +1 -1
- package/dist/cjs/kol-input-date.cjs.entry.js +1 -1
- package/dist/cjs/kol-input-email.cjs.entry.js +1 -1
- package/dist/cjs/kol-input-file.cjs.entry.js +1 -1
- package/dist/cjs/kol-input-number.cjs.entry.js +1 -1
- package/dist/cjs/kol-input-password.cjs.entry.js +1 -1
- package/dist/cjs/kol-input-radio-group.cjs.entry.js +1 -1
- package/dist/cjs/kol-input-radio.cjs.entry.js +1 -1
- package/dist/cjs/kol-input-range.cjs.entry.js +1 -1
- package/dist/cjs/kol-input-text.cjs.entry.js +1 -1
- package/dist/cjs/kol-kolibri.cjs.entry.js +1 -1
- package/dist/cjs/kol-link-button.cjs.entry.js +1 -1
- package/dist/cjs/kol-link-group.cjs.entry.js +1 -1
- package/dist/cjs/kol-link-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-link.cjs.entry.js +1 -1
- package/dist/cjs/kol-logo.cjs.entry.js +1 -1
- package/dist/cjs/kol-modal.cjs.entry.js +1 -1
- package/dist/cjs/kol-nav.cjs.entry.js +1 -1
- package/dist/cjs/kol-pagination.cjs.entry.js +1 -1
- package/dist/cjs/kol-progress.cjs.entry.js +1 -1
- package/dist/cjs/kol-select.cjs.entry.js +1 -1
- package/dist/cjs/kol-skip-nav.cjs.entry.js +1 -1
- package/dist/cjs/kol-span.cjs.entry.js +1 -1
- package/dist/cjs/kol-spin.cjs.entry.js +1 -1
- package/dist/cjs/kol-symbol.cjs.entry.js +1 -1
- package/dist/cjs/kol-table.cjs.entry.js +1 -1
- package/dist/cjs/kol-tabs.cjs.entry.js +1 -1
- package/dist/cjs/kol-textarea.cjs.entry.js +1 -1
- package/dist/cjs/kol-toast.cjs.entry.js +1 -1
- package/dist/cjs/kol-tooltip.cjs.entry.js +1 -1
- package/dist/cjs/kol-version.cjs.entry.js +1 -1
- package/dist/cjs/kolibri.cjs.js +1 -1
- package/dist/cjs/{label-928eb9e0.js → label-b376a163.js} +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{prop.validators-418838b5.js → prop.validators-d9b1328b.js} +1 -1
- package/dist/cjs/{tab-index-2e283146.js → tab-index-a6ce7671.js} +1 -1
- package/dist/cjs/{validation-96bfc49b.js → validation-e7db9a4e.js} +1 -1
- package/dist/cjs/{validation-65d6637a.js → validation-f9584225.js} +1 -1
- package/dist/components/index.d.ts +9 -0
- package/dist/components/index.js +1 -1
- package/dist/components/kol-nav.js +1 -1
- package/dist/components/prop.validators.js +1 -1
- package/dist/esm/app-globals-79adbf92.js +4 -0
- package/dist/esm/{button-link-12c0f0fc.js → button-link-4be4e0b3.js} +1 -1
- package/dist/esm/{controller-d1de0fb0.js → controller-2e2739f0.js} +1 -1
- package/dist/esm/{controller-881192cb.js → controller-96790379.js} +1 -1
- package/dist/esm/{controller-aa8b7245.js → controller-cce0f1ff.js} +1 -1
- package/dist/esm/{controller-b4f2f439.js → controller-d56406c9.js} +1 -1
- package/dist/esm/{controller-b9b5612a.js → controller-d720adef.js} +1 -1
- package/dist/esm/{controller-1c182403.js → controller-f9fd0dec.js} +1 -1
- package/dist/esm/{devtools-be185553.js → devtools-f6d00261.js} +1 -1
- package/dist/esm/index-1c88bb74.js +5 -0
- package/dist/esm/index-bb963364.js +4 -0
- package/dist/esm/index.js +1 -1
- package/dist/esm/kol-abbr.entry.js +1 -1
- package/dist/esm/kol-accordion.entry.js +1 -1
- package/dist/esm/kol-alert.entry.js +1 -1
- package/dist/esm/kol-badge.entry.js +1 -1
- package/dist/esm/kol-breadcrumb.entry.js +1 -1
- package/dist/esm/kol-button-group-wc.entry.js +1 -1
- package/dist/esm/kol-button-group.entry.js +1 -1
- package/dist/esm/kol-button-link.entry.js +1 -1
- package/dist/esm/kol-button-wc_2.entry.js +1 -1
- package/dist/esm/kol-button.entry.js +1 -1
- package/dist/esm/kol-card.entry.js +1 -1
- package/dist/esm/kol-color.entry.js +1 -1
- package/dist/esm/kol-counter.entry.js +1 -1
- package/dist/esm/kol-details.entry.js +1 -1
- package/dist/esm/kol-form.entry.js +1 -1
- package/dist/esm/kol-heading-wc_2.entry.js +1 -1
- package/dist/esm/kol-heading.entry.js +1 -1
- package/dist/esm/kol-icon-font-awesome.entry.js +1 -1
- package/dist/esm/kol-icon-icofont.entry.js +1 -1
- package/dist/esm/kol-icon.entry.js +1 -1
- package/dist/esm/kol-indented-text.entry.js +1 -1
- package/dist/esm/kol-input-adapter-leanup.entry.js +1 -1
- package/dist/esm/kol-input-checkbox.entry.js +1 -1
- package/dist/esm/kol-input-color.entry.js +1 -1
- package/dist/esm/kol-input-date.entry.js +1 -1
- package/dist/esm/kol-input-email.entry.js +1 -1
- package/dist/esm/kol-input-file.entry.js +1 -1
- package/dist/esm/kol-input-number.entry.js +1 -1
- package/dist/esm/kol-input-password.entry.js +1 -1
- package/dist/esm/kol-input-radio-group.entry.js +1 -1
- package/dist/esm/kol-input-radio.entry.js +1 -1
- package/dist/esm/kol-input-range.entry.js +1 -1
- package/dist/esm/kol-input-text.entry.js +1 -1
- package/dist/esm/kol-kolibri.entry.js +1 -1
- package/dist/esm/kol-link-button.entry.js +1 -1
- package/dist/esm/kol-link-group.entry.js +1 -1
- package/dist/esm/kol-link-wc.entry.js +1 -1
- package/dist/esm/kol-link.entry.js +1 -1
- package/dist/esm/kol-logo.entry.js +1 -1
- package/dist/esm/kol-modal.entry.js +1 -1
- package/dist/esm/kol-nav.entry.js +1 -1
- package/dist/esm/kol-pagination.entry.js +1 -1
- package/dist/esm/kol-progress.entry.js +1 -1
- package/dist/esm/kol-select.entry.js +1 -1
- package/dist/esm/kol-skip-nav.entry.js +1 -1
- package/dist/esm/kol-span.entry.js +1 -1
- package/dist/esm/kol-spin.entry.js +1 -1
- package/dist/esm/kol-symbol.entry.js +1 -1
- package/dist/esm/kol-table.entry.js +1 -1
- package/dist/esm/kol-tabs.entry.js +1 -1
- package/dist/esm/kol-textarea.entry.js +1 -1
- package/dist/esm/kol-toast.entry.js +1 -1
- package/dist/esm/kol-tooltip.entry.js +1 -1
- package/dist/esm/kol-version.entry.js +1 -1
- package/dist/esm/kolibri.js +1 -1
- package/dist/esm/{label-5ff0abd3.js → label-6eef1542.js} +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{prop.validators-aece40e0.js → prop.validators-6ea5c4bf.js} +1 -1
- package/dist/esm/{tab-index-6f076edf.js → tab-index-4f492046.js} +1 -1
- package/dist/esm/{validation-6bb25737.js → validation-7fff73cc.js} +1 -1
- package/dist/esm/{validation-44db1a43.js → validation-d60955a6.js} +1 -1
- package/dist/kolibri/app-globals-79adbf92.js +4 -0
- package/dist/kolibri/assets/icofont/demo.html +1 -1
- package/dist/kolibri/{button-link-12c0f0fc.js → button-link-4be4e0b3.js} +1 -1
- package/dist/kolibri/{controller-d1de0fb0.js → controller-2e2739f0.js} +1 -1
- package/dist/kolibri/{controller-881192cb.js → controller-96790379.js} +1 -1
- package/dist/kolibri/controller-cce0f1ff.js +4 -0
- package/dist/kolibri/{controller-b4f2f439.js → controller-d56406c9.js} +1 -1
- package/dist/kolibri/{controller-b9b5612a.js → controller-d720adef.js} +1 -1
- package/dist/kolibri/{controller-1c182403.js → controller-f9fd0dec.js} +1 -1
- package/dist/kolibri/devtools-f6d00261.js +4 -0
- package/dist/kolibri/index-1c88bb74.js +5 -0
- package/dist/kolibri/index-bb963364.js +4 -0
- package/dist/kolibri/index.esm.js +1 -1
- package/dist/kolibri/kol-abbr.entry.js +1 -1
- package/dist/kolibri/kol-accordion.entry.js +1 -1
- package/dist/kolibri/kol-alert.entry.js +1 -1
- package/dist/kolibri/kol-badge.entry.js +1 -1
- package/dist/kolibri/kol-breadcrumb.entry.js +1 -1
- package/dist/kolibri/kol-button-group-wc.entry.js +1 -1
- package/dist/kolibri/kol-button-group.entry.js +1 -1
- package/dist/kolibri/kol-button-link.entry.js +1 -1
- package/dist/kolibri/kol-button-wc_2.entry.js +1 -1
- package/dist/kolibri/kol-button.entry.js +1 -1
- package/dist/kolibri/kol-card.entry.js +1 -1
- package/dist/kolibri/kol-color.entry.js +1 -1
- package/dist/kolibri/kol-counter.entry.js +1 -1
- package/dist/kolibri/kol-details.entry.js +1 -1
- package/dist/kolibri/kol-form.entry.js +1 -1
- package/dist/kolibri/kol-heading-wc_2.entry.js +1 -1
- package/dist/kolibri/kol-heading.entry.js +1 -1
- package/dist/kolibri/kol-icon-font-awesome.entry.js +1 -1
- package/dist/kolibri/kol-icon-icofont.entry.js +1 -1
- package/dist/kolibri/kol-icon.entry.js +1 -1
- package/dist/kolibri/kol-indented-text.entry.js +1 -1
- package/dist/kolibri/kol-input-adapter-leanup.entry.js +1 -1
- package/dist/kolibri/kol-input-checkbox.entry.js +1 -1
- package/dist/kolibri/kol-input-color.entry.js +1 -1
- package/dist/kolibri/kol-input-date.entry.js +1 -1
- package/dist/kolibri/kol-input-email.entry.js +1 -1
- package/dist/kolibri/kol-input-file.entry.js +1 -1
- package/dist/kolibri/kol-input-number.entry.js +1 -1
- package/dist/kolibri/kol-input-password.entry.js +1 -1
- package/dist/kolibri/kol-input-radio-group.entry.js +1 -1
- package/dist/kolibri/kol-input-radio.entry.js +1 -1
- package/dist/kolibri/kol-input-range.entry.js +1 -1
- package/dist/kolibri/kol-input-text.entry.js +1 -1
- package/dist/kolibri/kol-kolibri.entry.js +1 -1
- package/dist/kolibri/kol-link-button.entry.js +1 -1
- package/dist/kolibri/kol-link-group.entry.js +1 -1
- package/dist/kolibri/kol-link-wc.entry.js +1 -1
- package/dist/kolibri/kol-link.entry.js +1 -1
- package/dist/kolibri/kol-logo.entry.js +1 -1
- package/dist/kolibri/kol-modal.entry.js +1 -1
- package/dist/kolibri/kol-nav.entry.js +1 -1
- package/dist/kolibri/kol-pagination.entry.js +1 -1
- package/dist/kolibri/kol-progress.entry.js +1 -1
- package/dist/kolibri/kol-select.entry.js +1 -1
- package/dist/kolibri/kol-skip-nav.entry.js +1 -1
- package/dist/kolibri/kol-span.entry.js +1 -1
- package/dist/kolibri/kol-spin.entry.js +1 -1
- package/dist/kolibri/kol-symbol.entry.js +1 -1
- package/dist/kolibri/kol-table.entry.js +1 -1
- package/dist/kolibri/kol-tabs.entry.js +1 -1
- package/dist/kolibri/kol-textarea.entry.js +1 -1
- package/dist/kolibri/kol-toast.entry.js +1 -1
- package/dist/kolibri/kol-tooltip.entry.js +1 -1
- package/dist/kolibri/kol-version.entry.js +1 -1
- package/dist/kolibri/kolibri.esm.js +1 -1
- package/dist/kolibri/{label-5ff0abd3.js → label-6eef1542.js} +1 -1
- package/dist/kolibri/{prop.validators-aece40e0.js → prop.validators-6ea5c4bf.js} +1 -1
- package/dist/kolibri/{tab-index-6f076edf.js → tab-index-4f492046.js} +1 -1
- package/dist/kolibri/{validation-6bb25737.js → validation-7fff73cc.js} +1 -1
- package/dist/kolibri/validation-d60955a6.js +4 -0
- package/dist/loader/index.d.ts +9 -0
- package/dist/types/stencil-public-runtime.d.ts +9 -0
- package/jest-test-results.json +1 -1
- package/package.json +1 -1
- package/dist/cjs/index-079091fe.js +0 -4
- package/dist/cjs/index-8dc4c8fe.js +0 -5
- package/dist/esm/app-globals-a3ea1c25.js +0 -4
- package/dist/esm/index-758cec5f.js +0 -5
- package/dist/esm/index-e8f75197.js +0 -4
- package/dist/kolibri/app-globals-a3ea1c25.js +0 -4
- package/dist/kolibri/controller-aa8b7245.js +0 -4
- package/dist/kolibri/devtools-be185553.js +0 -4
- package/dist/kolibri/index-758cec5f.js +0 -5
- package/dist/kolibri/index-e8f75197.js +0 -4
- package/dist/kolibri/validation-44db1a43.js +0 -4
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* KoliBri - The accessible HTML-Standard
|
|
3
3
|
*/
|
|
4
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});const index=require("./index-8dc4c8fe.js"),appGlobals=require("./app-globals-b5f9ed21.js");require("./index-079091fe.js"),require("./dev.utils-2353100d.js");const patchEsm=()=>index.promiseResolve(),defineCustomElements=(e,a)=>"undefined"==typeof window?Promise.resolve():index.promiseResolve().then((()=>(appGlobals.globalScripts(),index.bootstrapLazy(JSON.parse('[["kol-abbr.cjs",[[33,"kol-abbr",{"_tooltipAlign":[1,"_tooltip-align"],"_title":[1],"state":[32]}]]],["kol-accordion.cjs",[[33,"kol-accordion",{"_heading":[1],"_level":[2],"_on":[16],"_open":[1540],"state":[32]}]]],["kol-badge.cjs",[[33,"kol-badge",{"_color":[1],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[516,"_icon-only"],"_label":[1],"_smartButton":[1,"_smart-button"],"state":[32]}]]],["kol-table.cjs",[[33,"kol-table",{"_caption":[1],"_data":[1],"_headers":[1],"_minWidth":[1,"_min-width"],"_pagination":[8],"state":[32]}]]],["kol-input-adapter-leanup.cjs",[[1,"kol-input-adapter-leanup"]]],["kol-input-date.cjs",[[33,"kol-input-date",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_max":[1],"_min":[1],"_name":[1],"_on":[16],"_readOnly":[516,"_read-only"],"_required":[516],"_smartButton":[16],"_step":[2],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_type":[1],"_value":[1],"state":[32]}]]],["kol-input-radio-group.cjs",[[1,"kol-input-radio-group",{"_accessKey":[1,"_access-key"],"_alert":[516],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_id":[1],"_list":[1],"_name":[1],"_on":[16],"_orientation":[1],"_required":[516],"_tabIndex":[2,"_tab-index"],"_touched":[516],"_value":[1]}]]],["kol-input-checkbox.cjs",[[33,"kol-input-checkbox",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_checked":[1540],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_id":[1],"_indeterminate":[516],"_name":[1],"_on":[16],"_required":[516],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_type":[1],"_value":[1],"_variant":[1],"state":[32]}]]],["kol-input-color.cjs",[[33,"kol-input-color",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_name":[1],"_on":[16],"_smartButton":[16],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-email.cjs",[[33,"kol-input-email",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_maxLength":[2,"_max-length"],"_multiple":[516],"_name":[1],"_on":[16],"_pattern":[1],"_placeholder":[1],"_readOnly":[516,"_read-only"],"_required":[516],"_size":[2],"_smartButton":[16],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-file.cjs",[[33,"kol-input-file",{"_accept":[1],"_accessKey":[1,"_access-key"],"_alert":[1540],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_multiple":[516],"_name":[1],"_on":[16],"_required":[516],"_smartButton":[16],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-password.cjs",[[33,"kol-input-password",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_maxLength":[2,"_max-length"],"_name":[1],"_on":[16],"_pattern":[1],"_placeholder":[1],"_readOnly":[516,"_read-only"],"_required":[516],"_size":[2],"_smartButton":[16],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-range.cjs",[[33,"kol-input-range",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_max":[2],"_min":[2],"_name":[1],"_on":[16],"_step":[2],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[2],"state":[32]}]]],["kol-input-text.cjs",[[33,"kol-input-text",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_maxLength":[2,"_max-length"],"_name":[1],"_on":[16],"_pattern":[1],"_placeholder":[1],"_readOnly":[516,"_read-only"],"_required":[516],"_size":[2],"_smartButton":[16],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_type":[1],"_value":[1025],"state":[32]}]]],["kol-link-group.cjs",[[33,"kol-link-group",{"_ariaLabel":[1,"_aria-label"],"_listStyleType":[1,"_list-style-type"],"_heading":[1],"_level":[2],"_links":[1],"_ordered":[516],"_orientation":[1],"state":[32]}]]],["kol-textarea.cjs",[[33,"kol-textarea",{"_accessKey":[1,"_access-key"],"_adjustHeight":[516,"_adjust-height"],"_alert":[1540],"_hasCounter":[516,"_has-counter"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_id":[1],"_maxLength":[2,"_max-length"],"_name":[1],"_on":[16],"_placeholder":[1],"_readOnly":[516,"_read-only"],"_resize":[1],"_required":[516],"_rows":[1026],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-breadcrumb.cjs",[[33,"kol-breadcrumb",{"_ariaLabel":[1,"_aria-label"],"_links":[1],"state":[32]}]]],["kol-nav.cjs",[[33,"kol-nav",{"_ariaCurrentValue":[8,"_aria-current-value"],"_ariaLabel":[1,"_aria-label"],"_collapsible":[516],"_compact":[516],"_hasCompactButton":[516,"_has-compact-button"],"_orientation":[1],"_links":[1],"_variant":[1],"state":[32]}]]],["kol-skip-nav.cjs",[[33,"kol-skip-nav",{"_ariaLabel":[1,"_aria-label"],"_links":[1],"state":[32]}]]],["kol-toast.cjs",[[33,"kol-toast",{"_alert":[516],"_hasCloser":[516,"_has-closer"],"_heading":[1],"_level":[2],"_on":[16],"_show":[1540],"_showDuration":[2,"_show-duration"],"_type":[1],"state":[32]}]]],["kol-link-button.cjs",[[33,"kol-link-button",{"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[516,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[516,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[516],"_href":[1],"_icon":[1],"_iconOnly":[516,"_icon-only"],"_label":[1],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_target":[1],"_targetDescription":[1,"_target-description"],"_tooltipAlign":[1,"_tooltip-align"],"_variant":[1],"state":[32]}]]],["kol-tabs.cjs",[[33,"kol-tabs",{"_ariaLabel":[1,"_aria-label"],"_on":[16],"_selected":[1538],"_tabs":[1],"_tabsAlign":[1,"_tabs-align"],"state":[32]}]]],["kol-button-link.cjs",[[33,"kol-button-link",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[516,"_aria-expanded"],"_ariaLabel":[1025,"_aria-label"],"_ariaSelected":[516,"_aria-selected"],"_disabled":[516],"_icon":[1],"_iconOnly":[516,"_icon-only"],"_id":[1],"_label":[1],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16]}]]],["kol-version.cjs",[[33,"kol-version",{"_version":[1],"state":[32]}]]],["kol-details.cjs",[[33,"kol-details",{"_open":[1540],"_summary":[1],"state":[32]}]]],["kol-span.cjs",[[33,"kol-span",{"_icon":[1],"_iconOnly":[516,"_icon-only"],"_label":[1]}]]],["kol-button-group.cjs",[[33,"kol-button-group"]]],["kol-card.cjs",[[33,"kol-card",{"_hasFooter":[516,"_has-footer"],"_heading":[1],"_headline":[1],"_level":[2],"state":[32]}]]],["kol-form.cjs",[[1,"kol-form",{"_on":[16],"_requiredText":[8,"_required-text"],"state":[32]}]]],["kol-heading.cjs",[[33,"kol-heading",{"_level":[514]}]]],["kol-icon.cjs",[[33,"kol-icon",{"_ariaLabel":[1,"_aria-label"],"_icon":[1],"_part":[1],"state":[32]}]]],["kol-icon-font-awesome.cjs",[[32,"kol-icon-font-awesome",{"_ariaLabel":[1,"_aria-label"],"_icon":[1],"_prefix":[1],"_part":[1]}]]],["kol-icon-icofont.cjs",[[32,"kol-icon-icofont",{"_ariaLabel":[1,"_aria-label"],"_icon":[1],"_part":[1]}]]],["kol-color.cjs",[[33,"kol-color",{"selectedColor":[32]}]]],["kol-counter.cjs",[[33,"kol-counter",{"state":[32]}]]],["kol-kolibri.cjs",[[33,"kol-kolibri",{"_animate":[516],"_color":[1],"_labeled":[516],"state":[32]}]]],["kol-logo.cjs",[[33,"kol-logo",{"_abbr":[1],"_org":[1],"state":[32]}]]],["kol-modal.cjs",[[33,"kol-modal",{"_activeElement":[1040],"_ariaLabel":[1,"_aria-label"],"_width":[1],"_on":[16],"_show":[516],"state":[32]}]]],["kol-progress.cjs",[[33,"kol-progress",{"_max":[2],"_type":[1],"_unit":[1],"_value":[2],"state":[32]}]]],["kol-spin.cjs",[[33,"kol-spin",{"_show":[516],"state":[32]}]]],["kol-symbol.cjs",[[0,"kol-symbol",{"_ariaLabel":[1,"_aria-label"],"_symbol":[1],"state":[32]}]]],["kol-tooltip.cjs",[[32,"kol-tooltip",{"_align":[1],"_id":[1],"_label":[1],"state":[32]}]]],["kol-pagination.cjs",[[33,"kol-pagination",{"_boundaryCount":[2,"_boundary-count"],"_customClass":[1,"_custom-class"],"_hasButtons":[8,"_has-buttons"],"_page":[2],"_pageSize":[1026,"_page-size"],"_pageSizeOptions":[1,"_page-size-options"],"_on":[16],"_siblingCount":[2,"_sibling-count"],"_tooltipAlign":[1,"_tooltip-align"],"_total":[2],"_variant":[1],"state":[32]}]]],["kol-input-number.cjs",[[33,"kol-input-number",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_max":[8],"_min":[8],"_name":[1],"_on":[16],"_placeholder":[1],"_readOnly":[516,"_read-only"],"_required":[516],"_smartButton":[16],"_step":[2],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_type":[1],"_value":[8],"state":[32]}]]],["kol-input-radio.cjs",[[33,"kol-input-radio",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_id":[1],"_list":[1],"_name":[1],"_on":[16],"_orientation":[1],"_required":[516],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[8],"state":[32]}]]],["kol-select.cjs",[[33,"kol-select",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_disabled":[516],"_error":[1],"_height":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_multiple":[516],"_name":[1],"_on":[16],"_required":[516],"_size":[2],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[1025],"state":[32]}]]],["kol-button-group-wc.cjs",[[4,"kol-button-group-wc",{"state":[32]}]]],["kol-indented-text.cjs",[[33,"kol-indented-text",{"state":[32]}]]],["kol-button-wc_2.cjs",[[4,"kol-button-wc",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[516,"_aria-expanded"],"_ariaLabel":[1025,"_aria-label"],"_ariaSelected":[516,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[516],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[516,"_icon-only"],"_id":[1],"_label":[1025],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16],"_variant":[1],"state":[32]}],[4,"kol-span-wc",{"_icon":[1],"_iconOnly":[516,"_icon-only"],"_label":[1],"state":[32]}]]],["kol-button.cjs",[[33,"kol-button",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[516,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[516,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[516],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[516,"_icon-only"],"_id":[1],"_label":[1],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16],"_variant":[1]}]]],["kol-link-wc.cjs",[[4,"kol-link-wc",{"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[516,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[516,"_aria-selected"],"_disabled":[516],"_fill":[516],"_href":[1],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[516,"_icon-only"],"_label":[1025],"_on":[16],"_part":[1],"_role":[1],"_selector":[1],"_stealth":[516],"_tabIndex":[2,"_tab-index"],"_target":[1],"_targetDescription":[1,"_target-description"],"_tooltipAlign":[1,"_tooltip-align"],"_underline":[516],"_useCase":[1,"_use-case"],"state":[32]}]]],["kol-link.cjs",[[33,"kol-link",{"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[516,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[516,"_aria-selected"],"_disabled":[516],"_fill":[516],"_href":[1],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[516,"_icon-only"],"_label":[1],"_on":[16],"_part":[1],"_role":[1],"_selector":[1],"_stealth":[516],"_tabIndex":[2,"_tab-index"],"_target":[1],"_targetDescription":[1,"_target-description"],"_tooltipAlign":[1,"_tooltip-align"],"_underline":[516],"_useCase":[1,"_use-case"]}]]],["kol-alert.cjs",[[33,"kol-alert",{"_alert":[516],"_hasCloser":[516,"_has-closer"],"_heading":[1],"_level":[2],"_on":[16],"_type":[1],"_variant":[1],"state":[32]}]]],["kol-heading-wc_2.cjs",[[4,"kol-input",{"_alert":[516],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[16],"_id":[1],"_list":[1],"_readOnly":[516,"_read-only"],"_renderNoLabel":[516,"_render-no-label"],"_required":[516],"_smartButton":[16],"_touched":[516]}],[4,"kol-heading-wc",{"_level":[514],"state":[32]}]]]]'),a))));exports.defineCustomElements=defineCustomElements;
|
|
4
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});const index=require("./index-77965f6f.js"),appGlobals=require("./app-globals-4d8fc232.js");require("./index-2fff4c22.js"),require("./dev.utils-2353100d.js");const patchEsm=()=>index.promiseResolve(),defineCustomElements=(e,a)=>"undefined"==typeof window?Promise.resolve():index.promiseResolve().then((()=>(appGlobals.globalScripts(),index.bootstrapLazy(JSON.parse('[["kol-abbr.cjs",[[33,"kol-abbr",{"_tooltipAlign":[1,"_tooltip-align"],"_title":[1],"state":[32]}]]],["kol-accordion.cjs",[[33,"kol-accordion",{"_heading":[1],"_level":[2],"_on":[16],"_open":[1540],"state":[32]}]]],["kol-badge.cjs",[[33,"kol-badge",{"_color":[1],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[516,"_icon-only"],"_label":[1],"_smartButton":[1,"_smart-button"],"state":[32]}]]],["kol-table.cjs",[[33,"kol-table",{"_caption":[1],"_data":[1],"_headers":[1],"_minWidth":[1,"_min-width"],"_pagination":[8],"state":[32]}]]],["kol-input-adapter-leanup.cjs",[[1,"kol-input-adapter-leanup"]]],["kol-input-date.cjs",[[33,"kol-input-date",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_max":[1],"_min":[1],"_name":[1],"_on":[16],"_readOnly":[516,"_read-only"],"_required":[516],"_smartButton":[16],"_step":[2],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_type":[1],"_value":[1],"state":[32]}]]],["kol-input-radio-group.cjs",[[1,"kol-input-radio-group",{"_accessKey":[1,"_access-key"],"_alert":[516],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_id":[1],"_list":[1],"_name":[1],"_on":[16],"_orientation":[1],"_required":[516],"_tabIndex":[2,"_tab-index"],"_touched":[516],"_value":[1]}]]],["kol-input-checkbox.cjs",[[33,"kol-input-checkbox",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_checked":[1540],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_id":[1],"_indeterminate":[516],"_name":[1],"_on":[16],"_required":[516],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_type":[1],"_value":[1],"_variant":[1],"state":[32]}]]],["kol-input-color.cjs",[[33,"kol-input-color",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_name":[1],"_on":[16],"_smartButton":[16],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-email.cjs",[[33,"kol-input-email",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_maxLength":[2,"_max-length"],"_multiple":[516],"_name":[1],"_on":[16],"_pattern":[1],"_placeholder":[1],"_readOnly":[516,"_read-only"],"_required":[516],"_size":[2],"_smartButton":[16],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-file.cjs",[[33,"kol-input-file",{"_accept":[1],"_accessKey":[1,"_access-key"],"_alert":[1540],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_multiple":[516],"_name":[1],"_on":[16],"_required":[516],"_smartButton":[16],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-password.cjs",[[33,"kol-input-password",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_maxLength":[2,"_max-length"],"_name":[1],"_on":[16],"_pattern":[1],"_placeholder":[1],"_readOnly":[516,"_read-only"],"_required":[516],"_size":[2],"_smartButton":[16],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-input-range.cjs",[[33,"kol-input-range",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_max":[2],"_min":[2],"_name":[1],"_on":[16],"_step":[2],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[2],"state":[32]}]]],["kol-input-text.cjs",[[33,"kol-input-text",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_maxLength":[2,"_max-length"],"_name":[1],"_on":[16],"_pattern":[1],"_placeholder":[1],"_readOnly":[516,"_read-only"],"_required":[516],"_size":[2],"_smartButton":[16],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_type":[1],"_value":[1025],"state":[32]}]]],["kol-link-group.cjs",[[33,"kol-link-group",{"_ariaLabel":[1,"_aria-label"],"_listStyleType":[1,"_list-style-type"],"_heading":[1],"_level":[2],"_links":[1],"_ordered":[516],"_orientation":[1],"state":[32]}]]],["kol-textarea.cjs",[[33,"kol-textarea",{"_accessKey":[1,"_access-key"],"_adjustHeight":[516,"_adjust-height"],"_alert":[1540],"_hasCounter":[516,"_has-counter"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_id":[1],"_maxLength":[2,"_max-length"],"_name":[1],"_on":[16],"_placeholder":[1],"_readOnly":[516,"_read-only"],"_resize":[1],"_required":[516],"_rows":[1026],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[1],"state":[32]}]]],["kol-breadcrumb.cjs",[[33,"kol-breadcrumb",{"_ariaLabel":[1,"_aria-label"],"_links":[1],"state":[32]}]]],["kol-nav.cjs",[[33,"kol-nav",{"_ariaCurrentValue":[8,"_aria-current-value"],"_ariaLabel":[1,"_aria-label"],"_collapsible":[516],"_compact":[516],"_hasCompactButton":[516,"_has-compact-button"],"_orientation":[1],"_links":[1],"_variant":[1],"state":[32]}]]],["kol-skip-nav.cjs",[[33,"kol-skip-nav",{"_ariaLabel":[1,"_aria-label"],"_links":[1],"state":[32]}]]],["kol-toast.cjs",[[33,"kol-toast",{"_alert":[516],"_hasCloser":[516,"_has-closer"],"_heading":[1],"_level":[2],"_on":[16],"_show":[1540],"_showDuration":[2,"_show-duration"],"_type":[1],"state":[32]}]]],["kol-link-button.cjs",[[33,"kol-link-button",{"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[516,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[516,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[516],"_href":[1],"_icon":[1],"_iconOnly":[516,"_icon-only"],"_label":[1],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_target":[1],"_targetDescription":[1,"_target-description"],"_tooltipAlign":[1,"_tooltip-align"],"_variant":[1],"state":[32]}]]],["kol-tabs.cjs",[[33,"kol-tabs",{"_ariaLabel":[1,"_aria-label"],"_on":[16],"_selected":[1538],"_tabs":[1],"_tabsAlign":[1,"_tabs-align"],"state":[32]}]]],["kol-button-link.cjs",[[33,"kol-button-link",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[516,"_aria-expanded"],"_ariaLabel":[1025,"_aria-label"],"_ariaSelected":[516,"_aria-selected"],"_disabled":[516],"_icon":[1],"_iconOnly":[516,"_icon-only"],"_id":[1],"_label":[1],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16]}]]],["kol-version.cjs",[[33,"kol-version",{"_version":[1],"state":[32]}]]],["kol-details.cjs",[[33,"kol-details",{"_open":[1540],"_summary":[1],"state":[32]}]]],["kol-span.cjs",[[33,"kol-span",{"_icon":[1],"_iconOnly":[516,"_icon-only"],"_label":[1]}]]],["kol-button-group.cjs",[[33,"kol-button-group"]]],["kol-card.cjs",[[33,"kol-card",{"_hasFooter":[516,"_has-footer"],"_heading":[1],"_headline":[1],"_level":[2],"state":[32]}]]],["kol-form.cjs",[[1,"kol-form",{"_on":[16],"_requiredText":[8,"_required-text"],"state":[32]}]]],["kol-heading.cjs",[[33,"kol-heading",{"_level":[514]}]]],["kol-icon.cjs",[[33,"kol-icon",{"_ariaLabel":[1,"_aria-label"],"_icon":[1],"_part":[1],"state":[32]}]]],["kol-icon-font-awesome.cjs",[[32,"kol-icon-font-awesome",{"_ariaLabel":[1,"_aria-label"],"_icon":[1],"_prefix":[1],"_part":[1]}]]],["kol-icon-icofont.cjs",[[32,"kol-icon-icofont",{"_ariaLabel":[1,"_aria-label"],"_icon":[1],"_part":[1]}]]],["kol-color.cjs",[[33,"kol-color",{"selectedColor":[32]}]]],["kol-counter.cjs",[[33,"kol-counter",{"state":[32]}]]],["kol-kolibri.cjs",[[33,"kol-kolibri",{"_animate":[516],"_color":[1],"_labeled":[516],"state":[32]}]]],["kol-logo.cjs",[[33,"kol-logo",{"_abbr":[1],"_org":[1],"state":[32]}]]],["kol-modal.cjs",[[33,"kol-modal",{"_activeElement":[1040],"_ariaLabel":[1,"_aria-label"],"_width":[1],"_on":[16],"_show":[516],"state":[32]}]]],["kol-progress.cjs",[[33,"kol-progress",{"_max":[2],"_type":[1],"_unit":[1],"_value":[2],"state":[32]}]]],["kol-spin.cjs",[[33,"kol-spin",{"_show":[516],"state":[32]}]]],["kol-symbol.cjs",[[0,"kol-symbol",{"_ariaLabel":[1,"_aria-label"],"_symbol":[1],"state":[32]}]]],["kol-tooltip.cjs",[[32,"kol-tooltip",{"_align":[1],"_id":[1],"_label":[1],"state":[32]}]]],["kol-pagination.cjs",[[33,"kol-pagination",{"_boundaryCount":[2,"_boundary-count"],"_customClass":[1,"_custom-class"],"_hasButtons":[8,"_has-buttons"],"_page":[2],"_pageSize":[1026,"_page-size"],"_pageSizeOptions":[1,"_page-size-options"],"_on":[16],"_siblingCount":[2,"_sibling-count"],"_tooltipAlign":[1,"_tooltip-align"],"_total":[2],"_variant":[1],"state":[32]}]]],["kol-input-number.cjs",[[33,"kol-input-number",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_autoComplete":[1,"_auto-complete"],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_max":[8],"_min":[8],"_name":[1],"_on":[16],"_placeholder":[1],"_readOnly":[516,"_read-only"],"_required":[516],"_smartButton":[16],"_step":[2],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_type":[1],"_value":[8],"state":[32]}]]],["kol-input-radio.cjs",[[33,"kol-input-radio",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_id":[1],"_list":[1],"_name":[1],"_on":[16],"_orientation":[1],"_required":[516],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[8],"state":[32]}]]],["kol-select.cjs",[[33,"kol-select",{"_accessKey":[1,"_access-key"],"_alert":[1540],"_disabled":[516],"_error":[1],"_height":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[1],"_id":[1],"_list":[1],"_multiple":[516],"_name":[1],"_on":[16],"_required":[516],"_size":[2],"_tabIndex":[2,"_tab-index"],"_touched":[1540],"_value":[1025],"state":[32]}]]],["kol-button-group-wc.cjs",[[4,"kol-button-group-wc",{"state":[32]}]]],["kol-indented-text.cjs",[[33,"kol-indented-text",{"state":[32]}]]],["kol-button-wc_2.cjs",[[4,"kol-button-wc",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[516,"_aria-expanded"],"_ariaLabel":[1025,"_aria-label"],"_ariaSelected":[516,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[516],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[516,"_icon-only"],"_id":[1],"_label":[1025],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16],"_variant":[1],"state":[32]}],[4,"kol-span-wc",{"_icon":[1],"_iconOnly":[516,"_icon-only"],"_label":[1],"state":[32]}]]],["kol-button.cjs",[[33,"kol-button",{"_accessKey":[1,"_access-key"],"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[516,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[516,"_aria-selected"],"_customClass":[1,"_custom-class"],"_disabled":[516],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[516,"_icon-only"],"_id":[1],"_label":[1],"_on":[16],"_role":[1],"_tabIndex":[2,"_tab-index"],"_tooltipAlign":[1,"_tooltip-align"],"_type":[1],"_value":[16],"_variant":[1]}]]],["kol-link-wc.cjs",[[4,"kol-link-wc",{"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[516,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[516,"_aria-selected"],"_disabled":[516],"_fill":[516],"_href":[1],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[516,"_icon-only"],"_label":[1025],"_on":[16],"_part":[1],"_role":[1],"_selector":[1],"_stealth":[516],"_tabIndex":[2,"_tab-index"],"_target":[1],"_targetDescription":[1,"_target-description"],"_tooltipAlign":[1,"_tooltip-align"],"_underline":[516],"_useCase":[1,"_use-case"],"state":[32]}]]],["kol-link.cjs",[[33,"kol-link",{"_ariaControls":[1,"_aria-controls"],"_ariaCurrent":[8,"_aria-current"],"_ariaExpanded":[516,"_aria-expanded"],"_ariaLabel":[1,"_aria-label"],"_ariaSelected":[516,"_aria-selected"],"_disabled":[516],"_fill":[516],"_href":[1],"_icon":[1],"_iconAlign":[1,"_icon-align"],"_iconOnly":[516,"_icon-only"],"_label":[1],"_on":[16],"_part":[1],"_role":[1],"_selector":[1],"_stealth":[516],"_tabIndex":[2,"_tab-index"],"_target":[1],"_targetDescription":[1,"_target-description"],"_tooltipAlign":[1,"_tooltip-align"],"_underline":[516],"_useCase":[1,"_use-case"]}]]],["kol-alert.cjs",[[33,"kol-alert",{"_alert":[516],"_hasCloser":[516,"_has-closer"],"_heading":[1],"_level":[2],"_on":[16],"_type":[1],"_variant":[1],"state":[32]}]]],["kol-heading-wc_2.cjs",[[4,"kol-input",{"_alert":[516],"_disabled":[516],"_error":[1],"_hideLabel":[516,"_hide-label"],"_hint":[1],"_icon":[16],"_id":[1],"_list":[1],"_readOnly":[516,"_read-only"],"_renderNoLabel":[516,"_render-no-label"],"_required":[516],"_smartButton":[16],"_touched":[516]}],[4,"kol-heading-wc",{"_level":[514],"state":[32]}]]]]'),a))));exports.setNonce=index.setNonce,exports.defineCustomElements=defineCustomElements;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* KoliBri - The accessible HTML-Standard
|
|
3
3
|
*/
|
|
4
|
-
"use strict";const index=require("./index-079091fe.js"),index_m=require("./index.m-21aa1255.js"),a11y_tipps=require("./a11y.tipps-e1770acf.js"),dev_utils=require("./dev.utils-2353100d.js"),pushNodes=(e,t)=>{t.forEach((t=>{!1===e.has(t)&&e.add(t)}))},querySelectorAll=(e,t=document)=>{if(t instanceof Document||t instanceof HTMLElement||t instanceof ShadowRoot){const r=new Set;pushNodes(r,t.querySelectorAll(e));const o=t.querySelectorAll('[class*="hydrated"]');for(let t=0;t<o.length;t++){const n=o[t].shadowRoot;pushNodes(r,querySelectorAll(e,"object"==typeof n&&null!==n?n:o[t]))}return Array.from(r)}throw new Error("The parameter document for the method querySelectorAll is not type of Document, HTMLElement or ShadowRoot.")},querySelector=(e,t=document)=>{if(t instanceof Document||t instanceof HTMLElement||t instanceof ShadowRoot){let r=t.querySelector(e);if(null===r){const o=t.querySelectorAll('[class*="hydrated"]');for(let t=0;t<o.length;t++){const n=o[t].shadowRoot;if(r=querySelector(e,"object"==typeof n&&null!==n?n:o[t]),null!==r)break}}return r}throw new Error("The parameter document for the method querySelector is not type of Document, HTMLElement or ShadowRoot.")};var rgbaConvert=arr,arr_1=arr,obj_1=obj,css_1=css,hex_1=hex,num_1=num;function arr(e){var t=parse(e);return 3==t.length?t.concat(255):(t[3]=Math.round(t[3]),t)}function obj(e){var t=parse(e);return{r:t[0],g:t[1],b:t[2],a:3==t.length?255:Math.round(t[3])}}function css(e){var t=parse(e);return 3==t.length&&t.push(255),255==t[3]?"rgb("+t[0]+", "+t[1]+", "+t[2]+")":0==t[3]?"rgba("+t[0]+", "+t[1]+", "+t[2]+", 0)":"rgba("+t[0]+", "+t[1]+", "+t[2]+", "+String(t[3]/255).substr(1)+")"}function hex(e){3==(t=parse(e)).length&&t.push(255);var t,r=255==t[3],o=num2hex(t[0]),n=num2hex(t[1]),l=num2hex(t[2]),i=isshort(o,n,l,t=num2hex(Math.round(t[3])));return r?i?"#"+o.charAt(0)+n.charAt(0)+l.charAt(0):"#"+o+n+l:i?"#"+o.charAt(0)+n.charAt(0)+l.charAt(0)+t.charAt(0):"#"+o+n+l+t}function num(e){var t=parse(e);return 3==t.length?t.push(255):t[3]=Math.round(t[3]),(t[3]<<24>>>0|t[0]<<16|t[1]<<8|t[2])>>>0}function parse(e){return"string"==typeof e?name(e=e.toLowerCase())||hex3(e)||hex6(e)||rgb(e)||rgba(e)||[0,0,0,255]:object(e)||array(e)||number(e)||[0,0,0,255]}function num2hex(e){var t=e.toString(16);return 1==t.length?"0"+t:t}function isshort(e,t,r,o){var n=["ff","00","11","22","33","44","55","66","77","88","99","aa","bb","cc","dd","ee"];return-1!=n.indexOf(e)&&-1!=n.indexOf(t)&&-1!=n.indexOf(r)&&-1!=n.indexOf(o)}function name(e){return"red"==e?[255,0,0]:"green"==e?[0,255,0]:"blue"==e?[0,0,255]:"black"==e?[0,0,0]:"white"==e?[255,255,255]:"cyan"==e?[0,255,255]:"gray"==e||"grey"==e?[128,128,128]:"magenta"==e||"pink"==e?[255,0,255]:"yellow"==e?[255,255,0]:void 0}function hex2num(e){return 1==e.length?parseInt(e+e,16):parseInt(e,16)}function hex3(e){var t=e.replace(/^#/,""),r=t.length;if(3==r||4==r){var o=hex2num(t[0]),n=hex2num(t[1]),l=hex2num(t[2]),i=3==r?255:hex2num(t[3]);if(isNaN(o)||isNaN(n)||isNaN(l)||isNaN(i))return;return[o,n,l,i]}}function hex6(e){var t=e.replace(/^#/,""),r=t.length;if(6==r||8==r){var o=hex2num(t.slice(0,2)),n=hex2num(t.slice(2,4)),l=hex2num(t.slice(4,6)),i=6==r?255:hex2num(t.slice(6,8));if(isNaN(o)||isNaN(n)||isNaN(l)||isNaN(i))return;return[o,n,l,i]}}function getnum(e,t){return"number"!=typeof e||!0===t&&Math.floor(e)!==e?-1:e>=0&&e<=255?e:-1}function object(e){if("[object Object]"===Object.prototype.toString.call(e)&&Object.getPrototypeOf(e)===Object.getPrototypeOf({})){var t=getnum(null!=e.r?e.r:null!=e.red?e.red:0,!0),r=getnum(null!=e.g?e.g:null!=e.green?e.green:0,!0),o=getnum(null!=e.b?e.b:null!=e.blue?e.blue:0,!0),n=getnum(null!=e.a?e.a:null!=e.alpha?e.alpha:255,!0);if(-1!=t&&-1!=r&&-1!=o&&-1!=n)return[t,r,o,n]}}function array(e){if(Array.isArray(e)&&(3==e.length||4==e.length)){var t=getnum(e[0],!0),r=getnum(e[1],!0),o=getnum(e[2],!0),n=getnum(null!=e[3]?e[3]:255,!0);if(-1!=t&&-1!=r&&-1!=o&&-1!=n)return[t,r,o,n]}}function number(e){if("number"==typeof e&&Math.floor(e)==e&&e<=4294967295&&e>=0)return[e>>16&255,e>>8&255,255&e,e>>24&255]}function rgb(e){if("rgb("==e.substr(0,4)){var t=(e=e.match(/^rgb\(([^)]+)\)/)[1]).split(/ *, */).map(Number),r=getnum(t[0],!0),o=getnum(t[1],!0),n=getnum(t[2],!0);if(-1!=r&&-1!=o&&-1!=n)return[r,o,n,255]}}function rgba(e){if("rgba("==e.substr(0,5)){var t=(e=e.match(/^rgba\(([^)]+)\)/)[1]).split(/ *, */).map(Number),r=getnum(t[0],!0),o=getnum(t[1],!0),n=getnum(t[2],!0),l=getnum(255*t[3]);if(-1!=r&&-1!=o&&-1!=n&&-1!=l)return[r,o,n,l]}}rgbaConvert.arr=arr_1,rgbaConvert.obj=obj_1,rgbaConvert.css=css_1,rgbaConvert.hex=hex_1,rgbaConvert.num=num_1;const OBJECT_OBJECT=/\[object Object\]/,objectObjectHandler=(e,t)=>{"string"==typeof e&&OBJECT_OBJECT.test(e)||t()},emptyStringByArrayHandler=(e,t)=>{"string"==typeof e&&""===e||t()},setEventTargetAndStopPropagation=(e,t)=>{dev_utils.getExperimalMode()&&(console.log(e,t),a11y_tipps.devHint("↑ We propagate the (submit) event to this target.")),Object.defineProperty(e,"target",{value:t,writable:!1})},patchState=e=>{var t,r,o;null===(t=e.nextHooks)||void 0===t||t.forEach(((t,r)=>{var o;const n=t.get("beforePatch");"function"==typeof n&&n(null===(o=e.nextState)||void 0===o?void 0:o.get(r),e.nextState,e,r)})),(null===(r=e.nextState)||void 0===r?void 0:r.size)>0&&(e.state=Object.assign(Object.assign({},e.state),Object.fromEntries(e.nextState)),delete e.nextState,null===(o=e.nextHooks)||void 0===o||o.forEach(((t,r)=>{const o=t.get("afterPatch");"function"==typeof o&&o(e.state[r],e.state,e,r)}))),delete e.nextHooks},setState=(e,t,r,o={})=>{var n,l;if(void 0===e.nextHooks&&(e.nextHooks=new Map),void 0===e.nextState&&(e.nextState=new Map),e.nextState.get(t)!==r){e.nextHooks.get(t)instanceof Map==!1&&e.nextHooks.set(t,new Map),"function"==typeof o.afterPatch&&(null===(n=e.nextHooks.get(t))||void 0===n||n.set("afterPatch",o.afterPatch)),"function"==typeof o.beforePatch&&(null===(l=e.nextHooks.get(t))||void 0===l||l.set("beforePatch",o.beforePatch)),e.nextState.set(t,r),patchState(e)}},logWarn=(e,t,r,o)=>{a11y_tipps.devHint(`[${e.constructor.name}] Der Property-Wert (${r}) für '${t}' ist nicht valide. Folgende Werte sind erlaubt: ${Array.from(o).join(", ")}`)},watchValidator=(e,t,r,o,n,l={})=>{r(n)?setState(e,t,n,null==l?void 0:l.hooks):void 0===n||null===n&&(void 0===(null==l?void 0:l.required)||!1===(null==l?void 0:l.required))?setState(e,t,null==l?void 0:l.defaultValue,null==l?void 0:l.hooks):(void 0!==(null==l?void 0:l.required)&&!1!==(null==l?void 0:l.required)||o.add(null),logWarn(e,t,n,o))},watchBoolean=(e,t,r,o)=>{watchValidator(e,t,(e=>"boolean"==typeof e),new Set(["Boolean {true, false}"]),r,o)},watchString=(e,t,r,o={})=>{const n="number"==typeof o.minLength?null==o?void 0:o.minLength:0;watchValidator(e,t,(e=>"string"==typeof e&&e.length>=n),new Set([`String (Mindestlänge ${n})`]),r,o)},watchNumber=(e,t,r,o)=>{watchValidator(e,t,(e=>"number"==typeof e&&(void 0===(null==o?void 0:o.min)||"number"==typeof(null==o?void 0:o.min)&&e>=o.min)&&(void 0===(null==o?void 0:o.max)||"number"==typeof(null==o?void 0:o.max)&&e<=o.max)),new Set(["Number"]),r,o)},watchJsonArrayString=(e,t,r,o,n=(e=>e==e),l={})=>{emptyStringByArrayHandler(o,(()=>{objectObjectHandler(o,(()=>{void 0===o&&(o=[]);try{try{o=parseJson(o)}catch(e){}if(Array.isArray(o)){const i=o.find((e=>!r(e)));void 0===i&&n(o)?setState(e,t,o,l.hooks):objectObjectHandler(i,(()=>{throw console.log(i),new Error("↑ Das Schema für das Property (_options) ist nicht valide. Der Wert wird nicht geändert.")}))}else objectObjectHandler(o,(()=>{throw console.log(o),new Error("↑ Das Schema für das Property (_options) ist nicht valide. Der Wert wird nicht geändert.")}))}catch(e){a11y_tipps.devHint("Known bug: Zeichenkettenliste (string[])")}}))}))},BOOLEAN=/^(true|false)$/,INTEGER=/^-?(0|[1-9]\d*)$/,FLOAT=/^-?(0.|[1-9]\d*.)\d*[1-9]$/,mapString2Unknown=e=>{const t=typeof e,r=`${e}`;if("string"==typeof e)if(BOOLEAN.test(e))e="true"===e;else if(INTEGER.test(e))e=parseInt(e);else if(FLOAT.test(e))e=parseFloat(e);else if(JSON_CHARS.test(e))try{e=parseJson(e)}catch(e){}return t!==typeof e&&a11y_tipps.devHint(`You have used a stringified property value (${r} to ${JSON.stringify(e)}) which type switched from ${t} to ${typeof e}!`),e},stringifyJson=e=>{try{return JSON.stringify(e).replace(/"/g,"'")}catch(t){throw dev_utils.Log.warn(["stringifyJson",e]),dev_utils.Log.error("↑ Das JSON konnte nicht in einen String umgewandelt werden. Es wird ein stringifizierbares JSON erwartet."),new Error}},JSON_CHARS=/^[{[]/,parseJson=e=>{if("string"==typeof e)try{return JSON.parse(e)}catch(t){if(JSON_CHARS.test(e))try{return JSON.parse(e.replace(/'/g,'"'))}catch(t){dev_utils.Log.warn(["parseJson",e]),dev_utils.Log.error("↑ Der JSON-String konnte nicht geparsed werden. Achten Sie darauf, dass einfache Anführungszeichen im Text maskiert werden (‘).")}}throw new Error},mapBoolean2String=e=>"boolean"==typeof e?!0===e?"true":"false":void 0,mapStringOrBoolean2String=e=>"string"==typeof e?e:mapBoolean2String(e),koliBriQuerySelector=(e,t)=>querySelector(e,t||dev_utils.getDocument()),koliBriQuerySelectorAll=(e,t)=>querySelectorAll(e,t||dev_utils.getDocument());let DEFAULT_COLOR_CONTRAST=null;const getDefaultColorContrast=()=>(DEFAULT_COLOR_CONTRAST=DEFAULT_COLOR_CONTRAST||{backgroundColor:"#00000000",color:"#00000000",domNode:dev_utils.getDocument().body,level:"Fail",score:1},DEFAULT_COLOR_CONTRAST),TRANSPARENT_REGEXP=/(\d+, ){3}0\)/,koliBriA11yColorContrast=(e,t=getDefaultColorContrast())=>{const r=getComputedStyle(e),o=TRANSPARENT_REGEXP.test(r.backgroundColor)?t.backgroundColor:rgbaConvert.hex(r.backgroundColor),n=TRANSPARENT_REGEXP.test(r.color)?t.color:rgbaConvert.hex(r.color),l=index_m.s(o,n),i={backgroundColor:o,color:n,domNode:e,level:index_m.f(l),score:l};return l<4.5&&dev_utils.Log.error(["Color-Contrast-Error",{backgroundColor:i.backgroundColor,color:i.color,level:i.level,score:i.score},i.domNode]),i},koliBriQuerySelectorColors=(e,t=getDefaultColorContrast())=>{t.domNode instanceof HTMLElement&&(t=koliBriA11yColorContrast(t.domNode,t));const r=t.domNode.querySelector(e);if(null===r){const r=t.domNode.querySelectorAll('[class="hydrated"]');for(let o=0;o<r.length&&(t.domNode=r[o],null===(t=koliBriQuerySelectorColors(e,t)).domNode);o++);return t}return koliBriA11yColorContrast(r,t)},scrollByHTMLElement=(e,t=window)=>{e instanceof HTMLElement?(t.scrollTo({behavior:"smooth",top:e.getBoundingClientRect().top+dev_utils.getWindow().pageYOffset-50}),e.focus()):a11y_tipps.devHint("Das HTMLElement ist nicht valide, zu dem gescrollt werden soll.")},scrollBySelector=(e,t)=>{if((e instanceof Document||e instanceof HTMLElement||e instanceof ShadowRoot)&&"string"==typeof t){a11y_tipps.devHint("Bei der Methode querySelectorAll wurden die Parameter document, selector in selector, document getauscht, da der Parameter selector nicht, allerdings der Parameter document optional sein kann.");const r=`${t}`;t=e,e=r}if("string"==typeof e){const r=koliBriQuerySelector(e,t);r instanceof HTMLElement?scrollByHTMLElement(r):a11y_tipps.devHint(`Es konnte kein HTMLElement mit dem Selector (${e}) gefunden werden, zu dem gescrollt werden soll.`)}else a11y_tipps.devHint("Der Selector ist nicht valide, zu dem gescrollt werden soll.")};class KoliBriUtils{static queryHtmlElementColors(e,t,r=!1,o=!0){let n=null;if(!0===r||!1===KoliBriUtils.executionLock)if(!1===r&&(KoliBriUtils.cache.clear(),KoliBriUtils.cache.set(t.domNode,t),KoliBriUtils.executionLock=!0,!0===o&&dev_utils.Log.debug("[KoliBriUtils] Color contrast analysis started...")),e===t.domNode)n=t;else{const r=new Set;if(t.domNode.shadowRoot){const e=t.domNode.shadowRoot.children;for(let t=0;t<e.length;t++)r.add(e[t])}const o=t.domNode;if("function"==typeof o.assignedNodes){const e=o.assignedNodes();for(let t=0;t<e.length;t++)e[t]instanceof HTMLElement&&r.add(e[t])}const l=t.domNode.children;for(let e=0;e<l.length;e++)r.add(l[e]);const i=Array.from(r);for(let r=0;r<i.length;r++){let o=KoliBriUtils.cache.get(i[r]);void 0===o&&(o=koliBriA11yColorContrast(i[r],t)),KoliBriUtils.cache.set(i[r],o);const l=KoliBriUtils.queryHtmlElementColors(e,o,!0,!1);if(null!==l){n=l;break}}}else dev_utils.Log.debug("[KoliBriUtils] Call aborted because a color contrast analysis is currently being executed.");return!1===r&&(!0===o&&dev_utils.Log.debug(`[KoliBriUtils] Color contrast analysis finished (${KoliBriUtils.cache.size} DOM elements are analysed).`),KoliBriUtils.executionLock=!1,KoliBriUtils.cache.clear()),n}}KoliBriUtils.executionLock=!1,KoliBriUtils.cache=new Map;class KoliBriDevHelper{}KoliBriDevHelper.patchTheme=index.patchTheme,KoliBriDevHelper.patchThemeTag=index.patchThemeTag,KoliBriDevHelper.querySelector=koliBriQuerySelector,KoliBriDevHelper.querySelectorAll=koliBriQuerySelectorAll,KoliBriDevHelper.scrollByHTMLElement=scrollByHTMLElement,KoliBriDevHelper.scrollBySelector=scrollBySelector,KoliBriDevHelper.stringifyJson=stringifyJson,exports.KoliBriDevHelper=KoliBriDevHelper,exports.KoliBriUtils=KoliBriUtils,exports.emptyStringByArrayHandler=emptyStringByArrayHandler,exports.koliBriA11yColorContrast=koliBriA11yColorContrast,exports.koliBriQuerySelector=koliBriQuerySelector,exports.koliBriQuerySelectorAll=koliBriQuerySelectorAll,exports.koliBriQuerySelectorColors=koliBriQuerySelectorColors,exports.mapBoolean2String=mapBoolean2String,exports.mapString2Unknown=mapString2Unknown,exports.mapStringOrBoolean2String=mapStringOrBoolean2String,exports.objectObjectHandler=objectObjectHandler,exports.parseJson=parseJson,exports.rgbaConvert=rgbaConvert,exports.scrollBySelector=scrollBySelector,exports.setEventTargetAndStopPropagation=setEventTargetAndStopPropagation,exports.setState=setState,exports.stringifyJson=stringifyJson,exports.watchBoolean=watchBoolean,exports.watchJsonArrayString=watchJsonArrayString,exports.watchNumber=watchNumber,exports.watchString=watchString,exports.watchValidator=watchValidator;
|
|
4
|
+
"use strict";const index=require("./index-2fff4c22.js"),index_m=require("./index.m-21aa1255.js"),a11y_tipps=require("./a11y.tipps-e1770acf.js"),dev_utils=require("./dev.utils-2353100d.js"),pushNodes=(e,t)=>{t.forEach((t=>{!1===e.has(t)&&e.add(t)}))},querySelectorAll=(e,t=document)=>{if(t instanceof Document||t instanceof HTMLElement||t instanceof ShadowRoot){const r=new Set;pushNodes(r,t.querySelectorAll(e));const o=t.querySelectorAll('[class*="hydrated"]');for(let t=0;t<o.length;t++){const n=o[t].shadowRoot;pushNodes(r,querySelectorAll(e,"object"==typeof n&&null!==n?n:o[t]))}return Array.from(r)}throw new Error("The parameter document for the method querySelectorAll is not type of Document, HTMLElement or ShadowRoot.")},querySelector=(e,t=document)=>{if(t instanceof Document||t instanceof HTMLElement||t instanceof ShadowRoot){let r=t.querySelector(e);if(null===r){const o=t.querySelectorAll('[class*="hydrated"]');for(let t=0;t<o.length;t++){const n=o[t].shadowRoot;if(r=querySelector(e,"object"==typeof n&&null!==n?n:o[t]),null!==r)break}}return r}throw new Error("The parameter document for the method querySelector is not type of Document, HTMLElement or ShadowRoot.")};var rgbaConvert=arr,arr_1=arr,obj_1=obj,css_1=css,hex_1=hex,num_1=num;function arr(e){var t=parse(e);return 3==t.length?t.concat(255):(t[3]=Math.round(t[3]),t)}function obj(e){var t=parse(e);return{r:t[0],g:t[1],b:t[2],a:3==t.length?255:Math.round(t[3])}}function css(e){var t=parse(e);return 3==t.length&&t.push(255),255==t[3]?"rgb("+t[0]+", "+t[1]+", "+t[2]+")":0==t[3]?"rgba("+t[0]+", "+t[1]+", "+t[2]+", 0)":"rgba("+t[0]+", "+t[1]+", "+t[2]+", "+String(t[3]/255).substr(1)+")"}function hex(e){3==(t=parse(e)).length&&t.push(255);var t,r=255==t[3],o=num2hex(t[0]),n=num2hex(t[1]),l=num2hex(t[2]),i=isshort(o,n,l,t=num2hex(Math.round(t[3])));return r?i?"#"+o.charAt(0)+n.charAt(0)+l.charAt(0):"#"+o+n+l:i?"#"+o.charAt(0)+n.charAt(0)+l.charAt(0)+t.charAt(0):"#"+o+n+l+t}function num(e){var t=parse(e);return 3==t.length?t.push(255):t[3]=Math.round(t[3]),(t[3]<<24>>>0|t[0]<<16|t[1]<<8|t[2])>>>0}function parse(e){return"string"==typeof e?name(e=e.toLowerCase())||hex3(e)||hex6(e)||rgb(e)||rgba(e)||[0,0,0,255]:object(e)||array(e)||number(e)||[0,0,0,255]}function num2hex(e){var t=e.toString(16);return 1==t.length?"0"+t:t}function isshort(e,t,r,o){var n=["ff","00","11","22","33","44","55","66","77","88","99","aa","bb","cc","dd","ee"];return-1!=n.indexOf(e)&&-1!=n.indexOf(t)&&-1!=n.indexOf(r)&&-1!=n.indexOf(o)}function name(e){return"red"==e?[255,0,0]:"green"==e?[0,255,0]:"blue"==e?[0,0,255]:"black"==e?[0,0,0]:"white"==e?[255,255,255]:"cyan"==e?[0,255,255]:"gray"==e||"grey"==e?[128,128,128]:"magenta"==e||"pink"==e?[255,0,255]:"yellow"==e?[255,255,0]:void 0}function hex2num(e){return 1==e.length?parseInt(e+e,16):parseInt(e,16)}function hex3(e){var t=e.replace(/^#/,""),r=t.length;if(3==r||4==r){var o=hex2num(t[0]),n=hex2num(t[1]),l=hex2num(t[2]),i=3==r?255:hex2num(t[3]);if(isNaN(o)||isNaN(n)||isNaN(l)||isNaN(i))return;return[o,n,l,i]}}function hex6(e){var t=e.replace(/^#/,""),r=t.length;if(6==r||8==r){var o=hex2num(t.slice(0,2)),n=hex2num(t.slice(2,4)),l=hex2num(t.slice(4,6)),i=6==r?255:hex2num(t.slice(6,8));if(isNaN(o)||isNaN(n)||isNaN(l)||isNaN(i))return;return[o,n,l,i]}}function getnum(e,t){return"number"!=typeof e||!0===t&&Math.floor(e)!==e?-1:e>=0&&e<=255?e:-1}function object(e){if("[object Object]"===Object.prototype.toString.call(e)&&Object.getPrototypeOf(e)===Object.getPrototypeOf({})){var t=getnum(null!=e.r?e.r:null!=e.red?e.red:0,!0),r=getnum(null!=e.g?e.g:null!=e.green?e.green:0,!0),o=getnum(null!=e.b?e.b:null!=e.blue?e.blue:0,!0),n=getnum(null!=e.a?e.a:null!=e.alpha?e.alpha:255,!0);if(-1!=t&&-1!=r&&-1!=o&&-1!=n)return[t,r,o,n]}}function array(e){if(Array.isArray(e)&&(3==e.length||4==e.length)){var t=getnum(e[0],!0),r=getnum(e[1],!0),o=getnum(e[2],!0),n=getnum(null!=e[3]?e[3]:255,!0);if(-1!=t&&-1!=r&&-1!=o&&-1!=n)return[t,r,o,n]}}function number(e){if("number"==typeof e&&Math.floor(e)==e&&e<=4294967295&&e>=0)return[e>>16&255,e>>8&255,255&e,e>>24&255]}function rgb(e){if("rgb("==e.substr(0,4)){var t=(e=e.match(/^rgb\(([^)]+)\)/)[1]).split(/ *, */).map(Number),r=getnum(t[0],!0),o=getnum(t[1],!0),n=getnum(t[2],!0);if(-1!=r&&-1!=o&&-1!=n)return[r,o,n,255]}}function rgba(e){if("rgba("==e.substr(0,5)){var t=(e=e.match(/^rgba\(([^)]+)\)/)[1]).split(/ *, */).map(Number),r=getnum(t[0],!0),o=getnum(t[1],!0),n=getnum(t[2],!0),l=getnum(255*t[3]);if(-1!=r&&-1!=o&&-1!=n&&-1!=l)return[r,o,n,l]}}rgbaConvert.arr=arr_1,rgbaConvert.obj=obj_1,rgbaConvert.css=css_1,rgbaConvert.hex=hex_1,rgbaConvert.num=num_1;const OBJECT_OBJECT=/\[object Object\]/,objectObjectHandler=(e,t)=>{"string"==typeof e&&OBJECT_OBJECT.test(e)||t()},emptyStringByArrayHandler=(e,t)=>{"string"==typeof e&&""===e||t()},setEventTargetAndStopPropagation=(e,t)=>{dev_utils.getExperimalMode()&&(console.log(e,t),a11y_tipps.devHint("↑ We propagate the (submit) event to this target.")),Object.defineProperty(e,"target",{value:t,writable:!1})},patchState=e=>{var t,r,o;null===(t=e.nextHooks)||void 0===t||t.forEach(((t,r)=>{var o;const n=t.get("beforePatch");"function"==typeof n&&n(null===(o=e.nextState)||void 0===o?void 0:o.get(r),e.nextState,e,r)})),(null===(r=e.nextState)||void 0===r?void 0:r.size)>0&&(e.state=Object.assign(Object.assign({},e.state),Object.fromEntries(e.nextState)),delete e.nextState,null===(o=e.nextHooks)||void 0===o||o.forEach(((t,r)=>{const o=t.get("afterPatch");"function"==typeof o&&o(e.state[r],e.state,e,r)}))),delete e.nextHooks},setState=(e,t,r,o={})=>{var n,l;if(void 0===e.nextHooks&&(e.nextHooks=new Map),void 0===e.nextState&&(e.nextState=new Map),e.nextState.get(t)!==r){e.nextHooks.get(t)instanceof Map==!1&&e.nextHooks.set(t,new Map),"function"==typeof o.afterPatch&&(null===(n=e.nextHooks.get(t))||void 0===n||n.set("afterPatch",o.afterPatch)),"function"==typeof o.beforePatch&&(null===(l=e.nextHooks.get(t))||void 0===l||l.set("beforePatch",o.beforePatch)),e.nextState.set(t,r),patchState(e)}},logWarn=(e,t,r,o)=>{a11y_tipps.devHint(`[${e.constructor.name}] Der Property-Wert (${r}) für '${t}' ist nicht valide. Folgende Werte sind erlaubt: ${Array.from(o).join(", ")}`)},watchValidator=(e,t,r,o,n,l={})=>{r(n)?setState(e,t,n,null==l?void 0:l.hooks):void 0===n||null===n&&(void 0===(null==l?void 0:l.required)||!1===(null==l?void 0:l.required))?setState(e,t,null==l?void 0:l.defaultValue,null==l?void 0:l.hooks):(void 0!==(null==l?void 0:l.required)&&!1!==(null==l?void 0:l.required)||o.add(null),logWarn(e,t,n,o))},watchBoolean=(e,t,r,o)=>{watchValidator(e,t,(e=>"boolean"==typeof e),new Set(["Boolean {true, false}"]),r,o)},watchString=(e,t,r,o={})=>{const n="number"==typeof o.minLength?null==o?void 0:o.minLength:0;watchValidator(e,t,(e=>"string"==typeof e&&e.length>=n),new Set([`String (Mindestlänge ${n})`]),r,o)},watchNumber=(e,t,r,o)=>{watchValidator(e,t,(e=>"number"==typeof e&&(void 0===(null==o?void 0:o.min)||"number"==typeof(null==o?void 0:o.min)&&e>=o.min)&&(void 0===(null==o?void 0:o.max)||"number"==typeof(null==o?void 0:o.max)&&e<=o.max)),new Set(["Number"]),r,o)},watchJsonArrayString=(e,t,r,o,n=(e=>e==e),l={})=>{emptyStringByArrayHandler(o,(()=>{objectObjectHandler(o,(()=>{void 0===o&&(o=[]);try{try{o=parseJson(o)}catch(e){}if(Array.isArray(o)){const i=o.find((e=>!r(e)));void 0===i&&n(o)?setState(e,t,o,l.hooks):objectObjectHandler(i,(()=>{throw console.log(i),new Error("↑ Das Schema für das Property (_options) ist nicht valide. Der Wert wird nicht geändert.")}))}else objectObjectHandler(o,(()=>{throw console.log(o),new Error("↑ Das Schema für das Property (_options) ist nicht valide. Der Wert wird nicht geändert.")}))}catch(e){a11y_tipps.devHint("Known bug: Zeichenkettenliste (string[])")}}))}))},BOOLEAN=/^(true|false)$/,INTEGER=/^-?(0|[1-9]\d*)$/,FLOAT=/^-?(0.|[1-9]\d*.)\d*[1-9]$/,mapString2Unknown=e=>{const t=typeof e,r=`${e}`;if("string"==typeof e)if(BOOLEAN.test(e))e="true"===e;else if(INTEGER.test(e))e=parseInt(e);else if(FLOAT.test(e))e=parseFloat(e);else if(JSON_CHARS.test(e))try{e=parseJson(e)}catch(e){}return t!==typeof e&&a11y_tipps.devHint(`You have used a stringified property value (${r} to ${JSON.stringify(e)}) which type switched from ${t} to ${typeof e}!`),e},stringifyJson=e=>{try{return JSON.stringify(e).replace(/"/g,"'")}catch(t){throw dev_utils.Log.warn(["stringifyJson",e]),dev_utils.Log.error("↑ Das JSON konnte nicht in einen String umgewandelt werden. Es wird ein stringifizierbares JSON erwartet."),new Error}},JSON_CHARS=/^[{[]/,parseJson=e=>{if("string"==typeof e)try{return JSON.parse(e)}catch(t){if(JSON_CHARS.test(e))try{return JSON.parse(e.replace(/'/g,'"'))}catch(t){dev_utils.Log.warn(["parseJson",e]),dev_utils.Log.error("↑ Der JSON-String konnte nicht geparsed werden. Achten Sie darauf, dass einfache Anführungszeichen im Text maskiert werden (‘).")}}throw new Error},mapBoolean2String=e=>"boolean"==typeof e?!0===e?"true":"false":void 0,mapStringOrBoolean2String=e=>"string"==typeof e?e:mapBoolean2String(e),koliBriQuerySelector=(e,t)=>querySelector(e,t||dev_utils.getDocument()),koliBriQuerySelectorAll=(e,t)=>querySelectorAll(e,t||dev_utils.getDocument());let DEFAULT_COLOR_CONTRAST=null;const getDefaultColorContrast=()=>(DEFAULT_COLOR_CONTRAST=DEFAULT_COLOR_CONTRAST||{backgroundColor:"#00000000",color:"#00000000",domNode:dev_utils.getDocument().body,level:"Fail",score:1},DEFAULT_COLOR_CONTRAST),TRANSPARENT_REGEXP=/(\d+, ){3}0\)/,koliBriA11yColorContrast=(e,t=getDefaultColorContrast())=>{const r=getComputedStyle(e),o=TRANSPARENT_REGEXP.test(r.backgroundColor)?t.backgroundColor:rgbaConvert.hex(r.backgroundColor),n=TRANSPARENT_REGEXP.test(r.color)?t.color:rgbaConvert.hex(r.color),l=index_m.s(o,n),i={backgroundColor:o,color:n,domNode:e,level:index_m.f(l),score:l};return l<4.5&&dev_utils.Log.error(["Color-Contrast-Error",{backgroundColor:i.backgroundColor,color:i.color,level:i.level,score:i.score},i.domNode]),i},koliBriQuerySelectorColors=(e,t=getDefaultColorContrast())=>{t.domNode instanceof HTMLElement&&(t=koliBriA11yColorContrast(t.domNode,t));const r=t.domNode.querySelector(e);if(null===r){const r=t.domNode.querySelectorAll('[class="hydrated"]');for(let o=0;o<r.length&&(t.domNode=r[o],null===(t=koliBriQuerySelectorColors(e,t)).domNode);o++);return t}return koliBriA11yColorContrast(r,t)},scrollByHTMLElement=(e,t=window)=>{e instanceof HTMLElement?(t.scrollTo({behavior:"smooth",top:e.getBoundingClientRect().top+dev_utils.getWindow().pageYOffset-50}),e.focus()):a11y_tipps.devHint("Das HTMLElement ist nicht valide, zu dem gescrollt werden soll.")},scrollBySelector=(e,t)=>{if((e instanceof Document||e instanceof HTMLElement||e instanceof ShadowRoot)&&"string"==typeof t){a11y_tipps.devHint("Bei der Methode querySelectorAll wurden die Parameter document, selector in selector, document getauscht, da der Parameter selector nicht, allerdings der Parameter document optional sein kann.");const r=`${t}`;t=e,e=r}if("string"==typeof e){const r=koliBriQuerySelector(e,t);r instanceof HTMLElement?scrollByHTMLElement(r):a11y_tipps.devHint(`Es konnte kein HTMLElement mit dem Selector (${e}) gefunden werden, zu dem gescrollt werden soll.`)}else a11y_tipps.devHint("Der Selector ist nicht valide, zu dem gescrollt werden soll.")};class KoliBriUtils{static queryHtmlElementColors(e,t,r=!1,o=!0){let n=null;if(!0===r||!1===KoliBriUtils.executionLock)if(!1===r&&(KoliBriUtils.cache.clear(),KoliBriUtils.cache.set(t.domNode,t),KoliBriUtils.executionLock=!0,!0===o&&dev_utils.Log.debug("[KoliBriUtils] Color contrast analysis started...")),e===t.domNode)n=t;else{const r=new Set;if(t.domNode.shadowRoot){const e=t.domNode.shadowRoot.children;for(let t=0;t<e.length;t++)r.add(e[t])}const o=t.domNode;if("function"==typeof o.assignedNodes){const e=o.assignedNodes();for(let t=0;t<e.length;t++)e[t]instanceof HTMLElement&&r.add(e[t])}const l=t.domNode.children;for(let e=0;e<l.length;e++)r.add(l[e]);const i=Array.from(r);for(let r=0;r<i.length;r++){let o=KoliBriUtils.cache.get(i[r]);void 0===o&&(o=koliBriA11yColorContrast(i[r],t)),KoliBriUtils.cache.set(i[r],o);const l=KoliBriUtils.queryHtmlElementColors(e,o,!0,!1);if(null!==l){n=l;break}}}else dev_utils.Log.debug("[KoliBriUtils] Call aborted because a color contrast analysis is currently being executed.");return!1===r&&(!0===o&&dev_utils.Log.debug(`[KoliBriUtils] Color contrast analysis finished (${KoliBriUtils.cache.size} DOM elements are analysed).`),KoliBriUtils.executionLock=!1,KoliBriUtils.cache.clear()),n}}KoliBriUtils.executionLock=!1,KoliBriUtils.cache=new Map;class KoliBriDevHelper{}KoliBriDevHelper.patchTheme=index.patchTheme,KoliBriDevHelper.patchThemeTag=index.patchThemeTag,KoliBriDevHelper.querySelector=koliBriQuerySelector,KoliBriDevHelper.querySelectorAll=koliBriQuerySelectorAll,KoliBriDevHelper.scrollByHTMLElement=scrollByHTMLElement,KoliBriDevHelper.scrollBySelector=scrollBySelector,KoliBriDevHelper.stringifyJson=stringifyJson,exports.KoliBriDevHelper=KoliBriDevHelper,exports.KoliBriUtils=KoliBriUtils,exports.emptyStringByArrayHandler=emptyStringByArrayHandler,exports.koliBriA11yColorContrast=koliBriA11yColorContrast,exports.koliBriQuerySelector=koliBriQuerySelector,exports.koliBriQuerySelectorAll=koliBriQuerySelectorAll,exports.koliBriQuerySelectorColors=koliBriQuerySelectorColors,exports.mapBoolean2String=mapBoolean2String,exports.mapString2Unknown=mapString2Unknown,exports.mapStringOrBoolean2String=mapStringOrBoolean2String,exports.objectObjectHandler=objectObjectHandler,exports.parseJson=parseJson,exports.rgbaConvert=rgbaConvert,exports.scrollBySelector=scrollBySelector,exports.setEventTargetAndStopPropagation=setEventTargetAndStopPropagation,exports.setState=setState,exports.stringifyJson=stringifyJson,exports.watchBoolean=watchBoolean,exports.watchJsonArrayString=watchJsonArrayString,exports.watchNumber=watchNumber,exports.watchString=watchString,exports.watchValidator=watchValidator;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* KoliBri - The accessible HTML-Standard
|
|
3
3
|
*/
|
|
4
|
-
"use strict";const a11y_tipps=require("./a11y.tipps-e1770acf.js"),prop_validators=require("./prop.validators-
|
|
4
|
+
"use strict";const a11y_tipps=require("./a11y.tipps-e1770acf.js"),prop_validators=require("./prop.validators-d9b1328b.js"),validator=require("./validator-6f53d4a2.js"),mapCustomIcon=(t,o,i)=>{validator.isObject(i)?t[o]=i:validator.isString(i,1)&&(t[o]={icon:i})},mapIconProp2State=(t,o)=>{let i={};if(validator.isString(t,1))if("right"===o)i={right:{icon:t}};else i={left:{icon:t}};else"object"==typeof t&&null!==t&&(mapCustomIcon(i,"top",t.top),mapCustomIcon(i,"right",t.right),mapCustomIcon(i,"bottom",t.bottom),mapCustomIcon(i,"left",t.left));return i},beforePatchIcon=t=>{var o,i,e,a,n,r,l;if(null===(o=t.nextState)||void 0===o?void 0:o.has("_icon")){const o=null===(i=t.nextState)||void 0===i?void 0:i.get("_icon"),n=(null===(e=t.nextState)||void 0===e?void 0:e.get("_iconAlign"))||t.state._iconAlign;null===(a=t.nextState)||void 0===a||a.set("_icon",mapIconProp2State(o,n))}else if(null===(n=t.nextState)||void 0===n?void 0:n.has("_iconAlign")){const o=t.state._iconAlign;null===(r=t.nextState)||void 0===r||r.set("_icon",{[o]:void 0,[null===(l=t.nextState)||void 0===l?void 0:l.get("_iconAlign")]:t.state._icon[o]})}},isIcon=t=>"object"==typeof t&&null!==t&&(void 0===t.style||validator.isStyle(t.style))&&validator.isString(t.icon,1),validateIcon=(t,o)=>{prop_validators.objectObjectHandler(o,(()=>{try{o=prop_validators.parseJson(o)}catch(t){}prop_validators.watchValidator(t,"_icon",(t=>null===t||validator.isString(t,1)||"object"==typeof t&&null!==t&&(validator.isString(t.left,1)||isIcon(t.left)||validator.isString(t.right,1)||isIcon(t.right)||validator.isString(t.top,1)||isIcon(t.top)||validator.isString(t.bottom,1)||isIcon(t.bottom))),new Set(["KoliBriIcon"]),o,{hooks:{beforePatch:(o,i)=>{null===o&&i.set("_icon",{}),beforePatchIcon(t)}},required:!0})}))},watchIconAlign=(t,o)=>{a11y_tipps.deprecatedHint("Das Property _icon-align bzw. _iconAlign ist veraltet. Die Ausrichtung der Icon's kann jetzt direkt über das _icon-Property vorgenommen werden. (v1.1.10: https://public-ui.github.io/?path=/story/backlog-und-changelog--page)"),prop_validators.watchValidator(t,"_iconAlign",(t=>"left"===t||"right"===t),new Set(["Alignment {left, right, top, bottom}"]),o,{hooks:{beforePatch:()=>{beforePatchIcon(t)}}})},options={hooks:{afterPatch:t=>{-1!==t&&0!==t&&a11y_tipps.a11yHint("Don’t Use Tabindex Greater than 0: https://adrianroselli.com/2014/11/dont-use-tabindex-greater-than-0.html")}}},validateTabIndex=(t,o)=>{prop_validators.watchNumber(t,"_tabIndex",o,options)};exports.isIcon=isIcon,exports.validateIcon=validateIcon,exports.validateTabIndex=validateTabIndex,exports.watchIconAlign=watchIconAlign;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* KoliBri - The accessible HTML-Standard
|
|
3
3
|
*/
|
|
4
|
-
"use strict";const a11y_tipps=require("./a11y.tipps-e1770acf.js"),prop_validators=require("./prop.validators-
|
|
4
|
+
"use strict";const a11y_tipps=require("./a11y.tipps-e1770acf.js"),prop_validators=require("./prop.validators-d9b1328b.js"),watchNavLinks=(t,a,s)=>{prop_validators.watchJsonArrayString(a,"_links",(t=>"object"==typeof t&&"string"==typeof t._label),s),a11y_tipps.uiUxHintMillerscheZahl(t,a.state._links.length)};exports.watchNavLinks=watchNavLinks;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* KoliBri - The accessible HTML-Standard
|
|
3
3
|
*/
|
|
4
|
-
"use strict";const prop_validators=require("./prop.validators-
|
|
4
|
+
"use strict";const prop_validators=require("./prop.validators-d9b1328b.js"),watchHeadingLevel=(e,a)=>{prop_validators.watchValidator(e,"_level",(e=>"number"==typeof e&&1<=e&&e<=6),new Set(["Number {1, 2, 3, 4, 5, 6}"]),a,{defaultValue:1,required:!0})};exports.watchHeadingLevel=watchHeadingLevel;
|
|
@@ -68,6 +68,15 @@ export { KolVersion as KolVersion } from '../types/components/version/component'
|
|
|
68
68
|
*/
|
|
69
69
|
export declare const setAssetPath: (path: string) => void;
|
|
70
70
|
|
|
71
|
+
/**
|
|
72
|
+
* Used to specify a nonce value that corresponds with an application's CSP.
|
|
73
|
+
* When set, the nonce will be added to all dynamically created script and style tags at runtime.
|
|
74
|
+
* Alternatively, the nonce value can be set on a meta tag in the DOM head
|
|
75
|
+
* (<meta name="csp-nonce" content="{ nonce value here }" />) which
|
|
76
|
+
* will result in the same behavior.
|
|
77
|
+
*/
|
|
78
|
+
export declare const setNonce: (nonce: string) => void
|
|
79
|
+
|
|
71
80
|
export interface SetPlatformOptions {
|
|
72
81
|
raf?: (c: FrameRequestCallback) => number;
|
|
73
82
|
ael?: (el: EventTarget, eventName: string, listener: EventListenerOrEventListenerObject, options: boolean | AddEventListenerOptions) => void;
|
package/dist/components/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* KoliBri - The accessible HTML-Standard
|
|
3
3
|
*/
|
|
4
|
-
import{setMode}from"@stencil/core/internal/client";export{setAssetPath,setPlatformOptions}from"@stencil/core/internal/client";export{c as BUNDESAEMTER,e as BUNDESANSTALTEN,a as BUNDESMINISTERIEN,f as BUND_LOGO_TEXT_MAP,b as Bundesamt,d as Bundesanstalt,B as Bundesministerium,KolLogo,defineCustomElement as defineCustomElementKolLogo}from"./kol-logo.js";import{L as Log,s as setThemeStyle,g as getThemeDetails}from"./prop.validators.js";export{K as KoliBriDevHelper,T as ToasterService,c as configKoliBri}from"./prop.validators.js";export{t as translations}from"./i18n.js";export{KolAbbr,defineCustomElement as defineCustomElementKolAbbr}from"./kol-abbr.js";export{KolAccordion,defineCustomElement as defineCustomElementKolAccordion}from"./kol-accordion.js";export{KolAlert,defineCustomElement as defineCustomElementKolAlert}from"./kol-alert.js";export{KolBadge,defineCustomElement as defineCustomElementKolBadge}from"./kol-badge.js";export{KolBreadcrumb,defineCustomElement as defineCustomElementKolBreadcrumb}from"./kol-breadcrumb.js";export{KolButton,defineCustomElement as defineCustomElementKolButton}from"./kol-button.js";export{KolButtonGroup,defineCustomElement as defineCustomElementKolButtonGroup}from"./kol-button-group.js";export{KolButtonGroupWc,defineCustomElement as defineCustomElementKolButtonGroupWc}from"./kol-button-group-wc.js";export{KolButtonLink,defineCustomElement as defineCustomElementKolButtonLink}from"./kol-button-link.js";export{KolButtonWc,defineCustomElement as defineCustomElementKolButtonWc}from"./kol-button-wc.js";export{KolCard,defineCustomElement as defineCustomElementKolCard}from"./kol-card.js";export{KolColor,defineCustomElement as defineCustomElementKolColor}from"./kol-color.js";export{KolCounter,defineCustomElement as defineCustomElementKolCounter}from"./kol-counter.js";export{KolDetails,defineCustomElement as defineCustomElementKolDetails}from"./kol-details.js";export{KolForm,defineCustomElement as defineCustomElementKolForm}from"./kol-form.js";export{KolHeading,defineCustomElement as defineCustomElementKolHeading}from"./kol-heading.js";export{KolHeadingWc,defineCustomElement as defineCustomElementKolHeadingWc}from"./kol-heading-wc.js";export{KolIcon,defineCustomElement as defineCustomElementKolIcon}from"./kol-icon.js";export{KolIconFontAwesome,defineCustomElement as defineCustomElementKolIconFontAwesome}from"./kol-icon-font-awesome.js";export{KolIconIcofont,defineCustomElement as defineCustomElementKolIconIcofont}from"./kol-icon-icofont.js";export{KolIndentedText,defineCustomElement as defineCustomElementKolIndentedText}from"./kol-indented-text.js";export{KolInput,defineCustomElement as defineCustomElementKolInput}from"./kol-input.js";export{KolInputAdapterLeanup,defineCustomElement as defineCustomElementKolInputAdapterLeanup}from"./kol-input-adapter-leanup.js";export{KolInputCheckbox,defineCustomElement as defineCustomElementKolInputCheckbox}from"./kol-input-checkbox.js";export{KolInputColor,defineCustomElement as defineCustomElementKolInputColor}from"./kol-input-color.js";export{KolInputDate,defineCustomElement as defineCustomElementKolInputDate}from"./kol-input-date.js";export{KolInputEmail,defineCustomElement as defineCustomElementKolInputEmail}from"./kol-input-email.js";export{KolInputFile,defineCustomElement as defineCustomElementKolInputFile}from"./kol-input-file.js";export{KolInputNumber,defineCustomElement as defineCustomElementKolInputNumber}from"./kol-input-number.js";export{KolInputPassword,defineCustomElement as defineCustomElementKolInputPassword}from"./kol-input-password.js";export{KolInputRadio,defineCustomElement as defineCustomElementKolInputRadio}from"./kol-input-radio.js";export{KolInputRadioGroup,defineCustomElement as defineCustomElementKolInputRadioGroup}from"./kol-input-radio-group.js";export{KolInputRange,defineCustomElement as defineCustomElementKolInputRange}from"./kol-input-range.js";export{KolInputText,defineCustomElement as defineCustomElementKolInputText}from"./kol-input-text.js";export{KolKolibri,defineCustomElement as defineCustomElementKolKolibri}from"./kol-kolibri.js";export{KolLink,defineCustomElement as defineCustomElementKolLink}from"./kol-link.js";export{KolLinkButton,defineCustomElement as defineCustomElementKolLinkButton}from"./kol-link-button.js";export{KolLinkGroup,defineCustomElement as defineCustomElementKolLinkGroup}from"./kol-link-group.js";export{KolLinkWc,defineCustomElement as defineCustomElementKolLinkWc}from"./kol-link-wc.js";export{KolModal,defineCustomElement as defineCustomElementKolModal}from"./kol-modal.js";export{KolNav,defineCustomElement as defineCustomElementKolNav}from"./kol-nav.js";export{KolPagination,defineCustomElement as defineCustomElementKolPagination}from"./kol-pagination.js";export{KolProgress,defineCustomElement as defineCustomElementKolProgress}from"./kol-progress.js";export{KolSelect,defineCustomElement as defineCustomElementKolSelect}from"./kol-select.js";export{KolSkipNav,defineCustomElement as defineCustomElementKolSkipNav}from"./kol-skip-nav.js";export{KolSpan,defineCustomElement as defineCustomElementKolSpan}from"./kol-span.js";export{KolSpanWc,defineCustomElement as defineCustomElementKolSpanWc}from"./kol-span-wc.js";export{KolSpin,defineCustomElement as defineCustomElementKolSpin}from"./kol-spin.js";export{KolSymbol,defineCustomElement as defineCustomElementKolSymbol}from"./kol-symbol.js";export{KolTable,defineCustomElement as defineCustomElementKolTable}from"./kol-table.js";export{KolTabs,defineCustomElement as defineCustomElementKolTabs}from"./kol-tabs.js";export{KolTextarea,defineCustomElement as defineCustomElementKolTextarea}from"./kol-textarea.js";export{KolToast,defineCustomElement as defineCustomElementKolToast}from"./kol-toast.js";export{KolTooltip,defineCustomElement as defineCustomElementKolTooltip}from"./kol-tooltip.js";export{KolVersion,defineCustomElement as defineCustomElementKolVersion}from"./kol-version.js";const appGlobalScript=()=>{Log.info("\n,--. ,--. ,--. ,--. ,-----. ,--.\n| .' / ,---. | | `--' | |) /_ ,--.--. `--'\n| . ' | .-. | | | ,--. | .-. \\ | .--' ,--.\n| |\\ \\ | '-' | | | | | | '--' / | | | |\n`--' `--´ `---´ `--' `--' `------´ `--' `--'\n🚹 The accessible HTML-Standard | 👉 https://public-ui.github.io\n\t",{forceLog:!0}),setMode((e=>(e.shadowRoot instanceof ShadowRoot&&setThemeStyle(e,getThemeDetails(e)),"default"))),import("./devtools.js").then((e=>{"object"==typeof e&&null!==e&&"function"==typeof e.initialize&&e.initialize()})).catch((e=>{Log.error(e)}))},globalScripts=appGlobalScript;globalScripts();
|
|
4
|
+
import{setMode}from"@stencil/core/internal/client";export{setAssetPath,setNonce,setPlatformOptions}from"@stencil/core/internal/client";export{c as BUNDESAEMTER,e as BUNDESANSTALTEN,a as BUNDESMINISTERIEN,f as BUND_LOGO_TEXT_MAP,b as Bundesamt,d as Bundesanstalt,B as Bundesministerium,KolLogo,defineCustomElement as defineCustomElementKolLogo}from"./kol-logo.js";import{L as Log,s as setThemeStyle,g as getThemeDetails}from"./prop.validators.js";export{K as KoliBriDevHelper,T as ToasterService,c as configKoliBri}from"./prop.validators.js";export{t as translations}from"./i18n.js";export{KolAbbr,defineCustomElement as defineCustomElementKolAbbr}from"./kol-abbr.js";export{KolAccordion,defineCustomElement as defineCustomElementKolAccordion}from"./kol-accordion.js";export{KolAlert,defineCustomElement as defineCustomElementKolAlert}from"./kol-alert.js";export{KolBadge,defineCustomElement as defineCustomElementKolBadge}from"./kol-badge.js";export{KolBreadcrumb,defineCustomElement as defineCustomElementKolBreadcrumb}from"./kol-breadcrumb.js";export{KolButton,defineCustomElement as defineCustomElementKolButton}from"./kol-button.js";export{KolButtonGroup,defineCustomElement as defineCustomElementKolButtonGroup}from"./kol-button-group.js";export{KolButtonGroupWc,defineCustomElement as defineCustomElementKolButtonGroupWc}from"./kol-button-group-wc.js";export{KolButtonLink,defineCustomElement as defineCustomElementKolButtonLink}from"./kol-button-link.js";export{KolButtonWc,defineCustomElement as defineCustomElementKolButtonWc}from"./kol-button-wc.js";export{KolCard,defineCustomElement as defineCustomElementKolCard}from"./kol-card.js";export{KolColor,defineCustomElement as defineCustomElementKolColor}from"./kol-color.js";export{KolCounter,defineCustomElement as defineCustomElementKolCounter}from"./kol-counter.js";export{KolDetails,defineCustomElement as defineCustomElementKolDetails}from"./kol-details.js";export{KolForm,defineCustomElement as defineCustomElementKolForm}from"./kol-form.js";export{KolHeading,defineCustomElement as defineCustomElementKolHeading}from"./kol-heading.js";export{KolHeadingWc,defineCustomElement as defineCustomElementKolHeadingWc}from"./kol-heading-wc.js";export{KolIcon,defineCustomElement as defineCustomElementKolIcon}from"./kol-icon.js";export{KolIconFontAwesome,defineCustomElement as defineCustomElementKolIconFontAwesome}from"./kol-icon-font-awesome.js";export{KolIconIcofont,defineCustomElement as defineCustomElementKolIconIcofont}from"./kol-icon-icofont.js";export{KolIndentedText,defineCustomElement as defineCustomElementKolIndentedText}from"./kol-indented-text.js";export{KolInput,defineCustomElement as defineCustomElementKolInput}from"./kol-input.js";export{KolInputAdapterLeanup,defineCustomElement as defineCustomElementKolInputAdapterLeanup}from"./kol-input-adapter-leanup.js";export{KolInputCheckbox,defineCustomElement as defineCustomElementKolInputCheckbox}from"./kol-input-checkbox.js";export{KolInputColor,defineCustomElement as defineCustomElementKolInputColor}from"./kol-input-color.js";export{KolInputDate,defineCustomElement as defineCustomElementKolInputDate}from"./kol-input-date.js";export{KolInputEmail,defineCustomElement as defineCustomElementKolInputEmail}from"./kol-input-email.js";export{KolInputFile,defineCustomElement as defineCustomElementKolInputFile}from"./kol-input-file.js";export{KolInputNumber,defineCustomElement as defineCustomElementKolInputNumber}from"./kol-input-number.js";export{KolInputPassword,defineCustomElement as defineCustomElementKolInputPassword}from"./kol-input-password.js";export{KolInputRadio,defineCustomElement as defineCustomElementKolInputRadio}from"./kol-input-radio.js";export{KolInputRadioGroup,defineCustomElement as defineCustomElementKolInputRadioGroup}from"./kol-input-radio-group.js";export{KolInputRange,defineCustomElement as defineCustomElementKolInputRange}from"./kol-input-range.js";export{KolInputText,defineCustomElement as defineCustomElementKolInputText}from"./kol-input-text.js";export{KolKolibri,defineCustomElement as defineCustomElementKolKolibri}from"./kol-kolibri.js";export{KolLink,defineCustomElement as defineCustomElementKolLink}from"./kol-link.js";export{KolLinkButton,defineCustomElement as defineCustomElementKolLinkButton}from"./kol-link-button.js";export{KolLinkGroup,defineCustomElement as defineCustomElementKolLinkGroup}from"./kol-link-group.js";export{KolLinkWc,defineCustomElement as defineCustomElementKolLinkWc}from"./kol-link-wc.js";export{KolModal,defineCustomElement as defineCustomElementKolModal}from"./kol-modal.js";export{KolNav,defineCustomElement as defineCustomElementKolNav}from"./kol-nav.js";export{KolPagination,defineCustomElement as defineCustomElementKolPagination}from"./kol-pagination.js";export{KolProgress,defineCustomElement as defineCustomElementKolProgress}from"./kol-progress.js";export{KolSelect,defineCustomElement as defineCustomElementKolSelect}from"./kol-select.js";export{KolSkipNav,defineCustomElement as defineCustomElementKolSkipNav}from"./kol-skip-nav.js";export{KolSpan,defineCustomElement as defineCustomElementKolSpan}from"./kol-span.js";export{KolSpanWc,defineCustomElement as defineCustomElementKolSpanWc}from"./kol-span-wc.js";export{KolSpin,defineCustomElement as defineCustomElementKolSpin}from"./kol-spin.js";export{KolSymbol,defineCustomElement as defineCustomElementKolSymbol}from"./kol-symbol.js";export{KolTable,defineCustomElement as defineCustomElementKolTable}from"./kol-table.js";export{KolTabs,defineCustomElement as defineCustomElementKolTabs}from"./kol-tabs.js";export{KolTextarea,defineCustomElement as defineCustomElementKolTextarea}from"./kol-textarea.js";export{KolToast,defineCustomElement as defineCustomElementKolToast}from"./kol-toast.js";export{KolTooltip,defineCustomElement as defineCustomElementKolTooltip}from"./kol-tooltip.js";export{KolVersion,defineCustomElement as defineCustomElementKolVersion}from"./kol-version.js";const appGlobalScript=()=>{Log.info("\n,--. ,--. ,--. ,--. ,-----. ,--.\n| .' / ,---. | | `--' | |) /_ ,--.--. `--'\n| . ' | .-. | | | ,--. | .-. \\ | .--' ,--.\n| |\\ \\ | '-' | | | | | | '--' / | | | |\n`--' `--´ `---´ `--' `--' `------´ `--' `--'\n🚹 The accessible HTML-Standard | 👉 https://public-ui.github.io\n\t",{forceLog:!0}),setMode((e=>(e.shadowRoot instanceof ShadowRoot&&setThemeStyle(e,getThemeDetails(e)),"default"))),import("./devtools.js").then((e=>{"object"==typeof e&&null!==e&&"function"==typeof e.initialize&&e.initialize()})).catch((e=>{Log.error(e)}))},globalScripts=appGlobalScript;globalScripts();
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* KoliBri - The accessible HTML-Standard
|
|
3
3
|
*/
|
|
4
|
-
import{proxyCustomElement,HTMLElement,h,Host}from"@stencil/core/internal/client";import{d as devHint,i as watchValidator,w as watchString,e as a11yHintLabelingLandmarks,b as watchBoolean}from"./prop.validators.js";import{w as watchNavLinks}from"./validation.js";import{a as translate}from"./i18n.js";import{d as defineCustomElement$2,a as defineCustomElement$6,b as defineCustomElement$8}from"./component2.js";import{d as defineCustomElement$7}from"./shadow.js";import{d as defineCustomElement$5}from"./component5.js";import{d as defineCustomElement$4}from"./component10.js";import{d as defineCustomElement$3}from"./component13.js";const defaultStyleCss='*,::before,::after{-webkit-box-sizing:border-box;box-sizing:border-box;border-width:0;border-style:solid;border-color:var(--kolibri-border-color)}*{--tw-ring-inset:var(--tw-empty, );--tw-ring-offset-width:0px;--tw-ring-offset-color:var(--kolibri-color);--tw-ring-color:rgba(undefined, 0.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000}:root{-moz-tab-size:4;-o-tab-size:4;tab-size:4}:-moz-focusring{outline:1px dotted ButtonText}:-moz-ui-invalid{box-shadow:none}::moz-focus-inner{border-style:none;padding:0}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}[type=\'search\']{-webkit-appearance:textfield;outline-offset:-2px}abbr[title]{-webkit-text-decoration:underline dotted;text-decoration:underline dotted}a{color:inherit;text-decoration:inherit}body{margin:0;font-family:inherit;line-height:inherit}b,strong{font-weight:bolder}button,select{text-transform:none}button,[type=\'button\'],[type=\'reset\'],[type=\'submit\']{-webkit-appearance:button}button{background-color:transparent;background-image:none}button,[role="button"]{cursor:pointer}code{font-size:1em;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace}fieldset{margin:0;padding:0}html{-webkit-text-size-adjust:100%;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";line-height:1.5}h1,p,h2,h3,h4,h5,h6{margin:0}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}input,button,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;padding:0;line-height:inherit;color:inherit}input::placeholder{opacity:1;color:#9ca3af}input::webkit-input-placeholder{opacity:1;color:#9ca3af}input::-moz-placeholder{opacity:1;color:#9ca3af}input:-ms-input-placeholder{opacity:1;color:#9ca3af}input::-ms-input-placeholder{opacity:1;color:#9ca3af}legend{padding:0}progress{vertical-align:baseline}small{font-size:80%}svg{display:block;vertical-align:middle}table{text-indent:0;border-color:inherit;border-collapse:collapse}textarea{resize:vertical}textarea::placeholder{opacity:1;color:#9ca3af}textarea::webkit-input-placeholder{opacity:1;color:#9ca3af}textarea::-moz-placeholder{opacity:1;color:#9ca3af}textarea:-ms-input-placeholder{opacity:1;color:#9ca3af}textarea::-ms-input-placeholder{opacity:1;color:#9ca3af}ul,ol{list-style:none;margin:0;padding:0}.container{width:100%}@media (min-width: 640px){.container{max-width:640px}}@media (min-width: 768px){.container{max-width:768px}}@media (min-width: 1024px){.container{max-width:1024px}}@media (min-width: 1280px){.container{max-width:1280px}}@media (min-width: 1536px){.container{max-width:1536px}}.bg-normal{background-color:var(--kolibri-color-normal)}.bg-white{--tw-bg-opacity:1;background-color:rgba(255, 255, 255, var(--tw-bg-opacity))}.bg-spin-1{background-color:var(--kolibri-color-spin-1)}.bg-spin-2{background-color:var(--kolibri-color-spin-2)}.bg-spin-3{background-color:var(--kolibri-color-spin-3)}.rounded{border-radius:var(--kolibri-border-radius)}.border-1{border-width:1px}.cursor-pointer{cursor:pointer}.block{display:block}.inline-block{display:inline-block}.flex{display:-webkit-box;display:-ms-flexbox;display:-webkit-flex;display:flex}.inline-flex{display:-webkit-inline-box;display:-ms-inline-flexbox;display:-webkit-inline-flex;display:inline-flex}.table{display:table}.grid{display:-ms-grid;display:grid}.hidden{display:none}.flex-wrap{-ms-flex-wrap:wrap;-webkit-flex-wrap:wrap;flex-wrap:wrap}.items-center{-webkit-box-align:center;-ms-flex-align:center;-webkit-align-items:center;align-items:center}.content-center{-ms-flex-line-pack:center;-webkit-align-content:center;align-content:center}.font-80{font-weight:80}.font-60{font-weight:60}.h-full{height:100%}.h-0{height:0px}.h-0\\.41c-2\\.42\\2c 0-4\\.82-1\\.57-4\\.82-3\\.58c0\\.05-0\\.98\\2c 0\\.43-1\\.91\\2c 1\\.07-2\\.65c0\\.3\\2c 0\\.05\\2c 0\\.61\\2c 0\\.09\\2c 0\\.92\\2c 0\\.09c1\\.1\\2c 0\\2c 1\\.69-0\\.58\\2c 1\\.74-1\\.16{height:0.29rem}.text-sm{font-size:0.875rem;line-height:1.25rem}.text-2xl{font-size:1.5rem;line-height:2rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.leading-normal{line-height:1.5}.list-none{list-style-type:none}.list-disc{list-style-type:disc}.list-decimal{list-style-type:decimal}.mx-auto{margin-left:auto;margin-right:auto}.mb-1{margin-bottom:calc(1 * var(--kolibri-spacing))}.mt-2{margin-top:calc(2 * var(--kolibri-spacing))}.mt-4{margin-top:calc(4 * var(--kolibri-spacing))}.outline{outline-style:solid}.overflow-hidden{overflow:hidden}.overflow-y-visible{overflow-y:visible}.p-2{padding:calc(2 * var(--kolibri-spacing))}.p-4{padding:calc(4 * var(--kolibri-spacing))}.px{padding-left:1px;padding-right:1px}.py-2{padding-top:calc(2 * var(--kolibri-spacing));padding-bottom:calc(2 * var(--kolibri-spacing))}.pl-8{padding-left:2rem}.pb-2{padding-bottom:calc(2 * var(--kolibri-spacing))}.tab{-moz-tab-size:4;-o-tab-size:4;tab-size:4}.absolute{position:absolute}.text-center{text-align:center}.hover\\:text-primary:hover{color:var(--kolibri-color-primary)}.text-normal{color:var(--kolibri-color-normal)}.italic{font-style:italic}.underline{-webkit-text-decoration-line:underline;text-decoration-line:underline}.indent{text-indent:1.5rem}.visible{visibility:visible}.w-full{width:100%}.w-4\\/5{width:80%}.z-50{z-index:50}.gap-1{grid-gap:calc(1 * var(--kolibri-spacing));gap:calc(1 * var(--kolibri-spacing))}.gap-2{grid-gap:calc(2 * var(--kolibri-spacing));gap:calc(2 * var(--kolibri-spacing))}.grid-flow-col{grid-auto-flow:column}.transform{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-rotate:0;--tw-rotate-x:0;--tw-rotate-y:0;--tw-rotate-z:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;-webkit-transform:translateX(var(--tw-translate-x)) translateY(var(--tw-translate-y)) translateZ(var(--tw-translate-z)) rotate(var(--tw-rotate)) rotateX(var(--tw-rotate-x)) rotateY(var(--tw-rotate-y)) rotateZ(var(--tw-rotate-z)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)) scaleZ(var(--tw-scale-z));-ms-transform:translateX(var(--tw-translate-x)) translateY(var(--tw-translate-y)) translateZ(var(--tw-translate-z)) rotate(var(--tw-rotate)) rotateX(var(--tw-rotate-x)) rotateY(var(--tw-rotate-y)) rotateZ(var(--tw-rotate-z)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)) scaleZ(var(--tw-scale-z));transform:translateX(var(--tw-translate-x)) translateY(var(--tw-translate-y)) translateZ(var(--tw-translate-z)) rotate(var(--tw-rotate)) rotateX(var(--tw-rotate-x)) rotateY(var(--tw-rotate-y)) rotateZ(var(--tw-rotate-z)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)) scaleZ(var(--tw-scale-z))}.animate{-webkit-animation-iteration-count:1;animation-iteration-count:1}.filter{--tw-blur:var(--tw-empty, );--tw-brightness:var(--tw-empty, );--tw-contrast:var(--tw-empty, );--tw-grayscale:var(--tw-empty, );--tw-hue-rotate:var(--tw-empty, );--tw-invert:var(--tw-empty, );--tw-saturate:var(--tw-empty, );--tw-sepia:var(--tw-empty, );--tw-drop-shadow:var(--tw-empty, );-webkit-filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.blur{-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px)}:host *{font-size:inherit;hyphens:auto;letter-spacing:inherit;word-break:break-word;word-spacing:inherit}',UNIQUE_ARIA_LABEL=[],removeAriaLabel=t=>{const a=UNIQUE_ARIA_LABEL.indexOf(t);a>=0&&UNIQUE_ARIA_LABEL.splice(a,1)},KolNav$1=proxyCustomElement(class extends HTMLElement{constructor(){super(),this.__registerHost(),this.__attachShadow(),this.onClick=t=>{t._active=!1===t._active,this.state=Object.assign({},this.state)},this.hasActiveChild=t=>!!(Array.isArray(t._children)&&t._children.length>0)&&t._children.some(this.hasActiveChild),this.linkList=t=>h("ul",{class:{flex:0===t.deep&&"horizontal"===this.state._orientation},part:`nav ${this.state._orientation}`},t.links.map(((a,e)=>h("li",{key:e,part:`li ${0===t.deep?this.state._orientation:"vertical"}${a._active?" selected":""}${e<t.links.length-1?"":" last"}`},Array.isArray(a._children)&&a._children.length>0?h("div",{class:"h-full"},h("div",{class:{"h-full":!0}},h("kol-link-wc",{class:"block w-full h-full",exportparts:"icon,link,span"+(!0===a._active?",selected":""),_useCase:"nav",_ariaCurrent:!0===a._active&&this.state._ariaCurrentValue,_ariaLabel:!0===this.state._compact||!0===a._iconOnly?a._label:void 0,_ariaExpanded:!0===a._active,_disabled:a._disabled,_href:"javascript:void(0)",_icon:!0===this.state._collapsible?!0===a._active?"fa-solid fa-minus":"fa-solid fa-plus":"string"==typeof a._icon?a._icon:"fa-solid fa-link-slash",_iconOnly:!0===this.state._compact||!0===a._iconOnly,_label:a._label,_part:!0===a._active?"selected":void 0,_underline:!1,onClick:()=>this.onClick(a)})),!0===a._active&&h("div",{class:{expanded:!0,active:!0===a._active,"active-child":this.hasActiveChild(a),"absolute ":0===t.deep&&"horizontal"===this.state._orientation}},h(this.linkList,{links:a._children,deep:t.deep+1}))):h("div",{class:{"h-full":!0,"text-center":!0===this.state._compact||!0===a._iconOnly}},h("kol-link-wc",{class:{"block w-full h-full":!0,active:!0===a._active},exportparts:"icon,link,span"+(!0===a._active?",selected":""),_ariaLabel:!0===this.state._compact||!0===a._iconOnly?a._label:"undefined",_href:a._href,_icon:"string"==typeof a._icon?a._icon:"fa-solid fa-link-slash","_icon-only":!0===this.state._compact||!0===a._iconOnly,_label:a._label,_on:a._on,_part:!0===a._active?"selected":void 0,_selector:a._selector,_tooltipAlign:a._tooltipAlign,_target:a._target,_underline:!1,_useCase:"nav"})))))),this._ariaCurrentValue=!1,this._ariaLabel=void 0,this._collapsible=!1,this._compact=!1,this._hasCompactButton=!1,this._orientation="vertical",this._links=void 0,this._variant="primary",this.state={_ariaCurrentValue:!1,_ariaLabel:"…",_collapsible:!0,_hasCompactButton:!1,_links:[],_orientation:"vertical",_variant:"primary"}}render(){let t=this.state._hasCompactButton;return"horizontal"===this.state._orientation&&!0===this.state._hasCompactButton&&(t=!1,devHint("[KolNav] Wenn eine horizontale Navigation verwendet wird, kann die Option _hasCompactButton nicht aktiviert werden.")),h(Host,null,h("div",{class:{[this.state._orientation]:!0,"inline-block":!0===this.state._compact,[this.state._variant]:!0}},h("nav",{"aria-label":this.state._ariaLabel,id:"nav",part:"nav"},h(this.linkList,{links:this.state._links,deep:0})),t&&h("div",{class:"mt-2 w-full text-center"},h("kol-button",{exportparts:"button,ghost",_ariaControls:"nav",_ariaExpanded:!0===this.state._compact,_ariaLabel:translate(this.state._compact?"kol-nav-maximize":"kol-nav-minimize"),_icon:this.state._compact?"fa-solid fa-angles-right":"fa-solid fa-angles-left",_iconOnly:!0,_label:translate(this.state._compact?"kol-nav-maximize":"kol-nav-minimize"),_on:{onClick:()=>{this.state=Object.assign(Object.assign({},this.state),{_compact:!1===this.state._compact})}},_tooltipAlign:"right",_variant:"ghost"}))))}validateAriaCurrentValue(t){watchValidator(this,"_ariaCurrentValue",(t=>!0===t||"date"===t||"location"===t||"page"===t||"step"===t||"time"===t),new Set(["boolean","String {data, location, page, step, time}"]),t)}validateAriaLabel(t){watchString(this,"_ariaLabel",t,{hooks:{afterPatch:()=>{UNIQUE_ARIA_LABEL.includes(this.state._ariaLabel)&&devHint(`[KolNav] Das Aria-Label "${this.state._ariaLabel}" wurde für die Rolle Navigation mehrfach verwendet!`),UNIQUE_ARIA_LABEL.push(this.state._ariaLabel)},beforePatch:()=>{removeAriaLabel(this.state._ariaLabel)}},required:!0}),a11yHintLabelingLandmarks(t)}validateCollapsible(t){watchBoolean(this,"_collapsible",t)}validateCompact(t){watchBoolean(this,"_compact",t)}validateHasCompactButton(t){watchBoolean(this,"_hasCompactButton",t)}validateLinks(t){watchNavLinks("KolNav",this,t),devHint("[KolNav] Die Navigationsstruktur wird noch nicht rekursiv validiert.")}validateOrientation(t){watchValidator(this,"_orientation",(t=>"horizontal"===t||"vertical"===t),new Set(["Orientation {horizontal, vertical}"]),t,{defaultValue:"vertical"})}validateVariant(t){watchValidator(this,"_variant",(t=>"primary"===t||"secondary"===t),new Set(["KoliBriNavVariant {primary, secondary}"]),t,{defaultValue:"primary"})}componentWillLoad(){this.validateAriaLabel(this._ariaLabel),this.validateCollapsible(this._collapsible),this.validateCompact(this._compact),this.validateHasCompactButton(this._hasCompactButton),this.validateLinks(this._links),this.validateOrientation(this._orientation),this.validateVariant(this._variant)}disconnectedCallback(){removeAriaLabel(this.state._ariaLabel)}static get watchers(){return{_ariaCurrentValue:["validateAriaCurrentValue"],_ariaLabel:["validateAriaLabel"],_collapsible:["validateCollapsible"],_compact:["validateCompact"],_hasCompactButton:["validateHasCompactButton"],_links:["validateLinks"],_orientation:["validateOrientation"],_variant:["validateVariant"]}}static get style(){return{default:defaultStyleCss}}},[33,"kol-nav",{_ariaCurrentValue:[8,"_aria-current-value"],_ariaLabel:[1,"_aria-label"],_collapsible:[516],_compact:[516],_hasCompactButton:[516,"_has-compact-button"],_orientation:[1],_links:[1],_variant:[1],state:[32]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-nav","kol-badge","kol-button","kol-button-wc","kol-icon","kol-link-wc","kol-span-wc","kol-tooltip"].forEach((t=>{switch(t){case"kol-nav":customElements.get(t)||customElements.define(t,KolNav$1);break;case"kol-badge":customElements.get(t)||defineCustomElement$8();break;case"kol-button":customElements.get(t)||defineCustomElement$7();break;case"kol-button-wc":customElements.get(t)||defineCustomElement$6();break;case"kol-icon":customElements.get(t)||defineCustomElement$5();break;case"kol-link-wc":customElements.get(t)||defineCustomElement$4();break;case"kol-span-wc":customElements.get(t)||defineCustomElement$3();break;case"kol-tooltip":customElements.get(t)||defineCustomElement$2()}}))}const KolNav=KolNav$1,defineCustomElement=defineCustomElement$1;export{KolNav,defineCustomElement};
|
|
4
|
+
import{proxyCustomElement,HTMLElement,h,Host}from"@stencil/core/internal/client";import{d as devHint,i as watchValidator,w as watchString,e as a11yHintLabelingLandmarks,b as watchBoolean}from"./prop.validators.js";import{w as watchNavLinks}from"./validation.js";import{a as translate}from"./i18n.js";import{d as defineCustomElement$2,a as defineCustomElement$6,b as defineCustomElement$8}from"./component2.js";import{d as defineCustomElement$7}from"./shadow.js";import{d as defineCustomElement$5}from"./component5.js";import{d as defineCustomElement$4}from"./component10.js";import{d as defineCustomElement$3}from"./component13.js";const defaultStyleCss='*,::before,::after{-webkit-box-sizing:border-box;box-sizing:border-box;border-width:0;border-style:solid;border-color:var(--kolibri-border-color)}*{--tw-ring-inset:var(--tw-empty, );--tw-ring-offset-width:0px;--tw-ring-offset-color:var(--kolibri-color);--tw-ring-color:rgba(undefined, 0.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000}:root{-moz-tab-size:4;-o-tab-size:4;tab-size:4}:-moz-focusring{outline:1px dotted ButtonText}:-moz-ui-invalid{box-shadow:none}::moz-focus-inner{border-style:none;padding:0}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}[type=\'search\']{-webkit-appearance:textfield;outline-offset:-2px}abbr[title]{-webkit-text-decoration:underline dotted;text-decoration:underline dotted}a{color:inherit;text-decoration:inherit}body{margin:0;font-family:inherit;line-height:inherit}b,strong{font-weight:bolder}button,select{text-transform:none}button,[type=\'button\'],[type=\'reset\'],[type=\'submit\']{-webkit-appearance:button}button{background-color:transparent;background-image:none}button,[role="button"]{cursor:pointer}code{font-size:1em;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace}fieldset{margin:0;padding:0}html{-webkit-text-size-adjust:100%;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";line-height:1.5}h1,p,h2,h3,h4,h5,h6{margin:0}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}input,button,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;padding:0;line-height:inherit;color:inherit}input::placeholder{opacity:1;color:#9ca3af}input::webkit-input-placeholder{opacity:1;color:#9ca3af}input::-moz-placeholder{opacity:1;color:#9ca3af}input:-ms-input-placeholder{opacity:1;color:#9ca3af}input::-ms-input-placeholder{opacity:1;color:#9ca3af}legend{padding:0}progress{vertical-align:baseline}small{font-size:80%}svg{display:block;vertical-align:middle}table{text-indent:0;border-color:inherit;border-collapse:collapse}textarea{resize:vertical}textarea::placeholder{opacity:1;color:#9ca3af}textarea::webkit-input-placeholder{opacity:1;color:#9ca3af}textarea::-moz-placeholder{opacity:1;color:#9ca3af}textarea:-ms-input-placeholder{opacity:1;color:#9ca3af}textarea::-ms-input-placeholder{opacity:1;color:#9ca3af}ul,ol{list-style:none;margin:0;padding:0}.container{width:100%}@media (min-width: 640px){.container{max-width:640px}}@media (min-width: 768px){.container{max-width:768px}}@media (min-width: 1024px){.container{max-width:1024px}}@media (min-width: 1280px){.container{max-width:1280px}}@media (min-width: 1536px){.container{max-width:1536px}}.bg-normal{background-color:var(--kolibri-color-normal)}.bg-white{--tw-bg-opacity:1;background-color:rgba(255, 255, 255, var(--tw-bg-opacity))}.bg-spin-1{background-color:var(--kolibri-color-spin-1)}.bg-spin-2{background-color:var(--kolibri-color-spin-2)}.bg-spin-3{background-color:var(--kolibri-color-spin-3)}.rounded{border-radius:var(--kolibri-border-radius)}.border-1{border-width:1px}.cursor-pointer{cursor:pointer}.block{display:block}.inline-block{display:inline-block}.flex{display:-webkit-box;display:-ms-flexbox;display:-webkit-flex;display:flex}.inline-flex{display:-webkit-inline-box;display:-ms-inline-flexbox;display:-webkit-inline-flex;display:inline-flex}.table{display:table}.grid{display:-ms-grid;display:grid}.hidden{display:none}.flex-wrap{-ms-flex-wrap:wrap;-webkit-flex-wrap:wrap;flex-wrap:wrap}.items-center{-webkit-box-align:center;-ms-flex-align:center;-webkit-align-items:center;align-items:center}.content-center{-ms-flex-line-pack:center;-webkit-align-content:center;align-content:center}.font-80{font-weight:80}.font-60{font-weight:60}.h-full{height:100%}.h-0{height:0px}.h-0\\.41c-2\\.42\\2c 0-4\\.82-1\\.57-4\\.82-3\\.58c0\\.05-0\\.98\\2c 0\\.43-1\\.91\\2c 1\\.07-2\\.65c0\\.3\\2c 0\\.05\\2c 0\\.61\\2c 0\\.09\\2c 0\\.92\\2c 0\\.09c1\\.1\\2c 0\\2c 1\\.69-0\\.58\\2c 1\\.74-1\\.16{height:0.29rem}.text-sm{font-size:0.875rem;line-height:1.25rem}.text-2xl{font-size:1.5rem;line-height:2rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.leading-normal{line-height:1.5}.list-none{list-style-type:none}.list-disc{list-style-type:disc}.list-decimal{list-style-type:decimal}.mx-auto{margin-left:auto;margin-right:auto}.mb-1{margin-bottom:calc(1 * var(--kolibri-spacing))}.mt-2{margin-top:calc(2 * var(--kolibri-spacing))}.mt-4{margin-top:calc(4 * var(--kolibri-spacing))}.outline{outline-style:solid}.overflow-hidden{overflow:hidden}.overflow-y-visible{overflow-y:visible}.p-2{padding:calc(2 * var(--kolibri-spacing))}.p-4{padding:calc(4 * var(--kolibri-spacing))}.px{padding-left:1px;padding-right:1px}.py-2{padding-top:calc(2 * var(--kolibri-spacing));padding-bottom:calc(2 * var(--kolibri-spacing))}.pl-8{padding-left:2rem}.pb-2{padding-bottom:calc(2 * var(--kolibri-spacing))}.tab{-moz-tab-size:4;-o-tab-size:4;tab-size:4}.absolute{position:absolute}.text-center{text-align:center}.hover\\:text-primary:hover{color:var(--kolibri-color-primary)}.text-normal{color:var(--kolibri-color-normal)}.italic{font-style:italic}.underline{-webkit-text-decoration-line:underline;text-decoration-line:underline}.indent{text-indent:1.5rem}.visible{visibility:visible}.w-full{width:100%}.w-4\\/5{width:80%}.z-50{z-index:50}.gap-1{grid-gap:calc(1 * var(--kolibri-spacing));gap:calc(1 * var(--kolibri-spacing))}.gap-2{grid-gap:calc(2 * var(--kolibri-spacing));gap:calc(2 * var(--kolibri-spacing))}.grid-flow-col{grid-auto-flow:column}.transform{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-rotate:0;--tw-rotate-x:0;--tw-rotate-y:0;--tw-rotate-z:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;-webkit-transform:translateX(var(--tw-translate-x)) translateY(var(--tw-translate-y)) translateZ(var(--tw-translate-z)) rotate(var(--tw-rotate)) rotateX(var(--tw-rotate-x)) rotateY(var(--tw-rotate-y)) rotateZ(var(--tw-rotate-z)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)) scaleZ(var(--tw-scale-z));-ms-transform:translateX(var(--tw-translate-x)) translateY(var(--tw-translate-y)) translateZ(var(--tw-translate-z)) rotate(var(--tw-rotate)) rotateX(var(--tw-rotate-x)) rotateY(var(--tw-rotate-y)) rotateZ(var(--tw-rotate-z)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)) scaleZ(var(--tw-scale-z));transform:translateX(var(--tw-translate-x)) translateY(var(--tw-translate-y)) translateZ(var(--tw-translate-z)) rotate(var(--tw-rotate)) rotateX(var(--tw-rotate-x)) rotateY(var(--tw-rotate-y)) rotateZ(var(--tw-rotate-z)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)) scaleZ(var(--tw-scale-z))}.animate{-webkit-animation-iteration-count:1;animation-iteration-count:1}.filter{--tw-blur:var(--tw-empty, );--tw-brightness:var(--tw-empty, );--tw-contrast:var(--tw-empty, );--tw-grayscale:var(--tw-empty, );--tw-hue-rotate:var(--tw-empty, );--tw-invert:var(--tw-empty, );--tw-saturate:var(--tw-empty, );--tw-sepia:var(--tw-empty, );--tw-drop-shadow:var(--tw-empty, );-webkit-filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.blur{-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px)}:host *{font-size:inherit;hyphens:auto;letter-spacing:inherit;word-break:break-word;word-spacing:inherit}',UNIQUE_ARIA_LABEL=[],removeAriaLabel=t=>{const a=UNIQUE_ARIA_LABEL.indexOf(t);a>=0&&UNIQUE_ARIA_LABEL.splice(a,1)},KolNav$1=proxyCustomElement(class extends HTMLElement{constructor(){super(),this.__registerHost(),this.__attachShadow(),this.onClick=t=>{t._active=!1===t._active,this.state=Object.assign({},this.state)},this.hasActiveChild=t=>!!(Array.isArray(t._children)&&t._children.length>0)&&t._children.some(this.hasActiveChild),this.linkList=t=>h("ul",{class:{flex:0===t.deep&&"horizontal"===this.state._orientation},part:`nav ${this.state._orientation}`},t.links.map(((a,e)=>h("li",{key:e,part:`li ${0===t.deep?this.state._orientation:"vertical"}${a._active?" selected":""}${e<t.links.length-1?"":" last"}`},Array.isArray(a._children)&&a._children.length>0?h("div",{class:"h-full"},h("div",{class:{"h-full":!0}},h("kol-link-wc",{class:"block w-full h-full",exportparts:"icon,link,span"+(!0===a._active?",selected":""),_useCase:"nav",_ariaLabel:!0===this.state._compact||!0===a._iconOnly?a._label:void 0,_ariaExpanded:!0===a._active,_disabled:a._disabled,_href:"javascript:void(0)",_icon:!0===this.state._collapsible?!0===a._active?"fa-solid fa-minus":"fa-solid fa-plus":"string"==typeof a._icon?a._icon:"fa-solid fa-link-slash",_iconOnly:!0===this.state._compact||!0===a._iconOnly,_label:a._label,_part:!0===a._active?"selected":void 0,_underline:!1,onClick:()=>this.onClick(a)})),!0===a._active&&h("div",{class:{expanded:!0,active:!0===a._active,"active-child":this.hasActiveChild(a),"absolute ":0===t.deep&&"horizontal"===this.state._orientation}},h(this.linkList,{links:a._children,deep:t.deep+1}))):h("div",{class:{"h-full":!0,"text-center":!0===this.state._compact||!0===a._iconOnly}},h("kol-link-wc",{class:{"block w-full h-full":!0,active:!0===a._active},exportparts:"icon,link,span"+(!0===a._active?",selected":""),_ariaCurrent:!0===a._active&&this.state._ariaCurrentValue,_ariaLabel:!0===this.state._compact||!0===a._iconOnly?a._label:"undefined",_href:a._href,_icon:"string"==typeof a._icon?a._icon:"fa-solid fa-link-slash","_icon-only":!0===this.state._compact||!0===a._iconOnly,_label:a._label,_on:a._on,_part:!0===a._active?"selected":void 0,_selector:a._selector,_tooltipAlign:a._tooltipAlign,_target:a._target,_underline:!1,_useCase:"nav"})))))),this._ariaCurrentValue=!1,this._ariaLabel=void 0,this._collapsible=!1,this._compact=!1,this._hasCompactButton=!1,this._orientation="vertical",this._links=void 0,this._variant="primary",this.state={_ariaCurrentValue:!1,_ariaLabel:"…",_collapsible:!0,_hasCompactButton:!1,_links:[],_orientation:"vertical",_variant:"primary"}}render(){let t=this.state._hasCompactButton;return"horizontal"===this.state._orientation&&!0===this.state._hasCompactButton&&(t=!1,devHint("[KolNav] Wenn eine horizontale Navigation verwendet wird, kann die Option _hasCompactButton nicht aktiviert werden.")),h(Host,null,h("div",{class:{[this.state._orientation]:!0,"inline-block":!0===this.state._compact,[this.state._variant]:!0}},h("nav",{"aria-label":this.state._ariaLabel,id:"nav",part:"nav"},h(this.linkList,{links:this.state._links,deep:0})),t&&h("div",{class:"mt-2 w-full text-center"},h("kol-button",{exportparts:"button,ghost",_ariaControls:"nav",_ariaExpanded:!0===this.state._compact,_ariaLabel:translate(this.state._compact?"kol-nav-maximize":"kol-nav-minimize"),_icon:this.state._compact?"fa-solid fa-angles-right":"fa-solid fa-angles-left",_iconOnly:!0,_label:translate(this.state._compact?"kol-nav-maximize":"kol-nav-minimize"),_on:{onClick:()=>{this.state=Object.assign(Object.assign({},this.state),{_compact:!1===this.state._compact})}},_tooltipAlign:"right",_variant:"ghost"}))))}validateAriaCurrentValue(t){watchValidator(this,"_ariaCurrentValue",(t=>!0===t||"date"===t||"location"===t||"page"===t||"step"===t||"time"===t),new Set(["boolean","String {data, location, page, step, time}"]),t)}validateAriaLabel(t){watchString(this,"_ariaLabel",t,{hooks:{afterPatch:()=>{UNIQUE_ARIA_LABEL.includes(this.state._ariaLabel)&&devHint(`[KolNav] Das Aria-Label "${this.state._ariaLabel}" wurde für die Rolle Navigation mehrfach verwendet!`),UNIQUE_ARIA_LABEL.push(this.state._ariaLabel)},beforePatch:()=>{removeAriaLabel(this.state._ariaLabel)}},required:!0}),a11yHintLabelingLandmarks(t)}validateCollapsible(t){watchBoolean(this,"_collapsible",t)}validateCompact(t){watchBoolean(this,"_compact",t)}validateHasCompactButton(t){watchBoolean(this,"_hasCompactButton",t)}validateLinks(t){watchNavLinks("KolNav",this,t),devHint("[KolNav] Die Navigationsstruktur wird noch nicht rekursiv validiert.")}validateOrientation(t){watchValidator(this,"_orientation",(t=>"horizontal"===t||"vertical"===t),new Set(["Orientation {horizontal, vertical}"]),t,{defaultValue:"vertical"})}validateVariant(t){watchValidator(this,"_variant",(t=>"primary"===t||"secondary"===t),new Set(["KoliBriNavVariant {primary, secondary}"]),t,{defaultValue:"primary"})}componentWillLoad(){this.validateAriaLabel(this._ariaLabel),this.validateCollapsible(this._collapsible),this.validateCompact(this._compact),this.validateHasCompactButton(this._hasCompactButton),this.validateLinks(this._links),this.validateOrientation(this._orientation),this.validateVariant(this._variant)}disconnectedCallback(){removeAriaLabel(this.state._ariaLabel)}static get watchers(){return{_ariaCurrentValue:["validateAriaCurrentValue"],_ariaLabel:["validateAriaLabel"],_collapsible:["validateCollapsible"],_compact:["validateCompact"],_hasCompactButton:["validateHasCompactButton"],_links:["validateLinks"],_orientation:["validateOrientation"],_variant:["validateVariant"]}}static get style(){return{default:defaultStyleCss}}},[33,"kol-nav",{_ariaCurrentValue:[8,"_aria-current-value"],_ariaLabel:[1,"_aria-label"],_collapsible:[516],_compact:[516],_hasCompactButton:[516,"_has-compact-button"],_orientation:[1],_links:[1],_variant:[1],state:[32]}]);function defineCustomElement$1(){if("undefined"==typeof customElements)return;["kol-nav","kol-badge","kol-button","kol-button-wc","kol-icon","kol-link-wc","kol-span-wc","kol-tooltip"].forEach((t=>{switch(t){case"kol-nav":customElements.get(t)||customElements.define(t,KolNav$1);break;case"kol-badge":customElements.get(t)||defineCustomElement$8();break;case"kol-button":customElements.get(t)||defineCustomElement$7();break;case"kol-button-wc":customElements.get(t)||defineCustomElement$6();break;case"kol-icon":customElements.get(t)||defineCustomElement$5();break;case"kol-link-wc":customElements.get(t)||defineCustomElement$4();break;case"kol-span-wc":customElements.get(t)||defineCustomElement$3();break;case"kol-tooltip":customElements.get(t)||defineCustomElement$2()}}))}const KolNav=KolNav$1,defineCustomElement=defineCustomElement$1;export{KolNav,defineCustomElement};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* KoliBri - The accessible HTML-Standard
|
|
3
3
|
*/
|
|
4
|
-
import{s,f}from"./index.m.js";class ModalService{constructor(){this.lockedElements=new Map,this.modalStack=new Map}lockElement(e){const t=e.getAttribute("tabindex");(e instanceof HTMLAnchorElement||e instanceof HTMLButtonElement||e instanceof HTMLInputElement||e instanceof HTMLSelectElement||e instanceof HTMLTextAreaElement||"string"==typeof t||void 0!==e.dataset.kolModal)&&("string"==typeof t?this.lockedElements.set(e,{tabIndex:t}):this.lockedElements.set(e,{}),e.setAttribute("tabindex","-1"),e.setAttribute("aria-hidden","true"),e.style.userSelect="none")}unlockElement(e,t){"string"==typeof e.tabIndex?t.setAttribute("tabindex",e.tabIndex):t.removeAttribute("tabindex"),t.removeAttribute("aria-hidden"),t.style.userSelect="unset",this.lockedElements.delete(t)}unlockLockedElements(e){e.forEach(this.unlockElement.bind(this))}lockFocus(e,t){if(e!==t&&(e instanceof HTMLElement||e instanceof ShadowRoot)){e instanceof HTMLElement&&(this.lockElement(e),this.lockFocus(e.shadowRoot,t));for(let o=0;o<e.children.length;o++)this.lockFocus(e.children[o],t)}}renderModalIfExists(e){if(e instanceof HTMLElement){this.lockedElements.has(e)&&this.unlockElement(this.lockedElements.get(e),e);const t=setTimeout((()=>{clearTimeout(t),e.focus()}),500)}if(this.unlockLockedElements(this.lockedElements),this.modalStack.size>0){const e=Array.from(this.modalStack.keys()),t=e[e.length-1];this.modalStack.forEach(((e,o)=>{o.style.display=t===o?"inline":"none"})),getDocument().body.style.maxHeight="100vh",getDocument().body.style.overflow="hidden",this.lockFocus(getDocument().body,t)}else getDocument().body.style.maxHeight="unset",getDocument().body.style.overflow="unset"}openModal(e,t){e instanceof HTMLElement==!1?Log.warn("[KolModalService] Die DOM-Referenz des Modals ist nicht valide."):(this.modalStack.set(e,{activeElement:t}),this.renderModalIfExists())}closeModal(e){var t;if(e instanceof HTMLElement==!1)Log.warn("[KolModalService] Die DOM-Referenz des Modals ist nicht valide.");else{const o=null===(t=this.modalStack.get(e))||void 0===t?void 0:t.activeElement;this.modalStack.delete(e),this.renderModalIfExists(o)}}}class ToasterService{constructor(e){this.document=e,this.queue=new Set,this.isOpen=!1,this.toastElement=this.document.createElement("kol-toast"),this.toastElement.setAttribute("_level","3"),this.toastElement.setAttribute("_show","false"),this.toastElement.setAttribute("_show-duration","-1"),this.toastElement.setAttribute("_has-closer","true"),this.toastElement._on={onClose:()=>{const e=this.queue.values().next();e.value?(this.queue.delete(e.value),setTimeout((()=>{this.showToast(e.value)}),200)):this.isOpen=!1}},this.document.body.insertBefore(this.toastElement,this.document.body.firstChild)}enqueue(e){this.isOpen?this.queue.add(e):this.showToast(e)}showToast(e){this.toastElement.setAttribute("_heading",e.heading),this.toastElement.setAttribute("_show","true"),this.toastElement.setAttribute("_type",e.type),this.toastElement.innerText=e.description,this.isOpen=!0}}let WINDOW=null,DOCUMENT=null;const configKoliBri=e=>{e instanceof Window?(WINDOW=e,WINDOW.document instanceof Document?DOCUMENT=e.document:console.warn("The given Window has no valid Document.")):console.warn("The given Window is not valid.")},getWindow=()=>WINDOW||"undefined"==typeof window?null:window,getDocument=()=>DOCUMENT||void 0===getWindow().document?null:getWindow().document;let META_CONFIG=null,DEV_MODE=null,EXPERIMENTAL_MODE=null,COLOR_CONTRAST_ANALYSIS=null;const getDevMode=()=>!0===DEV_MODE,getExperimalMode=()=>!0===EXPERIMENTAL_MODE,getColorContrastAnalysis=()=>!0===COLOR_CONTRAST_ANALYSIS;class Log{static mapToArray(e){return Array.isArray(e)?e:[e]}static handleClassifier(e){return"string"==typeof e&&e.length>0?`${Log.shield.label} | ${e}`:Log.shield.label}static getShield(e){return[Log.handleClassifier(null==e?void 0:e.classifier),`${Log.shield.style};${(null==e?void 0:e.overwriteStyle)||""}`]}static debug(e,t){(DEV_MODE||!0===(null==t?void 0:t.forceLog))&&console.log(...Log.getShield(t),...Log.mapToArray(e))}static info(e,t){(DEV_MODE||!0===(null==t?void 0:t.forceLog))&&console.info(...Log.getShield(t),...Log.mapToArray(e))}static trace(e,t){(DEV_MODE||!0===(null==t?void 0:t.forceLog))&&console.trace(...Log.getShield(t),...Log.mapToArray(e))}static warn(e,t){(DEV_MODE||!0===(null==t?void 0:t.forceLog))&&console.warn(...Log.getShield(t),...Log.mapToArray(e))}static error(e,t){(DEV_MODE||!0===(null==t?void 0:t.forceLog))&&console.error(...Log.getShield(t),...Log.mapToArray(e))}static throw(e,t){if(DEV_MODE||!0===(null==t?void 0:t.forceLog))throw new Error(...Log.getShield(t),...Log.mapToArray(e))}}Log.shield={label:"%cKoliBri",style:"color: white; background: #666; font-weight: bold; padding: .25em .5em; border-radius: 3px; border: 1px solid #000"};const initMeta=()=>{if(null===DEV_MODE&&null===EXPERIMENTAL_MODE&&null===COLOR_CONTRAST_ANALYSIS){const e=getDocument().querySelector('meta[name="kolibri"]');e&&e.hasAttribute("content")&&(META_CONFIG=e.getAttribute("content"),"string"==typeof META_CONFIG&&(DEV_MODE=META_CONFIG.includes("dev-mode=true"),EXPERIMENTAL_MODE=META_CONFIG.includes("experimental-mode=true"),COLOR_CONTRAST_ANALYSIS=META_CONFIG.includes("color-contrast-analysis=true")))}else console.warn("You can only initialize DEV_MODE and COLOR_CONTRAST_ANALYSIS once.")};let KoliBri=null;const getKoliBri=()=>KoliBri||{},initKoliBri=()=>{if(null===KoliBri){KoliBri=getWindow().KoliBri||{};const e=new ModalService,t=new ToasterService(getDocument());Object.defineProperty(KoliBri,"Modal",{get:function(){return e}}),Object.defineProperty(KoliBri,"Toaster",{get:function(){return t}}),initMeta()}else console.warn("You can only initialize KoliBri once.")},renderDevAdvice=()=>{void 0===getWindow().KoliBri&&Object.defineProperty(window,"KoliBri",{get:function(){return KoliBri}}),!0!==getKoliBri().adviceShown&&(Object.defineProperty(KoliBri,"adviceShown",{get:function(){return!0}}),Log.debug("\n\nSie verwenden die KoliBri-Komponenten-Bibliothek. Sollten Sie Verbesserungsvorschläge haben oder ein Problem feststellen, dann wenden Sie sich gerne an kolibri@itzbund.de.\n\nHinweise:\n- WAI Web Accessibility Tutorials (https://www.w3.org/WAI/tutorials/)\n- The first rule of ARIA is “Don't use ARIA” (https://cccaccessibility.org/web-1/web-developer-tutorials/how-not-to-use-aria)\n- BIK BITV-Test (https://www.bitvtest.de/bitv_test.html)\n- A11y-Checkliste (https://www.a11yproject.com/checklist/)\n- BSI CON.10: Entwicklung von Webanwendungen (Edition 2021)\n\n"))};let nonce=()=>Math.floor(16777215*Math.random()).toString(16);var commonjsGlobal="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function createCommonjsModule(e,t,o){return e(o={path:t,exports:{},require:function(e,t){return commonjsRequire()}},o.exports),o.exports}function commonjsRequire(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}var loglevel=createCommonjsModule((function(e){var t,o;t=commonjsGlobal,o=function(){var e=function(){},t="undefined",o=typeof window!==t&&typeof window.navigator!==t&&/Trident\/|MSIE /.test(window.navigator.userAgent),n=["trace","debug","info","warn","error"];function r(e,t){var o=e[t];if("function"==typeof o.bind)return o.bind(e);try{return Function.prototype.bind.call(o,e)}catch(t){return function(){return Function.prototype.apply.apply(o,[e,arguments])}}}function i(){console.log&&(console.log.apply?console.log.apply(console,arguments):Function.prototype.apply.apply(console.log,[console,arguments])),console.trace&&console.trace()}function l(n){return"debug"===n&&(n="log"),typeof console!==t&&("trace"===n&&o?i:void 0!==console[n]?r(console,n):void 0!==console.log?r(console,"log"):e)}function a(t,o){for(var r=0;r<n.length;r++){var i=n[r];this[i]=r<t?e:this.methodFactory(i,t,o)}this.log=this.debug}function s(e,o,n){return function(){typeof console!==t&&(a.call(this,o,n),this[e].apply(this,arguments))}}function c(e,t,o){return l(e)||s.apply(this,arguments)}function d(e,o,r){var i,l=this;o=null==o?"WARN":o;var s="loglevel";function d(){var e;if(typeof window!==t&&s){try{e=window.localStorage[s]}catch(e){}if(typeof e===t)try{var o=window.document.cookie,n=o.indexOf(encodeURIComponent(s)+"=");-1!==n&&(e=/^([^;]+)/.exec(o.slice(n))[1])}catch(e){}return void 0===l.levels[e]&&(e=void 0),e}}"string"==typeof e?s+=":"+e:"symbol"==typeof e&&(s=void 0),l.name=e,l.levels={TRACE:0,DEBUG:1,INFO:2,WARN:3,ERROR:4,SILENT:5},l.methodFactory=r||c,l.getLevel=function(){return i},l.setLevel=function(o,r){if("string"==typeof o&&void 0!==l.levels[o.toUpperCase()]&&(o=l.levels[o.toUpperCase()]),!("number"==typeof o&&o>=0&&o<=l.levels.SILENT))throw"log.setLevel() called with invalid level: "+o;if(i=o,!1!==r&&function(e){var o=(n[e]||"silent").toUpperCase();if(typeof window!==t&&s){try{return void(window.localStorage[s]=o)}catch(e){}try{window.document.cookie=encodeURIComponent(s)+"="+o+";"}catch(e){}}}(o),a.call(l,o,e),typeof console===t&&o<l.levels.SILENT)return"No console available for logging"},l.setDefaultLevel=function(e){o=e,d()||l.setLevel(e,!1)},l.resetLevel=function(){l.setLevel(o,!1),function(){if(typeof window!==t&&s){try{return void window.localStorage.removeItem(s)}catch(e){}try{window.document.cookie=encodeURIComponent(s)+"=; expires=Thu, 01 Jan 1970 00:00:00 UTC"}catch(e){}}}()},l.enableAll=function(e){l.setLevel(l.levels.TRACE,e)},l.disableAll=function(e){l.setLevel(l.levels.SILENT,e)};var u=d();null==u&&(u=o),l.setLevel(u,!1)}var u=new d,h={};u.getLogger=function(e){if("symbol"!=typeof e&&"string"!=typeof e||""===e)throw new TypeError("You must supply a name when creating a logger.");var t=h[e];return t||(t=h[e]=new d(e,u.getLevel(),u.methodFactory)),t};var f=typeof window!==t?window.log:void 0;return u.noConflict=function(){return typeof window!==t&&window.log===u&&(window.log=f),u},u.getLoggers=function(){return h},u.default=u,u},e.exports?e.exports=o():t.log=o()}));const GLOBAL$1="object"==typeof window?window:"object"==typeof global?global:"object"==typeof self?self:{};let warrentyWarning=!1;const THEME_NAME_PATTERN=/^[a-z][a-z0-9]{1,}(-[a-z0-9]+)?$/,isThemeNameValid=e=>"string"==typeof e&&THEME_NAME_PATTERN.test(e),validateThemeName=e=>{if(!1===isThemeNameValid(e))throw new Error(`[Theming] The theme identifier "${"string"==typeof e?e:""}" (Type: ${typeof e}) is not valid. Please use only follow this pattern: /^[a-z][a-z0-9]{1,}(-[a-z0-9]+)?$/`)},patchThemeTag=(e,t,o)=>{validateThemeName(e),!1===warrentyWarning&&(warrentyWarning=!0,loglevel.warn(`[Theming] The theme process is locked. This means that the theme "${e}" should not be patched.\n\nimport { register } from '@a11y-ui/core';\nimport { defineCustomElements } from '...';\nimport { THEME } from '...';\n\nregister(THEME, defineCustomElements)\n\t.then(() => {\n\t\tconst htmlDivElement: HTMLDivElement | null = document.querySelector<HTMLDivElement>('div#app');\n if (htmlDivElement instanceof HTMLDivElement) {\n const root = createRoot(htmlDivElement);\n root.render(<AppComponent />);\n }\n })\n .catch(console.warn);`)),"object"==typeof GLOBAL$1.A11yUi&&null!==GLOBAL$1.A11yUi||(GLOBAL$1.A11yUi={}),"object"!=typeof GLOBAL$1.A11yUi||null===GLOBAL$1.A11yUi||"object"==typeof GLOBAL$1.A11yUi.Themes&&null!==GLOBAL$1.A11yUi.Themes||(GLOBAL$1.A11yUi.Themes={}),"object"!=typeof GLOBAL$1.A11yUi||null===GLOBAL$1.A11yUi||"object"!=typeof GLOBAL$1.A11yUi.Themes||null===GLOBAL$1.A11yUi.Themes||"object"==typeof GLOBAL$1.A11yUi.Themes[e]&&null!==GLOBAL$1.A11yUi.Themes[e]||(GLOBAL$1.A11yUi.Themes[e]={}),"object"==typeof GLOBAL$1.A11yUi&&null!==GLOBAL$1.A11yUi&&"object"==typeof GLOBAL$1.A11yUi.Themes&&null!==GLOBAL$1.A11yUi.Themes&&"object"==typeof GLOBAL$1.A11yUi.Themes[e]&&null!==GLOBAL$1.A11yUi.Themes[e]&&(GLOBAL$1.A11yUi.Themes[e][t]=o)},patchTheme=(e,t)=>{if(validateThemeName(e),"object"==typeof t&&null!==t){Object.getOwnPropertyNames(t).forEach((o=>{const n=t[o];"string"==typeof n&&n.length>0&&patchThemeTag(e,o,n)}))}return e},getThemeNode=e=>{if(e instanceof HTMLElement){if("string"==typeof e.dataset.theme)return e;{let t=e.parentNode;for(;t instanceof ShadowRoot;)t=t.host;return getThemeNode(t)}}return null},getEncroachCss=(e={})=>"false"!==e.themeEncroachCss&&"false"!==e.themeReset&&("string"!=typeof e.themeEncroachCssMode||"after"!==e.themeEncroachCssMode&&"before"!==e.themeEncroachCssMode?{mode:"before"}:{mode:e.themeEncroachCssMode}),isTheCurrentThemeConfigValid=()=>"object"==typeof GLOBAL$1.A11yUi&&null!==GLOBAL$1.A11yUi&&"object"==typeof GLOBAL$1.A11yUi.Theme&&null!==GLOBAL$1.A11yUi.Theme&&"boolean"==typeof GLOBAL$1.A11yUi.Theme.cache&&"object"==typeof GLOBAL$1.A11yUi.Theme.encroachCss&&null!==typeof GLOBAL$1.A11yUi.Theme.encroachCss&&"string"==typeof GLOBAL$1.A11yUi.Theme.encroachCss.mode&&"string"==typeof GLOBAL$1.A11yUi.Theme.name,getThemeDetails=e=>{if("object"==typeof GLOBAL$1.A11yUi&&null!==GLOBAL$1.A11yUi&&"object"==typeof GLOBAL$1.A11yUi.Theme&&null!==GLOBAL$1.A11yUi.Theme&&"boolean"==typeof GLOBAL$1.A11yUi.Theme.cache&&"object"==typeof GLOBAL$1.A11yUi.Theme.encroachCss&&null!==typeof GLOBAL$1.A11yUi.Theme.encroachCss&&"string"==typeof GLOBAL$1.A11yUi.Theme.encroachCss.mode&&"string"==typeof GLOBAL$1.A11yUi.Theme.name)return GLOBAL$1.A11yUi.Theme;{const t=getThemeNode(e),o={cache:!0,encroachCss:getEncroachCss(),name:null};return t instanceof HTMLElement&&(o.cache="false"!==t.dataset.themeCache,o.encroachCss=getEncroachCss(t.dataset),o.name=t.dataset.theme||null),o}},GLOBAL=window,CSS_PROPERTIES_REGISTERED=new Set,CSS_STYLE_SHEETS=new Map,HTML_STYLE_ELEMENTS=new Map,REGEX_CSS_PROPERTIES=/--[^;]+/g,REGEX_SPLT_CSS_PROPERTY=/:/,getCssStyleSheet=(e,t,o)=>{if(!0===e&&CSS_STYLE_SHEETS.has(t)&&CSS_STYLE_SHEETS.get(t)?.has(o))return CSS_STYLE_SHEETS.get(t)?.get(o);if(!0===e&&HTML_STYLE_ELEMENTS.has(t)&&HTML_STYLE_ELEMENTS.get(t)?.has(o))return HTML_STYLE_ELEMENTS.get(t)?.get(o);if("object"==typeof GLOBAL.A11yUi&&null!==GLOBAL.A11yUi&&"object"==typeof GLOBAL.A11yUi.Themes&&null!==GLOBAL.A11yUi.Themes&&"object"==typeof GLOBAL.A11yUi.Themes[t]&&null!==GLOBAL.A11yUi.Themes[t]&&"string"==typeof GLOBAL.A11yUi.Themes[t][o]){if(("GLOBAL"===o||"PROPERTIES"===o)&&!1===CSS_PROPERTIES_REGISTERED.has(t)){let e=GLOBAL.A11yUi.Themes[t][o].match(REGEX_CSS_PROPERTIES);if(Array.isArray(e)){e=e.filter((e=>REGEX_SPLT_CSS_PROPERTY.test(e)));const o=document.createElement("style");o.innerHTML=`.${t} {${e.join(";")}}`,document.querySelector("head")?.appendChild(o)}CSS_PROPERTIES_REGISTERED.add(t)}let n;try{n=new CSSStyleSheet,"function"==typeof n.replaceSync&&n.replaceSync(GLOBAL.A11yUi.Themes[t][o]),!0===e&&(!1===CSS_STYLE_SHEETS.has(t)&&CSS_STYLE_SHEETS.set(t,new Map),CSS_STYLE_SHEETS.get(t)?.set(o,n))}catch(e){n=document.createElement("style"),n.innerHTML=GLOBAL.A11yUi.Themes[t][o]}return n}return null},removeStyle=e=>{for(const t of Array.from(e.childNodes)){if(!(t instanceof HTMLStyleElement&&"STYLE"===t.tagName))break;e.removeChild(t)}},GLOBAL_A11Y_STYLE="* {\n font-size: inherit;\n hyphens: auto;\n letter-spacing: inherit;\n word-break: break-word;\n word-spacing: inherit;\n}",patchAdopted=(e,t,o,n)=>{removeStyle(t);const r=new CSSStyleSheet;"function"==typeof r.replaceSync&&r.replaceSync(GLOBAL_A11Y_STYLE),o.unshift(r),t.adoptedStyleSheets=o,e.style.display=n},patchStyle=(e,t,o,n)=>{removeStyle(t);const r=document.createElement("style");r.innerHTML=GLOBAL_A11Y_STYLE,o.unshift(r);const i=t.firstChild;o.forEach((e=>{i instanceof HTMLElement?t.insertBefore(e,i):t.appendChild(e)})),e.style.display=n},setThemeStyleAfterHydrated=(e,t,o)=>{const n=t.cache,r=t.encroachCss,i=t.name||"default",l=getCssStyleSheet(n,i,"GLOBAL"),a=getCssStyleSheet(n,i,e.tagName),s=e.shadowRoot;if(a instanceof CSSStyleSheet&&a.cssRules.length>0){const t=[],n=[...Array.from(new Set(s.adoptedStyleSheets))];!1!==r&&"before"===r?.mode&&n.forEach((e=>t.push(e))),l instanceof CSSStyleSheet&&l.cssRules.length>0&&!1===t.includes(l)&&t.push(l),a instanceof CSSStyleSheet&&a.cssRules.length>0&&!1===t.includes(a)&&t.push(a),!1!==r&&"after"===r?.mode&&n.forEach((e=>t.push(e))),patchAdopted(e,s,t,o)}else if(a instanceof HTMLStyleElement&&a.innerHTML.length>0){const t=[],n=[...Array.from(s.childNodes).filter((e=>e instanceof HTMLStyleElement&&"STYLE"===e.tagName))];!1!==r&&"before"===r?.mode&&n.forEach((e=>t.push(e))),l instanceof HTMLStyleElement&&l.innerHTML.length>0&&!1===t.includes(l)&&t.push(l),a instanceof HTMLStyleElement&&a.innerHTML.length>0&&!1===t.includes(a)&&t.push(a),patchStyle(e,s,t,o)}else e.style.display=o},waitForHydrated=(e,t,o)=>{const n=setTimeout((()=>{clearTimeout(n),e.classList.contains("hydrated")?setThemeStyleAfterHydrated(e,t,o):waitForHydrated(e,t,o)}),25)},setThemeStyle=(e,t)=>{const o=`${e.style.display}`;e.style.display="none",waitForHydrated(e,t,o)},pushNodes=(e,t)=>{t.forEach((t=>{!1===e.has(t)&&e.add(t)}))},querySelectorAll=(e,t=document)=>{if(t instanceof Document||t instanceof HTMLElement||t instanceof ShadowRoot){const o=new Set;pushNodes(o,t.querySelectorAll(e));const n=t.querySelectorAll('[class*="hydrated"]');for(let t=0;t<n.length;t++){const r=n[t].shadowRoot;pushNodes(o,querySelectorAll(e,"object"==typeof r&&null!==r?r:n[t]))}return Array.from(o)}throw new Error("The parameter document for the method querySelectorAll is not type of Document, HTMLElement or ShadowRoot.")},querySelector=(e,t=document)=>{if(t instanceof Document||t instanceof HTMLElement||t instanceof ShadowRoot){let o=t.querySelector(e);if(null===o){const n=t.querySelectorAll('[class*="hydrated"]');for(let t=0;t<n.length;t++){const r=n[t].shadowRoot;if(o=querySelector(e,"object"==typeof r&&null!==r?r:n[t]),null!==o)break}}return o}throw new Error("The parameter document for the method querySelector is not type of Document, HTMLElement or ShadowRoot.")};var rgbaConvert=arr,arr_1=arr,obj_1=obj,css_1=css,hex_1=hex,num_1=num;function arr(e){var t=parse(e);return 3==t.length?t.concat(255):(t[3]=Math.round(t[3]),t)}function obj(e){var t=parse(e);return{r:t[0],g:t[1],b:t[2],a:3==t.length?255:Math.round(t[3])}}function css(e){var t=parse(e);return 3==t.length&&t.push(255),255==t[3]?"rgb("+t[0]+", "+t[1]+", "+t[2]+")":0==t[3]?"rgba("+t[0]+", "+t[1]+", "+t[2]+", 0)":"rgba("+t[0]+", "+t[1]+", "+t[2]+", "+String(t[3]/255).substr(1)+")"}function hex(e){3==(t=parse(e)).length&&t.push(255);var t,o=255==t[3],n=num2hex(t[0]),r=num2hex(t[1]),i=num2hex(t[2]),l=isshort(n,r,i,t=num2hex(Math.round(t[3])));return o?l?"#"+n.charAt(0)+r.charAt(0)+i.charAt(0):"#"+n+r+i:l?"#"+n.charAt(0)+r.charAt(0)+i.charAt(0)+t.charAt(0):"#"+n+r+i+t}function num(e){var t=parse(e);return 3==t.length?t.push(255):t[3]=Math.round(t[3]),(t[3]<<24>>>0|t[0]<<16|t[1]<<8|t[2])>>>0}function parse(e){return"string"==typeof e?name(e=e.toLowerCase())||hex3(e)||hex6(e)||rgb(e)||rgba(e)||[0,0,0,255]:object(e)||array(e)||number(e)||[0,0,0,255]}function num2hex(e){var t=e.toString(16);return 1==t.length?"0"+t:t}function isshort(e,t,o,n){var r=["ff","00","11","22","33","44","55","66","77","88","99","aa","bb","cc","dd","ee"];return-1!=r.indexOf(e)&&-1!=r.indexOf(t)&&-1!=r.indexOf(o)&&-1!=r.indexOf(n)}function name(e){return"red"==e?[255,0,0]:"green"==e?[0,255,0]:"blue"==e?[0,0,255]:"black"==e?[0,0,0]:"white"==e?[255,255,255]:"cyan"==e?[0,255,255]:"gray"==e||"grey"==e?[128,128,128]:"magenta"==e||"pink"==e?[255,0,255]:"yellow"==e?[255,255,0]:void 0}function hex2num(e){return 1==e.length?parseInt(e+e,16):parseInt(e,16)}function hex3(e){var t=e.replace(/^#/,""),o=t.length;if(3==o||4==o){var n=hex2num(t[0]),r=hex2num(t[1]),i=hex2num(t[2]),l=3==o?255:hex2num(t[3]);if(isNaN(n)||isNaN(r)||isNaN(i)||isNaN(l))return;return[n,r,i,l]}}function hex6(e){var t=e.replace(/^#/,""),o=t.length;if(6==o||8==o){var n=hex2num(t.slice(0,2)),r=hex2num(t.slice(2,4)),i=hex2num(t.slice(4,6)),l=6==o?255:hex2num(t.slice(6,8));if(isNaN(n)||isNaN(r)||isNaN(i)||isNaN(l))return;return[n,r,i,l]}}function getnum(e,t){return"number"!=typeof e||!0===t&&Math.floor(e)!==e?-1:e>=0&&e<=255?e:-1}function object(e){if("[object Object]"===Object.prototype.toString.call(e)&&Object.getPrototypeOf(e)===Object.getPrototypeOf({})){var t=getnum(null!=e.r?e.r:null!=e.red?e.red:0,!0),o=getnum(null!=e.g?e.g:null!=e.green?e.green:0,!0),n=getnum(null!=e.b?e.b:null!=e.blue?e.blue:0,!0),r=getnum(null!=e.a?e.a:null!=e.alpha?e.alpha:255,!0);if(-1!=t&&-1!=o&&-1!=n&&-1!=r)return[t,o,n,r]}}function array(e){if(Array.isArray(e)&&(3==e.length||4==e.length)){var t=getnum(e[0],!0),o=getnum(e[1],!0),n=getnum(e[2],!0),r=getnum(null!=e[3]?e[3]:255,!0);if(-1!=t&&-1!=o&&-1!=n&&-1!=r)return[t,o,n,r]}}function number(e){if("number"==typeof e&&Math.floor(e)==e&&e<=4294967295&&e>=0)return[e>>16&255,e>>8&255,255&e,e>>24&255]}function rgb(e){if("rgb("==e.substr(0,4)){var t=(e=e.match(/^rgb\(([^)]+)\)/)[1]).split(/ *, */).map(Number),o=getnum(t[0],!0),n=getnum(t[1],!0),r=getnum(t[2],!0);if(-1!=o&&-1!=n&&-1!=r)return[o,n,r,255]}}function rgba(e){if("rgba("==e.substr(0,5)){var t=(e=e.match(/^rgba\(([^)]+)\)/)[1]).split(/ *, */).map(Number),o=getnum(t[0],!0),n=getnum(t[1],!0),r=getnum(t[2],!0),i=getnum(255*t[3]);if(-1!=o&&-1!=n&&-1!=r&&-1!=i)return[o,n,r,i]}}rgbaConvert.arr=arr_1,rgbaConvert.obj=obj_1,rgbaConvert.css=css_1,rgbaConvert.hex=hex_1,rgbaConvert.num=num_1;const a11yCache=new Set,a11yHint=e=>{!1===a11yCache.has(e)&&(a11yCache.add(e),Log.info(e,{classifier:"✋a11y",overwriteStyle:"; background-color: #09f"}))},deprecatedCache=new Set,deprecatedHint=e=>{!1===deprecatedCache.has(e)&&(deprecatedCache.add(e),Log.warn(e,{classifier:"🔥deprecated",forceLog:!0,overwriteStyle:"; background-color: #f00"}))},devCache=new Set,devHint=e=>{!1===devCache.has(e)&&(devCache.add(e),Log.debug(e,{classifier:"💻dev",overwriteStyle:"; background-color: #f09"}))},featureCache=new Set,featureHint=(e,t=!1)=>{!1===featureCache.has(e)&&(featureCache.add(e),e+=!0===t?" ✅":"",Log.debug(e,{classifier:"🌟feature",overwriteStyle:"; background-color: #309"}))};devHint("Wir freuen uns über jedes Feedback, Kommentare, Screenshots oder Demo-Links von einer auf KoliBri-basierenden Anwendung (kolibri@itzbund.de). Vielen Dank!");const uiUxCache=new Set,uiUxHint=e=>{!1===uiUxCache.has(e)&&(uiUxCache.add(e),Log.debug(e,{classifier:"📑ui/ux",overwriteStyle:"; background-color: #060;"}))},a11yHintDisabled=()=>{a11yHint('"Disabled" schränkt die Zugänglichkeit und Sichtbarkeit ein. Wir empfehlen aus Sicht der Barrierefreiheit readonly- statt disabled-Attribut zu verwenden.\n- https://uxdesign.cc/is-it-ok-to-grey-out-disabled-buttons-8afa74a0fae')},a11yHintLabelingLandmarks=e=>{"string"==typeof e&&""!==e||a11yHint("Manche Strukturelemente, wie bspw. der nav-Tag, können mehrfach in einer Webseite verwendet werden. Damit die gleichnamigen Strukturelemente voneinander unterschieden werden können, ist es erforderlich ein Aria-Label zu setzen.\n- https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/Navigation_Role#accessibility_concerns")},uiUxHintMillerscheZahl=(e,t=8)=>{var o;t>7&&(o=`[${e}] Innerhalb von Navigationsstrukturen wird empfohlen nicht mehr als 7 Menüpunkte zu verwenden.\n\nLinks:\n- https://de.ryte.com/wiki/Millersche_Zahl\n- https://de.wikipedia.org/wiki/Millersche_Zahl`,!1===uiUxCache.has(o)&&(uiUxCache.add(o),Log.debug(o,{classifier:"📑ui/ux",overwriteStyle:"; background-color: #060;"})))},OBJECT_OBJECT=/\[object Object\]/,objectObjectHandler=(e,t)=>{"string"==typeof e&&OBJECT_OBJECT.test(e)||t()},emptyStringByArrayHandler=(e,t)=>{"string"==typeof e&&""===e||t()},setEventTargetAndStopPropagation=(e,t)=>{getExperimalMode()&&(console.log(e,t),devHint("↑ We propagate the (submit) event to this target.")),Object.defineProperty(e,"target",{value:t,writable:!1})},patchState=e=>{var t,o,n;null===(t=e.nextHooks)||void 0===t||t.forEach(((t,o)=>{var n;const r=t.get("beforePatch");"function"==typeof r&&r(null===(n=e.nextState)||void 0===n?void 0:n.get(o),e.nextState,e,o)})),(null===(o=e.nextState)||void 0===o?void 0:o.size)>0&&(e.state=Object.assign(Object.assign({},e.state),Object.fromEntries(e.nextState)),delete e.nextState,null===(n=e.nextHooks)||void 0===n||n.forEach(((t,o)=>{const n=t.get("afterPatch");"function"==typeof n&&n(e.state[o],e.state,e,o)}))),delete e.nextHooks},setState=(e,t,o,n={})=>{var r,i;if(void 0===e.nextHooks&&(e.nextHooks=new Map),void 0===e.nextState&&(e.nextState=new Map),e.nextState.get(t)!==o){e.nextHooks.get(t)instanceof Map==!1&&e.nextHooks.set(t,new Map),"function"==typeof n.afterPatch&&(null===(r=e.nextHooks.get(t))||void 0===r||r.set("afterPatch",n.afterPatch)),"function"==typeof n.beforePatch&&(null===(i=e.nextHooks.get(t))||void 0===i||i.set("beforePatch",n.beforePatch)),e.nextState.set(t,o),patchState(e)}},logWarn=(e,t,o,n)=>{devHint(`[${e.constructor.name}] Der Property-Wert (${o}) für '${t}' ist nicht valide. Folgende Werte sind erlaubt: ${Array.from(n).join(", ")}`)},watchValidator=(e,t,o,n,r,i={})=>{o(r)?setState(e,t,r,null==i?void 0:i.hooks):void 0===r||null===r&&(void 0===(null==i?void 0:i.required)||!1===(null==i?void 0:i.required))?setState(e,t,null==i?void 0:i.defaultValue,null==i?void 0:i.hooks):(void 0!==(null==i?void 0:i.required)&&!1!==(null==i?void 0:i.required)||n.add(null),logWarn(e,t,r,n))},watchBoolean=(e,t,o,n)=>{watchValidator(e,t,(e=>"boolean"==typeof e),new Set(["Boolean {true, false}"]),o,n)},watchString=(e,t,o,n={})=>{const r="number"==typeof n.minLength?null==n?void 0:n.minLength:0;watchValidator(e,t,(e=>"string"==typeof e&&e.length>=r),new Set([`String (Mindestlänge ${r})`]),o,n)},watchNumber=(e,t,o,n)=>{watchValidator(e,t,(e=>"number"==typeof e&&(void 0===(null==n?void 0:n.min)||"number"==typeof(null==n?void 0:n.min)&&e>=n.min)&&(void 0===(null==n?void 0:n.max)||"number"==typeof(null==n?void 0:n.max)&&e<=n.max)),new Set(["Number"]),o,n)},watchJsonArrayString=(e,t,o,n,r=(e=>e==e),i={})=>{emptyStringByArrayHandler(n,(()=>{objectObjectHandler(n,(()=>{void 0===n&&(n=[]);try{try{n=parseJson(n)}catch(e){}if(Array.isArray(n)){const l=n.find((e=>!o(e)));void 0===l&&r(n)?setState(e,t,n,i.hooks):objectObjectHandler(l,(()=>{throw console.log(l),new Error("↑ Das Schema für das Property (_options) ist nicht valide. Der Wert wird nicht geändert.")}))}else objectObjectHandler(n,(()=>{throw console.log(n),new Error("↑ Das Schema für das Property (_options) ist nicht valide. Der Wert wird nicht geändert.")}))}catch(e){devHint("Known bug: Zeichenkettenliste (string[])")}}))}))},BOOLEAN=/^(true|false)$/,INTEGER=/^-?(0|[1-9]\d*)$/,FLOAT=/^-?(0.|[1-9]\d*.)\d*[1-9]$/,mapString2Unknown=e=>{const t=typeof e,o=`${e}`;if("string"==typeof e)if(BOOLEAN.test(e))e="true"===e;else if(INTEGER.test(e))e=parseInt(e);else if(FLOAT.test(e))e=parseFloat(e);else if(JSON_CHARS.test(e))try{e=parseJson(e)}catch(e){}return t!==typeof e&&devHint(`You have used a stringified property value (${o} to ${JSON.stringify(e)}) which type switched from ${t} to ${typeof e}!`),e},stringifyJson=e=>{try{return JSON.stringify(e).replace(/"/g,"'")}catch(t){throw Log.warn(["stringifyJson",e]),Log.error("↑ Das JSON konnte nicht in einen String umgewandelt werden. Es wird ein stringifizierbares JSON erwartet."),new Error}},JSON_CHARS=/^[{[]/,parseJson=e=>{if("string"==typeof e)try{return JSON.parse(e)}catch(t){if(JSON_CHARS.test(e))try{return JSON.parse(e.replace(/'/g,'"'))}catch(t){Log.warn(["parseJson",e]),Log.error("↑ Der JSON-String konnte nicht geparsed werden. Achten Sie darauf, dass einfache Anführungszeichen im Text maskiert werden (‘).")}}throw new Error},mapBoolean2String=e=>"boolean"==typeof e?!0===e?"true":"false":void 0,mapStringOrBoolean2String=e=>"string"==typeof e?e:mapBoolean2String(e),koliBriQuerySelector=(e,t)=>querySelector(e,t||getDocument()),koliBriQuerySelectorAll=(e,t)=>querySelectorAll(e,t||getDocument());let DEFAULT_COLOR_CONTRAST=null;const getDefaultColorContrast=()=>(DEFAULT_COLOR_CONTRAST=DEFAULT_COLOR_CONTRAST||{backgroundColor:"#00000000",color:"#00000000",domNode:getDocument().body,level:"Fail",score:1},DEFAULT_COLOR_CONTRAST),TRANSPARENT_REGEXP=/(\d+, ){3}0\)/,koliBriA11yColorContrast=(e,t=getDefaultColorContrast())=>{const o=getComputedStyle(e),n=TRANSPARENT_REGEXP.test(o.backgroundColor)?t.backgroundColor:rgbaConvert.hex(o.backgroundColor),r=TRANSPARENT_REGEXP.test(o.color)?t.color:rgbaConvert.hex(o.color),i=s(n,r),l={backgroundColor:n,color:r,domNode:e,level:f(i),score:i};return i<4.5&&Log.error(["Color-Contrast-Error",{backgroundColor:l.backgroundColor,color:l.color,level:l.level,score:l.score},l.domNode]),l},koliBriQuerySelectorColors=(e,t=getDefaultColorContrast())=>{t.domNode instanceof HTMLElement&&(t=koliBriA11yColorContrast(t.domNode,t));const o=t.domNode.querySelector(e);if(null===o){const o=t.domNode.querySelectorAll('[class="hydrated"]');for(let n=0;n<o.length&&(t.domNode=o[n],null===(t=koliBriQuerySelectorColors(e,t)).domNode);n++);return t}return koliBriA11yColorContrast(o,t)},scrollByHTMLElement=(e,t=window)=>{e instanceof HTMLElement?(t.scrollTo({behavior:"smooth",top:e.getBoundingClientRect().top+getWindow().pageYOffset-50}),e.focus()):devHint("Das HTMLElement ist nicht valide, zu dem gescrollt werden soll.")},scrollBySelector=(e,t)=>{if((e instanceof Document||e instanceof HTMLElement||e instanceof ShadowRoot)&&"string"==typeof t){devHint("Bei der Methode querySelectorAll wurden die Parameter document, selector in selector, document getauscht, da der Parameter selector nicht, allerdings der Parameter document optional sein kann.");const o=`${t}`;t=e,e=o}if("string"==typeof e){const o=koliBriQuerySelector(e,t);o instanceof HTMLElement?scrollByHTMLElement(o):devHint(`Es konnte kein HTMLElement mit dem Selector (${e}) gefunden werden, zu dem gescrollt werden soll.`)}else devHint("Der Selector ist nicht valide, zu dem gescrollt werden soll.")};class KoliBriUtils{static queryHtmlElementColors(e,t,o=!1,n=!0){let r=null;if(!0===o||!1===KoliBriUtils.executionLock)if(!1===o&&(KoliBriUtils.cache.clear(),KoliBriUtils.cache.set(t.domNode,t),KoliBriUtils.executionLock=!0,!0===n&&Log.debug("[KoliBriUtils] Color contrast analysis started...")),e===t.domNode)r=t;else{const o=new Set;if(t.domNode.shadowRoot){const e=t.domNode.shadowRoot.children;for(let t=0;t<e.length;t++)o.add(e[t])}const n=t.domNode;if("function"==typeof n.assignedNodes){const e=n.assignedNodes();for(let t=0;t<e.length;t++)e[t]instanceof HTMLElement&&o.add(e[t])}const i=t.domNode.children;for(let e=0;e<i.length;e++)o.add(i[e]);const l=Array.from(o);for(let o=0;o<l.length;o++){let n=KoliBriUtils.cache.get(l[o]);void 0===n&&(n=koliBriA11yColorContrast(l[o],t)),KoliBriUtils.cache.set(l[o],n);const i=KoliBriUtils.queryHtmlElementColors(e,n,!0,!1);if(null!==i){r=i;break}}}else Log.debug("[KoliBriUtils] Call aborted because a color contrast analysis is currently being executed.");return!1===o&&(!0===n&&Log.debug(`[KoliBriUtils] Color contrast analysis finished (${KoliBriUtils.cache.size} DOM elements are analysed).`),KoliBriUtils.executionLock=!1,KoliBriUtils.cache.clear()),r}}KoliBriUtils.executionLock=!1,KoliBriUtils.cache=new Map;class KoliBriDevHelper{}KoliBriDevHelper.patchTheme=patchTheme,KoliBriDevHelper.patchThemeTag=patchThemeTag,KoliBriDevHelper.querySelector=koliBriQuerySelector,KoliBriDevHelper.querySelectorAll=koliBriQuerySelectorAll,KoliBriDevHelper.scrollByHTMLElement=scrollByHTMLElement,KoliBriDevHelper.scrollBySelector=scrollBySelector,KoliBriDevHelper.stringifyJson=stringifyJson;export{mapBoolean2String as A,a11yHintDisabled as B,scrollBySelector as C,mapString2Unknown as D,initKoliBri as E,getDevMode as F,renderDevAdvice as G,getColorContrastAnalysis as H,KoliBriUtils as I,koliBriA11yColorContrast as J,KoliBriDevHelper as K,Log as L,KoliBri as M,koliBriQuerySelectorAll as N,koliBriQuerySelectorColors as O,stringifyJson as P,ToasterService as T,setState as a,watchBoolean as b,configKoliBri as c,devHint as d,a11yHintLabelingLandmarks as e,featureHint as f,getThemeDetails as g,deprecatedHint as h,watchValidator as i,watchJsonArrayString as j,watchNumber as k,getKoliBri as l,emptyStringByArrayHandler as m,nonce as n,objectObjectHandler as o,parseJson as p,koliBriQuerySelector as q,rgbaConvert as r,setThemeStyle as s,a11yHint as t,uiUxHintMillerscheZahl as u,setEventTargetAndStopPropagation as v,watchString as w,getExperimalMode as x,getDocument as y,mapStringOrBoolean2String as z};
|
|
4
|
+
import{s,f}from"./index.m.js";class ModalService{constructor(){this.lockedElements=new Map,this.modalStack=new Map}lockElement(e){const t=e.getAttribute("tabindex");(e instanceof HTMLAnchorElement||e instanceof HTMLButtonElement||e instanceof HTMLInputElement||e instanceof HTMLSelectElement||e instanceof HTMLTextAreaElement||"string"==typeof t||void 0!==e.dataset.kolModal)&&("string"==typeof t?this.lockedElements.set(e,{tabIndex:t}):this.lockedElements.set(e,{}),e.setAttribute("tabindex","-1"),e.setAttribute("aria-hidden","true"),e.style.userSelect="none")}unlockElement(e,t){"string"==typeof e.tabIndex?t.setAttribute("tabindex",e.tabIndex):t.removeAttribute("tabindex"),t.removeAttribute("aria-hidden"),t.style.userSelect="unset",this.lockedElements.delete(t)}unlockLockedElements(e){e.forEach(this.unlockElement.bind(this))}lockFocus(e,t){if(e!==t&&(e instanceof HTMLElement||e instanceof ShadowRoot)){e instanceof HTMLElement&&(this.lockElement(e),this.lockFocus(e.shadowRoot,t));for(let o=0;o<e.children.length;o++)this.lockFocus(e.children[o],t)}}renderModalIfExists(e){if(e instanceof HTMLElement){this.lockedElements.has(e)&&this.unlockElement(this.lockedElements.get(e),e);const t=setTimeout((()=>{clearTimeout(t),e.focus()}),500)}if(this.unlockLockedElements(this.lockedElements),this.modalStack.size>0){const e=Array.from(this.modalStack.keys()),t=e[e.length-1];this.modalStack.forEach(((e,o)=>{o.style.display=t===o?"inline":"none"})),getDocument().body.style.maxHeight="100vh",getDocument().body.style.overflow="hidden",this.lockFocus(getDocument().body,t)}else getDocument().body.style.maxHeight="unset",getDocument().body.style.overflow="unset"}openModal(e,t){e instanceof HTMLElement==!1?Log.warn("[KolModalService] Die DOM-Referenz des Modals ist nicht valide."):(this.modalStack.set(e,{activeElement:t}),this.renderModalIfExists())}closeModal(e){var t;if(e instanceof HTMLElement==!1)Log.warn("[KolModalService] Die DOM-Referenz des Modals ist nicht valide.");else{const o=null===(t=this.modalStack.get(e))||void 0===t?void 0:t.activeElement;this.modalStack.delete(e),this.renderModalIfExists(o)}}}class ToasterService{constructor(e){this.document=e,this.queue=new Set,this.isOpen=!1,this.toastElement=this.document.createElement("kol-toast"),this.toastElement.setAttribute("_level","3"),this.toastElement.setAttribute("_show","false"),this.toastElement.setAttribute("_show-duration","-1"),this.toastElement.setAttribute("_has-closer","true"),this.toastElement._on={onClose:()=>{const e=this.queue.values().next();e.value?(this.queue.delete(e.value),setTimeout((()=>{this.showToast(e.value)}),200)):this.isOpen=!1}},this.document.body.insertBefore(this.toastElement,this.document.body.firstChild)}enqueue(e){this.isOpen?this.queue.add(e):this.showToast(e)}showToast(e){this.toastElement.setAttribute("_heading",e.heading),this.toastElement.setAttribute("_show","true"),this.toastElement.setAttribute("_type",e.type),this.toastElement.innerText=e.description,this.isOpen=!0}}let WINDOW=null,DOCUMENT=null;const configKoliBri=e=>{e instanceof Window?(WINDOW=e,WINDOW.document instanceof Document?DOCUMENT=e.document:console.warn("The given Window has no valid Document.")):console.warn("The given Window is not valid.")},getWindow=()=>WINDOW||"undefined"==typeof window?null:window,getDocument=()=>DOCUMENT||void 0===getWindow().document?null:getWindow().document;let META_CONFIG=null,DEV_MODE=null,EXPERIMENTAL_MODE=null,COLOR_CONTRAST_ANALYSIS=null;const getDevMode=()=>!0===DEV_MODE,getExperimalMode=()=>!0===EXPERIMENTAL_MODE,getColorContrastAnalysis=()=>!0===COLOR_CONTRAST_ANALYSIS;class Log{static mapToArray(e){return Array.isArray(e)?e:[e]}static handleClassifier(e){return"string"==typeof e&&e.length>0?`${Log.shield.label} | ${e}`:Log.shield.label}static getShield(e){return[Log.handleClassifier(null==e?void 0:e.classifier),`${Log.shield.style};${(null==e?void 0:e.overwriteStyle)||""}`]}static debug(e,t){(DEV_MODE||!0===(null==t?void 0:t.forceLog))&&console.log(...Log.getShield(t),...Log.mapToArray(e))}static info(e,t){(DEV_MODE||!0===(null==t?void 0:t.forceLog))&&console.info(...Log.getShield(t),...Log.mapToArray(e))}static trace(e,t){(DEV_MODE||!0===(null==t?void 0:t.forceLog))&&console.trace(...Log.getShield(t),...Log.mapToArray(e))}static warn(e,t){(DEV_MODE||!0===(null==t?void 0:t.forceLog))&&console.warn(...Log.getShield(t),...Log.mapToArray(e))}static error(e,t){(DEV_MODE||!0===(null==t?void 0:t.forceLog))&&console.error(...Log.getShield(t),...Log.mapToArray(e))}static throw(e,t){if(DEV_MODE||!0===(null==t?void 0:t.forceLog))throw new Error(...Log.getShield(t),...Log.mapToArray(e))}}Log.shield={label:"%cKoliBri",style:"color: white; background: #666; font-weight: bold; padding: .25em .5em; border-radius: 3px; border: 1px solid #000"};const initMeta=()=>{if(null===DEV_MODE&&null===EXPERIMENTAL_MODE&&null===COLOR_CONTRAST_ANALYSIS){const e=getDocument().querySelector('meta[name="kolibri"]');e&&e.hasAttribute("content")&&(META_CONFIG=e.getAttribute("content"),"string"==typeof META_CONFIG&&(DEV_MODE=META_CONFIG.includes("dev-mode=true"),EXPERIMENTAL_MODE=META_CONFIG.includes("experimental-mode=true"),COLOR_CONTRAST_ANALYSIS=META_CONFIG.includes("color-contrast-analysis=true")))}else console.warn("You can only initialize DEV_MODE and COLOR_CONTRAST_ANALYSIS once.")};let KoliBri=null;const getKoliBri=()=>KoliBri||{},initKoliBri=()=>{if(null===KoliBri){KoliBri=getWindow().KoliBri||{};const e=new ModalService,t=new ToasterService(getDocument());Object.defineProperty(KoliBri,"Modal",{get:function(){return e}}),Object.defineProperty(KoliBri,"Toaster",{get:function(){return t}}),initMeta()}else console.warn("You can only initialize KoliBri once.")},renderDevAdvice=()=>{void 0===getWindow().KoliBri&&Object.defineProperty(window,"KoliBri",{get:function(){return KoliBri}}),!0!==getKoliBri().adviceShown&&(Object.defineProperty(KoliBri,"adviceShown",{get:function(){return!0}}),Log.debug("\n\nSie verwenden die KoliBri-Komponenten-Bibliothek. Sollten Sie Verbesserungsvorschläge haben oder ein Problem feststellen, dann wenden Sie sich gerne an kolibri@itzbund.de.\n\nHinweise:\n- WAI Web Accessibility Tutorials (https://www.w3.org/WAI/tutorials/)\n- The first rule of ARIA is “Don't use ARIA” (https://cccaccessibility.org/web-1/web-developer-tutorials/how-not-to-use-aria)\n- BIK BITV-Test (https://www.bitvtest.de/bitv_test.html)\n- A11y-Checkliste (https://www.a11yproject.com/checklist/)\n- BSI CON.10: Entwicklung von Webanwendungen (Edition 2021)\n\n"))};let nonce=()=>Math.floor(16777215*Math.random()).toString(16);var commonjsGlobal="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function createCommonjsModule(e,t,o){return e(o={path:t,exports:{},require:function(e,t){return commonjsRequire()}},o.exports),o.exports}function commonjsRequire(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}var loglevel=createCommonjsModule((function(e){var t,o;t=commonjsGlobal,o=function(){var e=function(){},t="undefined",o=typeof window!==t&&typeof window.navigator!==t&&/Trident\/|MSIE /.test(window.navigator.userAgent),n=["trace","debug","info","warn","error"];function r(e,t){var o=e[t];if("function"==typeof o.bind)return o.bind(e);try{return Function.prototype.bind.call(o,e)}catch(t){return function(){return Function.prototype.apply.apply(o,[e,arguments])}}}function i(){console.log&&(console.log.apply?console.log.apply(console,arguments):Function.prototype.apply.apply(console.log,[console,arguments])),console.trace&&console.trace()}function l(n){return"debug"===n&&(n="log"),typeof console!==t&&("trace"===n&&o?i:void 0!==console[n]?r(console,n):void 0!==console.log?r(console,"log"):e)}function a(t,o){for(var r=0;r<n.length;r++){var i=n[r];this[i]=r<t?e:this.methodFactory(i,t,o)}this.log=this.debug}function s(e,o,n){return function(){typeof console!==t&&(a.call(this,o,n),this[e].apply(this,arguments))}}function c(e,t,o){return l(e)||s.apply(this,arguments)}function d(e,o,r){var i,l=this;o=null==o?"WARN":o;var s="loglevel";function d(){var e;if(typeof window!==t&&s){try{e=window.localStorage[s]}catch(e){}if(typeof e===t)try{var o=window.document.cookie,n=o.indexOf(encodeURIComponent(s)+"=");-1!==n&&(e=/^([^;]+)/.exec(o.slice(n))[1])}catch(e){}return void 0===l.levels[e]&&(e=void 0),e}}"string"==typeof e?s+=":"+e:"symbol"==typeof e&&(s=void 0),l.name=e,l.levels={TRACE:0,DEBUG:1,INFO:2,WARN:3,ERROR:4,SILENT:5},l.methodFactory=r||c,l.getLevel=function(){return i},l.setLevel=function(o,r){if("string"==typeof o&&void 0!==l.levels[o.toUpperCase()]&&(o=l.levels[o.toUpperCase()]),!("number"==typeof o&&o>=0&&o<=l.levels.SILENT))throw"log.setLevel() called with invalid level: "+o;if(i=o,!1!==r&&function(e){var o=(n[e]||"silent").toUpperCase();if(typeof window!==t&&s){try{return void(window.localStorage[s]=o)}catch(e){}try{window.document.cookie=encodeURIComponent(s)+"="+o+";"}catch(e){}}}(o),a.call(l,o,e),typeof console===t&&o<l.levels.SILENT)return"No console available for logging"},l.setDefaultLevel=function(e){o=e,d()||l.setLevel(e,!1)},l.resetLevel=function(){l.setLevel(o,!1),function(){if(typeof window!==t&&s){try{return void window.localStorage.removeItem(s)}catch(e){}try{window.document.cookie=encodeURIComponent(s)+"=; expires=Thu, 01 Jan 1970 00:00:00 UTC"}catch(e){}}}()},l.enableAll=function(e){l.setLevel(l.levels.TRACE,e)},l.disableAll=function(e){l.setLevel(l.levels.SILENT,e)};var u=d();null==u&&(u=o),l.setLevel(u,!1)}var u=new d,h={};u.getLogger=function(e){if("symbol"!=typeof e&&"string"!=typeof e||""===e)throw new TypeError("You must supply a name when creating a logger.");var t=h[e];return t||(t=h[e]=new d(e,u.getLevel(),u.methodFactory)),t};var f=typeof window!==t?window.log:void 0;return u.noConflict=function(){return typeof window!==t&&window.log===u&&(window.log=f),u},u.getLoggers=function(){return h},u.default=u,u},e.exports?e.exports=o():t.log=o()}));const STORE="object"==typeof window?window:"object"==typeof global?global:"object"==typeof self?self:{};let warrentyWarning=!1;const THEME_NAME_PATTERN=/^[a-z][a-z0-9]{1,}(-[a-z0-9]+)?$/,isThemeNameValid=e=>"string"==typeof e&&THEME_NAME_PATTERN.test(e),validateThemeName=e=>{if(!1===isThemeNameValid(e))throw new Error(`[Theming] The theme identifier "${"string"==typeof e?e:""}" (Type: ${typeof e}) is not valid. Please use only follow this pattern: /^[a-z][a-z0-9]{1,}(-[a-z0-9]+)?$/`)},patchThemeTag=(e,t,o)=>{validateThemeName(e),!1===warrentyWarning&&(warrentyWarning=!0,loglevel.warn(`[Theming] The theme process is locked. This means that the theme "${e}" should not be patched.\n\nimport { register } from '@a11y-ui/core';\nimport { defineCustomElements } from '...';\nimport { THEME } from '...';\n\nregister(THEME, defineCustomElements)\n\t.then(() => {\n\t\tconst htmlDivElement: HTMLDivElement | null = document.querySelector<HTMLDivElement>('div#app');\n if (htmlDivElement instanceof HTMLDivElement) {\n const root = createRoot(htmlDivElement);\n root.render(<AppComponent />);\n }\n })\n .catch(console.warn);`)),"object"==typeof STORE.A11yUi&&null!==STORE.A11yUi||(STORE.A11yUi={}),"object"!=typeof STORE.A11yUi||null===STORE.A11yUi||"object"==typeof STORE.A11yUi.Themes&&null!==STORE.A11yUi.Themes||(STORE.A11yUi.Themes={}),"object"!=typeof STORE.A11yUi||null===STORE.A11yUi||"object"!=typeof STORE.A11yUi.Themes||null===STORE.A11yUi.Themes||"object"==typeof STORE.A11yUi.Themes[e]&&null!==STORE.A11yUi.Themes[e]||(STORE.A11yUi.Themes[e]={}),"object"==typeof STORE.A11yUi&&null!==STORE.A11yUi&&"object"==typeof STORE.A11yUi.Themes&&null!==STORE.A11yUi.Themes&&"object"==typeof STORE.A11yUi.Themes[e]&&null!==STORE.A11yUi.Themes[e]&&(STORE.A11yUi.Themes[e][t]=o)},patchTheme=(e,t)=>{if(validateThemeName(e),"object"==typeof t&&null!==t){Object.getOwnPropertyNames(t).forEach((o=>{const n=t[o];"string"==typeof n&&n.length>0&&patchThemeTag(e,o,n)}))}return e},getThemeNode=e=>{if(e instanceof HTMLElement){if("string"==typeof e.dataset.theme)return e;{let t=e.parentNode;for(;t instanceof ShadowRoot;)t=t.host;return getThemeNode(t)}}return null},getEncroachCss=(e={})=>"string"==typeof e.themeEncroachCssMode&&("after"===e.themeEncroachCssMode||"before"===e.themeEncroachCssMode)&&{mode:e.themeEncroachCssMode},isTheCurrentThemeConfigValid=()=>"object"==typeof STORE.A11yUi&&null!==STORE.A11yUi&&"object"==typeof STORE.A11yUi.Theme&&null!==STORE.A11yUi.Theme&&"boolean"==typeof STORE.A11yUi.Theme.cache&&"object"==typeof STORE.A11yUi.Theme.encroachCss&&null!==typeof STORE.A11yUi.Theme.encroachCss&&"string"==typeof STORE.A11yUi.Theme.encroachCss.mode&&"string"==typeof STORE.A11yUi.Theme.name,getThemeDetails=e=>{if("object"==typeof STORE.A11yUi&&null!==STORE.A11yUi&&"object"==typeof STORE.A11yUi.Theme&&null!==STORE.A11yUi.Theme&&"boolean"==typeof STORE.A11yUi.Theme.cache&&"object"==typeof STORE.A11yUi.Theme.encroachCss&&null!==typeof STORE.A11yUi.Theme.encroachCss&&"string"==typeof STORE.A11yUi.Theme.encroachCss.mode&&"string"==typeof STORE.A11yUi.Theme.name)return STORE.A11yUi.Theme;{const t=getThemeNode(e),o={cache:!0,encroachCss:getEncroachCss(),name:null};return t instanceof HTMLElement&&(o.cache="false"!==t.dataset.themeCache,o.encroachCss=getEncroachCss(t.dataset),o.name=t.dataset.theme||null),o}},CSS_PROPERTIES_REGISTERED=new Set,CSS_STYLE_SHEETS=new Map,HTML_STYLE_ELEMENTS=new Map,REGEX_CSS_PROPERTIES=/--[^;]+/g,REGEX_SPLT_CSS_PROPERTY=/:/,getCssStyleSheet=(e,t,o)=>{if(console.log("STORE.A11yUi",JSON.parse(JSON.stringify(STORE.A11yUi)),e,t,o),!0===e&&CSS_STYLE_SHEETS.has(t)&&CSS_STYLE_SHEETS.get(t)?.has(o))return CSS_STYLE_SHEETS.get(t)?.get(o);if(!0===e&&HTML_STYLE_ELEMENTS.has(t)&&HTML_STYLE_ELEMENTS.get(t)?.has(o))return HTML_STYLE_ELEMENTS.get(t)?.get(o);if("object"==typeof STORE.A11yUi&&null!==STORE.A11yUi&&"object"==typeof STORE.A11yUi.Themes&&null!==STORE.A11yUi.Themes&&"object"==typeof STORE.A11yUi.Themes[t]&&null!==STORE.A11yUi.Themes[t]&&"string"==typeof STORE.A11yUi.Themes[t][o]){if(("GLOBAL"===o||"PROPERTIES"===o)&&!1===CSS_PROPERTIES_REGISTERED.has(t)){let e=STORE.A11yUi.Themes[t][o].match(REGEX_CSS_PROPERTIES);if(Array.isArray(e)){e=e.filter((e=>REGEX_SPLT_CSS_PROPERTY.test(e)));const o=document.createElement("style");o.innerHTML=`.${t} {${e.join(";")}}`,document.querySelector("head")?.appendChild(o)}CSS_PROPERTIES_REGISTERED.add(t)}let n;try{n=new CSSStyleSheet,"function"==typeof n.replaceSync&&n.replaceSync(STORE.A11yUi.Themes[t][o]),!0===e&&(!1===CSS_STYLE_SHEETS.has(t)&&CSS_STYLE_SHEETS.set(t,new Map),CSS_STYLE_SHEETS.get(t)?.set(o,n))}catch(e){n=document.createElement("style"),n.innerHTML=STORE.A11yUi.Themes[t][o]}return n}return null},removeStyle=e=>{for(const t of Array.from(e.childNodes)){if(!(t instanceof HTMLStyleElement&&"STYLE"===t.tagName))break;e.removeChild(t)}},GLOBAL_A11Y_STYLE="* {\n font-size: inherit;\n hyphens: auto;\n letter-spacing: inherit;\n word-break: break-word;\n word-spacing: inherit;\n}",patchAdopted=(e,t,o,n)=>{const r=new CSSStyleSheet;"function"==typeof r.replaceSync&&r.replaceSync(GLOBAL_A11Y_STYLE),o.unshift(r),t.adoptedStyleSheets=o,e.style.display=n},patchStyle=(e,t,o,n)=>{const r=document.createElement("style");r.innerHTML=GLOBAL_A11Y_STYLE,o.unshift(r);const i=t.firstChild;o.forEach((e=>{i instanceof HTMLElement?t.insertBefore(e,i):t.appendChild(e)})),e.style.display=n},setThemeStyleAfterHydrated=(e,t,o)=>{const n=t.cache,r=t.encroachCss,i=t.name||"default",l=getCssStyleSheet(n,i,"GLOBAL"),a=getCssStyleSheet(n,i,e.tagName);console.log("globalStyle",l),console.log("componentStyle",a);const s=e.shadowRoot;if(removeStyle(s),a instanceof CSSStyleSheet&&a.cssRules.length>0){const t=[],n=[...Array.from(new Set(s.adoptedStyleSheets))];!1!==r&&"before"===r?.mode&&n.forEach((e=>t.push(e))),l instanceof CSSStyleSheet&&l.cssRules.length>0&&!1===t.includes(l)&&t.push(l),a instanceof CSSStyleSheet&&a.cssRules.length>0&&!1===t.includes(a)&&t.push(a),!1!==r&&"after"===r?.mode&&n.forEach((e=>t.push(e))),patchAdopted(e,s,t,o)}else if(a instanceof HTMLStyleElement&&a.innerHTML.length>0){const t=[],n=[...Array.from(s.childNodes).filter((e=>e instanceof HTMLStyleElement&&"STYLE"===e.tagName))];!1!==r&&"before"===r?.mode&&n.forEach((e=>t.push(e))),l instanceof HTMLStyleElement&&l.innerHTML.length>0&&!1===t.includes(l)&&t.push(l),a instanceof HTMLStyleElement&&a.innerHTML.length>0&&!1===t.includes(a)&&t.push(a),patchStyle(e,s,t,o)}else e.style.display=o},waitForHydrated=(e,t,o)=>{const n=setTimeout((()=>{clearTimeout(n),e.classList.contains("hydrated")?setThemeStyleAfterHydrated(e,t,o):waitForHydrated(e,t,o)}),25)},setThemeStyle=(e,t)=>{const o=`${e.style.display}`;e.style.display="none",waitForHydrated(e,t,o)},pushNodes=(e,t)=>{t.forEach((t=>{!1===e.has(t)&&e.add(t)}))},querySelectorAll=(e,t=document)=>{if(t instanceof Document||t instanceof HTMLElement||t instanceof ShadowRoot){const o=new Set;pushNodes(o,t.querySelectorAll(e));const n=t.querySelectorAll('[class*="hydrated"]');for(let t=0;t<n.length;t++){const r=n[t].shadowRoot;pushNodes(o,querySelectorAll(e,"object"==typeof r&&null!==r?r:n[t]))}return Array.from(o)}throw new Error("The parameter document for the method querySelectorAll is not type of Document, HTMLElement or ShadowRoot.")},querySelector=(e,t=document)=>{if(t instanceof Document||t instanceof HTMLElement||t instanceof ShadowRoot){let o=t.querySelector(e);if(null===o){const n=t.querySelectorAll('[class*="hydrated"]');for(let t=0;t<n.length;t++){const r=n[t].shadowRoot;if(o=querySelector(e,"object"==typeof r&&null!==r?r:n[t]),null!==o)break}}return o}throw new Error("The parameter document for the method querySelector is not type of Document, HTMLElement or ShadowRoot.")};var rgbaConvert=arr,arr_1=arr,obj_1=obj,css_1=css,hex_1=hex,num_1=num;function arr(e){var t=parse(e);return 3==t.length?t.concat(255):(t[3]=Math.round(t[3]),t)}function obj(e){var t=parse(e);return{r:t[0],g:t[1],b:t[2],a:3==t.length?255:Math.round(t[3])}}function css(e){var t=parse(e);return 3==t.length&&t.push(255),255==t[3]?"rgb("+t[0]+", "+t[1]+", "+t[2]+")":0==t[3]?"rgba("+t[0]+", "+t[1]+", "+t[2]+", 0)":"rgba("+t[0]+", "+t[1]+", "+t[2]+", "+String(t[3]/255).substr(1)+")"}function hex(e){3==(t=parse(e)).length&&t.push(255);var t,o=255==t[3],n=num2hex(t[0]),r=num2hex(t[1]),i=num2hex(t[2]),l=isshort(n,r,i,t=num2hex(Math.round(t[3])));return o?l?"#"+n.charAt(0)+r.charAt(0)+i.charAt(0):"#"+n+r+i:l?"#"+n.charAt(0)+r.charAt(0)+i.charAt(0)+t.charAt(0):"#"+n+r+i+t}function num(e){var t=parse(e);return 3==t.length?t.push(255):t[3]=Math.round(t[3]),(t[3]<<24>>>0|t[0]<<16|t[1]<<8|t[2])>>>0}function parse(e){return"string"==typeof e?name(e=e.toLowerCase())||hex3(e)||hex6(e)||rgb(e)||rgba(e)||[0,0,0,255]:object(e)||array(e)||number(e)||[0,0,0,255]}function num2hex(e){var t=e.toString(16);return 1==t.length?"0"+t:t}function isshort(e,t,o,n){var r=["ff","00","11","22","33","44","55","66","77","88","99","aa","bb","cc","dd","ee"];return-1!=r.indexOf(e)&&-1!=r.indexOf(t)&&-1!=r.indexOf(o)&&-1!=r.indexOf(n)}function name(e){return"red"==e?[255,0,0]:"green"==e?[0,255,0]:"blue"==e?[0,0,255]:"black"==e?[0,0,0]:"white"==e?[255,255,255]:"cyan"==e?[0,255,255]:"gray"==e||"grey"==e?[128,128,128]:"magenta"==e||"pink"==e?[255,0,255]:"yellow"==e?[255,255,0]:void 0}function hex2num(e){return 1==e.length?parseInt(e+e,16):parseInt(e,16)}function hex3(e){var t=e.replace(/^#/,""),o=t.length;if(3==o||4==o){var n=hex2num(t[0]),r=hex2num(t[1]),i=hex2num(t[2]),l=3==o?255:hex2num(t[3]);if(isNaN(n)||isNaN(r)||isNaN(i)||isNaN(l))return;return[n,r,i,l]}}function hex6(e){var t=e.replace(/^#/,""),o=t.length;if(6==o||8==o){var n=hex2num(t.slice(0,2)),r=hex2num(t.slice(2,4)),i=hex2num(t.slice(4,6)),l=6==o?255:hex2num(t.slice(6,8));if(isNaN(n)||isNaN(r)||isNaN(i)||isNaN(l))return;return[n,r,i,l]}}function getnum(e,t){return"number"!=typeof e||!0===t&&Math.floor(e)!==e?-1:e>=0&&e<=255?e:-1}function object(e){if("[object Object]"===Object.prototype.toString.call(e)&&Object.getPrototypeOf(e)===Object.getPrototypeOf({})){var t=getnum(null!=e.r?e.r:null!=e.red?e.red:0,!0),o=getnum(null!=e.g?e.g:null!=e.green?e.green:0,!0),n=getnum(null!=e.b?e.b:null!=e.blue?e.blue:0,!0),r=getnum(null!=e.a?e.a:null!=e.alpha?e.alpha:255,!0);if(-1!=t&&-1!=o&&-1!=n&&-1!=r)return[t,o,n,r]}}function array(e){if(Array.isArray(e)&&(3==e.length||4==e.length)){var t=getnum(e[0],!0),o=getnum(e[1],!0),n=getnum(e[2],!0),r=getnum(null!=e[3]?e[3]:255,!0);if(-1!=t&&-1!=o&&-1!=n&&-1!=r)return[t,o,n,r]}}function number(e){if("number"==typeof e&&Math.floor(e)==e&&e<=4294967295&&e>=0)return[e>>16&255,e>>8&255,255&e,e>>24&255]}function rgb(e){if("rgb("==e.substr(0,4)){var t=(e=e.match(/^rgb\(([^)]+)\)/)[1]).split(/ *, */).map(Number),o=getnum(t[0],!0),n=getnum(t[1],!0),r=getnum(t[2],!0);if(-1!=o&&-1!=n&&-1!=r)return[o,n,r,255]}}function rgba(e){if("rgba("==e.substr(0,5)){var t=(e=e.match(/^rgba\(([^)]+)\)/)[1]).split(/ *, */).map(Number),o=getnum(t[0],!0),n=getnum(t[1],!0),r=getnum(t[2],!0),i=getnum(255*t[3]);if(-1!=o&&-1!=n&&-1!=r&&-1!=i)return[o,n,r,i]}}rgbaConvert.arr=arr_1,rgbaConvert.obj=obj_1,rgbaConvert.css=css_1,rgbaConvert.hex=hex_1,rgbaConvert.num=num_1;const a11yCache=new Set,a11yHint=e=>{!1===a11yCache.has(e)&&(a11yCache.add(e),Log.info(e,{classifier:"✋a11y",overwriteStyle:"; background-color: #09f"}))},deprecatedCache=new Set,deprecatedHint=e=>{!1===deprecatedCache.has(e)&&(deprecatedCache.add(e),Log.warn(e,{classifier:"🔥deprecated",forceLog:!0,overwriteStyle:"; background-color: #f00"}))},devCache=new Set,devHint=e=>{!1===devCache.has(e)&&(devCache.add(e),Log.debug(e,{classifier:"💻dev",overwriteStyle:"; background-color: #f09"}))},featureCache=new Set,featureHint=(e,t=!1)=>{!1===featureCache.has(e)&&(featureCache.add(e),e+=!0===t?" ✅":"",Log.debug(e,{classifier:"🌟feature",overwriteStyle:"; background-color: #309"}))};devHint("Wir freuen uns über jedes Feedback, Kommentare, Screenshots oder Demo-Links von einer auf KoliBri-basierenden Anwendung (kolibri@itzbund.de). Vielen Dank!");const uiUxCache=new Set,uiUxHint=e=>{!1===uiUxCache.has(e)&&(uiUxCache.add(e),Log.debug(e,{classifier:"📑ui/ux",overwriteStyle:"; background-color: #060;"}))},a11yHintDisabled=()=>{a11yHint('"Disabled" schränkt die Zugänglichkeit und Sichtbarkeit ein. Wir empfehlen aus Sicht der Barrierefreiheit readonly- statt disabled-Attribut zu verwenden.\n- https://uxdesign.cc/is-it-ok-to-grey-out-disabled-buttons-8afa74a0fae')},a11yHintLabelingLandmarks=e=>{"string"==typeof e&&""!==e||a11yHint("Manche Strukturelemente, wie bspw. der nav-Tag, können mehrfach in einer Webseite verwendet werden. Damit die gleichnamigen Strukturelemente voneinander unterschieden werden können, ist es erforderlich ein Aria-Label zu setzen.\n- https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/Navigation_Role#accessibility_concerns")},uiUxHintMillerscheZahl=(e,t=8)=>{var o;t>7&&(o=`[${e}] Innerhalb von Navigationsstrukturen wird empfohlen nicht mehr als 7 Menüpunkte zu verwenden.\n\nLinks:\n- https://de.ryte.com/wiki/Millersche_Zahl\n- https://de.wikipedia.org/wiki/Millersche_Zahl`,!1===uiUxCache.has(o)&&(uiUxCache.add(o),Log.debug(o,{classifier:"📑ui/ux",overwriteStyle:"; background-color: #060;"})))},OBJECT_OBJECT=/\[object Object\]/,objectObjectHandler=(e,t)=>{"string"==typeof e&&OBJECT_OBJECT.test(e)||t()},emptyStringByArrayHandler=(e,t)=>{"string"==typeof e&&""===e||t()},setEventTargetAndStopPropagation=(e,t)=>{getExperimalMode()&&(console.log(e,t),devHint("↑ We propagate the (submit) event to this target.")),Object.defineProperty(e,"target",{value:t,writable:!1})},patchState=e=>{var t,o,n;null===(t=e.nextHooks)||void 0===t||t.forEach(((t,o)=>{var n;const r=t.get("beforePatch");"function"==typeof r&&r(null===(n=e.nextState)||void 0===n?void 0:n.get(o),e.nextState,e,o)})),(null===(o=e.nextState)||void 0===o?void 0:o.size)>0&&(e.state=Object.assign(Object.assign({},e.state),Object.fromEntries(e.nextState)),delete e.nextState,null===(n=e.nextHooks)||void 0===n||n.forEach(((t,o)=>{const n=t.get("afterPatch");"function"==typeof n&&n(e.state[o],e.state,e,o)}))),delete e.nextHooks},setState=(e,t,o,n={})=>{var r,i;if(void 0===e.nextHooks&&(e.nextHooks=new Map),void 0===e.nextState&&(e.nextState=new Map),e.nextState.get(t)!==o){e.nextHooks.get(t)instanceof Map==!1&&e.nextHooks.set(t,new Map),"function"==typeof n.afterPatch&&(null===(r=e.nextHooks.get(t))||void 0===r||r.set("afterPatch",n.afterPatch)),"function"==typeof n.beforePatch&&(null===(i=e.nextHooks.get(t))||void 0===i||i.set("beforePatch",n.beforePatch)),e.nextState.set(t,o),patchState(e)}},logWarn=(e,t,o,n)=>{devHint(`[${e.constructor.name}] Der Property-Wert (${o}) für '${t}' ist nicht valide. Folgende Werte sind erlaubt: ${Array.from(n).join(", ")}`)},watchValidator=(e,t,o,n,r,i={})=>{o(r)?setState(e,t,r,null==i?void 0:i.hooks):void 0===r||null===r&&(void 0===(null==i?void 0:i.required)||!1===(null==i?void 0:i.required))?setState(e,t,null==i?void 0:i.defaultValue,null==i?void 0:i.hooks):(void 0!==(null==i?void 0:i.required)&&!1!==(null==i?void 0:i.required)||n.add(null),logWarn(e,t,r,n))},watchBoolean=(e,t,o,n)=>{watchValidator(e,t,(e=>"boolean"==typeof e),new Set(["Boolean {true, false}"]),o,n)},watchString=(e,t,o,n={})=>{const r="number"==typeof n.minLength?null==n?void 0:n.minLength:0;watchValidator(e,t,(e=>"string"==typeof e&&e.length>=r),new Set([`String (Mindestlänge ${r})`]),o,n)},watchNumber=(e,t,o,n)=>{watchValidator(e,t,(e=>"number"==typeof e&&(void 0===(null==n?void 0:n.min)||"number"==typeof(null==n?void 0:n.min)&&e>=n.min)&&(void 0===(null==n?void 0:n.max)||"number"==typeof(null==n?void 0:n.max)&&e<=n.max)),new Set(["Number"]),o,n)},watchJsonArrayString=(e,t,o,n,r=(e=>e==e),i={})=>{emptyStringByArrayHandler(n,(()=>{objectObjectHandler(n,(()=>{void 0===n&&(n=[]);try{try{n=parseJson(n)}catch(e){}if(Array.isArray(n)){const l=n.find((e=>!o(e)));void 0===l&&r(n)?setState(e,t,n,i.hooks):objectObjectHandler(l,(()=>{throw console.log(l),new Error("↑ Das Schema für das Property (_options) ist nicht valide. Der Wert wird nicht geändert.")}))}else objectObjectHandler(n,(()=>{throw console.log(n),new Error("↑ Das Schema für das Property (_options) ist nicht valide. Der Wert wird nicht geändert.")}))}catch(e){devHint("Known bug: Zeichenkettenliste (string[])")}}))}))},BOOLEAN=/^(true|false)$/,INTEGER=/^-?(0|[1-9]\d*)$/,FLOAT=/^-?(0.|[1-9]\d*.)\d*[1-9]$/,mapString2Unknown=e=>{const t=typeof e,o=`${e}`;if("string"==typeof e)if(BOOLEAN.test(e))e="true"===e;else if(INTEGER.test(e))e=parseInt(e);else if(FLOAT.test(e))e=parseFloat(e);else if(JSON_CHARS.test(e))try{e=parseJson(e)}catch(e){}return t!==typeof e&&devHint(`You have used a stringified property value (${o} to ${JSON.stringify(e)}) which type switched from ${t} to ${typeof e}!`),e},stringifyJson=e=>{try{return JSON.stringify(e).replace(/"/g,"'")}catch(t){throw Log.warn(["stringifyJson",e]),Log.error("↑ Das JSON konnte nicht in einen String umgewandelt werden. Es wird ein stringifizierbares JSON erwartet."),new Error}},JSON_CHARS=/^[{[]/,parseJson=e=>{if("string"==typeof e)try{return JSON.parse(e)}catch(t){if(JSON_CHARS.test(e))try{return JSON.parse(e.replace(/'/g,'"'))}catch(t){Log.warn(["parseJson",e]),Log.error("↑ Der JSON-String konnte nicht geparsed werden. Achten Sie darauf, dass einfache Anführungszeichen im Text maskiert werden (‘).")}}throw new Error},mapBoolean2String=e=>"boolean"==typeof e?!0===e?"true":"false":void 0,mapStringOrBoolean2String=e=>"string"==typeof e?e:mapBoolean2String(e),koliBriQuerySelector=(e,t)=>querySelector(e,t||getDocument()),koliBriQuerySelectorAll=(e,t)=>querySelectorAll(e,t||getDocument());let DEFAULT_COLOR_CONTRAST=null;const getDefaultColorContrast=()=>(DEFAULT_COLOR_CONTRAST=DEFAULT_COLOR_CONTRAST||{backgroundColor:"#00000000",color:"#00000000",domNode:getDocument().body,level:"Fail",score:1},DEFAULT_COLOR_CONTRAST),TRANSPARENT_REGEXP=/(\d+, ){3}0\)/,koliBriA11yColorContrast=(e,t=getDefaultColorContrast())=>{const o=getComputedStyle(e),n=TRANSPARENT_REGEXP.test(o.backgroundColor)?t.backgroundColor:rgbaConvert.hex(o.backgroundColor),r=TRANSPARENT_REGEXP.test(o.color)?t.color:rgbaConvert.hex(o.color),i=s(n,r),l={backgroundColor:n,color:r,domNode:e,level:f(i),score:i};return i<4.5&&Log.error(["Color-Contrast-Error",{backgroundColor:l.backgroundColor,color:l.color,level:l.level,score:l.score},l.domNode]),l},koliBriQuerySelectorColors=(e,t=getDefaultColorContrast())=>{t.domNode instanceof HTMLElement&&(t=koliBriA11yColorContrast(t.domNode,t));const o=t.domNode.querySelector(e);if(null===o){const o=t.domNode.querySelectorAll('[class="hydrated"]');for(let n=0;n<o.length&&(t.domNode=o[n],null===(t=koliBriQuerySelectorColors(e,t)).domNode);n++);return t}return koliBriA11yColorContrast(o,t)},scrollByHTMLElement=(e,t=window)=>{e instanceof HTMLElement?(t.scrollTo({behavior:"smooth",top:e.getBoundingClientRect().top+getWindow().pageYOffset-50}),e.focus()):devHint("Das HTMLElement ist nicht valide, zu dem gescrollt werden soll.")},scrollBySelector=(e,t)=>{if((e instanceof Document||e instanceof HTMLElement||e instanceof ShadowRoot)&&"string"==typeof t){devHint("Bei der Methode querySelectorAll wurden die Parameter document, selector in selector, document getauscht, da der Parameter selector nicht, allerdings der Parameter document optional sein kann.");const o=`${t}`;t=e,e=o}if("string"==typeof e){const o=koliBriQuerySelector(e,t);o instanceof HTMLElement?scrollByHTMLElement(o):devHint(`Es konnte kein HTMLElement mit dem Selector (${e}) gefunden werden, zu dem gescrollt werden soll.`)}else devHint("Der Selector ist nicht valide, zu dem gescrollt werden soll.")};class KoliBriUtils{static queryHtmlElementColors(e,t,o=!1,n=!0){let r=null;if(!0===o||!1===KoliBriUtils.executionLock)if(!1===o&&(KoliBriUtils.cache.clear(),KoliBriUtils.cache.set(t.domNode,t),KoliBriUtils.executionLock=!0,!0===n&&Log.debug("[KoliBriUtils] Color contrast analysis started...")),e===t.domNode)r=t;else{const o=new Set;if(t.domNode.shadowRoot){const e=t.domNode.shadowRoot.children;for(let t=0;t<e.length;t++)o.add(e[t])}const n=t.domNode;if("function"==typeof n.assignedNodes){const e=n.assignedNodes();for(let t=0;t<e.length;t++)e[t]instanceof HTMLElement&&o.add(e[t])}const i=t.domNode.children;for(let e=0;e<i.length;e++)o.add(i[e]);const l=Array.from(o);for(let o=0;o<l.length;o++){let n=KoliBriUtils.cache.get(l[o]);void 0===n&&(n=koliBriA11yColorContrast(l[o],t)),KoliBriUtils.cache.set(l[o],n);const i=KoliBriUtils.queryHtmlElementColors(e,n,!0,!1);if(null!==i){r=i;break}}}else Log.debug("[KoliBriUtils] Call aborted because a color contrast analysis is currently being executed.");return!1===o&&(!0===n&&Log.debug(`[KoliBriUtils] Color contrast analysis finished (${KoliBriUtils.cache.size} DOM elements are analysed).`),KoliBriUtils.executionLock=!1,KoliBriUtils.cache.clear()),r}}KoliBriUtils.executionLock=!1,KoliBriUtils.cache=new Map;class KoliBriDevHelper{}KoliBriDevHelper.patchTheme=patchTheme,KoliBriDevHelper.patchThemeTag=patchThemeTag,KoliBriDevHelper.querySelector=koliBriQuerySelector,KoliBriDevHelper.querySelectorAll=koliBriQuerySelectorAll,KoliBriDevHelper.scrollByHTMLElement=scrollByHTMLElement,KoliBriDevHelper.scrollBySelector=scrollBySelector,KoliBriDevHelper.stringifyJson=stringifyJson;export{mapBoolean2String as A,a11yHintDisabled as B,scrollBySelector as C,mapString2Unknown as D,initKoliBri as E,getDevMode as F,renderDevAdvice as G,getColorContrastAnalysis as H,KoliBriUtils as I,koliBriA11yColorContrast as J,KoliBriDevHelper as K,Log as L,KoliBri as M,koliBriQuerySelectorAll as N,koliBriQuerySelectorColors as O,stringifyJson as P,ToasterService as T,setState as a,watchBoolean as b,configKoliBri as c,devHint as d,a11yHintLabelingLandmarks as e,featureHint as f,getThemeDetails as g,deprecatedHint as h,watchValidator as i,watchJsonArrayString as j,watchNumber as k,getKoliBri as l,emptyStringByArrayHandler as m,nonce as n,objectObjectHandler as o,parseJson as p,koliBriQuerySelector as q,rgbaConvert as r,setThemeStyle as s,a11yHint as t,uiUxHintMillerscheZahl as u,setEventTargetAndStopPropagation as v,watchString as w,getExperimalMode as x,getDocument as y,mapStringOrBoolean2String as z};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* KoliBri - The accessible HTML-Standard
|
|
3
|
+
*/
|
|
4
|
+
import{s as setThemeStyle,g as getThemeDetails}from"./index-bb963364.js";import{a as setMode}from"./index-1c88bb74.js";import{L as Log}from"./dev.utils-daaf2f39.js";const appGlobalScript=()=>{Log.info("\n,--. ,--. ,--. ,--. ,-----. ,--.\n| .' / ,---. | | `--' | |) /_ ,--.--. `--'\n| . ' | .-. | | | ,--. | .-. \\ | .--' ,--.\n| |\\ \\ | '-' | | | | | | '--' / | | | |\n`--' `--´ `---´ `--' `--' `------´ `--' `--'\n🚹 The accessible HTML-Standard | 👉 https://public-ui.github.io\n\t",{forceLog:!0}),setMode((t=>(t.shadowRoot instanceof ShadowRoot&&setThemeStyle(t,getThemeDetails(t)),"default"))),import("./devtools-f6d00261.js").then((t=>{"object"==typeof t&&null!==t&&"function"==typeof t.initialize&&t.initialize()})).catch((t=>{Log.error(t)}))},globalScripts=appGlobalScript;export{globalScripts as g};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* KoliBri - The accessible HTML-Standard
|
|
3
3
|
*/
|
|
4
|
-
import{a as watchValidator}from"./prop.validators-
|
|
4
|
+
import{a as watchValidator}from"./prop.validators-6ea5c4bf.js";const watchTooltipAlignment=(t,o,a)=>{watchValidator(t,o,(t=>"top"===t||"right"===t||"bottom"===t||"left"===t),new Set(["TooltipAlignment {top, right, buttom, left}"]),a,{defaultValue:"top"})};export{watchTooltipAlignment as w};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* KoliBri - The accessible HTML-Standard
|
|
3
3
|
*/
|
|
4
|
-
import{c as a11yHintDisabled,d as devHint}from"./a11y.tipps-ff5a1a99.js";import{b as watchBoolean,w as watchString,o as objectObjectHandler,p as parseJson,a as watchValidator,s as setState}from"./prop.validators-
|
|
4
|
+
import{c as a11yHintDisabled,d as devHint}from"./a11y.tipps-ff5a1a99.js";import{b as watchBoolean,w as watchString,o as objectObjectHandler,p as parseJson,a as watchValidator,s as setState}from"./prop.validators-6ea5c4bf.js";import{a as isString}from"./validator-8ee8737c.js";import{i as isIcon,v as validateTabIndex}from"./tab-index-4f492046.js";import{b as getExperimalMode}from"./dev.utils-daaf2f39.js";const getRenderStates=t=>{const e="string"==typeof t._error&&t._error.length>0&&!0===t._touched,o="string"==typeof t._hint&&t._hint.length>0,n=[];return!0===e&&n.push(`${t._id}-error`),!0===o&&n.push(`${t._id}-hint`),{hasError:e,hasHint:o,ariaDiscribedBy:n}},EXPERIMENTAL_MODE=getExperimalMode();class ControlledInputController{constructor(t,e,o){var n,i,a,s,h;if(this.syncFormAssociatedName=()=>{var t;EXPERIMENTAL_MODE&&(null===(t=this.formAssociated)||void 0===t||t.setAttribute("name",this.component.state._name||this.component.state._id))},this.setFormAssociatedValue=(t=null)=>{var e;EXPERIMENTAL_MODE&&(null===(e=this.formAssociated)||void 0===e||e.setAttribute("value",t))},this.component=t,this.name=e,this.host=o,EXPERIMENTAL_MODE){this.formAssociated=document.createElement("input"),this.formAssociated.setAttribute("type","hidden");const t=(null===(n=this.host)||void 0===n?void 0:n.children)||[];for(let e=0;e<t.length;e++)"INPUT"===(null===(i=this.host)||void 0===i?void 0:i.children[e].tagName)&&(null===(a=this.host)||void 0===a||a.removeChild(null===(s=this.host)||void 0===s?void 0:s.children[e]));null===(h=this.host)||void 0===h||h.appendChild(this.formAssociated)}}validateAlert(t){watchBoolean(this.component,"_alert",t)}validateTouched(t){watchBoolean(this.component,"_touched",t)}componentWillLoad(){this.validateAlert(this.component._alert),this.validateTouched(this.component._touched)}}const beforePatchIcon=(t,e)=>{const o=t;"object"==typeof o&&null!==o&&(isString(o.right,1)&&(o.right={icon:o.right}),isString(o.left,1)&&(o.left={icon:o.left}),e.set("_icon",o))};class InputController extends ControlledInputController{constructor(t,e,o){super(t,e,o),this.hideLabel=!1,this.onFacade={onBlur:this.onBlur.bind(this),onChange:this.onChange.bind(this),onClick:this.onClick.bind(this),onFocus:this.onFocus.bind(this)},this.component=t}validateAccessKey(t){watchString(this.component,"_accessKey",t)}validateAdjustHeight(t){watchBoolean(this.component,"_adjustHeight",t)}validateDisabled(t){watchBoolean(this.component,"_disabled",t),!0===t&&a11yHintDisabled()}validateError(t){watchString(this.component,"_error",t)}validateHideLabel(t){watchBoolean(this.component,"_hideLabel",t)}validateHint(t){watchString(this.component,"_hint",t)}validateIcon(t){objectObjectHandler(t,(()=>{try{t=parseJson(t)}catch(t){}watchValidator(this.component,"_icon",(t=>"object"==typeof t&&null!==t&&(isString(t.left,1)||isIcon(t.left)||isString(t.right,1)||isIcon(t.right))),new Set(["KoliBriInputIcon"]),t,{hooks:{beforePatch:beforePatchIcon},required:!0})}))}validateId(t){watchString(this.component,"_id",t,{hooks:{afterPatch:this.syncFormAssociatedName}}),void 0===t&&devHint("Eine eindeutige ID an den Eingabefeldern ist nicht zwingend erforderlich, könnte aber für die E2E-Tests relevant sein.")}validateName(t){watchString(this.component,"_name",t,{hooks:{afterPatch:this.syncFormAssociatedName}}),void 0===t&&devHint("Ein Name an den Eingabefeldern ist nicht zwingend erforderlich, kann aber für die Autocomplete-Funktion des Eingabefeldes relevant sein.")}validateOn(t){"object"==typeof t&&setState(this.component,"_on",t)}validateSmartButton(t){objectObjectHandler(t,(()=>{try{t=parseJson(t)}catch(t){}setState(this.component,"_smartButton",t)}))}validateTabIndex(t){validateTabIndex(this.component,t)}componentWillLoad(){super.componentWillLoad(),this.validateAccessKey(this.component._accessKey),this.validateAdjustHeight(this.component._adjustHeight),this.validateError(this.component._error),this.validateDisabled(this.component._disabled),this.validateHideLabel(this.component._hideLabel),this.validateHint(this.component._hint),this.validateIcon(this.component._icon),this.validateId(this.component._id),this.validateName(this.component._name),this.validateSmartButton(this.component._smartButton),this.validateOn(this.component._on),this.validateTabIndex(this.component._tabIndex),this.syncFormAssociatedName()}onBlur(t){var e;this.component._alert=!0,this.component._touched=!0,"function"==typeof(null===(e=this.component._on)||void 0===e?void 0:e.onBlur)&&this.component._on.onBlur(t)}onChange(t){var e;this.setFormAssociatedValue(t.target.value),"function"==typeof(null===(e=this.component._on)||void 0===e?void 0:e.onChange)&&this.component._on.onChange(t,t.target.value)}onClick(t){var e;"function"==typeof(null===(e=this.component._on)||void 0===e?void 0:e.onClick)&&this.component._on.onClick(t)}onFocus(t){var e;this.component._alert=!0,"function"==typeof(null===(e=this.component._on)||void 0===e?void 0:e.onFocus)&&this.component._on.onFocus(t)}setValue(t,e){var o;this.setFormAssociatedValue(e),"function"==typeof(null===(o=this.component._on)||void 0===o?void 0:o.onChange)&&this.component._on.onChange(t,e)}}export{InputController as I,getRenderStates as g};
|