@public-ui/components 4.1.0-rc.0 → 4.1.1-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/kolicons/kolicons.eot +0 -0
- package/assets/kolicons/kolicons.ttf +0 -0
- package/assets/kolicons/kolicons.woff +0 -0
- package/assets/kolicons/kolicons.woff2 +0 -0
- package/assets/kolicons/style.css +6 -6
- package/custom-elements.json +1 -1
- package/dist/cjs/{Alert-BfgtJ9NG.js → Alert-DZoC6byb.js} +1 -1
- package/dist/cjs/{Alert-BfgtJ9NG.js.map → Alert-DZoC6byb.js.map} +1 -1
- package/dist/cjs/{Collapsible-oSqY51Qj.js → Collapsible-B-ZM8-7A.js} +1 -1
- package/dist/cjs/{Collapsible-oSqY51Qj.js.map → Collapsible-B-ZM8-7A.js.map} +1 -1
- package/dist/cjs/{CustomSuggestionsOptionsGroup-BPEJMkIh.js → CustomSuggestionsOptionsGroup-CfOsFZbt.js} +1 -1
- package/dist/cjs/{CustomSuggestionsOptionsGroup-BPEJMkIh.js.map → CustomSuggestionsOptionsGroup-CfOsFZbt.js.map} +1 -1
- package/dist/cjs/{FieldControlStateWrapper-3bNGTTux.js → FieldControlStateWrapper-BjLCHRZt.js} +1 -1
- package/dist/cjs/{FieldControlStateWrapper-3bNGTTux.js.map → FieldControlStateWrapper-BjLCHRZt.js.map} +1 -1
- package/dist/cjs/{FormFieldStateWrapper-BdrkjcTv.js → FormFieldStateWrapper-yeKYlFfU.js} +1 -1
- package/dist/cjs/{FormFieldStateWrapper-BdrkjcTv.js.map → FormFieldStateWrapper-yeKYlFfU.js.map} +1 -1
- package/dist/cjs/{Heading-BQhFDauI.js → Heading-DRnE3p6n.js} +1 -1
- package/dist/cjs/{Heading-BQhFDauI.js.map → Heading-DRnE3p6n.js.map} +1 -1
- package/dist/cjs/{Icon-CYo-J1r1.js → Icon-DWUPoAzs.js} +1 -1
- package/dist/cjs/{Icon-CYo-J1r1.js.map → Icon-DWUPoAzs.js.map} +1 -1
- package/dist/cjs/{Input-DFcDqVFA.js → Input-BW0K0FOH.js} +1 -1
- package/dist/cjs/{Input-DFcDqVFA.js.map → Input-BW0K0FOH.js.map} +1 -1
- package/dist/cjs/{InputStateWrapper-xxWbdOSg.js → InputStateWrapper-CLU8Z1hM.js} +1 -1
- package/dist/cjs/{InputStateWrapper-xxWbdOSg.js.map → InputStateWrapper-CLU8Z1hM.js.map} +1 -1
- package/dist/cjs/{InternalUnderlinedBadgeText-DittwkA8.js → InternalUnderlinedBadgeText-EuIW3Q8k.js} +1 -1
- package/dist/cjs/{InternalUnderlinedBadgeText-DittwkA8.js.map → InternalUnderlinedBadgeText-EuIW3Q8k.js.map} +1 -1
- package/dist/cjs/{Span-CTYq8bm1.js → Span-AeGOE8aB.js} +1 -1
- package/dist/cjs/{Span-CTYq8bm1.js.map → Span-AeGOE8aB.js.map} +1 -1
- package/dist/cjs/{app-globals-C_axx0Yp.js → app-globals-BLH39C2T.js} +1 -1
- package/dist/cjs/{app-globals-C_axx0Yp.js.map → app-globals-BLH39C2T.js.map} +1 -1
- package/dist/cjs/base-controller-DBsJfwhu.js +4 -0
- package/dist/cjs/base-controller-DBsJfwhu.js.map +1 -0
- package/dist/cjs/{controller-QNN8Mujo.js → controller-2GlnamuC.js} +1 -1
- package/dist/cjs/{controller-QNN8Mujo.js.map → controller-2GlnamuC.js.map} +1 -1
- package/dist/cjs/{controller-DRMjQvoa.js → controller-CDjtHIAU.js} +1 -1
- package/dist/cjs/{controller-DRMjQvoa.js.map → controller-CDjtHIAU.js.map} +1 -1
- package/dist/cjs/{controller-BISWeEWi.js → controller-DtDZCXmq.js} +1 -1
- package/dist/cjs/{controller-BISWeEWi.js.map → controller-DtDZCXmq.js.map} +1 -1
- package/dist/cjs/{controller-icon-BEyVblUg.js → controller-icon-BtXBFuMR.js} +1 -1
- package/dist/cjs/{controller-icon-BEyVblUg.js.map → controller-icon-BtXBFuMR.js.map} +1 -1
- package/dist/cjs/{controller-GDbPD1pa.js → controller-qJGJm1I5.js} +1 -1
- package/dist/cjs/{controller-GDbPD1pa.js.map → controller-qJGJm1I5.js.map} +1 -1
- package/dist/cjs/{dev.utils-1NJyZFDJ.js → dev.utils-fEyHQeGr.js} +1 -1
- package/dist/cjs/{dev.utils-1NJyZFDJ.js.map → dev.utils-fEyHQeGr.js.map} +1 -1
- package/dist/cjs/{devtools-CSpZT3n0.js → devtools-DViQIp5X.js} +1 -1
- package/dist/cjs/{devtools-CSpZT3n0.js.map → devtools-DViQIp5X.js.map} +1 -1
- package/dist/cjs/{index-CixChVkT.js → index-DOJIk6hD.js} +1 -1
- package/dist/cjs/{index-CixChVkT.js.map → index-DOJIk6hD.js.map} +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-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-alert.cjs.entry.js +1 -1
- package/dist/cjs/kol-avatar.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-link.cjs.entry.js +1 -1
- package/dist/cjs/kol-button-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-button.cjs.entry.js +1 -1
- package/dist/cjs/kol-card-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-card.cjs.entry.js +1 -1
- package/dist/cjs/kol-click-button.cjs.entry.js +1 -1
- package/dist/cjs/kol-combobox.cjs.entry.js +1 -1
- package/dist/cjs/kol-details.cjs.entry.js +1 -1
- package/dist/cjs/kol-dialog-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-dialog.cjs.entry.js +1 -1
- package/dist/cjs/kol-drawer.cjs.entry.js +1 -1
- package/dist/cjs/kol-form.cjs.entry.js +1 -1
- package/dist/cjs/kol-heading.cjs.entry.js +1 -1
- package/dist/cjs/kol-icon.cjs.entry.js +1 -1
- package/dist/cjs/kol-image.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.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-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-link.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-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-pagination.cjs.entry.js +1 -1
- package/dist/cjs/kol-popover-button-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-popover-button.cjs.entry.js +1 -1
- package/dist/cjs/kol-popover-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-progress.cjs.entry.js +1 -1
- package/dist/cjs/kol-quote.cjs.entry.js +1 -1
- package/dist/cjs/kol-select-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-select.cjs.entry.js +1 -1
- package/dist/cjs/kol-single-select.cjs.entry.js +1 -1
- package/dist/cjs/kol-skeleton.cjs.entry.js +1 -1
- package/dist/cjs/kol-skip-nav.cjs.entry.js +1 -1
- package/dist/cjs/kol-spin.cjs.entry.js +1 -1
- package/dist/cjs/kol-split-button.cjs.entry.js +1 -1
- package/dist/cjs/kol-table-settings-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-table-stateful.cjs.entry.js +1 -1
- package/dist/cjs/kol-table-stateless-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-table-stateless.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-container.cjs.entry.js +1 -1
- package/dist/cjs/kol-toolbar.cjs.entry.js +1 -1
- package/dist/cjs/kol-tooltip-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-tree-item-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-tree-item.cjs.entry.js +1 -1
- package/dist/cjs/kol-tree-wc.cjs.entry.js +1 -1
- package/dist/cjs/kol-tree.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/loader.cjs.js +1 -1
- package/dist/cjs/test-component.cjs.entry.js +1 -1
- package/dist/components/base-controller.js +1 -1
- package/dist/components/base-controller.js.map +1 -1
- package/dist/components/kol-icon.js +1 -1
- package/dist/esm/{Alert-BsbKAp99.js → Alert-BNnW6X1O.js} +1 -1
- package/dist/esm/{Alert-BsbKAp99.js.map → Alert-BNnW6X1O.js.map} +1 -1
- package/dist/esm/{Collapsible-BTaZIREk.js → Collapsible-DNDdPxp5.js} +1 -1
- package/dist/esm/{Collapsible-BTaZIREk.js.map → Collapsible-DNDdPxp5.js.map} +1 -1
- package/dist/esm/{CustomSuggestionsOptionsGroup-C0pEClOW.js → CustomSuggestionsOptionsGroup-CWtO9VtS.js} +1 -1
- package/dist/{kolibri/CustomSuggestionsOptionsGroup-C0pEClOW.js.map → esm/CustomSuggestionsOptionsGroup-CWtO9VtS.js.map} +1 -1
- package/dist/esm/{FieldControlStateWrapper-BCNYRgaN.js → FieldControlStateWrapper-Bn5LNh4e.js} +1 -1
- package/dist/{kolibri/FieldControlStateWrapper-BCNYRgaN.js.map → esm/FieldControlStateWrapper-Bn5LNh4e.js.map} +1 -1
- package/dist/esm/{FormFieldStateWrapper--onY0vtr.js → FormFieldStateWrapper-SdWKU73w.js} +1 -1
- package/dist/{kolibri/FormFieldStateWrapper--onY0vtr.js.map → esm/FormFieldStateWrapper-SdWKU73w.js.map} +1 -1
- package/dist/esm/{Heading-OHdEuqsD.js → Heading-C4rnCYXm.js} +1 -1
- package/dist/esm/{Heading-OHdEuqsD.js.map → Heading-C4rnCYXm.js.map} +1 -1
- package/dist/esm/{Icon-DfgbH-hb.js → Icon-DiLz3fn_.js} +1 -1
- package/dist/esm/{Icon-DfgbH-hb.js.map → Icon-DiLz3fn_.js.map} +1 -1
- package/dist/esm/{Input-CnEOkt-P.js → Input-3yKCAK8D.js} +1 -1
- package/dist/esm/{Input-CnEOkt-P.js.map → Input-3yKCAK8D.js.map} +1 -1
- package/dist/esm/{InputStateWrapper-eppo6W8b.js → InputStateWrapper-CmSl1Pup.js} +1 -1
- package/dist/{kolibri/InputStateWrapper-eppo6W8b.js.map → esm/InputStateWrapper-CmSl1Pup.js.map} +1 -1
- package/dist/esm/{InternalUnderlinedBadgeText-BJBDCfSS.js → InternalUnderlinedBadgeText-7p1Sf6Uz.js} +1 -1
- package/dist/esm/{InternalUnderlinedBadgeText-BJBDCfSS.js.map → InternalUnderlinedBadgeText-7p1Sf6Uz.js.map} +1 -1
- package/dist/esm/{Span-CR60lRkb.js → Span-BdWhVqpE.js} +1 -1
- package/dist/esm/{Span-CR60lRkb.js.map → Span-BdWhVqpE.js.map} +1 -1
- package/dist/esm/{app-globals-d-6tc412.js → app-globals-B5nEYpOR.js} +1 -1
- package/dist/esm/{app-globals-d-6tc412.js.map → app-globals-B5nEYpOR.js.map} +1 -1
- package/dist/esm/base-controller-Cpw4bHkB.js +4 -0
- package/dist/esm/base-controller-Cpw4bHkB.js.map +1 -0
- package/dist/esm/{controller-C-9DC25-.js → controller-DeT6XiIB.js} +1 -1
- package/dist/esm/{controller-C-9DC25-.js.map → controller-DeT6XiIB.js.map} +1 -1
- package/dist/esm/{controller-Cn-Pxv9N.js → controller-DgjtfYEk.js} +1 -1
- package/dist/esm/{controller-Cn-Pxv9N.js.map → controller-DgjtfYEk.js.map} +1 -1
- package/dist/esm/{controller-De_Qbk_S.js → controller-OQt0tt67.js} +1 -1
- package/dist/esm/{controller-De_Qbk_S.js.map → controller-OQt0tt67.js.map} +1 -1
- package/dist/esm/{controller-DXRgDsy0.js → controller-cwZv_Ppb.js} +1 -1
- package/dist/esm/{controller-DXRgDsy0.js.map → controller-cwZv_Ppb.js.map} +1 -1
- package/dist/esm/{controller-icon-kGj-dj9j.js → controller-icon-Dopbz3nm.js} +1 -1
- package/dist/{kolibri/controller-icon-kGj-dj9j.js.map → esm/controller-icon-Dopbz3nm.js.map} +1 -1
- package/dist/esm/{dev.utils-khfgdH9Q.js → dev.utils-dsy3l66K.js} +1 -1
- package/dist/esm/{dev.utils-khfgdH9Q.js.map → dev.utils-dsy3l66K.js.map} +1 -1
- package/dist/esm/{devtools-EC4my9zk.js → devtools-xecG3w-I.js} +1 -1
- package/dist/{kolibri/devtools-EC4my9zk.js.map → esm/devtools-xecG3w-I.js.map} +1 -1
- package/dist/esm/{index-CTfYKeaf.js → index-2R8yiTEB.js} +1 -1
- package/dist/esm/{index-CTfYKeaf.js.map → index-2R8yiTEB.js.map} +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-wc.entry.js +1 -1
- package/dist/esm/kol-alert.entry.js +1 -1
- package/dist/esm/kol-avatar.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-link.entry.js +1 -1
- package/dist/esm/kol-button-wc.entry.js +1 -1
- package/dist/esm/kol-button.entry.js +1 -1
- package/dist/esm/kol-card-wc.entry.js +1 -1
- package/dist/esm/kol-card.entry.js +1 -1
- package/dist/esm/kol-click-button.entry.js +1 -1
- package/dist/esm/kol-combobox.entry.js +1 -1
- package/dist/esm/kol-details.entry.js +1 -1
- package/dist/esm/kol-dialog-wc.entry.js +1 -1
- package/dist/esm/kol-dialog.entry.js +1 -1
- package/dist/esm/kol-drawer.entry.js +1 -1
- package/dist/esm/kol-form.entry.js +1 -1
- package/dist/esm/kol-heading.entry.js +1 -1
- package/dist/esm/kol-icon.entry.js +1 -1
- package/dist/esm/kol-image.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.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-wc.entry.js +1 -1
- package/dist/esm/kol-link.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-wc.entry.js +1 -1
- package/dist/esm/kol-pagination.entry.js +1 -1
- package/dist/esm/kol-popover-button-wc.entry.js +1 -1
- package/dist/esm/kol-popover-button.entry.js +1 -1
- package/dist/esm/kol-popover-wc.entry.js +1 -1
- package/dist/esm/kol-progress.entry.js +1 -1
- package/dist/esm/kol-quote.entry.js +1 -1
- package/dist/esm/kol-select-wc.entry.js +1 -1
- package/dist/esm/kol-select.entry.js +1 -1
- package/dist/esm/kol-single-select.entry.js +1 -1
- package/dist/esm/kol-skeleton.entry.js +1 -1
- package/dist/esm/kol-skip-nav.entry.js +1 -1
- package/dist/esm/kol-spin.entry.js +1 -1
- package/dist/esm/kol-split-button.entry.js +1 -1
- package/dist/esm/kol-table-settings-wc.entry.js +1 -1
- package/dist/esm/kol-table-stateful.entry.js +1 -1
- package/dist/esm/kol-table-stateless-wc.entry.js +1 -1
- package/dist/esm/kol-table-stateless.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-container.entry.js +1 -1
- package/dist/esm/kol-toolbar.entry.js +1 -1
- package/dist/esm/kol-tooltip-wc.entry.js +1 -1
- package/dist/esm/kol-tree-item-wc.entry.js +1 -1
- package/dist/esm/kol-tree-item.entry.js +1 -1
- package/dist/esm/kol-tree-wc.entry.js +1 -1
- package/dist/esm/kol-tree.entry.js +1 -1
- package/dist/esm/kol-version.entry.js +1 -1
- package/dist/esm/kolibri.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/test-component.entry.js +1 -1
- package/dist/kolibri/{Alert-BsbKAp99.js → Alert-BNnW6X1O.js} +1 -1
- package/dist/kolibri/{Alert-BsbKAp99.js.map → Alert-BNnW6X1O.js.map} +1 -1
- package/dist/kolibri/{Collapsible-BTaZIREk.js → Collapsible-DNDdPxp5.js} +1 -1
- package/dist/kolibri/{Collapsible-BTaZIREk.js.map → Collapsible-DNDdPxp5.js.map} +1 -1
- package/dist/kolibri/CustomSuggestionsOptionsGroup-CWtO9VtS.js +4 -0
- package/dist/{esm/CustomSuggestionsOptionsGroup-C0pEClOW.js.map → kolibri/CustomSuggestionsOptionsGroup-CWtO9VtS.js.map} +1 -1
- package/dist/kolibri/FieldControlStateWrapper-Bn5LNh4e.js +4 -0
- package/dist/{esm/FieldControlStateWrapper-BCNYRgaN.js.map → kolibri/FieldControlStateWrapper-Bn5LNh4e.js.map} +1 -1
- package/dist/kolibri/{FormFieldStateWrapper--onY0vtr.js → FormFieldStateWrapper-SdWKU73w.js} +1 -1
- package/dist/{esm/FormFieldStateWrapper--onY0vtr.js.map → kolibri/FormFieldStateWrapper-SdWKU73w.js.map} +1 -1
- package/dist/kolibri/{Heading-OHdEuqsD.js → Heading-C4rnCYXm.js} +1 -1
- package/dist/kolibri/{Heading-OHdEuqsD.js.map → Heading-C4rnCYXm.js.map} +1 -1
- package/dist/kolibri/Icon-DiLz3fn_.js +4 -0
- package/dist/kolibri/{Icon-DfgbH-hb.js.map → Icon-DiLz3fn_.js.map} +1 -1
- package/dist/kolibri/Input-3yKCAK8D.js +4 -0
- package/dist/kolibri/{Input-CnEOkt-P.js.map → Input-3yKCAK8D.js.map} +1 -1
- package/dist/kolibri/{InputStateWrapper-eppo6W8b.js → InputStateWrapper-CmSl1Pup.js} +1 -1
- package/dist/{esm/InputStateWrapper-eppo6W8b.js.map → kolibri/InputStateWrapper-CmSl1Pup.js.map} +1 -1
- package/dist/kolibri/InternalUnderlinedBadgeText-7p1Sf6Uz.js +4 -0
- package/dist/kolibri/{InternalUnderlinedBadgeText-BJBDCfSS.js.map → InternalUnderlinedBadgeText-7p1Sf6Uz.js.map} +1 -1
- package/dist/kolibri/Span-BdWhVqpE.js +4 -0
- package/dist/kolibri/{Span-CR60lRkb.js.map → Span-BdWhVqpE.js.map} +1 -1
- package/dist/kolibri/app-globals-B5nEYpOR.js +4 -0
- package/dist/kolibri/{app-globals-d-6tc412.js.map → app-globals-B5nEYpOR.js.map} +1 -1
- package/dist/kolibri/base-controller-Cpw4bHkB.js +4 -0
- package/dist/kolibri/base-controller-Cpw4bHkB.js.map +1 -0
- package/dist/kolibri/{controller-C-9DC25-.js → controller-DeT6XiIB.js} +1 -1
- package/dist/kolibri/{controller-C-9DC25-.js.map → controller-DeT6XiIB.js.map} +1 -1
- package/dist/kolibri/{controller-Cn-Pxv9N.js → controller-DgjtfYEk.js} +1 -1
- package/dist/kolibri/{controller-Cn-Pxv9N.js.map → controller-DgjtfYEk.js.map} +1 -1
- package/dist/kolibri/{controller-De_Qbk_S.js → controller-OQt0tt67.js} +1 -1
- package/dist/kolibri/{controller-De_Qbk_S.js.map → controller-OQt0tt67.js.map} +1 -1
- package/dist/kolibri/{controller-DXRgDsy0.js → controller-cwZv_Ppb.js} +1 -1
- package/dist/kolibri/{controller-DXRgDsy0.js.map → controller-cwZv_Ppb.js.map} +1 -1
- package/dist/kolibri/{controller-icon-kGj-dj9j.js → controller-icon-Dopbz3nm.js} +1 -1
- package/dist/{esm/controller-icon-kGj-dj9j.js.map → kolibri/controller-icon-Dopbz3nm.js.map} +1 -1
- package/dist/kolibri/{dev.utils-khfgdH9Q.js → dev.utils-dsy3l66K.js} +1 -1
- package/dist/kolibri/{dev.utils-khfgdH9Q.js.map → dev.utils-dsy3l66K.js.map} +1 -1
- package/dist/kolibri/{devtools-EC4my9zk.js → devtools-xecG3w-I.js} +1 -1
- package/dist/{esm/devtools-EC4my9zk.js.map → kolibri/devtools-xecG3w-I.js.map} +1 -1
- package/dist/kolibri/{index-CTfYKeaf.js → index-2R8yiTEB.js} +1 -1
- package/dist/kolibri/{index-CTfYKeaf.js.map → index-2R8yiTEB.js.map} +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-wc.entry.js +1 -1
- package/dist/kolibri/kol-alert.entry.js +1 -1
- package/dist/kolibri/kol-avatar.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-link.entry.js +1 -1
- package/dist/kolibri/kol-button-wc.entry.js +1 -1
- package/dist/kolibri/kol-button.entry.js +1 -1
- package/dist/kolibri/kol-card-wc.entry.js +1 -1
- package/dist/kolibri/kol-card-wc.entry.js.map +1 -1
- package/dist/kolibri/kol-card.entry.js +1 -1
- package/dist/kolibri/kol-click-button.entry.js +1 -1
- package/dist/kolibri/kol-combobox.entry.js +1 -1
- package/dist/kolibri/kol-details.entry.js +1 -1
- package/dist/kolibri/kol-dialog-wc.entry.js +1 -1
- package/dist/kolibri/kol-dialog.entry.js +1 -1
- package/dist/kolibri/kol-drawer.entry.js +1 -1
- package/dist/kolibri/kol-form.entry.js +1 -1
- package/dist/kolibri/kol-heading.entry.js +1 -1
- package/dist/kolibri/kol-icon.entry.js +1 -1
- package/dist/kolibri/kol-image.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.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-wc.entry.js +1 -1
- package/dist/kolibri/kol-link.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-wc.entry.js +1 -1
- package/dist/kolibri/kol-pagination.entry.js +1 -1
- package/dist/kolibri/kol-popover-button-wc.entry.js +1 -1
- package/dist/kolibri/kol-popover-button.entry.js +1 -1
- package/dist/kolibri/kol-popover-wc.entry.js +1 -1
- package/dist/kolibri/kol-progress.entry.js +1 -1
- package/dist/kolibri/kol-quote.entry.js +1 -1
- package/dist/kolibri/kol-select-wc.entry.js +1 -1
- package/dist/kolibri/kol-select.entry.js +1 -1
- package/dist/kolibri/kol-single-select.entry.js +1 -1
- package/dist/kolibri/kol-skeleton.entry.js +1 -1
- package/dist/kolibri/kol-skip-nav.entry.js +1 -1
- package/dist/kolibri/kol-spin.entry.js +1 -1
- package/dist/kolibri/kol-split-button.entry.js +1 -1
- package/dist/kolibri/kol-table-settings-wc.entry.js +1 -1
- package/dist/kolibri/kol-table-stateful.entry.js +1 -1
- package/dist/kolibri/kol-table-stateless-wc.entry.js +1 -1
- package/dist/kolibri/kol-table-stateless.entry.js +1 -1
- package/dist/kolibri/kol-tabs.entry.js +1 -1
- package/dist/kolibri/kol-tabs.entry.js.map +1 -1
- package/dist/kolibri/kol-textarea.entry.js +1 -1
- package/dist/kolibri/kol-toast-container.entry.js +1 -1
- package/dist/kolibri/kol-toolbar.entry.js +1 -1
- package/dist/kolibri/kol-tooltip-wc.entry.js +1 -1
- package/dist/kolibri/kol-tree-item-wc.entry.js +1 -1
- package/dist/kolibri/kol-tree-item.entry.js +1 -1
- package/dist/kolibri/kol-tree-wc.entry.js +1 -1
- package/dist/kolibri/kol-tree.entry.js +1 -1
- package/dist/kolibri/kol-version.entry.js +1 -1
- package/dist/kolibri/kolibri.esm.js +1 -1
- package/dist/kolibri/test-component.entry.js +1 -1
- package/dist/types/internal/props/helpers/factory.d.ts +1 -1
- package/doc/_skeleton.md +71 -435
- package/package.json +3 -3
- package/dist/cjs/base-controller-Dh7xUmRQ.js +0 -4
- package/dist/cjs/base-controller-Dh7xUmRQ.js.map +0 -1
- package/dist/esm/base-controller-BGteZxSE.js +0 -4
- package/dist/esm/base-controller-BGteZxSE.js.map +0 -1
- package/dist/kolibri/CustomSuggestionsOptionsGroup-C0pEClOW.js +0 -4
- package/dist/kolibri/FieldControlStateWrapper-BCNYRgaN.js +0 -4
- package/dist/kolibri/Icon-DfgbH-hb.js +0 -4
- package/dist/kolibri/Input-CnEOkt-P.js +0 -4
- package/dist/kolibri/InternalUnderlinedBadgeText-BJBDCfSS.js +0 -4
- package/dist/kolibri/Span-CR60lRkb.js +0 -4
- package/dist/kolibri/app-globals-d-6tc412.js +0 -4
- package/dist/kolibri/base-controller-BGteZxSE.js +0 -4
- package/dist/kolibri/base-controller-BGteZxSE.js.map +0 -1
package/doc/_skeleton.md
CHANGED
|
@@ -1,473 +1,109 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Refactoring-Auftrag: Komponente auf Skeleton/Internals-Architektur migrieren
|
|
2
2
|
|
|
3
|
-
##
|
|
3
|
+
## Rolle
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Du bist ein **Senior Software Architect und Developer** mit über 15 Jahren Erfahrung in komponentenbasierter Frontend-Architektur. Du legst höchsten Wert auf:
|
|
6
6
|
|
|
7
|
-
-
|
|
8
|
-
-
|
|
9
|
-
-
|
|
10
|
-
-
|
|
11
|
-
-
|
|
7
|
+
- **Clean Architecture** — klare Schichtentrennung, Single Responsibility, Dependency Inversion.
|
|
8
|
+
- **Wartbarkeit** — Code, der in 2 Jahren von einem neuen Teammitglied ohne Rückfragen verstanden wird.
|
|
9
|
+
- **Lesbarkeit** — selbstdokumentierende Strukturen, konsistente Namensgebung, minimaler kognitiver Aufwand beim Lesen.
|
|
10
|
+
- **Nachvollziehbarkeit** — jede Entscheidung folgt einem erkennbaren Pattern, keine Sonderfälle ohne Begründung.
|
|
11
|
+
- **Reduktion** — du schreibst nicht mehr Code als nötig. Du löschst mutig, was nicht gebraucht wird.
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
Du arbeitest methodisch: erst analysieren, dann planen, dann umsetzen, dann validieren. Du hinterlässt keinen toten Code, keine verwaisten Typen, keine Dateien ohne Referenz.
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
---
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
## Auftrag
|
|
18
18
|
|
|
19
|
-
|
|
19
|
+
Refaktoriere die angegebene Komponente so, dass sie vollständig der Referenzimplementierung im Skeleton-Blueprint und der Internals-Schicht entspricht. Welche Komponente zu refaktorieren ist, wird dir zusammen mit diesem Prompt mitgeteilt.
|
|
20
20
|
|
|
21
|
-
|
|
22
|
-
- Overhead JavaScript Engine: ~100 Bytes pro Instanz
|
|
21
|
+
---
|
|
23
22
|
|
|
24
|
-
##
|
|
23
|
+
## ⚠️ Arbeitsverzeichnis
|
|
25
24
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
export class KolClickButton {
|
|
29
|
-
private readonly ctrl = new ClickButtonController(); // ✅ 1× pro WC-Instanz
|
|
30
|
-
}
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
### Charakteristiken
|
|
34
|
-
|
|
35
|
-
| Metrik | Wert |
|
|
36
|
-
| ------------------------ | -------------------------- |
|
|
37
|
-
| **Controller-Instanzen** | 100 |
|
|
38
|
-
| **RAM (Gesamt)** | ~60 KB |
|
|
39
|
-
| **Constructor Aufrufe** | 100 |
|
|
40
|
-
| **Share State möglich?** | ❌ Nein (isoliert) |
|
|
41
|
-
| **Memory Leak Risk** | ✅ Niedrig (GC-freundlich) |
|
|
42
|
-
| **Wartbarkeit** | ✅ Einfach |
|
|
43
|
-
| **Performance Scaling** | ❌ Linear schlecht |
|
|
44
|
-
|
|
45
|
-
### Vorteile
|
|
46
|
-
|
|
47
|
-
- ✅ Maximale Isolation pro Komponenten-Instanz
|
|
48
|
-
- ✅ Keine Komplexität mit Pools/Factories
|
|
49
|
-
- ✅ Debugging einfach (1:1 Mapping)
|
|
50
|
-
- ✅ Test-freundlich (Mock ist straightforward)
|
|
51
|
-
|
|
52
|
-
### Nachteile
|
|
53
|
-
|
|
54
|
-
- ❌ 100× redundante Instanzen
|
|
55
|
-
- ❌ 100× Constructor-Aufrufe bei Mount
|
|
56
|
-
- ❌ bei 1000 Komponenten: 500+ KB Ram verschwendet
|
|
57
|
-
- ❌ Redundante Methoden-Referenzen (`handleClick`, `setButtonRef` 100×)
|
|
58
|
-
|
|
59
|
-
### Reale Performance-Impact
|
|
60
|
-
|
|
61
|
-
```
|
|
62
|
-
Anwendungsfall: Single Page mit 100 Buttons
|
|
63
|
-
─────────────────────────────────────────
|
|
64
|
-
Initial Load: +25ms (100× Constructor-Aufrufe)
|
|
65
|
-
Memory: +60 KB (100 Controller × 600 Bytes)
|
|
66
|
-
Runtime: Neutral (jeder Controller ist optimiert)
|
|
67
|
-
Garbage: Gut (GC hat leichte Zeit)
|
|
68
|
-
```
|
|
69
|
-
|
|
70
|
-
## Pattern 2: Reiner Singleton (1 Controller für ALLE)
|
|
71
|
-
|
|
72
|
-
```typescript
|
|
73
|
-
// Controller:
|
|
74
|
-
export const clickButtonController = { // ✅ 1× global
|
|
75
|
-
validateLabel: (value) => { ... },
|
|
76
|
-
handleClick: (callback) => { ... },
|
|
77
|
-
};
|
|
78
|
-
|
|
79
|
-
// Web Component:
|
|
80
|
-
export class KolClickButton {
|
|
81
|
-
private readonly ctrl = clickButtonController; // ✅ Referenz, kein new
|
|
82
|
-
private buttonRef?: HTMLButtonElement; // ❌ State in WC
|
|
83
|
-
}
|
|
84
|
-
```
|
|
85
|
-
|
|
86
|
-
### Charakteristiken
|
|
87
|
-
|
|
88
|
-
| Metrik | Wert |
|
|
89
|
-
| ------------------------ | -------------------------------------------- |
|
|
90
|
-
| **Controller-Instanzen** | 1 |
|
|
91
|
-
| **RAM (Gesamt)** | ~1 KB + 100× State-Duplikate in WCs |
|
|
92
|
-
| **Constructor Aufrufe** | 1 |
|
|
93
|
-
| **Share State möglich?** | ✅ Ja (aber problematisch!) |
|
|
94
|
-
| **Memory Leak Risk** | ✅ Sehr niedrig |
|
|
95
|
-
| **Wartbarkeit** | ⚠️ Hybrid (State in WC, Logik in Controller) |
|
|
96
|
-
| **Performance Scaling** | ✅ Konstant |
|
|
97
|
-
|
|
98
|
-
### Vorteile
|
|
99
|
-
|
|
100
|
-
- ✅ Minimale Controller-Instanzen
|
|
101
|
-
- ✅ Shared Validierungslogik
|
|
102
|
-
- ✅ Performance bei scale-out
|
|
103
|
-
- ✅ GC-Druck minimal
|
|
104
|
-
|
|
105
|
-
### Nachteile
|
|
106
|
-
|
|
107
|
-
- ❌ **State muss in Web Component sitzen** → WC wird fett
|
|
108
|
-
- ❌ Schwer zu verstehen: "Wo lebt welcher State?"
|
|
109
|
-
- ❌ **Shared State Bug-Gefahr**: `buttonRef` zeigt auf zuletzt geclickten Button
|
|
110
|
-
- ❌ Logik und State getrennt → Cognitive Load hoch
|
|
111
|
-
- ❌ Proxy-Methoden in WC (State-Übergabe)
|
|
112
|
-
- ⚠️ Test-Komplexität: Mock-State ist versteckt
|
|
113
|
-
|
|
114
|
-
### Reale Performance-Impact
|
|
115
|
-
|
|
116
|
-
```
|
|
117
|
-
Anwendungsfall: Single Page mit 100 Buttons
|
|
118
|
-
─────────────────────────────────────────
|
|
119
|
-
Initial Load: -20ms (nur 1× Constructor)
|
|
120
|
-
Memory: -58 KB (100 Controllers gespart)
|
|
121
|
-
Runtime: + komplexere State-Übergabe
|
|
122
|
-
Wartbarkeit: 😞 WC ist kompliziert
|
|
123
|
-
Debugging: 😞 "Wo ist der State?"
|
|
124
|
-
```
|
|
125
|
-
|
|
126
|
-
### Das Shared-State-Problem
|
|
127
|
-
|
|
128
|
-
```typescript
|
|
129
|
-
// ❌ KRITISCHER BUG mit Singleton:
|
|
130
|
-
export const clickButtonController = {
|
|
131
|
-
private buttonRef?: HTMLButtonElement; // ⚠️ Geteilt!
|
|
132
|
-
|
|
133
|
-
setButtonRef: (el) => { this.buttonRef = el; },
|
|
134
|
-
focus: () => this.buttonRef?.focus(), // ❌ Focus auf LETZTEN Button!
|
|
135
|
-
};
|
|
136
|
-
|
|
137
|
-
// HTML:
|
|
138
|
-
<button id="btn1"></button>
|
|
139
|
-
<button id="btn2"></button>
|
|
140
|
-
|
|
141
|
-
// Szenario:
|
|
142
|
-
// 1. btn1.setButtonRef(btn1_element)
|
|
143
|
-
// 2. btn2.setButtonRef(btn2_element) // ⚠️ Überschreibt!
|
|
144
|
-
// 3. clickButtonController.focus() // 🐛 Fokussiert btn2, nicht btn1!
|
|
145
|
-
```
|
|
146
|
-
|
|
147
|
-
## Pattern 3: WeakMap Pool (Zukünftige Alternative) 🔮
|
|
148
|
-
|
|
149
|
-
```typescript
|
|
150
|
-
// BaseController:
|
|
151
|
-
export abstract class BaseController {
|
|
152
|
-
protected static readonly pool = new WeakMap<object, BaseController>();
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
// ClickButtonController:
|
|
156
|
-
export class ClickButtonController extends BaseController {
|
|
157
|
-
private static readonly pool = new WeakMap<object, ClickButtonController>();
|
|
158
|
-
|
|
159
|
-
private buttonRef?: HTMLButtonElement; // ✅ Pro Instanz
|
|
160
|
-
|
|
161
|
-
public static getOrCreate(wcInstance: object): ClickButtonController {
|
|
162
|
-
if (!this.pool.has(wcInstance)) {
|
|
163
|
-
this.pool.set(wcInstance, new ClickButtonController());
|
|
164
|
-
}
|
|
165
|
-
return this.pool.get(wcInstance)!;
|
|
166
|
-
}
|
|
167
|
-
}
|
|
25
|
+
- **Skeleton** (`_skeleton/`) = **nur lesen**. Dient ausschließlich als Referenz und Vorlage.
|
|
26
|
+
- **Komponentenverzeichnis** = **Arbeitsort**. Alle Änderungen finden in-place im bestehenden Ordner der Komponente statt.
|
|
168
27
|
|
|
169
|
-
|
|
170
|
-
export class KolClickButton {
|
|
171
|
-
private readonly ctrl = ClickButtonController.getOrCreate(this); // 🔮 Optional future
|
|
172
|
-
}
|
|
173
|
-
```
|
|
174
|
-
|
|
175
|
-
### Charakteristiken
|
|
176
|
-
|
|
177
|
-
| Metrik | Wert |
|
|
178
|
-
| ------------------------ | ------------------------------------- |
|
|
179
|
-
| **Controller-Instanzen** | 100 (aber pooled) |
|
|
180
|
-
| **RAM (Gesamt)** | ~60 KB |
|
|
181
|
-
| **Constructor Aufrufe** | 100 (aber 1× pro Komponenten-Instanz) |
|
|
182
|
-
| **Share State möglich?** | ❌ Nein (isoliert) |
|
|
183
|
-
| **Memory Leak Risk** | ✅ Minimal (WeakMap GC) |
|
|
184
|
-
| **Wartbarkeit** | ✅ Sehr gut |
|
|
185
|
-
| **Performance Scaling** | ✅ Linear akzeptabel |
|
|
28
|
+
---
|
|
186
29
|
|
|
187
|
-
|
|
30
|
+
## Verbindliche Spezifikation
|
|
188
31
|
|
|
189
|
-
|
|
190
|
-
- ✅ Keine Shared-State-Bugs
|
|
191
|
-
- ✅ Logik BLEIBT im Controller (WC bleibt schlank)
|
|
192
|
-
- ✅ Auto-Cleanup via WeakMap
|
|
193
|
-
- ✅ Memory Leak-frei
|
|
194
|
-
- ✅ Einfach zu verstehen: "1 WC = 1 Controller"
|
|
195
|
-
- ✅ Test-freundlich
|
|
196
|
-
- ✅ Debuggbar
|
|
32
|
+
Die [ARC42.md](./ARC42.md) ist die **führende Architektur-Spezifikation**. Lies sie vollständig, bevor du mit dem Refactoring beginnst. Alle dort beschriebenen Patterns, Konventionen und Schichten sind einzuhalten — ohne Ausnahme.
|
|
197
33
|
|
|
198
|
-
|
|
34
|
+
Ergänzend gelten:
|
|
199
35
|
|
|
200
|
-
-
|
|
201
|
-
-
|
|
202
|
-
- ⚠️ Nicht maximale Performance-Optimierung
|
|
36
|
+
- `AGENTS.md` (Repository-Root)
|
|
37
|
+
- `.github/copilot-instructions.md`
|
|
203
38
|
|
|
204
|
-
|
|
39
|
+
Bei Widersprüchen hat die ARC42.md Vorrang.
|
|
205
40
|
|
|
206
|
-
|
|
207
|
-
Anwendungsfall: Single Page mit 100 Buttons
|
|
208
|
-
─────────────────────────────────────────
|
|
209
|
-
Initial Load: +10ms (100 Constructors, aber gecacht)
|
|
210
|
-
Memory: ~60 KB (100 Controller × 600 Bytes)
|
|
211
|
-
Runtime: Neutral (optimierte Methoden)
|
|
212
|
-
Garbage: ✅ Gut (WeakMap GC ist effizient)
|
|
213
|
-
Wartbarkeit: ✅ Exzellent
|
|
214
|
-
Debugging: ✅ Sehr gut
|
|
215
|
-
Stabilität: ✅ Keine Race Conditions
|
|
216
|
-
```
|
|
41
|
+
---
|
|
217
42
|
|
|
218
|
-
##
|
|
43
|
+
## Vorgehen
|
|
219
44
|
|
|
220
|
-
|
|
221
|
-
// ClickButtonController:
|
|
222
|
-
export class ClickButtonController {
|
|
223
|
-
private static instance: ClickButtonController;
|
|
224
|
-
private buttonRef?: HTMLButtonElement; // ❌ Geteilt!
|
|
45
|
+
### 1. Analyse
|
|
225
46
|
|
|
226
|
-
|
|
47
|
+
- Lies **alle** Dateien im Komponentenverzeichnis.
|
|
48
|
+
- Lies die Skeleton-Referenzimplementierung (`_skeleton/web-components/`) und die Internals-Schicht (`src/internal/`).
|
|
49
|
+
- Erstelle eine **Gap-Analyse**: Was weicht von der Skeleton-Architektur ab?
|
|
227
50
|
|
|
228
|
-
|
|
229
|
-
if (!this.instance) {
|
|
230
|
-
this.instance = new ClickButtonController();
|
|
231
|
-
}
|
|
232
|
-
return this.instance;
|
|
233
|
-
}
|
|
234
|
-
}
|
|
51
|
+
### 2. Props-First: Struktur aufbauen (KRITISCH — ZUERST!)
|
|
235
52
|
|
|
236
|
-
|
|
237
|
-
export class KolClickButton {
|
|
238
|
-
private readonly ctrl = ClickButtonController.getInstance(); // ✅ 1× Instance
|
|
239
|
-
}
|
|
240
|
-
```
|
|
53
|
+
**Bevor du die Komponente implementierst, musst du alle Props migrieren:**
|
|
241
54
|
|
|
242
|
-
|
|
55
|
+
1. **Props-Inventar**: Sammle alle vorhandenen `@Prop()` Deklarationen aus der aktuellen Komponente
|
|
56
|
+
2. **Pro Prop eine Datei** unter `src/internal/props/`:
|
|
57
|
+
- Dateiname: `<prop-name>.ts` (z.B. `label.ts`, `href.ts`, `disabled.ts`)
|
|
58
|
+
- Nutze `Prop<K, TExternal, TInternal>` oder `SimpleProp<K, T>`
|
|
59
|
+
- Implementiere `normalize()` und `validate()` via `createPropDefinition<P>()`
|
|
60
|
+
3. **Props exportieren** in `src/internal/props/index.ts`
|
|
61
|
+
4. **Props-Typen im Controller** verwenden (z.B. `InternalOf<P>`, `ExternalOf<P>`)
|
|
243
62
|
|
|
244
|
-
|
|
245
|
-
| ------------------------ | ---------------------- |
|
|
246
|
-
| **Controller-Instanzen** | 1 |
|
|
247
|
-
| **RAM (Gesamt)** | ~1 KB |
|
|
248
|
-
| **Constructor Aufrufe** | 1 |
|
|
249
|
-
| **Share State möglich?** | ✅ Ja (problematisch!) |
|
|
250
|
-
| **Memory Leak Risk** | ✅ Sehr niedrig |
|
|
251
|
-
| **Wartbarkeit** | ❌ Problematisch |
|
|
252
|
-
| **Performance Scaling** | ✅ Konstant |
|
|
63
|
+
**Warum Props-First?**
|
|
253
64
|
|
|
254
|
-
|
|
65
|
+
- API-Verträge sind klar, bevor Implementation beginnt
|
|
66
|
+
- Keine Props gehen verloren oder werden vergessen
|
|
67
|
+
- Controller und Tests haben sichere Typen von Anfang an
|
|
68
|
+
- Architektur muss nicht nachträglich angepasst werden
|
|
255
69
|
|
|
256
|
-
|
|
257
|
-
- ❌ `buttonRef` zeigt auf zuletzt registrierte Komponente
|
|
258
|
-
- ❌ 100 `<kol-click-button>` müssen State extern verwalten
|
|
259
|
-
- ❌ Race Conditions möglich
|
|
260
|
-
- ❌ Nicht-Thread-Safe (theoretisch, aber JS ist Single-Threaded)
|
|
70
|
+
### 3. Refactoring: Komponenten-Implementierung
|
|
261
71
|
|
|
262
|
-
|
|
72
|
+
Erstelle bzw. ersetze die Dateien im Komponentenverzeichnis gemäß der ARC42-Schichten:
|
|
263
73
|
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
74
|
+
1. **API-Definition** (`api.tsx`) — Interface für die Komponente (nutzt Props-Typen aus Schritt 2)
|
|
75
|
+
2. **Controller** — erweitert `BaseController`, nutzt normalisierte Props
|
|
76
|
+
3. **Functional Component** — stateless Renderer
|
|
77
|
+
4. **Web Component** — Stencil `@Component` mit Lifecycle, Watchers, Rendering
|
|
78
|
+
5. **CSS/SCSS** — bestehende Styles beibehalten, bei Bedarf anpassen
|
|
79
|
+
6. **Tests** — Testdateien **neben** `component.tsx` erstellen bzw. aktualisieren (kein `test/`-Unterordner, siehe ARC42 Design Decision 11):
|
|
80
|
+
- `snapshot.spec.tsx` — Jest DOM-Snapshot-Tests (`executeSnapshotTests`)
|
|
81
|
+
- `interaction.e2e.ts` — Playwright Interaction-Tests (Klick, Tastatur, Events)
|
|
271
82
|
|
|
272
|
-
|
|
83
|
+
### 4. Dead Code eliminieren
|
|
273
84
|
|
|
274
|
-
|
|
275
|
-
┌─────────────────────────────────────────────────────────────┐
|
|
276
|
-
│ Pattern │ RAM │ Performance │ Stabilität │ Wart. │
|
|
277
|
-
├──────────────────┼──────────┼─────────────┼────────────┼────────┤
|
|
278
|
-
│ new pro WC ✅ │ 60 KB │ ⚠️ Linear │ ✅ Gut │ ✅ Gut │
|
|
279
|
-
│ Reiner Singleton │ 1 KB │ ✅ Optimal │ ❌ Bugs │ ❌ Komplex│
|
|
280
|
-
│ WeakMap Pool 🔮 │ 60 KB │ ⚠️ Akzeptabel│ ✅ Gut │ ✅ Sehr gut│
|
|
281
|
-
│ Klassisches Sing.│ 1 KB │ ✅ Optimal │ ❌ Bugs │ ❌ Schlecht│
|
|
282
|
-
└─────────────────────────────────────────────────────────────┘
|
|
283
|
-
```
|
|
85
|
+
Nach dem Refactoring darf **kein veralteter Code** zurückbleiben:
|
|
284
86
|
|
|
285
|
-
|
|
87
|
+
- **Dateien löschen**: alte Type-/Interface-Dateien, alte Controller, verwaiste Module, leere Dateien.
|
|
88
|
+
- **Code entfernen**: unused Types, Imports, auskommentierter Code, deprecated Wrapper.
|
|
89
|
+
- **Prüfen**: Keine Datei ohne Referenz, keine Barrel-Files.
|
|
286
90
|
|
|
287
|
-
###
|
|
91
|
+
### 5. Validierung
|
|
288
92
|
|
|
93
|
+
```bash
|
|
94
|
+
pnpm format
|
|
95
|
+
pnpm lint
|
|
96
|
+
pnpm --filter @public-ui/components test:unit
|
|
97
|
+
pnpm --filter @public-ui/components build
|
|
289
98
|
```
|
|
290
|
-
Anforderung: 100+ Komponenten ohne Bugs
|
|
291
|
-
─────────────────────────────────────────
|
|
292
|
-
✅ new pro WC: Jede WC hat ihren Controller, volle Isolation
|
|
293
|
-
⚠️ WeakMap Pool: Zusätzliche Komplexität für später, wenn nötig
|
|
294
|
-
❌ Singleton: Shared State → Focus-Bug auf falscher Komponente
|
|
295
|
-
```
|
|
296
|
-
|
|
297
|
-
### 2. **Zugänglichkeit**
|
|
298
|
-
|
|
299
|
-
```
|
|
300
|
-
Anforderung: Code muss für neue Entwickler verständlich sein
|
|
301
|
-
──────────────────────────────────────────────────────────
|
|
302
|
-
✅ new pro WC: "Diese WC erstellt einen Controller" – einfach und klar
|
|
303
|
-
⚠️ WeakMap Pool: "Pool-Pattern mit WeakMap+getOrCreate" – mehr Denkaufwand
|
|
304
|
-
❌ Singleton: "State ist... irgendwo anders?"
|
|
305
|
-
```
|
|
306
|
-
|
|
307
|
-
### 3. **RAM vs. Verständlichkeit Trade-off**
|
|
308
|
-
|
|
309
|
-
```
|
|
310
|
-
Szenario: Typische Anwendung mit 100 Komponenten
|
|
311
|
-
────────────────────────────────────────────────
|
|
312
|
-
new pro WC: ~60 KB RAM (akzeptabel, verständlich)
|
|
313
|
-
WeakMap Pool: ~60 KB RAM (identisch, aber komplexer)
|
|
314
|
-
Singleton: ~2 KB RAM (aber: 10+ Stunden Debugging für Race Conditions)
|
|
315
|
-
```
|
|
316
|
-
|
|
317
|
-
**Kosten-Nutzen:**
|
|
318
|
-
|
|
319
|
-
- new pro WC: Klarheit + Stabilität > minimale RAM-Ersparnis
|
|
320
|
-
- Wenn Skalierung (1000+) nötig wird: dann auf WeakMap Pool migrieren
|
|
321
|
-
|
|
322
|
-
### 4. **Skalierbarkeit später**
|
|
323
|
-
|
|
324
|
-
```
|
|
325
|
-
Wenn später 1000+ Komponenten im DOM?
|
|
326
|
-
──────────────────────────────────────
|
|
327
|
-
new pro WC: ~600 KB RAM (linear, aber noch okay für Moderns UIs)
|
|
328
|
-
WeakMap Pool: ~600 KB RAM (identisch, dann würde Optimierung mehr Sinn machen)
|
|
329
|
-
Singleton: ~2 KB RAM (aber 1000× Potential für Bugs = unmaintainable)
|
|
330
|
-
|
|
331
|
-
Realität: 1000 Komponenten kommen vor (Virtual Scrolling, Data Tables)
|
|
332
|
-
Lösung: WeakMap Pool beschrieben + kann später hinzugefügt werden
|
|
333
|
-
Status Quo: new pro WC ist der bessere Default
|
|
334
|
-
```
|
|
335
|
-
|
|
336
|
-
## Micro-Optimierungen (Zukunft)
|
|
337
|
-
|
|
338
|
-
Falls die Anwendung wirklich in extreme Skalierung geht (1000+ gleichzeitig im DOM):
|
|
339
|
-
|
|
340
|
-
### Option A: Object Pool mit Max-Size
|
|
341
|
-
|
|
342
|
-
```typescript
|
|
343
|
-
private static readonly pool = new WeakMap<object, ClickButtonController>();
|
|
344
|
-
private static readonly maxPoolSize = 100;
|
|
345
|
-
|
|
346
|
-
public static getOrCreate(wcInstance: object): ClickButtonController {
|
|
347
|
-
if (this.pool.size >= this.maxPoolSize) {
|
|
348
|
-
// Cleanup alte Instanzen
|
|
349
|
-
// Aber: WeakMap hat keine .size Property
|
|
350
|
-
}
|
|
351
|
-
// ...
|
|
352
|
-
}
|
|
353
|
-
```
|
|
354
|
-
|
|
355
|
-
### Option B: Lazy Initialization für Häufige Props
|
|
356
|
-
|
|
357
|
-
```typescript
|
|
358
|
-
// Cache häufige Validierungen
|
|
359
|
-
const LABEL_CACHE = new Map<string, LabelPropType>();
|
|
360
|
-
|
|
361
|
-
public watchLabel(value?: LabelPropType): void {
|
|
362
|
-
if (LABEL_CACHE.has(value!)) {
|
|
363
|
-
this.setProp('label', LABEL_CACHE.get(value!)!);
|
|
364
|
-
return;
|
|
365
|
-
}
|
|
366
|
-
// Teuer Validierung
|
|
367
|
-
const normalized = labelProp.normalize(value);
|
|
368
|
-
LABEL_CACHE.set(value!, normalized);
|
|
369
|
-
this.setProp('label', normalized);
|
|
370
|
-
}
|
|
371
|
-
```
|
|
372
|
-
|
|
373
|
-
### Option C: Shared Stateless Validators
|
|
374
|
-
|
|
375
|
-
```typescript
|
|
376
|
-
// Nur Validierung teilen, State bleibt privat
|
|
377
|
-
export const createClickButtonValidators = () => ({
|
|
378
|
-
validateLabel: (value?: LabelPropType) => { ... },
|
|
379
|
-
});
|
|
380
|
-
|
|
381
|
-
// Dann: 1× Validator, 100× Controller
|
|
382
|
-
```
|
|
383
|
-
|
|
384
|
-
## Architektur-Entscheidung: Pattern 1 (`new` pro WC) – Aktuell
|
|
385
|
-
|
|
386
|
-
### Begründung
|
|
387
|
-
|
|
388
|
-
1. **Zugänglichkeit**: Neue Entwickler verstehen schnell: "1 WC = 1 Controller"
|
|
389
|
-
2. **Stabilität**: Keine Shared-State-Bugs, Race-Conditions ausgeschlossen
|
|
390
|
-
3. **Wartbarkeit**: Logik bleibt zentral im Controller, WC bleibt schlank
|
|
391
|
-
4. **Performance**: 60 KB für 100 Komponenten ist ein akzeptabler Trade-off
|
|
392
|
-
5. **Debugging**: Straightforward, kein Pool-Overhead
|
|
393
|
-
6. **Zukunftssicherheit**: Kann später zu WeakMap Pool migrieren, wenn nötig
|
|
394
|
-
|
|
395
|
-
### Nicht-Ziele (bewusst)
|
|
396
|
-
|
|
397
|
-
- ❌ Maximale RAM-Effizienz um jeden Preis
|
|
398
|
-
- ❌ Complexe Pooling-Mechaniken für Szenarien, die nicht häufig sind
|
|
399
|
-
- ❌ Micro-Optimierungen ohne Nutzen
|
|
400
|
-
|
|
401
|
-
### Trade-off Akzeptanz
|
|
402
|
-
|
|
403
|
-
```
|
|
404
|
-
Was wir AUFGEBEN: 58 KB RAM pro 100 Komponenten, etwas mehr Constructor-Aufrufe
|
|
405
|
-
Was wir GEWINNEN:
|
|
406
|
-
✅ Stabile, verständliche Architektur
|
|
407
|
-
✅ Verständlicher Code für alle Entwickler
|
|
408
|
-
✅ Keine Race Conditions
|
|
409
|
-
✅ Test-freundlich
|
|
410
|
-
✅ Einfach zu debuggen
|
|
411
|
-
✅ Kann später zu WeakMap Pattern migrieren
|
|
412
|
-
```
|
|
413
|
-
|
|
414
|
-
### Zukünftige Überlegung
|
|
415
|
-
|
|
416
|
-
Falls die Anwendung in extreme Skalierung geht (1000+ gleichzeitig im DOM), kann **Pattern 3 (WeakMap Pool)** in einem Major-Release eingebaut werden, ohne dass die API bricht – die Änderung würde nur in den Internals stattfinden.
|
|
417
|
-
|
|
418
|
-
## Messungen (reale Szenarien)
|
|
419
|
-
|
|
420
|
-
### Szenario 1: React Sample mit 50 Skeleton Komponenten
|
|
421
|
-
|
|
422
|
-
```
|
|
423
|
-
Initial Load:
|
|
424
|
-
new pro WC: ~8ms
|
|
425
|
-
WeakMap Pool: ~7ms
|
|
426
|
-
Differenz: -1ms (irrelevant)
|
|
427
|
-
|
|
428
|
-
Memory (Chrome DevTools):
|
|
429
|
-
new pro WC: ~25 KB
|
|
430
|
-
WeakMap Pool: ~25 KB
|
|
431
|
-
Differenz: 0 KB (gleich)
|
|
432
|
-
|
|
433
|
-
Laufzeit GC:
|
|
434
|
-
new pro WC: ~2ms (GC nach Unmount)
|
|
435
|
-
WeakMap Pool: ~0.5ms (WeakMap GC ist effizienter)
|
|
436
|
-
```
|
|
437
|
-
|
|
438
|
-
### Szenario 2: Table mit 100 Rows (100× Row Component)
|
|
439
|
-
|
|
440
|
-
```
|
|
441
|
-
Initial Load:
|
|
442
|
-
new pro WC: ~45ms
|
|
443
|
-
WeakMap Pool: ~42ms
|
|
444
|
-
Differenz: -3ms (irrelevant)
|
|
445
|
-
|
|
446
|
-
Memory:
|
|
447
|
-
new pro WC: ~60 KB
|
|
448
|
-
WeakMap Pool: ~60 KB
|
|
449
|
-
Differenz: 0 KB (identisch)
|
|
450
|
-
|
|
451
|
-
Interaktion (Focus/Blur):
|
|
452
|
-
new pro WC: ~0.1ms pro Focus
|
|
453
|
-
WeakMap Pool: ~0.1ms pro Focus
|
|
454
|
-
Differenz: 0ms (identisch)
|
|
455
|
-
```
|
|
456
|
-
|
|
457
|
-
## Conclusion
|
|
458
|
-
|
|
459
|
-
**Pattern 1 (`new` pro WC) ist die richtige Wahl für KoliBri – aktuell und kurzfristig**, weil:
|
|
460
99
|
|
|
461
|
-
|
|
462
|
-
2. **Stabilität**: Garantiert keine Race Conditions
|
|
463
|
-
3. **Code-Qualität**: Wartbar, verständlich, testbar
|
|
464
|
-
4. **Developer Experience**: "1 WC = 1 Controller" ist unmittelbar verständlich
|
|
465
|
-
5. **Zukunftssicherheit**: Kann später zu WeakMap Pool migriert werden, wenn die Skalierung (1000+) es erfordert
|
|
100
|
+
Alle vier Befehle müssen fehlerfrei durchlaufen. **Kein Befehl darf vor dem Timeout abgebrochen werden.**
|
|
466
101
|
|
|
467
|
-
|
|
102
|
+
---
|
|
468
103
|
|
|
469
|
-
##
|
|
104
|
+
## Ausgabe
|
|
470
105
|
|
|
471
|
-
-
|
|
472
|
-
|
|
473
|
-
-
|
|
106
|
+
1. **Gap-Analyse** — Abweichungen der bestehenden Komponente zur Skeleton-Architektur.
|
|
107
|
+
2. **Gelöschte Dateien** — Liste mit Begründung pro Datei.
|
|
108
|
+
3. **Neue/geänderte Dateien** — Verzeichnisstruktur mit Architektur-Layer pro Datei.
|
|
109
|
+
4. **Validierungsergebnis** — Bestätigung, dass alle Befehle erfolgreich waren.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@public-ui/components",
|
|
3
|
-
"version": "4.1.
|
|
3
|
+
"version": "4.1.1-rc.0",
|
|
4
4
|
"license": "EUPL-1.2",
|
|
5
5
|
"homepage": "https://public-ui.github.io",
|
|
6
6
|
"repository": {
|
|
@@ -102,7 +102,7 @@
|
|
|
102
102
|
"@typescript-eslint/eslint-plugin": "8.56.1",
|
|
103
103
|
"@typescript-eslint/parser": "8.56.1",
|
|
104
104
|
"adopted-style-sheets": "1.1.9-rc.21",
|
|
105
|
-
"autoprefixer": "10.4.
|
|
105
|
+
"autoprefixer": "10.4.27",
|
|
106
106
|
"cross-env": "10.1.0",
|
|
107
107
|
"cssnano": "7.1.2",
|
|
108
108
|
"eslint": "9.39.3",
|
|
@@ -117,7 +117,7 @@
|
|
|
117
117
|
"pug": "3.0.3",
|
|
118
118
|
"rimraf": "6.1.3",
|
|
119
119
|
"stencil-awesome-test": "1.0.6",
|
|
120
|
-
"stylelint": "17.
|
|
120
|
+
"stylelint": "17.4.0",
|
|
121
121
|
"terser": "5.46.0",
|
|
122
122
|
"twig": "1.17.1",
|
|
123
123
|
"typescript": "5.9.3"
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
/*!
|
|
2
|
-
* KoliBri - The accessible HTML-Standard
|
|
3
|
-
*/
|
|
4
|
-
"use strict";var common=require("./common-BDQKBMeS.js");function createPropDefinition(r,e){return{normalize:r,validate:e}}function withValidPropValue(r,e,t){try{const o=r.normalize(e);r.validate(o)&&t(o)}catch(r){common.Log.debug(r)}}function normalizeString(r){if("string"==typeof r)return r;if("number"==typeof r||"boolean"==typeof r||"bigint"==typeof r)return String(r);throw new Error(`Invalid string: ${r}`)}function normalizeInteger(r){if("number"==typeof r)return Number.isInteger(r)?r:Math.round(r);if("string"==typeof r){const e=parseInt(r,10);if(!isNaN(e))return e}throw new Error(`Invalid integer: ${r}`)}const labelProp=createPropDefinition(normalizeString,r=>r.length>=2&&r.length<=80);class BaseController{constructor(r,e){this.component=r,this.props=e}setProp(r,e){this.props[r]=e}getProps(){return this.props}setState(r,e){this.component[r]=e}}exports.BaseController=BaseController,exports.createPropDefinition=createPropDefinition,exports.labelProp=labelProp,exports.normalizeInteger=normalizeInteger,exports.normalizeString=normalizeString,exports.withValidPropValue=withValidPropValue;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"base-controller-Dh7xUmRQ.js","sources":["src/internal/props/helpers/factory.ts","src/internal/props/helpers/normalizers.ts","src/internal/props/label.ts","src/internal/functional-components/base-controller.ts"],"sourcesContent":["import { Log } from '../../../schema';\n\n/**\n * Definiert einen Prop-Typ mit internem und externem Typ.\n *\n * - K: der Property-Name\n * - TExternal: der externe Eingabe-Typ (Web Component)\n * - TInternal: der normalisierte Typ (Controller/FC), default = TExternal\n *\n * Phantom-Keys `__input_${K}` tragen den externen Typ auf Type-Ebene.\n * Der feste Phantom-Key `__propInternal__` trägt TInternal für eine zuverlässige Inferenz.\n */\nexport type Prop<K extends string, TExternal, TInternal> = {\n\t[P in K]: TInternal;\n} & {\n\t[P in K as `__input_${P}`]?: TExternal;\n} & {\n\treadonly __propInternal__?: TInternal;\n};\n\n/**\n * Shorthand for Prop when external and internal types are identical.\n *\n * - K: der Property-Name\n * - T: der Typ (verwendet für externe und interne Nutzung)\n */\nexport type SimpleProp<K extends string, T> = Prop<K, T, T>;\n\nexport type InternalPropValue<P extends Prop<string, unknown, unknown>> = NonNullable<P['__propInternal__']>;\n\nexport type PropDefinition<TInternal> = {\n\tnormalize: (value: unknown) => TInternal | never;\n\tvalidate: (value: TInternal) => boolean;\n};\n\nexport function createPropDefinition<P extends Prop<string, unknown, unknown>>(\n\tnormalize: (value: unknown) => InternalPropValue<P> | never,\n\tvalidate: (value: InternalPropValue<P>) => boolean,\n): PropDefinition<InternalPropValue<P>> {\n\treturn {\n\t\tnormalize,\n\t\tvalidate,\n\t};\n}\n\nexport function withValidPropValue<P extends Prop<string, unknown, unknown>>(\n\tpropDef: PropDefinition<InternalPropValue<P>>,\n\tvalue: unknown,\n\tcallback: (normalized: InternalPropValue<P>) => void,\n): void {\n\ttry {\n\t\tconst normalized = propDef.normalize(value);\n\t\tif (propDef.validate(normalized)) {\n\t\t\tcallback(normalized);\n\t\t}\n\t} catch (e) {\n\t\tLog.debug(e);\n\t}\n}\n","import { isObject } from '../../../schema';\n\nexport function normalizeString(value?: unknown): string | never {\n\tif (typeof value === 'string') {\n\t\treturn value;\n\t}\n\tif (typeof value === 'number' || typeof value === 'boolean' || typeof value === 'bigint') {\n\t\treturn String(value);\n\t}\n\tthrow new Error(`Invalid string: ${value as string}`);\n}\n\nexport function normalizeInteger(value?: unknown): number | never {\n\tif (typeof value === 'number') {\n\t\treturn Number.isInteger(value) ? value : Math.round(value);\n\t}\n\tif (typeof value === 'string') {\n\t\tconst parsed = parseInt(value, 10);\n\t\tif (!isNaN(parsed)) {\n\t\t\treturn parsed;\n\t\t}\n\t}\n\tthrow new Error(`Invalid integer: ${value as string}`);\n}\n\nexport function normalizeNumber(value?: unknown): number | never {\n\tif (typeof value === 'number') {\n\t\treturn value;\n\t}\n\tif (typeof value === 'string') {\n\t\tconst parsed = Number(value);\n\t\tif (!isNaN(parsed)) {\n\t\t\treturn parsed;\n\t\t}\n\t}\n\tthrow new Error(`Invalid number: ${value as string}`);\n}\n\nexport function normalizeBoolean(value?: unknown): boolean | never {\n\tif (typeof value === 'boolean') {\n\t\treturn value;\n\t}\n\tif (typeof value === 'string') {\n\t\treturn value.toLowerCase() === 'true';\n\t}\n\tthrow new Error(`Invalid boolean: ${value as string}`);\n}\n\nexport function normalizeObject(value?: unknown): object | never {\n\tif (isObject(value)) {\n\t\treturn value as object;\n\t}\n\tif (typeof value === 'string') {\n\t\tconst parsed = JSON.parse(value) as unknown;\n\t\tif (isObject(parsed)) {\n\t\t\treturn parsed as object;\n\t\t}\n\t}\n\tthrow new Error(`Invalid object: ${value as string}`);\n}\n\nexport function normalizeArray(value?: unknown): unknown[] | never {\n\tif (isObject(value) && Array.isArray(value)) {\n\t\treturn value as unknown[];\n\t}\n\tif (typeof value === 'string') {\n\t\tconst parsed = JSON.parse(value) as unknown;\n\t\tif (isObject(parsed) && Array.isArray(parsed)) {\n\t\t\treturn parsed as unknown[];\n\t\t}\n\t}\n\tthrow new Error(`Invalid array: ${value as string}`);\n}\n","import type { SimpleProp } from './helpers/factory';\nimport { createPropDefinition } from './helpers/factory';\nimport { normalizeString } from './helpers/normalizers';\n\nexport type LabelProp = SimpleProp<'label', string>;\nexport const labelProp = createPropDefinition<LabelProp>(normalizeString, (v) => v.length >= 2 && v.length <= 80);\n","import type { ComponentApi, InternalOf, ResolvedProps, StrictFields } from './generic-types';\n\ntype InternalStates<Api extends ComponentApi> = InternalOf<NonNullable<Api['States']>>;\n\nexport abstract class BaseController<Api extends ComponentApi> {\n\tpublic constructor(\n\t\tprotected readonly component: InternalStates<Api>,\n\t\tprivate readonly props: StrictFields<ResolvedProps<Api>>,\n\t) {}\n\n\tprotected setProp<K extends keyof ResolvedProps<Api>>(key: K, value: StrictFields<ResolvedProps<Api>>[K]): void {\n\t\tthis.props[key] = value;\n\t}\n\n\tpublic getProps(): StrictFields<ResolvedProps<Api>> {\n\t\treturn this.props;\n\t}\n\n\tprotected setState<K extends keyof InternalStates<Api>>(key: K, value: InternalStates<Api>[K]): void {\n\t\t(this.component as Record<string, unknown>)[key as string] = value;\n\t}\n}\n"],"names":["Log"],"mappings":";;;;;;;AAmCgB,SAAA,oBAAoB,CACnC,SAA2D,EAC3D,QAAkD,EAAA;IAElD,OAAO;QACN,SAAS;QACT,QAAQ;KACR;AACF;SAEgB,kBAAkB,CACjC,OAA6C,EAC7C,KAAc,EACd,QAAoD,EAAA;AAEpD,IAAA,IAAI;QACH,MAAM,UAAU,GAAG,OAAO,CAAC,SAAS,CAAC,KAAK,CAAC;AAC3C,QAAA,IAAI,OAAO,CAAC,QAAQ,CAAC,UAAU,CAAC,EAAE;YACjC,QAAQ,CAAC,UAAU,CAAC;;;IAEpB,OAAO,CAAC,EAAE;AACX,QAAAA,UAAG,CAAC,KAAK,CAAC,CAAC,CAAC;;AAEd;;ACxDM,SAAU,eAAe,CAAC,KAAe,EAAA;AAC9C,IAAA,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;AAC9B,QAAA,OAAO,KAAK;;AAEb,IAAA,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,OAAO,KAAK,KAAK,SAAS,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;AACzF,QAAA,OAAO,MAAM,CAAC,KAAK,CAAC;;AAErB,IAAA,MAAM,IAAI,KAAK,CAAC,mBAAmB,KAAe,CAAA,CAAE,CAAC;AACtD;AAEM,SAAU,gBAAgB,CAAC,KAAe,EAAA;AAC/C,IAAA,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;AAC9B,QAAA,OAAO,MAAM,CAAC,SAAS,CAAC,KAAK,CAAC,GAAG,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC;;AAE3D,IAAA,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;QAC9B,MAAM,MAAM,GAAG,QAAQ,CAAC,KAAK,EAAE,EAAE,CAAC;AAClC,QAAA,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,EAAE;AACnB,YAAA,OAAO,MAAM;;;AAGf,IAAA,MAAM,IAAI,KAAK,CAAC,oBAAoB,KAAe,CAAA,CAAE,CAAC;AACvD;;AClBa,MAAA,SAAS,GAAG,oBAAoB,CAAY,eAAe,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,MAAM,IAAI,CAAC,IAAI,CAAC,CAAC,MAAM,IAAI,EAAE;;MCD1F,cAAc,CAAA;IACnC,WACoB,CAAA,SAA8B,EAChC,KAAuC,EAAA;AADrC,QAAA,IAAS,CAAA,SAAA,GAAT,SAAS;AACX,QAAA,IAAK,CAAA,KAAA,GAAL,KAAK;;IAGb,OAAO,CAAqC,GAAM,EAAE,KAA0C,EAAA;AACvG,QAAA,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,KAAK;;IAGjB,QAAQ,GAAA;QACd,OAAO,IAAI,CAAC,KAAK;;IAGR,QAAQ,CAAsC,GAAM,EAAE,KAA6B,EAAA;AAC3F,QAAA,IAAI,CAAC,SAAqC,CAAC,GAAa,CAAC,GAAG,KAAK;;AAEnE;;;;;;;;;"}
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
/*!
|
|
2
|
-
* KoliBri - The accessible HTML-Standard
|
|
3
|
-
*/
|
|
4
|
-
import{L as Log}from"./common-BIkdAxr0.js";function createPropDefinition(r,t){return{normalize:r,validate:t}}function withValidPropValue(r,t,e){try{const n=r.normalize(t);r.validate(n)&&e(n)}catch(r){Log.debug(r)}}function normalizeString(r){if("string"==typeof r)return r;if("number"==typeof r||"boolean"==typeof r||"bigint"==typeof r)return String(r);throw new Error(`Invalid string: ${r}`)}function normalizeInteger(r){if("number"==typeof r)return Number.isInteger(r)?r:Math.round(r);if("string"==typeof r){const t=parseInt(r,10);if(!isNaN(t))return t}throw new Error(`Invalid integer: ${r}`)}const labelProp=createPropDefinition(normalizeString,r=>r.length>=2&&r.length<=80);class BaseController{constructor(r,t){this.component=r,this.props=t}setProp(r,t){this.props[r]=t}getProps(){return this.props}setState(r,t){this.component[r]=t}}export{BaseController as B,normalizeInteger as a,createPropDefinition as c,labelProp as l,normalizeString as n,withValidPropValue as w};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"base-controller-BGteZxSE.js","sources":["src/internal/props/helpers/factory.ts","src/internal/props/helpers/normalizers.ts","src/internal/props/label.ts","src/internal/functional-components/base-controller.ts"],"sourcesContent":["import { Log } from '../../../schema';\n\n/**\n * Definiert einen Prop-Typ mit internem und externem Typ.\n *\n * - K: der Property-Name\n * - TExternal: der externe Eingabe-Typ (Web Component)\n * - TInternal: der normalisierte Typ (Controller/FC), default = TExternal\n *\n * Phantom-Keys `__input_${K}` tragen den externen Typ auf Type-Ebene.\n * Der feste Phantom-Key `__propInternal__` trägt TInternal für eine zuverlässige Inferenz.\n */\nexport type Prop<K extends string, TExternal, TInternal> = {\n\t[P in K]: TInternal;\n} & {\n\t[P in K as `__input_${P}`]?: TExternal;\n} & {\n\treadonly __propInternal__?: TInternal;\n};\n\n/**\n * Shorthand for Prop when external and internal types are identical.\n *\n * - K: der Property-Name\n * - T: der Typ (verwendet für externe und interne Nutzung)\n */\nexport type SimpleProp<K extends string, T> = Prop<K, T, T>;\n\nexport type InternalPropValue<P extends Prop<string, unknown, unknown>> = NonNullable<P['__propInternal__']>;\n\nexport type PropDefinition<TInternal> = {\n\tnormalize: (value: unknown) => TInternal | never;\n\tvalidate: (value: TInternal) => boolean;\n};\n\nexport function createPropDefinition<P extends Prop<string, unknown, unknown>>(\n\tnormalize: (value: unknown) => InternalPropValue<P> | never,\n\tvalidate: (value: InternalPropValue<P>) => boolean,\n): PropDefinition<InternalPropValue<P>> {\n\treturn {\n\t\tnormalize,\n\t\tvalidate,\n\t};\n}\n\nexport function withValidPropValue<P extends Prop<string, unknown, unknown>>(\n\tpropDef: PropDefinition<InternalPropValue<P>>,\n\tvalue: unknown,\n\tcallback: (normalized: InternalPropValue<P>) => void,\n): void {\n\ttry {\n\t\tconst normalized = propDef.normalize(value);\n\t\tif (propDef.validate(normalized)) {\n\t\t\tcallback(normalized);\n\t\t}\n\t} catch (e) {\n\t\tLog.debug(e);\n\t}\n}\n","import { isObject } from '../../../schema';\n\nexport function normalizeString(value?: unknown): string | never {\n\tif (typeof value === 'string') {\n\t\treturn value;\n\t}\n\tif (typeof value === 'number' || typeof value === 'boolean' || typeof value === 'bigint') {\n\t\treturn String(value);\n\t}\n\tthrow new Error(`Invalid string: ${value as string}`);\n}\n\nexport function normalizeInteger(value?: unknown): number | never {\n\tif (typeof value === 'number') {\n\t\treturn Number.isInteger(value) ? value : Math.round(value);\n\t}\n\tif (typeof value === 'string') {\n\t\tconst parsed = parseInt(value, 10);\n\t\tif (!isNaN(parsed)) {\n\t\t\treturn parsed;\n\t\t}\n\t}\n\tthrow new Error(`Invalid integer: ${value as string}`);\n}\n\nexport function normalizeNumber(value?: unknown): number | never {\n\tif (typeof value === 'number') {\n\t\treturn value;\n\t}\n\tif (typeof value === 'string') {\n\t\tconst parsed = Number(value);\n\t\tif (!isNaN(parsed)) {\n\t\t\treturn parsed;\n\t\t}\n\t}\n\tthrow new Error(`Invalid number: ${value as string}`);\n}\n\nexport function normalizeBoolean(value?: unknown): boolean | never {\n\tif (typeof value === 'boolean') {\n\t\treturn value;\n\t}\n\tif (typeof value === 'string') {\n\t\treturn value.toLowerCase() === 'true';\n\t}\n\tthrow new Error(`Invalid boolean: ${value as string}`);\n}\n\nexport function normalizeObject(value?: unknown): object | never {\n\tif (isObject(value)) {\n\t\treturn value as object;\n\t}\n\tif (typeof value === 'string') {\n\t\tconst parsed = JSON.parse(value) as unknown;\n\t\tif (isObject(parsed)) {\n\t\t\treturn parsed as object;\n\t\t}\n\t}\n\tthrow new Error(`Invalid object: ${value as string}`);\n}\n\nexport function normalizeArray(value?: unknown): unknown[] | never {\n\tif (isObject(value) && Array.isArray(value)) {\n\t\treturn value as unknown[];\n\t}\n\tif (typeof value === 'string') {\n\t\tconst parsed = JSON.parse(value) as unknown;\n\t\tif (isObject(parsed) && Array.isArray(parsed)) {\n\t\t\treturn parsed as unknown[];\n\t\t}\n\t}\n\tthrow new Error(`Invalid array: ${value as string}`);\n}\n","import type { SimpleProp } from './helpers/factory';\nimport { createPropDefinition } from './helpers/factory';\nimport { normalizeString } from './helpers/normalizers';\n\nexport type LabelProp = SimpleProp<'label', string>;\nexport const labelProp = createPropDefinition<LabelProp>(normalizeString, (v) => v.length >= 2 && v.length <= 80);\n","import type { ComponentApi, InternalOf, ResolvedProps, StrictFields } from './generic-types';\n\ntype InternalStates<Api extends ComponentApi> = InternalOf<NonNullable<Api['States']>>;\n\nexport abstract class BaseController<Api extends ComponentApi> {\n\tpublic constructor(\n\t\tprotected readonly component: InternalStates<Api>,\n\t\tprivate readonly props: StrictFields<ResolvedProps<Api>>,\n\t) {}\n\n\tprotected setProp<K extends keyof ResolvedProps<Api>>(key: K, value: StrictFields<ResolvedProps<Api>>[K]): void {\n\t\tthis.props[key] = value;\n\t}\n\n\tpublic getProps(): StrictFields<ResolvedProps<Api>> {\n\t\treturn this.props;\n\t}\n\n\tprotected setState<K extends keyof InternalStates<Api>>(key: K, value: InternalStates<Api>[K]): void {\n\t\t(this.component as Record<string, unknown>)[key as string] = value;\n\t}\n}\n"],"names":[],"mappings":";;;;;AAmCgB,SAAA,oBAAoB,CACnC,SAA2D,EAC3D,QAAkD,EAAA;IAElD,OAAO;QACN,SAAS;QACT,QAAQ;KACR;AACF;SAEgB,kBAAkB,CACjC,OAA6C,EAC7C,KAAc,EACd,QAAoD,EAAA;AAEpD,IAAA,IAAI;QACH,MAAM,UAAU,GAAG,OAAO,CAAC,SAAS,CAAC,KAAK,CAAC;AAC3C,QAAA,IAAI,OAAO,CAAC,QAAQ,CAAC,UAAU,CAAC,EAAE;YACjC,QAAQ,CAAC,UAAU,CAAC;;;IAEpB,OAAO,CAAC,EAAE;AACX,QAAA,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC;;AAEd;;ACxDM,SAAU,eAAe,CAAC,KAAe,EAAA;AAC9C,IAAA,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;AAC9B,QAAA,OAAO,KAAK;;AAEb,IAAA,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,OAAO,KAAK,KAAK,SAAS,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;AACzF,QAAA,OAAO,MAAM,CAAC,KAAK,CAAC;;AAErB,IAAA,MAAM,IAAI,KAAK,CAAC,mBAAmB,KAAe,CAAA,CAAE,CAAC;AACtD;AAEM,SAAU,gBAAgB,CAAC,KAAe,EAAA;AAC/C,IAAA,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;AAC9B,QAAA,OAAO,MAAM,CAAC,SAAS,CAAC,KAAK,CAAC,GAAG,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC;;AAE3D,IAAA,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;QAC9B,MAAM,MAAM,GAAG,QAAQ,CAAC,KAAK,EAAE,EAAE,CAAC;AAClC,QAAA,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,EAAE;AACnB,YAAA,OAAO,MAAM;;;AAGf,IAAA,MAAM,IAAI,KAAK,CAAC,oBAAoB,KAAe,CAAA,CAAE,CAAC;AACvD;;AClBa,MAAA,SAAS,GAAG,oBAAoB,CAAY,eAAe,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,MAAM,IAAI,CAAC,IAAI,CAAC,CAAC,MAAM,IAAI,EAAE;;MCD1F,cAAc,CAAA;IACnC,WACoB,CAAA,SAA8B,EAChC,KAAuC,EAAA;AADrC,QAAA,IAAS,CAAA,SAAA,GAAT,SAAS;AACX,QAAA,IAAK,CAAA,KAAA,GAAL,KAAK;;IAGb,OAAO,CAAqC,GAAM,EAAE,KAA0C,EAAA;AACvG,QAAA,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,KAAK;;IAGjB,QAAQ,GAAA;QACd,OAAO,IAAI,CAAC,KAAK;;IAGR,QAAQ,CAAsC,GAAM,EAAE,KAA6B,EAAA;AAC3F,QAAA,IAAI,CAAC,SAAqC,CAAC,GAAa,CAAC,GAAG,KAAK;;AAEnE;;;;"}
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
/*!
|
|
2
|
-
* KoliBri - The accessible HTML-Standard
|
|
3
|
-
*/
|
|
4
|
-
import{h as o}from"./index-CTfYKeaf.js";import{c as e}from"./clsx-COFh-Vc8.js";const s=({disabled:s,index:n,ref:i,selected:t,onClick:l,onMouseOver:r,onFocus:u,onKeyDown:a,option:d,searchTerm:c})=>o("li",{id:`option-${n}`,key:`-${n}`,ref:i,"data-index":n,tabIndex:-1,role:"option","aria-selected":t?"true":void 0,"aria-disabled":s?"true":void 0,onClick:l,onMouseOver:r,onFocus:u,class:e("kol-custom-suggestions-option",{"kol-custom-suggestions-option--disabled":s}),onKeyDown:a},o("span",null,((s,e)=>{if(!(null==e?void 0:e.trim()))return s;const n=new RegExp(`(${e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")})`,"gi");return s.split(n).map((s,e)=>e%2==1?o("mark",null,s):s)})(String(d),c||""))),n=({blockSuggestionMouseOver:s,onKeyDown:n,style:i,hidden:t},l)=>o("ul",{role:"listbox",style:i,class:e("kol-custom-suggestions-options-group",{"kol-custom-suggestions-options-group--cursor-hidden":s,"kol-custom-suggestions-options-group--open":!t}),hidden:t,onKeyDown:n},l);export{n as C,s as a};
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
/*!
|
|
2
|
-
* KoliBri - The accessible HTML-Standard
|
|
3
|
-
*/
|
|
4
|
-
import{_ as o}from"./tslib.es6-CxX45GIN.js";import{h as l,F as e}from"./index-CTfYKeaf.js";import"./common-BIkdAxr0.js";import{b as t,s as i}from"./reuse-CX4AQDkS.js";import{b as s,K as n,c as r,g as a,i as d}from"./FormFieldStateWrapper--onY0vtr.js";import{c}from"./clsx-COFh-Vc8.js";const f=(e,s)=>{var{class:i}=e,r=o(e,["class"]);return l("div",Object.assign({class:c("kol-field-control__input",i)},r),s)},b=(b,p)=>{const{class:h,id:u,disabled:g,label:_,hideLabel:m,labelAlign:y,renderNoTooltip:k,hint:C,renderNoHint:K,tooltipAlign:j,accessKey:O,shortKey:A,msg:B,touched:v,required:P,readonly:x,fieldControlInputProps:N,fieldControlLabelProps:q,fieldControlTooltipProps:L,fieldControlHintProps:T}=b,F=o(b,["class","id","disabled","label","hideLabel","labelAlign","renderNoTooltip","hint","renderNoHint","tooltipAlign","accessKey","shortKey","msg","touched","required","readonly","fieldControlInputProps","fieldControlLabelProps","fieldControlTooltipProps","fieldControlHintProps"]),H=!K,I=!k,S=i(_),X=I&&!S&&m,Y=t(O,A),$=[l(e,null,l(f,Object.assign({},N),p),X&&l(s,Object.assign({},L||{},{id:u,label:_,align:j,badgeText:Y}))),l(n,Object.assign({},q||{},{id:u,baseClassName:"kol-field-control",class:c(null==q?void 0:q.class,{"kol-field-control__label--visually-hidden":Boolean(m)}),hasExpertSlot:S,label:_,accessKey:O,shortKey:A}))];"left"===y&&$.reverse();const D={"kol-field-control--disabled":Boolean(g),"kol-field-control--required":Boolean(P),"kol-field-control--touched":Boolean(v),"kol-field-control--hide-label":Boolean(m),"kol-field-control--read-only":Boolean(x),[`kol-field-control--${a(B)}`]:Boolean(d(B,v)),[`kol-field-control--label-align-${y}`]:Boolean(y)};return l("div",Object.assign({class:c("kol-field-control",D,h)},F),$,H&&l(r,Object.assign({},T||{},{baseClassName:"kol-field-control",id:u,hint:C})))};function p(l){const e={id:l._id,disabled:l._disabled,msg:l._msg,hint:l._hint,label:l._label,hideLabel:l._hideLabel,touched:l._touched};return"_required"in l&&(e.required=l._required),"_readOnly"in l&&(e.readonly=l._readOnly),"_labelAlign"in l&&(e.labelAlign=l._labelAlign),"_accessKey"in l&&(e.accessKey=l._accessKey),"_shortKey"in l&&(e.shortKey=l._shortKey),e}const u=(e,s)=>{var{state:i}=e,r=o(e,["state"]);return l(b,Object.assign({},p(i),r),s)};export{u as F};
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
/*!
|
|
2
|
-
* KoliBri - The accessible HTML-Standard
|
|
3
|
-
*/
|
|
4
|
-
import{h as s}from"./index-CTfYKeaf.js";import{d as o}from"./component-names-CqTpXVIM.js";const n=n=>{const{class:e,style:l,icons:a,label:c,onClick:t}=n;return s(o,{class:e,style:l,onClick:t,_icons:a,_label:c})};export{n as K};
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
/*!
|
|
2
|
-
* KoliBri - The accessible HTML-Standard
|
|
3
|
-
*/
|
|
4
|
-
import{_ as e}from"./tslib.es6-CxX45GIN.js";import{h as s,F as o}from"./index-CTfYKeaf.js";import"./common-BIkdAxr0.js";import{i as a,d as l,g as i}from"./FormFieldStateWrapper--onY0vtr.js";import{c as r}from"./clsx-COFh-Vc8.js";const t=t=>{const{class:d,msg:n,required:u,disabled:c,touched:b,readonly:p,ariaDescribedBy:m,hideLabel:g,label:h,suggestions:j,value:y}=t,B=e(t,["class","msg","required","disabled","touched","readonly","ariaDescribedBy","hideLabel","label","suggestions","value"]),k={"kol-input--disabled":Boolean(c),"kol-input--required":Boolean(u),"kol-input--touched":Boolean(b),"kol-input--readonly":Boolean(p),[`kol-input--${i(n)}`]:a(n,b)},f=Object.assign(Object.assign({class:r("kol-input",k,d),required:u,disabled:c,readonly:p,type:"text",list:j?`${B.id}-list`:void 0},l({ariaDescribedBy:m,hideLabel:g,label:h})),B);return s(o,null,s("input",Object.assign({},f,{value:y})),j)};export{t as I};
|