@rededor/cura 1.0.0 → 1.1.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/dist/assets/assets/cura-assets.zip +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-Black.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-BlackItalic.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-Bold.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-BoldItalic.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-Book.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-BookItalic.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-ExtraLight.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-ExtraLightItalic.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-Light.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-LightItalic.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-Medium.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-MediumItalic.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-Thin.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-ThinItalic.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-Ultra.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/Gotham-UltraItalic.woff2 +0 -0
- package/dist/assets/assets/fonts/Gotham/style.css +90 -0
- package/dist/assets/assets/fonts/HankenGrotesk/HankenGrotesk-Italic-VariableFont_wght.woff2 +0 -0
- package/dist/assets/assets/fonts/HankenGrotesk/HankenGrotesk-VariableFont_wght.woff2 +0 -0
- package/dist/assets/assets/fonts/HankenGrotesk/style-webfont.css +72 -0
- package/dist/assets/assets/fonts/HankenGrotesk/style.css +16 -0
- package/dist/assets/assets/fonts/Roboto/Roboto-Black.woff2 +0 -0
- package/dist/assets/assets/fonts/Roboto/Roboto-BlackItalic.woff2 +0 -0
- package/dist/assets/assets/fonts/Roboto/Roboto-Bold.woff2 +0 -0
- package/dist/assets/assets/fonts/Roboto/Roboto-BoldItalic.woff2 +0 -0
- package/dist/assets/assets/fonts/Roboto/Roboto-Italic.woff2 +0 -0
- package/dist/assets/assets/fonts/Roboto/Roboto-Light.woff2 +0 -0
- package/dist/assets/assets/fonts/Roboto/Roboto-LightItalic.woff2 +0 -0
- package/dist/assets/assets/fonts/Roboto/Roboto-Medium.woff2 +0 -0
- package/dist/assets/assets/fonts/Roboto/Roboto-MediumItalic.woff2 +0 -0
- package/dist/assets/assets/fonts/Roboto/Roboto-Regular.woff2 +0 -0
- package/dist/assets/assets/fonts/Roboto/Roboto-Thin.woff2 +0 -0
- package/dist/assets/assets/fonts/Roboto/Roboto-ThinItalic.woff2 +0 -0
- package/dist/assets/assets/fonts/Roboto/style-webfont.css +756 -0
- package/dist/assets/assets/fonts/Roboto/style.css +90 -0
- package/dist/assets/assets/images/avatar/doctor-default.svg +6 -7
- package/dist/assets/assets/images/avatar/doctor-default_old.svg +8 -0
- package/dist/assets/assets/images/avatar/dora-default.svg +3 -4
- package/dist/assets/assets/images/avatar/dora-default_old.svg +5 -0
- package/dist/assets/assets/images/avatar/patient-default.svg +16 -10
- package/dist/assets/assets/images/avatar/patient-default_old.svg +12 -0
- package/dist/assets/assets/images/avatar/unit-default.svg +7 -8
- package/dist/assets/assets/images/avatar/unit-default_old.svg +9 -0
- package/dist/cjs/{app-globals-b77d5b06.js → app-globals-4d07f363.js} +20 -4
- package/dist/cjs/app-globals-4d07f363.js.map +1 -0
- package/dist/cjs/cura-accordion_12.cjs.entry.js +8 -7
- package/dist/cjs/cura-accordion_12.cjs.entry.js.map +1 -1
- package/dist/cjs/cura-button-outline.cjs.entry.js +1 -1
- package/dist/cjs/cura-button-outline.cjs.entry.js.map +1 -1
- package/dist/cjs/cura-button-transparent.cjs.entry.js +1 -1
- package/dist/cjs/cura-button-transparent.cjs.entry.js.map +1 -1
- package/dist/cjs/cura-calendar.cjs.entry.js +9 -4
- package/dist/cjs/cura-calendar.cjs.entry.js.map +1 -1
- package/dist/cjs/cura-checkbox.cjs.entry.js +1 -1
- package/dist/cjs/cura-checkbox.cjs.entry.js.map +1 -1
- package/dist/cjs/cura-dropdown-search.cjs.entry.js +5 -4
- package/dist/cjs/cura-dropdown-search.cjs.entry.js.map +1 -1
- package/dist/cjs/cura.cjs.js +2 -2
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/api/theme-presets/theme-default.js +3 -3
- package/dist/collection/api/theme-presets/theme-default.js.map +1 -1
- package/dist/collection/api/theme-presets/theme-legacy-default.js +16 -0
- package/dist/collection/api/theme-presets/theme-legacy-default.js.map +1 -1
- package/dist/collection/assets/images/avatar/doctor-default.svg +6 -7
- package/dist/collection/assets/images/avatar/doctor-default_old.svg +8 -0
- package/dist/collection/assets/images/avatar/dora-default.svg +3 -4
- package/dist/collection/assets/images/avatar/dora-default_old.svg +5 -0
- package/dist/collection/assets/images/avatar/patient-default.svg +16 -10
- package/dist/collection/assets/images/avatar/patient-default_old.svg +12 -0
- package/dist/collection/assets/images/avatar/unit-default.svg +7 -8
- package/dist/collection/assets/images/avatar/unit-default_old.svg +9 -0
- package/dist/collection/components/buttons/cura-button/cura-button.js +1 -1
- package/dist/collection/components/buttons/cura-button/cura-button.js.map +1 -1
- package/dist/collection/components/buttons/cura-button-outline/cura-button-outline.js +1 -1
- package/dist/collection/components/buttons/cura-button-outline/cura-button-outline.js.map +1 -1
- package/dist/collection/components/buttons/cura-button-transparent/cura-button-transparent.js +1 -1
- package/dist/collection/components/buttons/cura-button-transparent/cura-button-transparent.js.map +1 -1
- package/dist/collection/components/cura-calendar/cura-calendar.css +13 -5
- package/dist/collection/components/cura-calendar/cura-calendar.js +61 -6
- package/dist/collection/components/cura-calendar/cura-calendar.js.map +1 -1
- package/dist/collection/components/cura-calendar/cura-calendar.stories.js +33 -3
- package/dist/collection/components/cura-calendar/cura-calendar.stories.js.map +1 -1
- package/dist/collection/components/forms/cura-checkbox/cura-checkbox.css +13 -5
- package/dist/collection/components/forms/cura-dropdown-search/cura-dropdown-search.js +23 -4
- package/dist/collection/components/forms/cura-dropdown-search/cura-dropdown-search.js.map +1 -1
- package/dist/collection/components/forms/cura-dropdown-search/cura-dropdown-search.stories.js +19 -6
- package/dist/collection/components/forms/cura-dropdown-search/cura-dropdown-search.stories.js.map +1 -1
- package/dist/collection/components/forms/cura-select/cura-select.css +1 -0
- package/dist/collection/components/forms/cura-select/cura-select.js +23 -4
- package/dist/collection/components/forms/cura-select/cura-select.js.map +1 -1
- package/dist/collection/components/forms/cura-select/cura-select.stories.js +11 -1
- package/dist/collection/components/forms/cura-select/cura-select.stories.js.map +1 -1
- package/dist/collection/components/text/cura-paragraph/cura-paragraph.css +3 -1
- package/dist/collection/stories/blocks/index.js +85 -0
- package/dist/components/cura-button-outline.js +1 -1
- package/dist/components/cura-button-outline.js.map +1 -1
- package/dist/components/cura-button-transparent2.js +1 -1
- package/dist/components/cura-button-transparent2.js.map +1 -1
- package/dist/components/cura-button.js +1 -1
- package/dist/components/cura-button.js.map +1 -1
- package/dist/components/cura-calendar.js +12 -4
- package/dist/components/cura-calendar.js.map +1 -1
- package/dist/components/cura-checkbox.js +1 -1
- package/dist/components/cura-checkbox.js.map +1 -1
- package/dist/components/cura-dropdown-search.js +6 -4
- package/dist/components/cura-dropdown-search.js.map +1 -1
- package/dist/components/cura-paragraph2.js +1 -1
- package/dist/components/cura-paragraph2.js.map +1 -1
- package/dist/components/cura-select2.js +7 -5
- package/dist/components/cura-select2.js.map +1 -1
- package/dist/components/index.js +19 -3
- package/dist/components/index.js.map +1 -1
- package/dist/cura/cura.esm.js +1 -1
- package/dist/cura/cura.esm.js.map +1 -1
- package/dist/cura/p-0b7a7306.js +2 -0
- package/dist/cura/p-0b7a7306.js.map +1 -0
- package/dist/cura/p-42dfa3a7.entry.js +2 -0
- package/dist/cura/p-42dfa3a7.entry.js.map +1 -0
- package/dist/cura/{p-599acc84.entry.js → p-5ac9d510.entry.js} +2 -2
- package/dist/cura/p-5ac9d510.entry.js.map +1 -0
- package/dist/cura/{p-b301a1ef.entry.js → p-9b658260.entry.js} +2 -2
- package/dist/cura/{p-b301a1ef.entry.js.map → p-9b658260.entry.js.map} +1 -1
- package/dist/cura/{p-4ef24fbd.entry.js → p-a9cda3b1.entry.js} +2 -2
- package/dist/cura/p-a9cda3b1.entry.js.map +1 -0
- package/dist/cura/{p-0a923806.entry.js → p-afd2c148.entry.js} +2 -2
- package/dist/cura/{p-0a923806.entry.js.map → p-afd2c148.entry.js.map} +1 -1
- package/dist/cura/p-fbf20e5a.entry.js +2 -0
- package/dist/cura/p-fbf20e5a.entry.js.map +1 -0
- package/dist/esm/{app-globals-488bf508.js → app-globals-6ca7103d.js} +20 -4
- package/dist/esm/app-globals-6ca7103d.js.map +1 -0
- package/dist/esm/cura-accordion_12.entry.js +8 -7
- package/dist/esm/cura-accordion_12.entry.js.map +1 -1
- package/dist/esm/cura-button-outline.entry.js +1 -1
- package/dist/esm/cura-button-outline.entry.js.map +1 -1
- package/dist/esm/cura-button-transparent.entry.js +1 -1
- package/dist/esm/cura-button-transparent.entry.js.map +1 -1
- package/dist/esm/cura-calendar.entry.js +9 -4
- package/dist/esm/cura-calendar.entry.js.map +1 -1
- package/dist/esm/cura-checkbox.entry.js +1 -1
- package/dist/esm/cura-checkbox.entry.js.map +1 -1
- package/dist/esm/cura-dropdown-search.entry.js +5 -4
- package/dist/esm/cura-dropdown-search.entry.js.map +1 -1
- package/dist/esm/cura.js +2 -2
- package/dist/esm/loader.js +2 -2
- package/dist/types/api/theme-presets/theme-legacy-default.d.ts +3 -3
- package/dist/types/api/theme-presets/theme-presets.d.ts +3 -3
- package/dist/types/components/cura-calendar/cura-calendar.d.ts +3 -0
- package/dist/types/components/cura-calendar/cura-calendar.stories.d.ts +33 -0
- package/dist/types/components/forms/cura-dropdown-search/cura-dropdown-search.d.ts +7 -3
- package/dist/types/components/forms/cura-dropdown-search/cura-dropdown-search.stories.d.ts +14 -0
- package/dist/types/components/forms/cura-select/cura-select.d.ts +5 -0
- package/dist/types/components/forms/cura-select/cura-select.stories.d.ts +11 -0
- package/dist/types/components.d.ts +22 -0
- package/package.json +5 -3
- package/dist/cjs/app-globals-b77d5b06.js.map +0 -1
- package/dist/cura/p-0dd837cf.entry.js +0 -2
- package/dist/cura/p-0dd837cf.entry.js.map +0 -1
- package/dist/cura/p-4ef24fbd.entry.js.map +0 -1
- package/dist/cura/p-599acc84.entry.js.map +0 -1
- package/dist/cura/p-a6c3c0ea.js +0 -2
- package/dist/cura/p-a6c3c0ea.js.map +0 -1
- package/dist/cura/p-dc5d0c29.entry.js +0 -2
- package/dist/cura/p-dc5d0c29.entry.js.map +0 -1
- package/dist/esm/app-globals-488bf508.js.map +0 -1
|
@@ -5,7 +5,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
const index = require('./index-98e7ba54.js');
|
|
6
6
|
const curaForms_definitions = require('./cura-forms.definitions-c164f1b8.js');
|
|
7
7
|
|
|
8
|
-
const curaCheckboxCss = "@charset \"UTF-8\";:host{display:block;width:fit-content;box-sizing:border-box}.container{display:flex;align-items:center;flex-direction:row-reverse;gap:var(--gap)}.position.container{flex-direction:row}.position .label-wrapper{justify-content:end}.position .message{text-align:right}.position .label{order:1}.info{display:flex;flex-direction:column}.label-wrapper{display:flex;justify-content:start;align-items:center;gap:5px}.control{width:fit-content;cursor:pointer;position:relative}.checkbox{appearance:none;border:2px solid var(--neutral-base-neutral-medium);border-radius:4px;background:var(--neutral-black-neutral-purewhite);flex:1 0;display:flex;align-items:center;justify-content:center;position:relative;cursor:pointer;box-sizing:border-box;width:var(--size);height:var(--size);flex:0 0 var(--size)}.icon{position:absolute;display:flex;opacity:0;transition:opacity 0.3s}.checkbox:focus{border-color:var(--info-base) !important}.disabled .checkbox{background:var(--neutral-black-neutral-white);border-color:var(--neutral-darker-neutral-base);cursor:not-allowed}.disabled .checkbox:hover{border-color:var(--neutral-darker-neutral-base) !important}.disabled.checked .checkbox,.disabled.indeterminate .checkbox{background:var(--neutral-black-neutral-white);border-color:var(--neutral-darker-neutral-base)}.disabled.checked .checkbox:hover,.disabled.indeterminate .checkbox:hover{border-color:var(--neutral-base-neutral-white);background:var(--primary-base-neutral-white)}.disabled .checkbox:focus{border-color:var(--neutral-darker-neutral-base) !important}.checked .checkbox
|
|
8
|
+
const curaCheckboxCss = "@charset \"UTF-8\";:host{display:block;width:fit-content;box-sizing:border-box}.container{display:flex;align-items:center;flex-direction:row-reverse;gap:var(--gap)}.position.container{flex-direction:row}.position .label-wrapper{justify-content:end}.position .message{text-align:right}.position .label{order:1}.info{display:flex;flex-direction:column}.label-wrapper{display:flex;justify-content:start;align-items:center;gap:5px}.control{width:fit-content;cursor:pointer;position:relative}.checkbox{appearance:none;border:2px solid var(--neutral-base-neutral-medium);border-radius:4px;background:var(--neutral-black-neutral-purewhite);flex:1 0;display:flex;align-items:center;justify-content:center;position:relative;cursor:pointer;box-sizing:border-box;width:var(--size);height:var(--size);flex:0 0 var(--size)}.icon{position:absolute;display:flex;opacity:0;transition:opacity 0.3s}.checkbox:focus{border-color:var(--info-base) !important}.disabled .checkbox{background:var(--neutral-black-neutral-white);border-color:var(--neutral-darker-neutral-base);cursor:not-allowed}.disabled .checkbox:hover{border-color:var(--neutral-darker-neutral-base) !important}.disabled.checked .checkbox,.disabled.indeterminate .checkbox{background:var(--neutral-black-neutral-white);border-color:var(--neutral-darker-neutral-base)}.disabled.checked .checkbox:hover,.disabled.indeterminate .checkbox:hover{border-color:var(--neutral-base-neutral-white);background:var(--primary-base-neutral-white)}.disabled .checkbox:focus{border-color:var(--neutral-darker-neutral-base) !important}.checked .checkbox{border-color:var(--color-dark);background:var(--color-base)}.checked .checkbox:hover{border-color:var(--color-base) !important;background:var(--color-light)}.indeterminate .checkbox{border-color:var(--color-base);background:var(--color-light)}.indeterminate .checkbox:hover{border-color:var(--color-dark) !important;background:var(--color-base)}.checked .icon,.indeterminate .icon{opacity:1}:not(.disabled):not(.checked):not(.indeterminate) .checkbox:hover{border-color:var(--neutral-purewhite-neutral-dark)}.success.dark .checkbox{background:var(--neutral-black)}.success .checkbox{border-color:var(--success-base);background:var(--success-lighter)}.success .checkbox:hover{border-color:var(--success-base) !important}.success.checked .checkbox{border-color:var(--success-dark-base);background:var(--success-base-lighter)}.success.checked .checkbox:hover{border-color:var(--success-dark-base)}.error.dark .checkbox{background:var(--neutral-black)}.error .checkbox{border-color:var(--error-base);background:var(--error-lighter)}.error .checkbox:hover{border-color:var(--error-base) !important}.error.checked .checkbox{border-color:var(--error-dark-base);background:var(--error-base-lighter)}.error.checked .checkbox:hover{border-color:var(--error-dark-base)}input{appearance:none;-webkit-appearance:none;-moz-appearance:none}";
|
|
9
9
|
const CuraCheckboxStyle0 = curaCheckboxCss;
|
|
10
10
|
|
|
11
11
|
const CuraCheckbox = class {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"cura-checkbox.entry.cjs.js","mappings":";;;;;;;AAAA,MAAM,eAAe,GAAG,4tFAA4tF,CAAC;AACrvF,2BAAe,eAAe;;MCQjB,YAAY;;;;;;;;;;;QAyEvB,qBAAgB,GAAG,MAAM,IAAI,CAAC,UAAU,KAAK,MAAM,CAAC;QAEpD,oBAAe,GAAG,MAAM,IAAI,CAAC,SAAS,KAAK,MAAM,CAAC;QAyFlD,gBAAW,GAAG;YACZ,IAAI,IAAI,CAAC,QAAQ;gBAAE,OAAO;YAE1B,IAAI,CAAC,aAAa,GAAG,KAAK,CAAC;YAC3B,IAAI,CAAC,OAAO,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC;YAC7B,IAAI,CAAC,SAAS,CAAC,YAAY,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;YACxC,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,IAAI,CAAC,KAAK,EAA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Aa,CACF,CACT,EACNA,kEAAK,KAAK,EAAE,UAAU,EAAE,QAAQ,EAAE,IAAI,CAAC,UAAU,IAC/CA,oEACE,IAAI,EAAC,UAAU,EACf,IAAI,EAAE,IAAI,CAAC,IAAI,EACf,KAAK,EAAE,IAAI,CAAC,KAAK,EACjB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,OAAO,EAAE,IAAI,CAAC,OAAO,EACrB,aAAa,EAAE,IAAI,CAAC,aAAa,GACjC,EACD,IAAI,CAAC,OAAO,EAAE,CACX,CACF,CACD,EACP;KACH;;;;;;;;;;;;;;","names":["formsSizes","h","Host"],"sources":["src/components/forms/cura-checkbox/cura-checkbox.scss?tag=cura-checkbox&encapsulation=shadow","src/components/forms/cura-checkbox/cura-checkbox.tsx"],"sourcesContent":[":host {\n display: block;\n width: fit-content;\n box-sizing: border-box;\n}\n\n/* Container e Layout */\n.container {\n display: flex;\n align-items: center;\n flex-direction: row-reverse;\n gap: var(--gap);\n}\n\n.position {\n &.container {\n flex-direction: row;\n }\n\n .label-wrapper {\n justify-content: end;\n }\n\n .message {\n text-align: right;\n }\n\n .label {\n order: 1;\n }\n}\n\n.info {\n display: flex;\n flex-direction: column;\n}\n\n.label-wrapper {\n display: flex;\n justify-content: start;\n align-items: center;\n gap: 5px;\n}\n\n/* Control e Checkbox */\n.control {\n width: fit-content;\n cursor: pointer;\n position: relative;\n}\n\n.checkbox {\n appearance: none;\n border: 2px solid var(--neutral-base-neutral-medium);\n border-radius: 4px;\n background: var(--neutral-black-neutral-purewhite);\n flex: 1 0;\n display: flex;\n align-items: center;\n justify-content: center;\n position: relative;\n cursor: pointer;\n box-sizing: border-box;\n width: var(--size);\n height: var(--size);\n flex: 0 0 var(--size);\n}\n\n.icon {\n position: absolute;\n display: flex;\n opacity: 0;\n transition: opacity 0.3s;\n}\n\n/* Estados de Foco */\n.checkbox:focus {\n border-color: var(--info-base) !important;\n}\n\n/* Estado Disabled */\n.disabled .checkbox {\n background: var(--neutral-black-neutral-white);\n border-color: var(--neutral-darker-neutral-base);\n cursor: not-allowed;\n\n &:hover {\n border-color: var(--neutral-darker-neutral-base) !important;\n }\n}\n\n.disabled.checked .checkbox,\n.disabled.indeterminate .checkbox {\n background: var(--neutral-black-neutral-white);\n border-color: var(--neutral-darker-neutral-base);\n\n &:hover {\n border-color: var(--neutral-base-neutral-white);\n background: var(--primary-base-neutral-white);\n }\n}\n\n.disabled .checkbox:focus {\n border-color: var(--neutral-darker-neutral-base) !important;\n}\n\n/* Estado Checked */\n.checked .checkbox,\n.indeterminate .checkbox {\n border-color: var(--color-dark);\n background: var(--color-base);\n\n &:hover {\n border-color: var(--color-light) !important;\n background: var(--color-lighter);\n }\n}\n\n.checked .icon,\n.indeterminate .icon {\n opacity: 1;\n}\n\n/* Hover para não disabled, default, checked, indeterminate */\n:not(.disabled):not(.checked):not(.indeterminate) .checkbox:hover {\n border-color: var(--neutral-purewhite-neutral-dark);\n}\n\n/* Estado Success */\n\n.success.dark .checkbox {\n background: var(--neutral-black) ;\n}\n\n.success .checkbox {\n border-color: var(--success-base);\n background: var(--success-lighter);\n\n &:hover {\n border-color: var(--success-base) !important;\n }\n}\n\n.success.checked .checkbox {\n border-color: var(--success-dark-base);\n background: var(--success-base-lighter);\n\n &:hover {\n border-color: var(--success-dark-base);\n }\n}\n\n/* Estado Error */\n\n.error.dark .checkbox {\n background: var(--neutral-black) ;\n}\n\n.error .checkbox {\n border-color: var(--error-base);\n background: var(--error-lighter);\n\n &:hover {\n border-color: var(--error-base) !important;\n }\n}\n\n.error.checked .checkbox {\n border-color: var(--error-dark-base);\n background: var(--error-base-lighter);\n\n &:hover {\n border-color: var(--error-dark-base);\n }\n}\n\n/* Input */\ninput {\n appearance: none;\n -webkit-appearance: none;\n -moz-appearance: none;\n}\n","import { Component, Prop, Event, Element, h, Host, Watch, EventEmitter, State, AttachInternals } from '@stencil/core';\nimport { formsSizes } from '../cura-forms.definitions';\n\n@Component({\n tag: 'cura-checkbox',\n styleUrl: 'cura-checkbox.scss',\n shadow: true,\n formAssociated: true,\n})\nexport class CuraCheckbox {\n /**\n * Reflects the checked state of the checkbox.\n * Mutable property allowing state change.\n */\n @Prop({ reflect: true, mutable: true }) checked: boolean = false;\n /**\n * Reflects the indeterminate state of the checkbox.\n * Mutable property allowing state change.\n */\n @Prop({ reflect: true, mutable: true }) indeterminate: boolean = false;\n /**\n * Status of the checkbox.\n * Can be 'error', 'success', or 'default'.\n */\n @Prop({ reflect: true, mutable: true }) status: 'error' | 'success' | 'default' = 'default';\n /**\n * Reflects the disabled state of the checkbox.\n */\n @Prop({ reflect: true }) disabled: boolean = false;\n /**\n * Reflects the required state of the checkbox.\n */\n @Prop({ reflect: true }) required: boolean = false;\n /**\n * Text label associated with the checkbox.\n */\n @Prop({ reflect: true }) label: string;\n /**\n * Specifies the tabindex of the checkbox.\n */\n @Prop({ reflect: true }) ontabindex: number = 0;\n /**\n * Position of the label relative to the checkbox.\n * Can be 'left' or 'right'.\n */\n @Prop({ reflect: true }) position: 'left' | 'right' = 'left';\n /**\n * Value associated with the checkbox.\n */\n @Prop({ reflect: true }) value: string;\n /**\n * Name attribute of the checkbox.\n */\n @Prop({ reflect: true }) name: string;\n /**\n * Size of the checkbox.\n * Can be 'small', 'medium', or 'large'.\n */\n @Prop({ reflect: true }) size: 'small' | 'medium' | 'large' = 'medium';\n /**\n * Background theme of the checkbox.\n * Can be 'dark' or 'light'.\n */\n @Prop() background: 'dark' | 'light' = 'light';\n /**\n * iconColor theme of the checkbox.\n * Can be 'dark' or 'light'.\n */\n @Prop() iconColor: 'dark' | 'light' = 'dark';\n /**\n * Color theme of the checkbox.\n */\n @Prop() color = 'accent';\n\n @State() styles = {};\n\n @Element() host: HTMLElement;\n\n @Event() onchange: EventEmitter<{ value: string; checked: boolean; indeterminate: boolean }>;\n\n @AttachInternals() internals: ElementInternals;\n\n isDarkBackground = () => this.background === 'dark';\n\n isDarkIconColor = () => this.iconColor === 'dark';\n\n @Watch('size')\n sizeHandler() {\n this.styles = {\n ...this.styles,\n '--size': `${formsSizes[this.size].size}px`,\n '--gap': `${formsSizes[this.size].gap}px`,\n };\n }\n\n /**\n * Watches changes in color and background properties to update styles.\n */\n @Watch('color')\n @Watch('background')\n setColors() {\n const colors = [\n { name: '--color-base', background: `${this.color}-base` },\n { name: '--color-lighter', background: `${this.color}-lighter` },\n { name: '--color-light', background: `${this.color}-light` },\n { name: '--color-dark', background: `${this.color}-dark` },\n { name: '--info-base', background: 'info-base' },\n { name: '--error-base', background: 'error-base' },\n { name: '--success-lighter', background: 'success-lighter' },\n { name: '--success-base', background: 'success-base' },\n { name: '--success-dark', background: 'success-dark' },\n { name: '--error-lighter', background: 'error-lighter' },\n { name: '--neutral-black', background: 'neutral-black' },\n { name: '--primary-base-neutral-white', background: this.isDarkBackground() ? 'primary-base' : 'neutral-white' },\n { name: '--neutral-base-neutral-medium', background: this.isDarkBackground() ? 'neutral-base' : 'neutral-medium' },\n { name: '--neutral-black-neutral-purewhite', background: this.isDarkBackground() ? 'neutral-black' : 'neutral-purewhite' },\n { name: '--neutral-black-neutral-white', background: this.isDarkBackground() ? 'neutral-black' : 'neutral-white' },\n { name: '--neutral-darker-neutral-base', background: this.isDarkBackground() ? 'neutral-darker' : 'neutral-base' },\n { name: '--neutral-base-neutral-base', background: this.isDarkBackground() ? 'primary-base' : 'neutral-base' },\n { name: '--neutral-purewhite-neutral-dark', background: this.isDarkBackground() ? 'neutral-purewhite' : 'neutral-dark' },\n { name: '--primary-base-neutral-medium', background: this.isDarkBackground() ? 'primary-base' : 'neutral-medium' },\n { name: '--success-base-lighter', background: this.isDarkBackground() ? 'success-base' : 'success-lighter' },\n { name: '--success-dark-base', background: this.isDarkBackground() ? 'success-dark' : 'success-base' },\n { name: '--error-base-lighter', background: this.isDarkBackground() ? 'error-base' : 'error-lighter' },\n { name: '--error-dark-base', background: this.isDarkBackground() ? 'error-dark' : 'error-base' },\n ];\n\n colors.forEach(color => {\n this.styles[color.name] = window.CuraAPI.theme.colors.getColor(color.background);\n });\n this.styles = { ...this.styles };\n }\n\n connectedCallback() {\n this.sizeHandler();\n this.setColors();\n }\n\n /**\n * Callback for form association.\n */\n formAssociatedCallback(form: { ariaLabel: string }) {\n form.ariaLabel = this.label;\n }\n\n /**\n * Callback to restore the switch state from the form.\n */\n formStateRestoreCallback(state: { value: string; checked: boolean; indeterminate: boolean }) {\n this.value = state.value;\n this.checked = state.checked;\n this.indeterminate = state.indeterminate;\n this.internals.setFormValue(this.value);\n }\n\n /**\n * Callback to reset the switch state when the form is reset.\n */\n formResetCallback() {\n this.value = '';\n this.checked = false;\n this.indeterminate = false;\n this.internals.setValidity({});\n this.internals.setFormValue(this.value);\n }\n\n /**\n * Callback to update the switch's disabled state when the form's disabled state changes.\n */\n formDisabledCallback(disabled: boolean) {\n this.disabled = disabled;\n }\n\n handleClick = () => {\n if (this.disabled) return;\n\n this.indeterminate = false;\n this.checked = !this.checked;\n this.internals.setFormValue(this.value);\n this.onchange.emit({ value: this.value, checked: this.checked, indeterminate: this.indeterminate });\n };\n\n getClasses() {\n const classes = {};\n classes['container'] = true;\n classes['checked'] = this.checked;\n classes['disabled'] = this.disabled;\n classes[this.background] = true;\n classes['indeterminate'] = this.indeterminate;\n classes['position'] = this.position === 'right';\n classes[this.status] = true;\n\n return classes;\n }\n\n /**\n * Assigns color based on status and background theme.\n * @param defaultColor Default color.\n */\n @Watch('background')\n @Watch('iconColor')\n assignColor(type: 'icon' | 'label' | 'message') {\n if (this.disabled) return this.isDarkBackground() ? 'neutral-dark' : 'neutral-dark';\n\n const statusColors = {\n success: {\n icon: 'success-dark',\n label: this.isDarkBackground() ? 'success-lighter' : 'success-darker',\n message: this.isDarkBackground() ? 'success-base' : 'success-dark',\n },\n error: {\n icon: 'error-dark',\n label: this.isDarkBackground() ? 'error-lighter' : 'neutral-darker',\n message: this.isDarkBackground() ? 'error-base' : 'error-dark',\n },\n default: {\n icon: this.isDarkIconColor() ? 'neutral-black' : 'neutral-purewhite',\n label: this.isDarkBackground() ? 'neutral-white' : 'neutral-black',\n message: this.isDarkBackground() ? 'primary-lighter' : 'neutral-dark',\n },\n };\n\n return statusColors[this.status][type];\n }\n\n /**\n * Retrieves icon element based on checkbox state.\n */\n getIcon() {\n const iconName = this.indeterminate ? 'minus' : 'check';\n const iconColor = this.assignColor('icon');\n const iconSize = this.size === 'large' ? 20 : 'micro';\n\n return <cura-icon class=\"icon\" name={iconName} size={iconSize} color={iconColor}></cura-icon>;\n }\n\n render() {\n return (\n <Host>\n <div class={this.getClasses()} style={this.styles} onClick={this.handleClick}>\n <div class=\"info\">\n <div class=\"label-wrapper\">\n <cura-label class=\"label\" weight='bold' size={this.size === 'large' ? 'medium' : 'xsmall'} color={this.assignColor('label')}>\n {this.label}\n </cura-label>\n {this.required && <cura-paragraph lineHeight='0%' marginBlock='0' color=\"error-base\" >* </cura-paragraph>}\n </div>\n <cura-label color={this.assignColor('message')} size=\"xsmall\" class=\"message\">\n <slot></slot>\n </cura-label>\n </div>\n <div class={'checkbox'} tabIndex={this.ontabindex}>\n <input\n type=\"checkbox\"\n name={this.name}\n value={this.value}\n disabled={this.disabled}\n required={this.required}\n checked={this.checked}\n indeterminate={this.indeterminate}\n />\n {this.getIcon()}\n </div>\n </div>\n </Host>\n );\n }\n}\n"],"version":3}
|
|
1
|
+
{"file":"cura-checkbox.entry.cjs.js","mappings":";;;;;;;AAAA,MAAM,eAAe,GAAG,61FAA61F,CAAC;AACt3F,2BAAe,eAAe;;MCQjB,YAAY;;;;;;;;;;;QAyEvB,qBAAgB,GAAG,MAAM,IAAI,CAAC,UAAU,KAAK,MAAM,CAAC;QAEpD,oBAAe,GAAG,MAAM,IAAI,CAAC,SAAS,KAAK,MAAM,CAAC;QAyFlD,gBAAW,GAAG;YACZ,IAAI,IAAI,CAAC,QAAQ;gBAAE,OAAO;YAE1B,IAAI,CAAC,aAAa,GAAG,KAAK,CAAC;YAC3B,IAAI,CA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UAAU,EAAC,IAAI,EAAC,WAAW,EAAC,GAAG,EAAC,KAAK,EAAC,YAAY,SAAqB,CACrG,EACNA,yEAAY,KAAK,EAAE,IAAI,CAAC,WAAW,CAAC,SAAS,CAAC,EAAE,IAAI,EAAC,QAAQ,EAAC,KAAK,EAAC,SAAS,IAC3EA,oEAAa,CACF,CACT,EACNA,kEAAK,KAAK,EAAE,UAAU,EAAE,QAAQ,EAAE,IAAI,CAAC,UAAU,IAC/CA,oEACE,IAAI,EAAC,UAAU,EACf,IAAI,EAAE,IAAI,CAAC,IAAI,EACf,KAAK,EAAE,IAAI,CAAC,KAAK,EACjB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,OAAO,EAAE,IAAI,CAAC,OAAO,EACrB,aAAa,EAAE,IAAI,CAAC,aAAa,GACjC,EACD,IAAI,CAAC,OAAO,EAAE,CACX,CACF,CACD,EACP;KACH;;;;;;;;;;;;;;","names":["formsSizes","h","Host"],"sources":["src/components/forms/cura-checkbox/cura-checkbox.scss?tag=cura-checkbox&encapsulation=shadow","src/components/forms/cura-checkbox/cura-checkbox.tsx"],"sourcesContent":[":host {\n display: block;\n width: fit-content;\n box-sizing: border-box;\n}\n\n/* Container e Layout */\n.container {\n display: flex;\n align-items: center;\n flex-direction: row-reverse;\n gap: var(--gap);\n}\n\n.position {\n &.container {\n flex-direction: row;\n }\n\n .label-wrapper {\n justify-content: end;\n }\n\n .message {\n text-align: right;\n }\n\n .label {\n order: 1;\n }\n}\n\n.info {\n display: flex;\n flex-direction: column;\n}\n\n.label-wrapper {\n display: flex;\n justify-content: start;\n align-items: center;\n gap: 5px;\n}\n\n/* Control e Checkbox */\n.control {\n width: fit-content;\n cursor: pointer;\n position: relative;\n}\n\n.checkbox {\n appearance: none;\n border: 2px solid var(--neutral-base-neutral-medium);\n border-radius: 4px;\n background: var(--neutral-black-neutral-purewhite);\n flex: 1 0;\n display: flex;\n align-items: center;\n justify-content: center;\n position: relative;\n cursor: pointer;\n box-sizing: border-box;\n width: var(--size);\n height: var(--size);\n flex: 0 0 var(--size);\n}\n\n.icon {\n position: absolute;\n display: flex;\n opacity: 0;\n transition: opacity 0.3s;\n}\n\n/* Estados de Foco */\n.checkbox:focus {\n border-color: var(--info-base) !important;\n}\n\n/* Estado Disabled */\n.disabled .checkbox {\n background: var(--neutral-black-neutral-white);\n border-color: var(--neutral-darker-neutral-base);\n cursor: not-allowed;\n\n &:hover {\n border-color: var(--neutral-darker-neutral-base) !important;\n }\n}\n\n.disabled.checked .checkbox,\n.disabled.indeterminate .checkbox {\n background: var(--neutral-black-neutral-white);\n border-color: var(--neutral-darker-neutral-base);\n\n &:hover {\n border-color: var(--neutral-base-neutral-white);\n background: var(--primary-base-neutral-white);\n }\n}\n\n.disabled .checkbox:focus {\n border-color: var(--neutral-darker-neutral-base) !important;\n}\n\n/* Estado Checked */\n.checked .checkbox {\n border-color: var(--color-dark);\n background: var(--color-base);\n\n &:hover {\n border-color: var(--color-base) !important;\n background: var(--color-light);\n }\n}\n\n/* Estado Indeterminate */\n.indeterminate .checkbox {\n border-color: var(--color-base);\n background: var(--color-light);\n\n &:hover {\n border-color: var(--color-dark) !important;\n background: var(--color-base);\n }\n}\n\n.checked .icon,\n.indeterminate .icon {\n opacity: 1;\n}\n\n/* Hover para não disabled, default, checked, indeterminate */\n:not(.disabled):not(.checked):not(.indeterminate) .checkbox:hover {\n border-color: var(--neutral-purewhite-neutral-dark);\n}\n\n/* Estado Success */\n\n.success.dark .checkbox {\n background: var(--neutral-black) ;\n}\n\n.success .checkbox {\n border-color: var(--success-base);\n background: var(--success-lighter);\n\n &:hover {\n border-color: var(--success-base) !important;\n }\n}\n\n.success.checked .checkbox {\n border-color: var(--success-dark-base);\n background: var(--success-base-lighter);\n\n &:hover {\n border-color: var(--success-dark-base);\n }\n}\n\n/* Estado Error */\n\n.error.dark .checkbox {\n background: var(--neutral-black) ;\n}\n\n.error .checkbox {\n border-color: var(--error-base);\n background: var(--error-lighter);\n\n &:hover {\n border-color: var(--error-base) !important;\n }\n}\n\n.error.checked .checkbox {\n border-color: var(--error-dark-base);\n background: var(--error-base-lighter);\n\n &:hover {\n border-color: var(--error-dark-base);\n }\n}\n\n/* Input */\ninput {\n appearance: none;\n -webkit-appearance: none;\n -moz-appearance: none;\n}\n","import { Component, Prop, Event, Element, h, Host, Watch, EventEmitter, State, AttachInternals } from '@stencil/core';\nimport { formsSizes } from '../cura-forms.definitions';\n\n@Component({\n tag: 'cura-checkbox',\n styleUrl: 'cura-checkbox.scss',\n shadow: true,\n formAssociated: true,\n})\nexport class CuraCheckbox {\n /**\n * Reflects the checked state of the checkbox.\n * Mutable property allowing state change.\n */\n @Prop({ reflect: true, mutable: true }) checked: boolean = false;\n /**\n * Reflects the indeterminate state of the checkbox.\n * Mutable property allowing state change.\n */\n @Prop({ reflect: true, mutable: true }) indeterminate: boolean = false;\n /**\n * Status of the checkbox.\n * Can be 'error', 'success', or 'default'.\n */\n @Prop({ reflect: true, mutable: true }) status: 'error' | 'success' | 'default' = 'default';\n /**\n * Reflects the disabled state of the checkbox.\n */\n @Prop({ reflect: true }) disabled: boolean = false;\n /**\n * Reflects the required state of the checkbox.\n */\n @Prop({ reflect: true }) required: boolean = false;\n /**\n * Text label associated with the checkbox.\n */\n @Prop({ reflect: true }) label: string;\n /**\n * Specifies the tabindex of the checkbox.\n */\n @Prop({ reflect: true }) ontabindex: number = 0;\n /**\n * Position of the label relative to the checkbox.\n * Can be 'left' or 'right'.\n */\n @Prop({ reflect: true }) position: 'left' | 'right' = 'left';\n /**\n * Value associated with the checkbox.\n */\n @Prop({ reflect: true }) value: string;\n /**\n * Name attribute of the checkbox.\n */\n @Prop({ reflect: true }) name: string;\n /**\n * Size of the checkbox.\n * Can be 'small', 'medium', or 'large'.\n */\n @Prop({ reflect: true }) size: 'small' | 'medium' | 'large' = 'medium';\n /**\n * Background theme of the checkbox.\n * Can be 'dark' or 'light'.\n */\n @Prop() background: 'dark' | 'light' = 'light';\n /**\n * iconColor theme of the checkbox.\n * Can be 'dark' or 'light'.\n */\n @Prop() iconColor: 'dark' | 'light' = 'dark';\n /**\n * Color theme of the checkbox.\n */\n @Prop() color = 'accent';\n\n @State() styles = {};\n\n @Element() host: HTMLElement;\n\n @Event() onchange: EventEmitter<{ value: string; checked: boolean; indeterminate: boolean }>;\n\n @AttachInternals() internals: ElementInternals;\n\n isDarkBackground = () => this.background === 'dark';\n\n isDarkIconColor = () => this.iconColor === 'dark';\n\n @Watch('size')\n sizeHandler() {\n this.styles = {\n ...this.styles,\n '--size': `${formsSizes[this.size].size}px`,\n '--gap': `${formsSizes[this.size].gap}px`,\n };\n }\n\n /**\n * Watches changes in color and background properties to update styles.\n */\n @Watch('color')\n @Watch('background')\n setColors() {\n const colors = [\n { name: '--color-base', background: `${this.color}-base` },\n { name: '--color-lighter', background: `${this.color}-lighter` },\n { name: '--color-light', background: `${this.color}-light` },\n { name: '--color-dark', background: `${this.color}-dark` },\n { name: '--info-base', background: 'info-base' },\n { name: '--error-base', background: 'error-base' },\n { name: '--success-lighter', background: 'success-lighter' },\n { name: '--success-base', background: 'success-base' },\n { name: '--success-dark', background: 'success-dark' },\n { name: '--error-lighter', background: 'error-lighter' },\n { name: '--neutral-black', background: 'neutral-black' },\n { name: '--primary-base-neutral-white', background: this.isDarkBackground() ? 'primary-base' : 'neutral-white' },\n { name: '--neutral-base-neutral-medium', background: this.isDarkBackground() ? 'neutral-base' : 'neutral-medium' },\n { name: '--neutral-black-neutral-purewhite', background: this.isDarkBackground() ? 'neutral-black' : 'neutral-purewhite' },\n { name: '--neutral-black-neutral-white', background: this.isDarkBackground() ? 'neutral-black' : 'neutral-white' },\n { name: '--neutral-darker-neutral-base', background: this.isDarkBackground() ? 'neutral-darker' : 'neutral-base' },\n { name: '--neutral-base-neutral-base', background: this.isDarkBackground() ? 'primary-base' : 'neutral-base' },\n { name: '--neutral-purewhite-neutral-dark', background: this.isDarkBackground() ? 'neutral-purewhite' : 'neutral-dark' },\n { name: '--primary-base-neutral-medium', background: this.isDarkBackground() ? 'primary-base' : 'neutral-medium' },\n { name: '--success-base-lighter', background: this.isDarkBackground() ? 'success-base' : 'success-lighter' },\n { name: '--success-dark-base', background: this.isDarkBackground() ? 'success-dark' : 'success-base' },\n { name: '--error-base-lighter', background: this.isDarkBackground() ? 'error-base' : 'error-lighter' },\n { name: '--error-dark-base', background: this.isDarkBackground() ? 'error-dark' : 'error-base' },\n ];\n\n colors.forEach(color => {\n this.styles[color.name] = window.CuraAPI.theme.colors.getColor(color.background);\n });\n this.styles = { ...this.styles };\n }\n\n connectedCallback() {\n this.sizeHandler();\n this.setColors();\n }\n\n /**\n * Callback for form association.\n */\n formAssociatedCallback(form: { ariaLabel: string }) {\n form.ariaLabel = this.label;\n }\n\n /**\n * Callback to restore the switch state from the form.\n */\n formStateRestoreCallback(state: { value: string; checked: boolean; indeterminate: boolean }) {\n this.value = state.value;\n this.checked = state.checked;\n this.indeterminate = state.indeterminate;\n this.internals.setFormValue(this.value);\n }\n\n /**\n * Callback to reset the switch state when the form is reset.\n */\n formResetCallback() {\n this.value = '';\n this.checked = false;\n this.indeterminate = false;\n this.internals.setValidity({});\n this.internals.setFormValue(this.value);\n }\n\n /**\n * Callback to update the switch's disabled state when the form's disabled state changes.\n */\n formDisabledCallback(disabled: boolean) {\n this.disabled = disabled;\n }\n\n handleClick = () => {\n if (this.disabled) return;\n\n this.indeterminate = false;\n this.checked = !this.checked;\n this.internals.setFormValue(this.value);\n this.onchange.emit({ value: this.value, checked: this.checked, indeterminate: this.indeterminate });\n };\n\n getClasses() {\n const classes = {};\n classes['container'] = true;\n classes['checked'] = this.checked;\n classes['disabled'] = this.disabled;\n classes[this.background] = true;\n classes['indeterminate'] = this.indeterminate;\n classes['position'] = this.position === 'right';\n classes[this.status] = true;\n\n return classes;\n }\n\n /**\n * Assigns color based on status and background theme.\n * @param defaultColor Default color.\n */\n @Watch('background')\n @Watch('iconColor')\n assignColor(type: 'icon' | 'label' | 'message') {\n if (this.disabled) return this.isDarkBackground() ? 'neutral-dark' : 'neutral-dark';\n\n const statusColors = {\n success: {\n icon: 'success-dark',\n label: this.isDarkBackground() ? 'success-lighter' : 'success-darker',\n message: this.isDarkBackground() ? 'success-base' : 'success-dark',\n },\n error: {\n icon: 'error-dark',\n label: this.isDarkBackground() ? 'error-lighter' : 'neutral-darker',\n message: this.isDarkBackground() ? 'error-base' : 'error-dark',\n },\n default: {\n icon: this.isDarkIconColor() ? 'neutral-black' : 'neutral-purewhite',\n label: this.isDarkBackground() ? 'neutral-white' : 'neutral-black',\n message: this.isDarkBackground() ? 'primary-lighter' : 'neutral-dark',\n },\n };\n\n return statusColors[this.status][type];\n }\n\n /**\n * Retrieves icon element based on checkbox state.\n */\n getIcon() {\n const iconName = this.indeterminate ? 'minus' : 'check';\n const iconColor = this.assignColor('icon');\n const iconSize = this.size === 'large' ? 20 : 'micro';\n\n return <cura-icon class=\"icon\" name={iconName} size={iconSize} color={iconColor}></cura-icon>;\n }\n\n render() {\n return (\n <Host>\n <div class={this.getClasses()} style={this.styles} onClick={this.handleClick}>\n <div class=\"info\">\n <div class=\"label-wrapper\">\n <cura-label class=\"label\" weight='bold' size={this.size === 'large' ? 'medium' : 'xsmall'} color={this.assignColor('label')}>\n {this.label}\n </cura-label>\n {this.required && <cura-paragraph lineHeight='0%' marginBlock='0' color=\"error-base\" >* </cura-paragraph>}\n </div>\n <cura-label color={this.assignColor('message')} size=\"xsmall\" class=\"message\">\n <slot></slot>\n </cura-label>\n </div>\n <div class={'checkbox'} tabIndex={this.ontabindex}>\n <input\n type=\"checkbox\"\n name={this.name}\n value={this.value}\n disabled={this.disabled}\n required={this.required}\n checked={this.checked}\n indeterminate={this.indeterminate}\n />\n {this.getIcon()}\n </div>\n </div>\n </Host>\n );\n }\n}\n"],"version":3}
|
|
@@ -52,6 +52,7 @@ const CuraDropdownSearch = class {
|
|
|
52
52
|
}
|
|
53
53
|
}
|
|
54
54
|
};
|
|
55
|
+
this.size = 'large';
|
|
55
56
|
this.status = 'default';
|
|
56
57
|
this.disabled = false;
|
|
57
58
|
this.name = undefined;
|
|
@@ -194,14 +195,14 @@ const CuraDropdownSearch = class {
|
|
|
194
195
|
return {
|
|
195
196
|
'dropdown-input-search': true,
|
|
196
197
|
'dropdown-open': this.isDropdownOpen,
|
|
197
|
-
disabled: this.disabled,
|
|
198
|
+
'disabled': this.disabled,
|
|
198
199
|
[this.status]: true,
|
|
199
200
|
};
|
|
200
201
|
}
|
|
201
202
|
getDropdownClasses() {
|
|
202
203
|
return {
|
|
203
204
|
'dropdown-search-list': true,
|
|
204
|
-
'visible': this.options.length && this.isDropdownOpen ? true : false
|
|
205
|
+
'visible': this.options.length && this.isDropdownOpen ? true : false,
|
|
205
206
|
};
|
|
206
207
|
}
|
|
207
208
|
hostCSSProperties() {
|
|
@@ -211,9 +212,9 @@ const CuraDropdownSearch = class {
|
|
|
211
212
|
}
|
|
212
213
|
render() {
|
|
213
214
|
const isMobileDropdown = this.isMobile && this.isDropdownOpen;
|
|
214
|
-
return (index.h(index.Host, { key: '
|
|
215
|
+
return (index.h(index.Host, { key: 'd0b8f3d5a755ad1898c046b9138f1e67ffaa7551', style: this.hostCSSProperties(), class: "dropdown-overlay" }, index.h("div", { key: '6f39302526074fbeb79258900300e9b0fae32a81', class: `dropdown ${isMobileDropdown ? 'dropdown-mobile' : ''}`, style: this.styles }, index.h("div", { key: 'acc77ef22319099260652c7f3863c360d5f29438', class: this.getClasses() }, this.isMobile && this.isDropdownOpen && (index.h("cura-button-transparent", { key: '2b69691925b17800a5a9ad212106700c79446d70', fontColor: "dark", onClick: () => (this.isMobile = false), iconName: "arrowLeft", size: "medium", iconOnly: true, color: "primary" })), index.h("cura-input-text", { key: 'd13ea595a08ad01dc4f3c551d28d036b73068d5a', disabled: this.disabled, label: this.label, part: "cura-input-field", mode: isMobileDropdown ? 'transparent' : 'default', required: this.required, hideErrorIcon: this.status === 'error', iconName: this.iconName || 'search', value: this.value, status: this.status, onValueChange: e => this.onValueChange(e.target.value), onInput: e => this.handleInputChange(e), onFocus: () => (this.isDropdownOpen = true), onClick: () => (window.innerWidth < 768 ? (this.isMobile = true) : null), onBlur: () => {
|
|
215
216
|
this.handleOnBlur();
|
|
216
|
-
}, placeholder: this.placeholder, size:
|
|
217
|
+
}, placeholder: this.placeholder, size: this.size, onKeyDown: this.handleKeyDown }, index.h("slot", { key: '2a24a3c4e0909eb46e710f894e2a281f024496a4', name: "helperText" }))), index.h("div", { key: 'af42a387f10bb455a812d89878dd65b15858a7ff', id: "dropdown-search-list", class: this.getDropdownClasses() }, index.h("slot", { key: '1d574b5166aad988bfd713abda3f6befebf44335', name: "dropdown-search-option", onSlotchange: this.handleSlotChange })))));
|
|
217
218
|
}
|
|
218
219
|
get host() { return index.getElement(this); }
|
|
219
220
|
static get watchers() { return {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"cura-dropdown-search.entry.cjs.js","mappings":";;;;;;AAAA,MAAM,qBAAqB,GAAG,q1EAAq1E,CAAC;AACp3E,iCAAe,qBAAqB;;MCMvB,kBAAkB;;;;;QA8GrB,mBAAc,GAA0B,IAAI,CAAC;QAkE7C,qBAAgB,GAAG;YACzB,IAAI,CAAC,OAAO,GAAG,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,gBAAgB,CAAC,6BAA6B,CAAC,CAAC,CAAC;YACrF,IAAI,CAAC,0BAA0B,EAAE,CAAC;YAClC,IAAI,CAAC,kBAAkB,EAAE,CAAC;SAC3B,CAAC;QAiBM,sBAAiB,GAAG,CAAC,KAAY;YACvC,MAAM,KAAK,GAAG,KAAK,CAAC,MAA0B,CAAC;YAC/C,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC,KAAK,CAAC;YACzB,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;;SAEhC,CAAC;QAgBM,kBAAa,GAAG,CAAC,KAAoB;YAC3C,IAAI,KAAK,CAA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C7B,IAAI,EAAC,OAAO,EACZ,SAAS,EAAE,IAAI,CAAC,aAAa,IAE7BA,mEAAM,IAAI,EAAC,YAAY,GAAQ,CACf,CACd,EACNA,kEAAK,EAAE,EAAC,sBAAsB,EAAC,KAAK,EAAE,IAAI,CAAC,kBAAkB,EAAE,IAC7DA,mEAAM,IAAI,EAAC,wBAAwB,EAAC,YAAY,EAAE,IAAI,CAAC,gBAAgB,GAAS,CAC5E,CACF,CACD,EACP;KACH;;;;;;;;;;","names":["h","Host"],"sources":["src/components/forms/cura-dropdown-search/cura-dropdown-search.scss?tag=cura-dropdown-search&encapsulation=shadow","src/components/forms/cura-dropdown-search/cura-dropdown-search.tsx"],"sourcesContent":["@import '../../../scss/mixins/shadows.scss';\n\n:host {\n display: block;\n width: 100%;\n box-sizing: border-box;\n}\n\n.dropdown {\n display: flex;\n position: relative;\n\n flex-direction: column;\n width: inherit;\n\n .dropdown-search-list {\n z-index: 1000;\n }\n\n &-input-search {\n width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n background: transparent;\n\n\n &.dropdown-open {\n ::part(cura-input-field) {\n border-radius: 4px 4px 0px 0px;\n }\n ::slotted([slot='helperText']) {\n display: none;\n }\n\n cura-input-text {\n ::slotted([slot='helperText']) {\n display: none;\n }\n }\n }\n }\n\n &-search-list {\n position: absolute;\n top: calc(100% - 8px);\n width: 100%;\n max-height: var(--dropdown-max-height);\n padding: 12px 12px;\n margin: 0;\n box-sizing: border-box;\n @include shadow-level3(--neutral-black-shadow);\n border-radius: 0px 0px 4px 4px;\n border-top: 0 var(--neutral-light);\n border-right: 2px solid var(--neutral-light);\n border-bottom: 2px solid var(--neutral-light);\n border-left: 2px solid var(--neutral-light);\n background-color: var(--neutral-purewhite);\n list-style: none;\n overflow-y: auto;\n display: none;\n\n &.visible {\n display: block;\n }\n\n &-input-search {\n width: inherit;\n\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 16px 8px;\n border-bottom: 2px solid var(--info-base);\n background-color: var(--neutral-purewhite);\n\n cura-input-text {\n width: inherit;\n }\n\n &.error {\n background-color: var(--error-lighter);\n border-bottom: 2px solid var(--error-dark);\n }\n }\n }\n\n &-mobile {\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n width: 100%;\n\n z-index: 10000;\n .dropdown-input-search {\n display: flex;\n gap: 4px;\n padding: 12px 8px;\n background-color: var(--neutral-purewhite);\n border-bottom: 2px solid var(--info-base);\n z-index: 10000;\n cura-button-transparent {\n display: flex;\n }\n &.error {\n background-color: var(--error-lighter);\n border-bottom: 2px solid var(--error-dark);\n }\n &.dropdown-open {\n display: flex;\n\n ::slotted([slot='helperText']) {\n display: block;\n }\n }\n }\n .dropdown-search-list {\n position: static;\n width: 100%;\n height: 100%;\n max-height: none;\n padding: 12px 12px;\n margin: 0;\n box-sizing: border-box;\n box-shadow: none;\n border: none;\n background-color: var(--neutral-purewhite);\n list-style: none;\n overflow-y: auto;\n z-index: 10000;\n }\n }\n}\n","import { Component, Host, Prop, State, Event, EventEmitter, Element, Watch, h } from '@stencil/core';\n\n@Component({\n tag: 'cura-dropdown-search',\n styleUrl: 'cura-dropdown-search.scss',\n shadow: true,\n})\nexport class CuraDropdownSearch {\n /**\n * Define the status of the dropdown search.\n */\n @Prop({ reflect: true }) status: 'error' | 'default' = 'default';\n\n /**\n * Whether the select component is disabled.\n * Reflects as an attribute in the DOM.\n */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /**\n * The name of the dropdown search component.\n */\n @Prop({ reflect: true }) name: string;\n\n /**\n * Indicates if the dropdown search is required.\n */\n @Prop({ reflect: true, mutable: true }) required: boolean = false;\n\n /**\n * Indicates if the dropdown search is selected.\n */\n @Prop({ reflect: true, mutable: true }) selected: boolean = false;\n\n /**\n * The value of the dropdown search.\n */\n @Prop({ reflect: true, mutable: true }) value: string = '';\n\n /**\n * The placeholder text for the dropdown search.\n */\n @Prop({ reflect: true, mutable: true }) placeholder: string = '';\n\n /**\n * The label for the dropdown search.\n */\n @Prop({ reflect: true, mutable: true }) label: string = '';\n\n /**\n * Custom icon name. Default: search.\n */\n @Prop({reflect: true}) iconName = 'search';\n\n /**\n * CSS max-height property for dropdown item.\n * Default to 630px\n */\n @Prop({reflect: true}) dropdownMaxHeight = '630px';\n\n /**\n * Reference to the host element.\n */\n @Element() host: HTMLElement;\n\n /**\n * Indicates if the overlay is visible.\n */\n @State() overlayVisible: boolean = false;\n\n /**\n * Event emitted when the value changes.\n */\n @Event() valueChanged: EventEmitter<string>;\n\n /**\n * Indicates if the dropdown is open.\n */\n @State() isDropdownOpen: boolean = false;\n\n /**\n * Styles for the component.\n\n */\n @State() styles = {};\n\n /**\n * Indicates if the component is being viewed on a mobile device.\n */\n @State() isMobile: boolean = window.innerWidth < 768;\n\n /**\n * The mode of the dropdown search.\n */\n @State() mode: 'default' | 'transparent' = 'default';\n\n @Event() onselect: EventEmitter;\n\n @State() inputTextRef!: HTMLCuraInputTextElement;\n\n /**\n * Indicates if the input is on blur.\n */\n @State() isOnBlurInput: boolean = true;\n\n /**\n * The index of the currently hovered option.\n */\n @State() hoveredIndex: number = -1;\n\n /**\n * The options for the dropdown search.\n * @type {HTMLCuraDropdownSearchOptionElement[]}\n */\n\n weights;\n\n private overlayElement: HTMLDivElement | null = null;\n\n @State() options: HTMLCuraDropdownSearchOptionElement[] = [];\n\n connectedCallback() {\n this.weights = window.CuraAPI.theme.fonts.getWeights();\n this.styles['--info-base'] = window.CuraAPI.theme.colors.getColor('info-base');\n this.styles['--neutral-purewhite'] = window.CuraAPI.theme.colors.getColor('neutral-purewhite');\n this.styles['--neutral-light'] = window.CuraAPI.theme.colors.getColor('neutral-light');\n this.styles['--neutral-dark'] = window.CuraAPI.theme.colors.getColor('neutral-dark');\n this.styles['--neutral-black-shadow'] = window.CuraAPI.theme.colors.getColor(`neutral-black`, 0.16);\n this.styles['--error-dark'] = window.CuraAPI.theme.colors.getColor('error-dark');\n this.styles['--error-lighter'] = window.CuraAPI.theme.colors.getColor('error-lighter');\n this.styles['--breakpoints'] = window.CuraAPI.theme.breakpoints.get();\n this.styles['--font-size'] = window.CuraAPI.theme.fonts.getSize();\n this.styles['--font-family'] = window.CuraAPI.theme.fonts.getFamily();\n this.styles['--font-weight-medium'] = this.weights.medium;\n }\n\n @Watch('value')\n onValueChange(newValue: string) {\n this.updateSelectedOption(newValue);\n this.valueChanged.emit(newValue);\n }\n\n componentWillLoad() {\n this.updateSelectedOption(this.value);\n }\n\n componentDidRender() {\n if (this.isDropdownOpen && this.isMobile) {\n this.showOverlay();\n } else {\n this.removeOverlay();\n }\n }\n componentDidLoad() {\n window.addEventListener('resize', this.handleResize);\n }\n\n disconnectedCallback() {\n window.removeEventListener('resize', this.handleResize);\n }\n\n private showOverlay() {\n if (!this.overlayElement) {\n this.overlayElement = document.createElement('div');\n this.overlayElement.className = 'dropdown-overlay';\n this.overlayElement.style.position = 'fixed';\n this.overlayElement.style.top = '0';\n this.overlayElement.style.left = '0';\n this.overlayElement.style.width = '100%';\n this.overlayElement.style.height = '100%';\n this.overlayElement.style.zIndex = '9999';\n this.overlayElement.style.backgroundColor = 'white';\n document.body.appendChild(this.overlayElement);\n }\n }\n\n private removeOverlay() {\n if (this.overlayElement && this.overlayElement.parentNode === document.body) {\n document.body.removeChild(this.overlayElement);\n this.overlayElement = null;\n }\n }\n\n private handleSlotChange = () => {\n this.options = Array.from(this.host.querySelectorAll('cura-dropdown-search-option'));\n this.addClickListenersToOptions();\n this.updateHoveredIndex();\n };\n\n private addClickListenersToOptions() {\n this.options.forEach((option, index) => {\n option.addEventListener('optionSelected', () => this.onSelectedOption(index));\n });\n }\n\n private updateSelectedOption(value: string) {\n const selectedOptionIndex = this.options.findIndex(option => option.getAttribute('value') === value);\n this.hoveredIndex = selectedOptionIndex;\n this.updateOptionAttribute('hovered', this.hoveredIndex);\n this.updateOptionAttribute('selected', this.hoveredIndex);\n\n this.scrollIntoView();\n }\n\n private handleInputChange = (event: Event) => {\n const input = event.target as HTMLInputElement;\n this.value = input.value;\n this.onValueChange(this.value);\n // this.valueChanged.emit(this.value);\n };\n\n private onSelectedOption(index: number) {\n const selectedOption = this.options[index];\n if(selectedOption.selectable) {\n const selectedValue = selectedOption.getAttribute('value') || selectedOption.textContent;\n\n this.value = selectedValue || '';\n this.updateSelectedOption(this.value);\n\n this.isDropdownOpen = false;\n this.isOnBlurInput = true;\n this.removeOverlay();\n }\n }\n\n private handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === 'ArrowDown') {\n event.preventDefault();\n this.moveHighlight(1);\n } else if (event.key === 'ArrowUp') {\n event.preventDefault();\n this.moveHighlight(-1);\n } else if (event.key === 'Enter') {\n event.preventDefault();\n if (this.hoveredIndex > -1) {\n this.handleOnBlur();\n this.onSelectedOption(this.hoveredIndex);\n }\n }\n };\n\n private moveHighlight(direction: number) {\n const visibleOptions = this.options;\n const newIndex = (this.hoveredIndex + direction + visibleOptions.length) % visibleOptions.length;\n this.hoveredIndex = newIndex;\n this.updateOptionAttribute('hovered', this.hoveredIndex);\n this.scrollIntoView();\n }\n\n private updateOptionAttribute(attribute: string, indexToUpdate: number) {\n this.options.forEach((option, index) => {\n (option as any)[attribute] = index === indexToUpdate;\n });\n }\n\n private updateHoveredIndex() {\n const visibleOptions = this.options;\n const currentValue = this.value;\n this.hoveredIndex = visibleOptions.findIndex(option => option.getAttribute('value') === currentValue);\n }\n\n private scrollIntoView() {\n const container = this.host.shadowRoot?.querySelector('.dropdown-search-list');\n const hoveredOption = this.options[this.hoveredIndex];\n\n if (container && hoveredOption) {\n const optionRect = hoveredOption.getBoundingClientRect();\n const containerRect = container.getBoundingClientRect();\n\n if (optionRect.bottom > containerRect.bottom) {\n container.scrollTop += optionRect.bottom - containerRect.bottom;\n }\n\n if (optionRect.top < containerRect.top) {\n container.scrollTop -= containerRect.top - optionRect.top;\n }\n }\n }\n\n private handleResize = () => {\n this.isMobile = window.innerWidth < 768;\n if (this.isDropdownOpen) {\n if (this.isMobile) {\n this.showOverlay();\n } else {\n this.removeOverlay();\n }\n }\n };\n\n handleOnBlur() {\n if (this.isOnBlurInput === true) {\n setTimeout(() => {\n this.isDropdownOpen = false;\n this.removeOverlay();\n }, 200);\n }\n }\n getClasses() {\n return {\n 'dropdown-input-search': true,\n 'dropdown-open': this.isDropdownOpen,\n disabled: this.disabled,\n [this.status]: true,\n };\n }\n\n getDropdownClasses() {\n return {\n 'dropdown-search-list': true,\n 'visible': this.options.length && this.isDropdownOpen ? true : false\n };\n }\n\n hostCSSProperties() {\n return {\n '--dropdown-max-height': this.dropdownMaxHeight,\n };\n }\n\n render() {\n const isMobileDropdown = this.isMobile && this.isDropdownOpen;\n return (\n <Host style={this.hostCSSProperties()} class=\"dropdown-overlay\">\n <div class={`dropdown ${isMobileDropdown ? 'dropdown-mobile' : ''}`} style={this.styles}>\n <div class={this.getClasses()}>\n {this.isMobile && this.isDropdownOpen && (\n <cura-button-transparent\n fontColor=\"dark\"\n onClick={() => (this.isMobile = false)}\n iconName=\"arrowLeft\"\n size=\"medium\"\n iconOnly\n color=\"primary\"\n ></cura-button-transparent>\n )}\n <cura-input-text\n disabled={this.disabled}\n label={this.label}\n part=\"cura-input-field\"\n mode={isMobileDropdown ? 'transparent' : 'default'}\n required={this.required}\n hideErrorIcon={this.status === 'error'}\n iconName={this.iconName || 'search'}\n value={this.value}\n status={this.status}\n onValueChange={e => this.onValueChange(e.target.value as string)}\n onInput={e => this.handleInputChange(e)}\n onFocus={() => (this.isDropdownOpen = true)}\n onClick={() => (window.innerWidth < 768 ? (this.isMobile = true) : null)}\n onBlur={() => {\n this.handleOnBlur();\n }}\n placeholder={this.placeholder}\n size=\"large\"\n onKeyDown={this.handleKeyDown}\n >\n <slot name=\"helperText\"></slot>\n </cura-input-text>\n </div>\n <div id=\"dropdown-search-list\" class={this.getDropdownClasses()}>\n <slot name=\"dropdown-search-option\" onSlotchange={this.handleSlotChange}></slot>\n </div>\n </div>\n </Host>\n );\n }\n}\n"],"version":3}
|
|
1
|
+
{"file":"cura-dropdown-search.entry.cjs.js","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,GAAG,SAAS,EAClD,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,aAAa,EAAE,IAAI,CAAC,MAAM,KAAK,OAAO,EACtC,QAAQ,EAAE,IAAI,CAAC,QAAQ,IAAI,QAAQ,EACnC,KAAK,EAAE,IAAI,CAAC,KAAK,EACjB,MAAM,EAAE,IAAI,CAAC,MAAM,EACnB,aAAa,EAAE,CAAC,IAAI,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,MAAM,CAAC,KAAe,CAAC,EAChE,OAAO,EAAE,CAAC,IAAI,IAAI,CAAC,iBAAiB,CAAC,CAAC,CAAC,EACvC,OAAO,EAAE,OAAO,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,EAC3C,OAAO,EAAE,OAAO,MAAM,CAAC,UAAU,GAAG,GAAG,IAAI,IAAI,CAAC,QAAQ,GAAG,IAAI,IAAI,IAAI,CAAC,EACxE,MAAM,EAAE;gBACN,IAAI,CAAC,YAAY,EAAE,CAAC;aACrB,EACD,WAAW,EAAE,IAAI,CAAC,WAAW,EAC7B,IAAI,EAAE,IAAI,CAAC,IAAI,EACf,SAAS,EAAE,IAAI,CAAC,aAAa,IAE7BA,mEAAM,IAAI,EAAC,YAAY,GAAQ,CACf,CACd,EACNA,kEAAK,EAAE,EAAC,sBAAsB,EAAC,KAAK,EAAE,IAAI,CAAC,kBAAkB,EAAE,IAC7DA,mEAAM,IAAI,EAAC,wBAAwB,EAAC,YAAY,EAAE,IAAI,CAAC,gBAAgB,GAAS,CAC5E,CACF,CACD,EACP;KACH;;;;;;;;;;","names":["h","Host"],"sources":["src/components/forms/cura-dropdown-search/cura-dropdown-search.scss?tag=cura-dropdown-search&encapsulation=shadow","src/components/forms/cura-dropdown-search/cura-dropdown-search.tsx"],"sourcesContent":["@import '../../../scss/mixins/shadows.scss';\n\n:host {\n display: block;\n width: 100%;\n box-sizing: border-box;\n}\n\n.dropdown {\n display: flex;\n position: relative;\n\n flex-direction: column;\n width: inherit;\n\n .dropdown-search-list {\n z-index: 1000;\n }\n\n &-input-search {\n width: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n background: transparent;\n\n\n &.dropdown-open {\n ::part(cura-input-field) {\n border-radius: 4px 4px 0px 0px;\n }\n ::slotted([slot='helperText']) {\n display: none;\n }\n\n cura-input-text {\n ::slotted([slot='helperText']) {\n display: none;\n }\n }\n }\n }\n\n &-search-list {\n position: absolute;\n top: calc(100% - 8px);\n width: 100%;\n max-height: var(--dropdown-max-height);\n padding: 12px 12px;\n margin: 0;\n box-sizing: border-box;\n @include shadow-level3(--neutral-black-shadow);\n border-radius: 0px 0px 4px 4px;\n border-top: 0 var(--neutral-light);\n border-right: 2px solid var(--neutral-light);\n border-bottom: 2px solid var(--neutral-light);\n border-left: 2px solid var(--neutral-light);\n background-color: var(--neutral-purewhite);\n list-style: none;\n overflow-y: auto;\n display: none;\n\n &.visible {\n display: block;\n }\n\n &-input-search {\n width: inherit;\n\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 16px 8px;\n border-bottom: 2px solid var(--info-base);\n background-color: var(--neutral-purewhite);\n\n cura-input-text {\n width: inherit;\n }\n\n &.error {\n background-color: var(--error-lighter);\n border-bottom: 2px solid var(--error-dark);\n }\n }\n }\n\n &-mobile {\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n width: 100%;\n\n z-index: 10000;\n .dropdown-input-search {\n display: flex;\n gap: 4px;\n padding: 12px 8px;\n background-color: var(--neutral-purewhite);\n border-bottom: 2px solid var(--info-base);\n z-index: 10000;\n cura-button-transparent {\n display: flex;\n }\n &.error {\n background-color: var(--error-lighter);\n border-bottom: 2px solid var(--error-dark);\n }\n &.dropdown-open {\n display: flex;\n\n ::slotted([slot='helperText']) {\n display: block;\n }\n }\n }\n .dropdown-search-list {\n position: static;\n width: 100%;\n height: 100%;\n max-height: none;\n padding: 12px 12px;\n margin: 0;\n box-sizing: border-box;\n box-shadow: none;\n border: none;\n background-color: var(--neutral-purewhite);\n list-style: none;\n overflow-y: auto;\n z-index: 10000;\n }\n }\n}\n","import { Component, Host, Prop, State, Event, EventEmitter, Element, Watch, h } from '@stencil/core';\n\n@Component({\n tag: 'cura-dropdown-search',\n styleUrl: 'cura-dropdown-search.scss',\n shadow: true,\n})\nexport class CuraDropdownSearch {\n /**\n * Size of the dropdown search mode default: 'small', 'medium', or 'large' (default: 'large')\n */\n @Prop({ reflect: true, mutable: true }) size: 'small' | 'medium' | 'large' = 'large';\n\n /**\n * Define the status of the dropdown search.\n */\n @Prop({ reflect: true }) status: 'error' | 'default' = 'default';\n\n /**\n * Whether the select component is disabled.\n * Reflects as an attribute in the DOM.\n */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /**\n * The name of the dropdown search component.\n */\n @Prop({ reflect: true }) name: string;\n\n /**\n * Indicates if the dropdown search is required.\n */\n @Prop({ reflect: true, mutable: true }) required: boolean = false;\n\n /**\n * Indicates if the dropdown search is selected.\n */\n @Prop({ reflect: true, mutable: true }) selected: boolean = false;\n\n /**\n * The value of the dropdown search.\n */\n @Prop({ reflect: true, mutable: true }) value: string = '';\n\n /**\n * The placeholder text for the dropdown search.\n */\n @Prop({ reflect: true, mutable: true }) placeholder: string = '';\n\n /**\n * The label for the dropdown search.\n */\n @Prop({ reflect: true, mutable: true }) label: string = '';\n\n /**\n * Custom icon name. Default: search.\n */\n @Prop({ reflect: true }) iconName = 'search';\n\n /**\n * CSS max-height property for dropdown item.\n * Default to 630px\n */\n @Prop({ reflect: true }) dropdownMaxHeight = '630px';\n\n /**\n * Reference to the host element.\n */\n @Element() host: HTMLElement;\n\n /**\n * Indicates if the overlay is visible.\n */\n @State() overlayVisible: boolean = false;\n\n /**\n * Event emitted when the value changes.\n */\n @Event() valueChanged: EventEmitter<string>;\n\n /**\n * Indicates if the dropdown is open.\n */\n @State() isDropdownOpen: boolean = false;\n\n /**\n * Styles for the component.\n\n */\n @State() styles = {};\n\n /**\n * Indicates if the component is being viewed on a mobile device.\n */\n @State() isMobile: boolean = window.innerWidth < 768;\n\n /**\n * The mode of the dropdown search.\n */\n @State() mode: 'default' | 'transparent' = 'default';\n\n @Event() onselect: EventEmitter;\n\n @State() inputTextRef!: HTMLCuraInputTextElement;\n\n /**\n * Indicates if the input is on blur.\n */\n @State() isOnBlurInput: boolean = true;\n\n /**\n * The index of the currently hovered option.\n */\n @State() hoveredIndex: number = -1;\n\n /**\n * The options for the dropdown search.\n * @type {HTMLCuraDropdownSearchOptionElement[]}\n */\n\n weights;\n\n private overlayElement: HTMLDivElement | null = null;\n\n @State() options: HTMLCuraDropdownSearchOptionElement[] = [];\n\n connectedCallback() {\n this.weights = window.CuraAPI.theme.fonts.getWeights();\n this.styles['--info-base'] = window.CuraAPI.theme.colors.getColor('info-base');\n this.styles['--neutral-purewhite'] = window.CuraAPI.theme.colors.getColor('neutral-purewhite');\n this.styles['--neutral-light'] = window.CuraAPI.theme.colors.getColor('neutral-light');\n this.styles['--neutral-dark'] = window.CuraAPI.theme.colors.getColor('neutral-dark');\n this.styles['--neutral-black-shadow'] = window.CuraAPI.theme.colors.getColor(`neutral-black`, 0.16);\n this.styles['--error-dark'] = window.CuraAPI.theme.colors.getColor('error-dark');\n this.styles['--error-lighter'] = window.CuraAPI.theme.colors.getColor('error-lighter');\n this.styles['--breakpoints'] = window.CuraAPI.theme.breakpoints.get();\n this.styles['--font-size'] = window.CuraAPI.theme.fonts.getSize();\n this.styles['--font-family'] = window.CuraAPI.theme.fonts.getFamily();\n this.styles['--font-weight-medium'] = this.weights.medium;\n }\n\n @Watch('value')\n onValueChange(newValue: string) {\n this.updateSelectedOption(newValue);\n this.valueChanged.emit(newValue);\n }\n\n componentWillLoad() {\n this.updateSelectedOption(this.value);\n }\n\n componentDidRender() {\n if (this.isDropdownOpen && this.isMobile) {\n this.showOverlay();\n } else {\n this.removeOverlay();\n }\n }\n componentDidLoad() {\n window.addEventListener('resize', this.handleResize);\n }\n\n disconnectedCallback() {\n window.removeEventListener('resize', this.handleResize);\n }\n\n private showOverlay() {\n if (!this.overlayElement) {\n this.overlayElement = document.createElement('div');\n this.overlayElement.className = 'dropdown-overlay';\n this.overlayElement.style.position = 'fixed';\n this.overlayElement.style.top = '0';\n this.overlayElement.style.left = '0';\n this.overlayElement.style.width = '100%';\n this.overlayElement.style.height = '100%';\n this.overlayElement.style.zIndex = '9999';\n this.overlayElement.style.backgroundColor = 'white';\n document.body.appendChild(this.overlayElement);\n }\n }\n\n private removeOverlay() {\n if (this.overlayElement && this.overlayElement.parentNode === document.body) {\n document.body.removeChild(this.overlayElement);\n this.overlayElement = null;\n }\n }\n\n private handleSlotChange = () => {\n this.options = Array.from(this.host.querySelectorAll('cura-dropdown-search-option'));\n this.addClickListenersToOptions();\n this.updateHoveredIndex();\n };\n\n private addClickListenersToOptions() {\n this.options.forEach((option, index) => {\n option.addEventListener('optionSelected', () => this.onSelectedOption(index));\n });\n }\n\n private updateSelectedOption(value: string) {\n const selectedOptionIndex = this.options.findIndex(option => option.getAttribute('value') === value);\n this.hoveredIndex = selectedOptionIndex;\n this.updateOptionAttribute('hovered', this.hoveredIndex);\n this.updateOptionAttribute('selected', this.hoveredIndex);\n\n this.scrollIntoView();\n }\n\n private handleInputChange = (event: Event) => {\n const input = event.target as HTMLInputElement;\n this.value = input.value;\n this.onValueChange(this.value);\n // this.valueChanged.emit(this.value);\n };\n\n private onSelectedOption(index: number) {\n const selectedOption = this.options[index];\n if (selectedOption.selectable) {\n const selectedValue = selectedOption.getAttribute('value') || selectedOption.textContent;\n\n this.value = selectedValue || '';\n this.updateSelectedOption(this.value);\n\n this.isDropdownOpen = false;\n this.isOnBlurInput = true;\n this.removeOverlay();\n }\n }\n\n private handleKeyDown = (event: KeyboardEvent) => {\n if (event.key === 'ArrowDown') {\n event.preventDefault();\n this.moveHighlight(1);\n } else if (event.key === 'ArrowUp') {\n event.preventDefault();\n this.moveHighlight(-1);\n } else if (event.key === 'Enter') {\n event.preventDefault();\n if (this.hoveredIndex > -1) {\n this.handleOnBlur();\n this.onSelectedOption(this.hoveredIndex);\n }\n }\n };\n\n private moveHighlight(direction: number) {\n const visibleOptions = this.options;\n const newIndex = (this.hoveredIndex + direction + visibleOptions.length) % visibleOptions.length;\n this.hoveredIndex = newIndex;\n this.updateOptionAttribute('hovered', this.hoveredIndex);\n this.scrollIntoView();\n }\n\n private updateOptionAttribute(attribute: string, indexToUpdate: number) {\n this.options.forEach((option, index) => {\n (option as any)[attribute] = index === indexToUpdate;\n });\n }\n\n private updateHoveredIndex() {\n const visibleOptions = this.options;\n const currentValue = this.value;\n this.hoveredIndex = visibleOptions.findIndex(option => option.getAttribute('value') === currentValue);\n }\n\n private scrollIntoView() {\n const container = this.host.shadowRoot?.querySelector('.dropdown-search-list');\n const hoveredOption = this.options[this.hoveredIndex];\n\n if (container && hoveredOption) {\n const optionRect = hoveredOption.getBoundingClientRect();\n const containerRect = container.getBoundingClientRect();\n\n if (optionRect.bottom > containerRect.bottom) {\n container.scrollTop += optionRect.bottom - containerRect.bottom;\n }\n\n if (optionRect.top < containerRect.top) {\n container.scrollTop -= containerRect.top - optionRect.top;\n }\n }\n }\n\n private handleResize = () => {\n this.isMobile = window.innerWidth < 768;\n if (this.isDropdownOpen) {\n if (this.isMobile) {\n this.showOverlay();\n } else {\n this.removeOverlay();\n }\n }\n };\n\n handleOnBlur() {\n if (this.isOnBlurInput === true) {\n setTimeout(() => {\n this.isDropdownOpen = false;\n this.removeOverlay();\n }, 200);\n }\n }\n getClasses() {\n return {\n 'dropdown-input-search': true,\n 'dropdown-open': this.isDropdownOpen,\n 'disabled': this.disabled,\n [this.status]: true,\n };\n }\n\n getDropdownClasses() {\n return {\n 'dropdown-search-list': true,\n 'visible': this.options.length && this.isDropdownOpen ? true : false,\n };\n }\n\n hostCSSProperties() {\n return {\n '--dropdown-max-height': this.dropdownMaxHeight,\n };\n }\n\n render() {\n const isMobileDropdown = this.isMobile && this.isDropdownOpen;\n return (\n <Host style={this.hostCSSProperties()} class=\"dropdown-overlay\">\n <div class={`dropdown ${isMobileDropdown ? 'dropdown-mobile' : ''}`} style={this.styles}>\n <div class={this.getClasses()}>\n {this.isMobile && this.isDropdownOpen && (\n <cura-button-transparent\n fontColor=\"dark\"\n onClick={() => (this.isMobile = false)}\n iconName=\"arrowLeft\"\n size=\"medium\"\n iconOnly\n color=\"primary\"\n ></cura-button-transparent>\n )}\n <cura-input-text\n disabled={this.disabled}\n label={this.label}\n part=\"cura-input-field\"\n mode={isMobileDropdown ? 'transparent' : 'default'}\n required={this.required}\n hideErrorIcon={this.status === 'error'}\n iconName={this.iconName || 'search'}\n value={this.value}\n status={this.status}\n onValueChange={e => this.onValueChange(e.target.value as string)}\n onInput={e => this.handleInputChange(e)}\n onFocus={() => (this.isDropdownOpen = true)}\n onClick={() => (window.innerWidth < 768 ? (this.isMobile = true) : null)}\n onBlur={() => {\n this.handleOnBlur();\n }}\n placeholder={this.placeholder}\n size={this.size}\n onKeyDown={this.handleKeyDown}\n >\n <slot name=\"helperText\"></slot>\n </cura-input-text>\n </div>\n <div id=\"dropdown-search-list\" class={this.getDropdownClasses()}>\n <slot name=\"dropdown-search-option\" onSlotchange={this.handleSlotChange}></slot>\n </div>\n </div>\n </Host>\n );\n }\n}\n"],"version":3}
|
package/dist/cjs/cura.cjs.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-98e7ba54.js');
|
|
6
|
-
const appGlobals = require('./app-globals-
|
|
6
|
+
const appGlobals = require('./app-globals-4d07f363.js');
|
|
7
7
|
|
|
8
8
|
/*
|
|
9
9
|
Stencil Client Patch Browser v4.22.0 | MIT Licensed | https://stenciljs.com
|
|
@@ -19,7 +19,7 @@ var patchBrowser = () => {
|
|
|
19
19
|
|
|
20
20
|
patchBrowser().then(async (options) => {
|
|
21
21
|
await appGlobals.globalScripts();
|
|
22
|
-
return index.bootstrapLazy([["cura-accordion_12.cjs",[[65,"cura-button",{"type":[513],"size":[513],"disabled":[516],"isLoading":[516,"is-loading"],"iconName":[513,"icon-name"],"iconset":[513],"iconPosition":[513,"icon-position"],"iconOnly":[516,"icon-only"],"href":[513],"target":[513],"color":[1],"background":[513],"fontColor":[513,"font-color"],"textAlign":[513,"text-align"],"justify":[516],"styles":[32],"hovered":[32]},null,{"background":["setColors"],"color":["setColors"]}],[1,"cura-accordion-item",{"label":[513],"iconSize":[514,"icon-size"],"openIcon":[513,"open-icon"],"closeIcon":[513,"close-icon"],"iconColor":[513,"icon-color"],"iconActiveColor":[513,"icon-active-color"],"colorMode":[1,"color-mode"],"opened":[1540],"styles":[32]}],[1,"cura-accordion",{"color":[513],"activeColor":[513,"active-color"],"colorMode":[513,"color-mode"],"iconSize":[514,"icon-size"],"openIcon":[513,"open-icon"],"closeIcon":[513,"close-icon"],"iconColor":[513,"icon-color"],"iconActiveColor":[513,"icon-active-color"],"behavior":[513],"styles":[32]},null,{"color":["handleChangeColor"],"activeColor":["handleChangeColor"]}],[1,"cura-page-template",{"contentwidth":[513]}],[65,"cura-input-text",{"mode":[1537],"status":[1537],"size":[1537],"type":[513],"inputMode":[513,"input-mode"],"label":[513],"name":[513],"placeholder":[513],"value":[1032],"iconName":[1537,"icon-name"],"helperText":[1537,"helper-text"],"disabled":[516],"required":[516],"maskPreset":[8,"mask-preset"],"maskRegex":[1537,"mask-regex"],"maskAdvanced":[1544,"mask-advanced"],"maxlength":[1538],"readOnly":[516,"read-only"],"isLoading":[1540,"is-loading"],"clearIcon":[1540,"clear-icon"],"hideErrorIcon":[4,"hide-error-icon"],"isHovered":[32],"isFocused":[32],"styles":[32]},null,{"styles":["connectedCallback"],"size":["getClasses"],"status":["renderIcon"],"mode":["renderIcon"],"maskPreset":["initializeMask"],"maskRegex":["initializeMask"],"maskAdvanced":["initializeMask"]}],[65,"cura-select",{"label":[513],"placeholder":[513],"value":[1537],"mode":[513],"size":[513],"status":[1537],"disabled":[516],"required":[516],"isHovered":[32],"isFocused":[32],"isOpen":[32],"options":[32],"activeIndex":[32],"textInput":[32]},null,{"activeIndex":["updateOptionHighlights"],"textInput":["filterOptions"],"value":["handleValueChange"]}],[1,"cura-select-option",{"value":[513],"selected":[516],"active":[516],"size":[1],"styles":[32]},null,{"size":["getSize"]}],[1,"cura-heading",{"level":[514],"size":[513],"weight":[513],"spotColor":[513,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}],[1,"cura-paragraph",{"size":[513],"spotColor":[513,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}],[1,"cura-loader-circle",{"size":[513],"color":[513]}],[1,"cura-icon",{"name":[513],"color":[1],"size":[8],"iconset":[513],"disabled":[4]},null,{"size":["sizeHandler"],"color":["colorHandler"],"disabled":["colorHandler"]}],[1,"cura-label",{"size":[513],"weight":[513],"spotColor":[513,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}]]],["cura-calendar.cjs",[[1,"cura-calendar",{"period":[513],"width":[513],"mode":[513],"dateFormat":[1537,"date-format"],"locale":[513],"type":[513],"disable":[16],"enable":[16],"defaultDate":[16],"limitRange":[514,"limit-range"],"disablePassDates":[1540,"disable-pass-dates"],"collapsed":[1540],"currentDate":[32],"selectedDates":[32],"rangeStart":[32],"defaultDates":[32],"selectMonth":[32],"selectYear":[32],"styles":[32]}]]],["cura-dropdown-search.cjs",[[1,"cura-dropdown-search",{"status":[513],"disabled":[516],"name":[513],"required":[1540],"selected":[1540],"value":[1537],"placeholder":[1537],"label":[1537],"iconName":[513,"icon-name"],"dropdownMaxHeight":[513,"dropdown-max-height"],"overlayVisible":[32],"isDropdownOpen":[32],"styles":[32],"isMobile":[32],"mode":[32],"inputTextRef":[32],"isOnBlurInput":[32],"hoveredIndex":[32],"options":[32]},null,{"value":["onValueChange"]}]]],["cura-icons-view.cjs",[[1,"cura-icons-view",{"selected":[32]}]]],["cura-toast.cjs",[[1,"cura-toast",{"type":[1],"position":[1],"icon":[513],"label":[513],"closeButton":[516,"close-button"],"loader":[516],"autoCloseDelay":[514,"auto-close-delay"],"styles":[32],"progress":[32]},null,{"type":["handleChangeType"],"position":["handleChangeType"]}]]],["cura-alert.cjs",[[1,"cura-alert",{"type":[1],"floating":[516],"label":[513],"closeable":[516],"icon":[513],"styles":[32]},null,{"type":["setColors"]}]]],["cura-button-outline.cjs",[[65,"cura-button-outline",{"type":[513],"size":[513],"disabled":[516],"isLoading":[516,"is-loading"],"iconName":[513,"icon-name"],"iconset":[513],"iconPosition":[513,"icon-position"],"iconOnly":[516,"icon-only"],"href":[513],"target":[513],"color":[1],"background":[1],"fontColor":[1,"font-color"],"textAlign":[513,"text-align"],"justify":[516],"styles":[32],"hovered":[32]},null,{"background":["setColors"],"color":["setColors","getSymbolColor"],"fontColor":["getSymbolColor"]}]]],["cura-checkbox.cjs",[[65,"cura-checkbox",{"checked":[1540],"indeterminate":[1540],"status":[1537],"disabled":[516],"required":[516],"label":[513],"ontabindex":[514],"position":[513],"value":[513],"name":[513],"size":[513],"background":[1],"iconColor":[1,"icon-color"],"color":[1],"styles":[32]},null,{"size":["sizeHandler"],"color":["setColors"],"background":["setColors","assignColor"],"iconColor":["assignColor"]}]]],["cura-button-select.cjs",[[1,"cura-button-select",{"size":[513],"disabled":[516],"selected":[516],"iconPosition":[513,"icon-position"],"color":[1],"background":[1],"fontcolor":[1],"hovered":[32],"styles":[32]},null,{"background":["setColors","assignColor"],"color":["setColors"],"fontcolor":["setColors","assignColor"]}]]],["cura-radio.cjs",[[65,"cura-radio",{"checked":[1540],"status":[1537],"disabled":[516],"required":[516],"label":[513],"ontabindex":[514],"position":[513],"value":[513],"name":[513],"background":[1],"size":[1],"color":[1],"styles":[32]},null,{"size":["sizeHandler"],"color":["setColors"],"background":["setColors","assignColor"]}]]],["cura-badge-distance.cjs",[[1,"cura-badge-distance",{"distance":[2],"label":[513],"styles":[32],"displayDistance":[32]},null,{"distance":["formatDistance"]}]]],["cura-dropdown-search-option.cjs",[[1,"cura-dropdown-search-option",{"value":[513],"selected":[1540],"selectable":[516],"hovered":[1540],"styles":[32]},null,{"selected":["updateIconColor"]}]]],["cura-dropdown-search-option-title.cjs",[[1,"cura-dropdown-search-option-title"]]],["cura-switch.cjs",[[65,"cura-switch",{"checked":[1540],"disabled":[516],"label":[513],"ontabindex":[514],"position":[513],"size":[513],"background":[1],"color":[1],"styles":[32]},null,{"size":["sizeHandler"],"color":["setColors"],"background":["setColors"]}]]],["cura-avatar.cjs",[[1,"cura-avatar",{"size":[1],"backgroundColor":[513,"background-color"],"borderColor":[513,"border-color"],"borderRadius":[513,"border-radius"],"border":[516],"type":[513],"imageSrc":[1537,"image-src"],"imageSrcDefault":[513,"image-src-default"],"floating":[516],"styles":[32]},null,{"size":["sizeHandler"]}]]],["cura-card.cjs",[[1,"cura-card",{"hasPadding":[1028,"has-padding"],"hasShadow":[1028,"has-shadow"],"type":[1025],"colorMode":[1025,"color-mode"],"href":[1537],"target":[513],"styles":[32]}]]],["cura-display.cjs",[[1,"cura-display",{"level":[514],"size":[513],"spotColor":[1,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}]]],["cura-loader-bar.cjs",[[1,"cura-loader-bar",{"color":[1],"progress":[2],"styles":[32]},null,{"color":["handleChangeColor"],"progress":["handleProgress"]}]]],["cura-button-transparent.cjs",[[65,"cura-button-transparent",{"type":[513],"size":[513],"disabled":[516],"isLoading":[516,"is-loading"],"iconName":[513,"icon-name"],"iconset":[513],"iconPosition":[513,"icon-position"],"iconOnly":[516,"icon-only"],"href":[513],"target":[513],"color":[513],"fontColor":[513,"font-color"],"textAlign":[513,"text-align"],"justify":[516],"hovered":[32],"styles":[32]},null,{"fontColor":["getSymbolColor"],"color":["getSymbolColor"]}]]]], options);
|
|
22
|
+
return index.bootstrapLazy([["cura-accordion_12.cjs",[[65,"cura-button",{"type":[513],"size":[513],"disabled":[516],"isLoading":[516,"is-loading"],"iconName":[513,"icon-name"],"iconset":[513],"iconPosition":[513,"icon-position"],"iconOnly":[516,"icon-only"],"href":[513],"target":[513],"color":[1],"background":[513],"fontColor":[513,"font-color"],"textAlign":[513,"text-align"],"justify":[516],"styles":[32],"hovered":[32]},null,{"background":["setColors"],"color":["setColors"]}],[1,"cura-accordion-item",{"label":[513],"iconSize":[514,"icon-size"],"openIcon":[513,"open-icon"],"closeIcon":[513,"close-icon"],"iconColor":[513,"icon-color"],"iconActiveColor":[513,"icon-active-color"],"colorMode":[1,"color-mode"],"opened":[1540],"styles":[32]}],[1,"cura-accordion",{"color":[513],"activeColor":[513,"active-color"],"colorMode":[513,"color-mode"],"iconSize":[514,"icon-size"],"openIcon":[513,"open-icon"],"closeIcon":[513,"close-icon"],"iconColor":[513,"icon-color"],"iconActiveColor":[513,"icon-active-color"],"behavior":[513],"styles":[32]},null,{"color":["handleChangeColor"],"activeColor":["handleChangeColor"]}],[1,"cura-page-template",{"contentwidth":[513]}],[65,"cura-input-text",{"mode":[1537],"status":[1537],"size":[1537],"type":[513],"inputMode":[513,"input-mode"],"label":[513],"name":[513],"placeholder":[513],"value":[1032],"iconName":[1537,"icon-name"],"helperText":[1537,"helper-text"],"disabled":[516],"required":[516],"maskPreset":[8,"mask-preset"],"maskRegex":[1537,"mask-regex"],"maskAdvanced":[1544,"mask-advanced"],"maxlength":[1538],"readOnly":[516,"read-only"],"isLoading":[1540,"is-loading"],"clearIcon":[1540,"clear-icon"],"hideErrorIcon":[4,"hide-error-icon"],"isHovered":[32],"isFocused":[32],"styles":[32]},null,{"styles":["connectedCallback"],"size":["getClasses"],"status":["renderIcon"],"mode":["renderIcon"],"maskPreset":["initializeMask"],"maskRegex":["initializeMask"],"maskAdvanced":["initializeMask"]}],[65,"cura-select",{"label":[513],"placeholder":[513],"value":[1537],"mode":[513],"size":[513],"status":[1537],"disabled":[516],"required":[516],"searchBehavior":[516,"search-behavior"],"isHovered":[32],"isFocused":[32],"isOpen":[32],"options":[32],"activeIndex":[32],"textInput":[32]},null,{"activeIndex":["updateOptionHighlights"],"textInput":["filterOptions"],"value":["handleValueChange"]}],[1,"cura-select-option",{"value":[513],"selected":[516],"active":[516],"size":[1],"styles":[32]},null,{"size":["getSize"]}],[1,"cura-heading",{"level":[514],"size":[513],"weight":[513],"spotColor":[513,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}],[1,"cura-paragraph",{"size":[513],"spotColor":[513,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}],[1,"cura-loader-circle",{"size":[513],"color":[513]}],[1,"cura-icon",{"name":[513],"color":[1],"size":[8],"iconset":[513],"disabled":[4]},null,{"size":["sizeHandler"],"color":["colorHandler"],"disabled":["colorHandler"]}],[1,"cura-label",{"size":[513],"weight":[513],"spotColor":[513,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}]]],["cura-calendar.cjs",[[1,"cura-calendar",{"period":[513],"width":[513],"mode":[513],"dateFormat":[1537,"date-format"],"locale":[513],"type":[513],"disable":[16],"enable":[16],"defaultDate":[16],"limitRange":[514,"limit-range"],"disablePassDates":[1540,"disable-pass-dates"],"disableFutureDates":[1540,"disable-future-dates"],"collapsed":[1540],"floating":[1540],"embedded":[1540],"currentDate":[32],"selectedDates":[32],"rangeStart":[32],"defaultDates":[32],"selectMonth":[32],"selectYear":[32],"styles":[32]}]]],["cura-dropdown-search.cjs",[[1,"cura-dropdown-search",{"size":[1537],"status":[513],"disabled":[516],"name":[513],"required":[1540],"selected":[1540],"value":[1537],"placeholder":[1537],"label":[1537],"iconName":[513,"icon-name"],"dropdownMaxHeight":[513,"dropdown-max-height"],"overlayVisible":[32],"isDropdownOpen":[32],"styles":[32],"isMobile":[32],"mode":[32],"inputTextRef":[32],"isOnBlurInput":[32],"hoveredIndex":[32],"options":[32]},null,{"value":["onValueChange"]}]]],["cura-icons-view.cjs",[[1,"cura-icons-view",{"selected":[32]}]]],["cura-toast.cjs",[[1,"cura-toast",{"type":[1],"position":[1],"icon":[513],"label":[513],"closeButton":[516,"close-button"],"loader":[516],"autoCloseDelay":[514,"auto-close-delay"],"styles":[32],"progress":[32]},null,{"type":["handleChangeType"],"position":["handleChangeType"]}]]],["cura-alert.cjs",[[1,"cura-alert",{"type":[1],"floating":[516],"label":[513],"closeable":[516],"icon":[513],"styles":[32]},null,{"type":["setColors"]}]]],["cura-button-outline.cjs",[[65,"cura-button-outline",{"type":[513],"size":[513],"disabled":[516],"isLoading":[516,"is-loading"],"iconName":[513,"icon-name"],"iconset":[513],"iconPosition":[513,"icon-position"],"iconOnly":[516,"icon-only"],"href":[513],"target":[513],"color":[1],"background":[1],"fontColor":[1,"font-color"],"textAlign":[513,"text-align"],"justify":[516],"styles":[32],"hovered":[32]},null,{"background":["setColors"],"color":["setColors","getSymbolColor"],"fontColor":["getSymbolColor"]}]]],["cura-checkbox.cjs",[[65,"cura-checkbox",{"checked":[1540],"indeterminate":[1540],"status":[1537],"disabled":[516],"required":[516],"label":[513],"ontabindex":[514],"position":[513],"value":[513],"name":[513],"size":[513],"background":[1],"iconColor":[1,"icon-color"],"color":[1],"styles":[32]},null,{"size":["sizeHandler"],"color":["setColors"],"background":["setColors","assignColor"],"iconColor":["assignColor"]}]]],["cura-button-select.cjs",[[1,"cura-button-select",{"size":[513],"disabled":[516],"selected":[516],"iconPosition":[513,"icon-position"],"color":[1],"background":[1],"fontcolor":[1],"hovered":[32],"styles":[32]},null,{"background":["setColors","assignColor"],"color":["setColors"],"fontcolor":["setColors","assignColor"]}]]],["cura-radio.cjs",[[65,"cura-radio",{"checked":[1540],"status":[1537],"disabled":[516],"required":[516],"label":[513],"ontabindex":[514],"position":[513],"value":[513],"name":[513],"background":[1],"size":[1],"color":[1],"styles":[32]},null,{"size":["sizeHandler"],"color":["setColors"],"background":["setColors","assignColor"]}]]],["cura-badge-distance.cjs",[[1,"cura-badge-distance",{"distance":[2],"label":[513],"styles":[32],"displayDistance":[32]},null,{"distance":["formatDistance"]}]]],["cura-dropdown-search-option.cjs",[[1,"cura-dropdown-search-option",{"value":[513],"selected":[1540],"selectable":[516],"hovered":[1540],"styles":[32]},null,{"selected":["updateIconColor"]}]]],["cura-dropdown-search-option-title.cjs",[[1,"cura-dropdown-search-option-title"]]],["cura-switch.cjs",[[65,"cura-switch",{"checked":[1540],"disabled":[516],"label":[513],"ontabindex":[514],"position":[513],"size":[513],"background":[1],"color":[1],"styles":[32]},null,{"size":["sizeHandler"],"color":["setColors"],"background":["setColors"]}]]],["cura-avatar.cjs",[[1,"cura-avatar",{"size":[1],"backgroundColor":[513,"background-color"],"borderColor":[513,"border-color"],"borderRadius":[513,"border-radius"],"border":[516],"type":[513],"imageSrc":[1537,"image-src"],"imageSrcDefault":[513,"image-src-default"],"floating":[516],"styles":[32]},null,{"size":["sizeHandler"]}]]],["cura-card.cjs",[[1,"cura-card",{"hasPadding":[1028,"has-padding"],"hasShadow":[1028,"has-shadow"],"type":[1025],"colorMode":[1025,"color-mode"],"href":[1537],"target":[513],"styles":[32]}]]],["cura-display.cjs",[[1,"cura-display",{"level":[514],"size":[513],"spotColor":[1,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}]]],["cura-loader-bar.cjs",[[1,"cura-loader-bar",{"color":[1],"progress":[2],"styles":[32]},null,{"color":["handleChangeColor"],"progress":["handleProgress"]}]]],["cura-button-transparent.cjs",[[65,"cura-button-transparent",{"type":[513],"size":[513],"disabled":[516],"isLoading":[516,"is-loading"],"iconName":[513,"icon-name"],"iconset":[513],"iconPosition":[513,"icon-position"],"iconOnly":[516,"icon-only"],"href":[513],"target":[513],"color":[513],"fontColor":[513,"font-color"],"textAlign":[513,"text-align"],"justify":[516],"hovered":[32],"styles":[32]},null,{"fontColor":["getSymbolColor"],"color":["getSymbolColor"]}]]]], options);
|
|
23
23
|
});
|
|
24
24
|
|
|
25
25
|
exports.setNonce = index.setNonce;
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -3,12 +3,12 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
const index = require('./index-98e7ba54.js');
|
|
6
|
-
const appGlobals = require('./app-globals-
|
|
6
|
+
const appGlobals = require('./app-globals-4d07f363.js');
|
|
7
7
|
|
|
8
8
|
const defineCustomElements = async (win, options) => {
|
|
9
9
|
if (typeof window === 'undefined') return undefined;
|
|
10
10
|
await appGlobals.globalScripts();
|
|
11
|
-
return index.bootstrapLazy([["cura-accordion_12.cjs",[[65,"cura-button",{"type":[513],"size":[513],"disabled":[516],"isLoading":[516,"is-loading"],"iconName":[513,"icon-name"],"iconset":[513],"iconPosition":[513,"icon-position"],"iconOnly":[516,"icon-only"],"href":[513],"target":[513],"color":[1],"background":[513],"fontColor":[513,"font-color"],"textAlign":[513,"text-align"],"justify":[516],"styles":[32],"hovered":[32]},null,{"background":["setColors"],"color":["setColors"]}],[1,"cura-accordion-item",{"label":[513],"iconSize":[514,"icon-size"],"openIcon":[513,"open-icon"],"closeIcon":[513,"close-icon"],"iconColor":[513,"icon-color"],"iconActiveColor":[513,"icon-active-color"],"colorMode":[1,"color-mode"],"opened":[1540],"styles":[32]}],[1,"cura-accordion",{"color":[513],"activeColor":[513,"active-color"],"colorMode":[513,"color-mode"],"iconSize":[514,"icon-size"],"openIcon":[513,"open-icon"],"closeIcon":[513,"close-icon"],"iconColor":[513,"icon-color"],"iconActiveColor":[513,"icon-active-color"],"behavior":[513],"styles":[32]},null,{"color":["handleChangeColor"],"activeColor":["handleChangeColor"]}],[1,"cura-page-template",{"contentwidth":[513]}],[65,"cura-input-text",{"mode":[1537],"status":[1537],"size":[1537],"type":[513],"inputMode":[513,"input-mode"],"label":[513],"name":[513],"placeholder":[513],"value":[1032],"iconName":[1537,"icon-name"],"helperText":[1537,"helper-text"],"disabled":[516],"required":[516],"maskPreset":[8,"mask-preset"],"maskRegex":[1537,"mask-regex"],"maskAdvanced":[1544,"mask-advanced"],"maxlength":[1538],"readOnly":[516,"read-only"],"isLoading":[1540,"is-loading"],"clearIcon":[1540,"clear-icon"],"hideErrorIcon":[4,"hide-error-icon"],"isHovered":[32],"isFocused":[32],"styles":[32]},null,{"styles":["connectedCallback"],"size":["getClasses"],"status":["renderIcon"],"mode":["renderIcon"],"maskPreset":["initializeMask"],"maskRegex":["initializeMask"],"maskAdvanced":["initializeMask"]}],[65,"cura-select",{"label":[513],"placeholder":[513],"value":[1537],"mode":[513],"size":[513],"status":[1537],"disabled":[516],"required":[516],"isHovered":[32],"isFocused":[32],"isOpen":[32],"options":[32],"activeIndex":[32],"textInput":[32]},null,{"activeIndex":["updateOptionHighlights"],"textInput":["filterOptions"],"value":["handleValueChange"]}],[1,"cura-select-option",{"value":[513],"selected":[516],"active":[516],"size":[1],"styles":[32]},null,{"size":["getSize"]}],[1,"cura-heading",{"level":[514],"size":[513],"weight":[513],"spotColor":[513,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}],[1,"cura-paragraph",{"size":[513],"spotColor":[513,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}],[1,"cura-loader-circle",{"size":[513],"color":[513]}],[1,"cura-icon",{"name":[513],"color":[1],"size":[8],"iconset":[513],"disabled":[4]},null,{"size":["sizeHandler"],"color":["colorHandler"],"disabled":["colorHandler"]}],[1,"cura-label",{"size":[513],"weight":[513],"spotColor":[513,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}]]],["cura-calendar.cjs",[[1,"cura-calendar",{"period":[513],"width":[513],"mode":[513],"dateFormat":[1537,"date-format"],"locale":[513],"type":[513],"disable":[16],"enable":[16],"defaultDate":[16],"limitRange":[514,"limit-range"],"disablePassDates":[1540,"disable-pass-dates"],"collapsed":[1540],"currentDate":[32],"selectedDates":[32],"rangeStart":[32],"defaultDates":[32],"selectMonth":[32],"selectYear":[32],"styles":[32]}]]],["cura-dropdown-search.cjs",[[1,"cura-dropdown-search",{"status":[513],"disabled":[516],"name":[513],"required":[1540],"selected":[1540],"value":[1537],"placeholder":[1537],"label":[1537],"iconName":[513,"icon-name"],"dropdownMaxHeight":[513,"dropdown-max-height"],"overlayVisible":[32],"isDropdownOpen":[32],"styles":[32],"isMobile":[32],"mode":[32],"inputTextRef":[32],"isOnBlurInput":[32],"hoveredIndex":[32],"options":[32]},null,{"value":["onValueChange"]}]]],["cura-icons-view.cjs",[[1,"cura-icons-view",{"selected":[32]}]]],["cura-toast.cjs",[[1,"cura-toast",{"type":[1],"position":[1],"icon":[513],"label":[513],"closeButton":[516,"close-button"],"loader":[516],"autoCloseDelay":[514,"auto-close-delay"],"styles":[32],"progress":[32]},null,{"type":["handleChangeType"],"position":["handleChangeType"]}]]],["cura-alert.cjs",[[1,"cura-alert",{"type":[1],"floating":[516],"label":[513],"closeable":[516],"icon":[513],"styles":[32]},null,{"type":["setColors"]}]]],["cura-button-outline.cjs",[[65,"cura-button-outline",{"type":[513],"size":[513],"disabled":[516],"isLoading":[516,"is-loading"],"iconName":[513,"icon-name"],"iconset":[513],"iconPosition":[513,"icon-position"],"iconOnly":[516,"icon-only"],"href":[513],"target":[513],"color":[1],"background":[1],"fontColor":[1,"font-color"],"textAlign":[513,"text-align"],"justify":[516],"styles":[32],"hovered":[32]},null,{"background":["setColors"],"color":["setColors","getSymbolColor"],"fontColor":["getSymbolColor"]}]]],["cura-checkbox.cjs",[[65,"cura-checkbox",{"checked":[1540],"indeterminate":[1540],"status":[1537],"disabled":[516],"required":[516],"label":[513],"ontabindex":[514],"position":[513],"value":[513],"name":[513],"size":[513],"background":[1],"iconColor":[1,"icon-color"],"color":[1],"styles":[32]},null,{"size":["sizeHandler"],"color":["setColors"],"background":["setColors","assignColor"],"iconColor":["assignColor"]}]]],["cura-button-select.cjs",[[1,"cura-button-select",{"size":[513],"disabled":[516],"selected":[516],"iconPosition":[513,"icon-position"],"color":[1],"background":[1],"fontcolor":[1],"hovered":[32],"styles":[32]},null,{"background":["setColors","assignColor"],"color":["setColors"],"fontcolor":["setColors","assignColor"]}]]],["cura-radio.cjs",[[65,"cura-radio",{"checked":[1540],"status":[1537],"disabled":[516],"required":[516],"label":[513],"ontabindex":[514],"position":[513],"value":[513],"name":[513],"background":[1],"size":[1],"color":[1],"styles":[32]},null,{"size":["sizeHandler"],"color":["setColors"],"background":["setColors","assignColor"]}]]],["cura-badge-distance.cjs",[[1,"cura-badge-distance",{"distance":[2],"label":[513],"styles":[32],"displayDistance":[32]},null,{"distance":["formatDistance"]}]]],["cura-dropdown-search-option.cjs",[[1,"cura-dropdown-search-option",{"value":[513],"selected":[1540],"selectable":[516],"hovered":[1540],"styles":[32]},null,{"selected":["updateIconColor"]}]]],["cura-dropdown-search-option-title.cjs",[[1,"cura-dropdown-search-option-title"]]],["cura-switch.cjs",[[65,"cura-switch",{"checked":[1540],"disabled":[516],"label":[513],"ontabindex":[514],"position":[513],"size":[513],"background":[1],"color":[1],"styles":[32]},null,{"size":["sizeHandler"],"color":["setColors"],"background":["setColors"]}]]],["cura-avatar.cjs",[[1,"cura-avatar",{"size":[1],"backgroundColor":[513,"background-color"],"borderColor":[513,"border-color"],"borderRadius":[513,"border-radius"],"border":[516],"type":[513],"imageSrc":[1537,"image-src"],"imageSrcDefault":[513,"image-src-default"],"floating":[516],"styles":[32]},null,{"size":["sizeHandler"]}]]],["cura-card.cjs",[[1,"cura-card",{"hasPadding":[1028,"has-padding"],"hasShadow":[1028,"has-shadow"],"type":[1025],"colorMode":[1025,"color-mode"],"href":[1537],"target":[513],"styles":[32]}]]],["cura-display.cjs",[[1,"cura-display",{"level":[514],"size":[513],"spotColor":[1,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}]]],["cura-loader-bar.cjs",[[1,"cura-loader-bar",{"color":[1],"progress":[2],"styles":[32]},null,{"color":["handleChangeColor"],"progress":["handleProgress"]}]]],["cura-button-transparent.cjs",[[65,"cura-button-transparent",{"type":[513],"size":[513],"disabled":[516],"isLoading":[516,"is-loading"],"iconName":[513,"icon-name"],"iconset":[513],"iconPosition":[513,"icon-position"],"iconOnly":[516,"icon-only"],"href":[513],"target":[513],"color":[513],"fontColor":[513,"font-color"],"textAlign":[513,"text-align"],"justify":[516],"hovered":[32],"styles":[32]},null,{"fontColor":["getSymbolColor"],"color":["getSymbolColor"]}]]]], options);
|
|
11
|
+
return index.bootstrapLazy([["cura-accordion_12.cjs",[[65,"cura-button",{"type":[513],"size":[513],"disabled":[516],"isLoading":[516,"is-loading"],"iconName":[513,"icon-name"],"iconset":[513],"iconPosition":[513,"icon-position"],"iconOnly":[516,"icon-only"],"href":[513],"target":[513],"color":[1],"background":[513],"fontColor":[513,"font-color"],"textAlign":[513,"text-align"],"justify":[516],"styles":[32],"hovered":[32]},null,{"background":["setColors"],"color":["setColors"]}],[1,"cura-accordion-item",{"label":[513],"iconSize":[514,"icon-size"],"openIcon":[513,"open-icon"],"closeIcon":[513,"close-icon"],"iconColor":[513,"icon-color"],"iconActiveColor":[513,"icon-active-color"],"colorMode":[1,"color-mode"],"opened":[1540],"styles":[32]}],[1,"cura-accordion",{"color":[513],"activeColor":[513,"active-color"],"colorMode":[513,"color-mode"],"iconSize":[514,"icon-size"],"openIcon":[513,"open-icon"],"closeIcon":[513,"close-icon"],"iconColor":[513,"icon-color"],"iconActiveColor":[513,"icon-active-color"],"behavior":[513],"styles":[32]},null,{"color":["handleChangeColor"],"activeColor":["handleChangeColor"]}],[1,"cura-page-template",{"contentwidth":[513]}],[65,"cura-input-text",{"mode":[1537],"status":[1537],"size":[1537],"type":[513],"inputMode":[513,"input-mode"],"label":[513],"name":[513],"placeholder":[513],"value":[1032],"iconName":[1537,"icon-name"],"helperText":[1537,"helper-text"],"disabled":[516],"required":[516],"maskPreset":[8,"mask-preset"],"maskRegex":[1537,"mask-regex"],"maskAdvanced":[1544,"mask-advanced"],"maxlength":[1538],"readOnly":[516,"read-only"],"isLoading":[1540,"is-loading"],"clearIcon":[1540,"clear-icon"],"hideErrorIcon":[4,"hide-error-icon"],"isHovered":[32],"isFocused":[32],"styles":[32]},null,{"styles":["connectedCallback"],"size":["getClasses"],"status":["renderIcon"],"mode":["renderIcon"],"maskPreset":["initializeMask"],"maskRegex":["initializeMask"],"maskAdvanced":["initializeMask"]}],[65,"cura-select",{"label":[513],"placeholder":[513],"value":[1537],"mode":[513],"size":[513],"status":[1537],"disabled":[516],"required":[516],"searchBehavior":[516,"search-behavior"],"isHovered":[32],"isFocused":[32],"isOpen":[32],"options":[32],"activeIndex":[32],"textInput":[32]},null,{"activeIndex":["updateOptionHighlights"],"textInput":["filterOptions"],"value":["handleValueChange"]}],[1,"cura-select-option",{"value":[513],"selected":[516],"active":[516],"size":[1],"styles":[32]},null,{"size":["getSize"]}],[1,"cura-heading",{"level":[514],"size":[513],"weight":[513],"spotColor":[513,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}],[1,"cura-paragraph",{"size":[513],"spotColor":[513,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}],[1,"cura-loader-circle",{"size":[513],"color":[513]}],[1,"cura-icon",{"name":[513],"color":[1],"size":[8],"iconset":[513],"disabled":[4]},null,{"size":["sizeHandler"],"color":["colorHandler"],"disabled":["colorHandler"]}],[1,"cura-label",{"size":[513],"weight":[513],"spotColor":[513,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}]]],["cura-calendar.cjs",[[1,"cura-calendar",{"period":[513],"width":[513],"mode":[513],"dateFormat":[1537,"date-format"],"locale":[513],"type":[513],"disable":[16],"enable":[16],"defaultDate":[16],"limitRange":[514,"limit-range"],"disablePassDates":[1540,"disable-pass-dates"],"disableFutureDates":[1540,"disable-future-dates"],"collapsed":[1540],"floating":[1540],"embedded":[1540],"currentDate":[32],"selectedDates":[32],"rangeStart":[32],"defaultDates":[32],"selectMonth":[32],"selectYear":[32],"styles":[32]}]]],["cura-dropdown-search.cjs",[[1,"cura-dropdown-search",{"size":[1537],"status":[513],"disabled":[516],"name":[513],"required":[1540],"selected":[1540],"value":[1537],"placeholder":[1537],"label":[1537],"iconName":[513,"icon-name"],"dropdownMaxHeight":[513,"dropdown-max-height"],"overlayVisible":[32],"isDropdownOpen":[32],"styles":[32],"isMobile":[32],"mode":[32],"inputTextRef":[32],"isOnBlurInput":[32],"hoveredIndex":[32],"options":[32]},null,{"value":["onValueChange"]}]]],["cura-icons-view.cjs",[[1,"cura-icons-view",{"selected":[32]}]]],["cura-toast.cjs",[[1,"cura-toast",{"type":[1],"position":[1],"icon":[513],"label":[513],"closeButton":[516,"close-button"],"loader":[516],"autoCloseDelay":[514,"auto-close-delay"],"styles":[32],"progress":[32]},null,{"type":["handleChangeType"],"position":["handleChangeType"]}]]],["cura-alert.cjs",[[1,"cura-alert",{"type":[1],"floating":[516],"label":[513],"closeable":[516],"icon":[513],"styles":[32]},null,{"type":["setColors"]}]]],["cura-button-outline.cjs",[[65,"cura-button-outline",{"type":[513],"size":[513],"disabled":[516],"isLoading":[516,"is-loading"],"iconName":[513,"icon-name"],"iconset":[513],"iconPosition":[513,"icon-position"],"iconOnly":[516,"icon-only"],"href":[513],"target":[513],"color":[1],"background":[1],"fontColor":[1,"font-color"],"textAlign":[513,"text-align"],"justify":[516],"styles":[32],"hovered":[32]},null,{"background":["setColors"],"color":["setColors","getSymbolColor"],"fontColor":["getSymbolColor"]}]]],["cura-checkbox.cjs",[[65,"cura-checkbox",{"checked":[1540],"indeterminate":[1540],"status":[1537],"disabled":[516],"required":[516],"label":[513],"ontabindex":[514],"position":[513],"value":[513],"name":[513],"size":[513],"background":[1],"iconColor":[1,"icon-color"],"color":[1],"styles":[32]},null,{"size":["sizeHandler"],"color":["setColors"],"background":["setColors","assignColor"],"iconColor":["assignColor"]}]]],["cura-button-select.cjs",[[1,"cura-button-select",{"size":[513],"disabled":[516],"selected":[516],"iconPosition":[513,"icon-position"],"color":[1],"background":[1],"fontcolor":[1],"hovered":[32],"styles":[32]},null,{"background":["setColors","assignColor"],"color":["setColors"],"fontcolor":["setColors","assignColor"]}]]],["cura-radio.cjs",[[65,"cura-radio",{"checked":[1540],"status":[1537],"disabled":[516],"required":[516],"label":[513],"ontabindex":[514],"position":[513],"value":[513],"name":[513],"background":[1],"size":[1],"color":[1],"styles":[32]},null,{"size":["sizeHandler"],"color":["setColors"],"background":["setColors","assignColor"]}]]],["cura-badge-distance.cjs",[[1,"cura-badge-distance",{"distance":[2],"label":[513],"styles":[32],"displayDistance":[32]},null,{"distance":["formatDistance"]}]]],["cura-dropdown-search-option.cjs",[[1,"cura-dropdown-search-option",{"value":[513],"selected":[1540],"selectable":[516],"hovered":[1540],"styles":[32]},null,{"selected":["updateIconColor"]}]]],["cura-dropdown-search-option-title.cjs",[[1,"cura-dropdown-search-option-title"]]],["cura-switch.cjs",[[65,"cura-switch",{"checked":[1540],"disabled":[516],"label":[513],"ontabindex":[514],"position":[513],"size":[513],"background":[1],"color":[1],"styles":[32]},null,{"size":["sizeHandler"],"color":["setColors"],"background":["setColors"]}]]],["cura-avatar.cjs",[[1,"cura-avatar",{"size":[1],"backgroundColor":[513,"background-color"],"borderColor":[513,"border-color"],"borderRadius":[513,"border-radius"],"border":[516],"type":[513],"imageSrc":[1537,"image-src"],"imageSrcDefault":[513,"image-src-default"],"floating":[516],"styles":[32]},null,{"size":["sizeHandler"]}]]],["cura-card.cjs",[[1,"cura-card",{"hasPadding":[1028,"has-padding"],"hasShadow":[1028,"has-shadow"],"type":[1025],"colorMode":[1025,"color-mode"],"href":[1537],"target":[513],"styles":[32]}]]],["cura-display.cjs",[[1,"cura-display",{"level":[514],"size":[513],"spotColor":[1,"spot-color"],"color":[1],"marginBlock":[513,"margin-block"],"lineHeight":[513,"line-height"],"styles":[32]},null,{"color":["handleChangeColor"],"spotColor":["handleChangeColor"]}]]],["cura-loader-bar.cjs",[[1,"cura-loader-bar",{"color":[1],"progress":[2],"styles":[32]},null,{"color":["handleChangeColor"],"progress":["handleProgress"]}]]],["cura-button-transparent.cjs",[[65,"cura-button-transparent",{"type":[513],"size":[513],"disabled":[516],"isLoading":[516,"is-loading"],"iconName":[513,"icon-name"],"iconset":[513],"iconPosition":[513,"icon-position"],"iconOnly":[516,"icon-only"],"href":[513],"target":[513],"color":[513],"fontColor":[513,"font-color"],"textAlign":[513,"text-align"],"justify":[516],"hovered":[32],"styles":[32]},null,{"fontColor":["getSymbolColor"],"color":["getSymbolColor"]}]]]], options);
|
|
12
12
|
};
|
|
13
13
|
|
|
14
14
|
exports.setNonce = index.setNonce;
|
|
@@ -34,9 +34,9 @@ export const ThemeDefault = {
|
|
|
34
34
|
font: {
|
|
35
35
|
size: '14px',
|
|
36
36
|
color: '#4A4A4A',
|
|
37
|
-
body: "'
|
|
38
|
-
heading: "'
|
|
39
|
-
display: "'
|
|
37
|
+
body: "'Gotham', Arial, Helvetica, sans-serif",
|
|
38
|
+
heading: "'Gotham', Arial, Helvetica, sans-serif",
|
|
39
|
+
display: "'Gotham', Arial, Helvetica, sans-serif",
|
|
40
40
|
weights: {
|
|
41
41
|
thin: 100,
|
|
42
42
|
light: 300,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"theme-default.js","sourceRoot":"","sources":["../../../src/api/theme-presets/theme-default.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG;IAC1B,YAAY;IACZ,KAAK,EAAE;QACL,OAAO,EAAE;YACP,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,UAAU;YACjB,KAAK,EAAE,UAAU;YACjB,KAAK,EAAE,SAAS;SACjB;QACD,SAAS,EAAE;YACT,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,UAAU;SAClB;QACD,MAAM,EAAE;YACN,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,WAAW;YAClB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,WAAW;SACnB;KACF;IACD,aAAa;IACb,OAAO,EAAE;QACP,IAAI,EAAE,CAAC;KACR;IACD,WAAW;IACX,IAAI,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,KAAK,EAAE,SAAS;QAChB,IAAI,EAAE,wCAAwC;QAC9C,OAAO,EAAE,wCAAwC;QACjD,OAAO,EAAE,wCAAwC;QACjD,OAAO,EAAE;YACP,IAAI,EAAE,GAAG;YACT,KAAK,EAAE,GAAG;YACV,OAAO,EAAE,GAAG;YACZ,MAAM,EAAE,GAAG;YACX,IAAI,EAAE,GAAG;YACT,KAAK,EAAE,GAAG;SACX;KACF;CACF,CAAC","sourcesContent":["/**\n * Cura Default Theme\n */\nexport const ThemeDefault = {\n /* Colors */\n color: {\n primary: {\n '100': '113,197,232',\n '300': '68,142,205',\n '500': '0,61,165',\n '700': '0,48,117',\n '900': '0,40,85'\n },\n secondary: {\n '100': '245,236,227',\n '300': '221,192,162',\n '500': '204,160,116',\n '700': '136,107,77',\n '900': '41,32,23'\n },\n accent: {\n '100': '255,194,123',\n '300': '255,168,74',\n '500': '255,130,0',\n '700': '215,114,10',\n '900': '155,90,26'\n }\n },\n /* Spacing */\n spacing: {\n base: 4,\n },\n /* Fonts */\n font: {\n size: '14px',\n color: '#4A4A4A',\n body: \"'
|
|
1
|
+
{"version":3,"file":"theme-default.js","sourceRoot":"","sources":["../../../src/api/theme-presets/theme-default.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,CAAC,MAAM,YAAY,GAAG;IAC1B,YAAY;IACZ,KAAK,EAAE;QACL,OAAO,EAAE;YACP,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,UAAU;YACjB,KAAK,EAAE,UAAU;YACjB,KAAK,EAAE,SAAS;SACjB;QACD,SAAS,EAAE;YACT,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,UAAU;SAClB;QACD,MAAM,EAAE;YACN,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,WAAW;YAClB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,WAAW;SACnB;KACF;IACD,aAAa;IACb,OAAO,EAAE;QACP,IAAI,EAAE,CAAC;KACR;IACD,WAAW;IACX,IAAI,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,KAAK,EAAE,SAAS;QAChB,IAAI,EAAE,wCAAwC;QAC9C,OAAO,EAAE,wCAAwC;QACjD,OAAO,EAAE,wCAAwC;QACjD,OAAO,EAAE;YACP,IAAI,EAAE,GAAG;YACT,KAAK,EAAE,GAAG;YACV,OAAO,EAAE,GAAG;YACZ,MAAM,EAAE,GAAG;YACX,IAAI,EAAE,GAAG;YACT,KAAK,EAAE,GAAG;SACX;KACF;CACF,CAAC","sourcesContent":["/**\n * Cura Default Theme\n */\nexport const ThemeDefault = {\n /* Colors */\n color: {\n primary: {\n '100': '113,197,232',\n '300': '68,142,205',\n '500': '0,61,165',\n '700': '0,48,117',\n '900': '0,40,85'\n },\n secondary: {\n '100': '245,236,227',\n '300': '221,192,162',\n '500': '204,160,116',\n '700': '136,107,77',\n '900': '41,32,23'\n },\n accent: {\n '100': '255,194,123',\n '300': '255,168,74',\n '500': '255,130,0',\n '700': '215,114,10',\n '900': '155,90,26'\n }\n },\n /* Spacing */\n spacing: {\n base: 4,\n },\n /* Fonts */\n font: {\n size: '14px',\n color: '#4A4A4A',\n body: \"'Gotham', Arial, Helvetica, sans-serif\",\n heading: \"'Gotham', Arial, Helvetica, sans-serif\",\n display: \"'Gotham', Arial, Helvetica, sans-serif\",\n weights: {\n thin: 100,\n light: 300,\n regular: 400,\n medium: 500,\n bold: 700,\n black: 900\n },\n }\n};\n"]}
|
|
@@ -27,6 +27,22 @@ export const ThemeLegacyDefault = Object.assign(Object.assign({}, ThemeDefault),
|
|
|
27
27
|
'700': '149,94,29',
|
|
28
28
|
'900': '45,28,9'
|
|
29
29
|
}
|
|
30
|
+
},
|
|
31
|
+
/* Fonts */
|
|
32
|
+
font: {
|
|
33
|
+
size: '14px',
|
|
34
|
+
color: '#4A4A4A',
|
|
35
|
+
body: "'Roboto', Arial, Helvetica, sans-serif",
|
|
36
|
+
heading: "'Roboto', Arial, Helvetica, sans-serif",
|
|
37
|
+
display: "'Roboto', Arial, Helvetica, sans-serif",
|
|
38
|
+
weights: {
|
|
39
|
+
thin: 100,
|
|
40
|
+
light: 300,
|
|
41
|
+
regular: 400,
|
|
42
|
+
medium: 500,
|
|
43
|
+
bold: 700,
|
|
44
|
+
black: 900
|
|
45
|
+
},
|
|
30
46
|
}
|
|
31
47
|
});
|
|
32
48
|
//# sourceMappingURL=theme-legacy-default.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"theme-legacy-default.js","sourceRoot":"","sources":["../../../src/api/theme-presets/theme-legacy-default.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAE/C,MAAM,CAAC,MAAM,kBAAkB,mCAE1B,YAAY;IAEf,YAAY;IACZ,YAAY;IACZ,KAAK,EAAE;QACL,OAAO,EAAE;YACP,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,UAAU;YACjB,KAAK,EAAE,SAAS;YAChB,KAAK,EAAE,SAAS;SACjB;QACD,SAAS,EAAE;YACT,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,UAAU;YACjB,KAAK,EAAE,SAAS;SACjB;QACD,MAAM,EAAE;YACN,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,WAAW;YAClB,KAAK,EAAE,SAAS;SACjB;KACF,GACF,CAAC","sourcesContent":["/**\n * Legacy Default Theme\n */\nimport { ThemeDefault } from \"./theme-default\";\n\nexport const ThemeLegacyDefault = {\n /* Get default theme */\n ...ThemeDefault,\n\n /* Custom */\n /* Colors */\n color: {\n primary: {\n '100': '204,217,231',\n '300': '85,128,174',\n '500': '0,65,134',\n '700': '0,43,89',\n '900': '0,13,27'\n },\n secondary: {\n '100': '238,232,206',\n '300': '198,180,92',\n '500': '170,142,11',\n '700': '113,95,7',\n '900': '34,28,2'\n },\n accent: {\n '100': '249,232,213',\n '300': '228,160,79',\n '500': '223,141,44',\n '700': '149,94,29',\n '900': '45,28,9'\n }\n }\n};\n"]}
|
|
1
|
+
{"version":3,"file":"theme-legacy-default.js","sourceRoot":"","sources":["../../../src/api/theme-presets/theme-legacy-default.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAE/C,MAAM,CAAC,MAAM,kBAAkB,mCAE1B,YAAY;IAEf,YAAY;IACZ,YAAY;IACZ,KAAK,EAAE;QACL,OAAO,EAAE;YACP,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,UAAU;YACjB,KAAK,EAAE,SAAS;YAChB,KAAK,EAAE,SAAS;SACjB;QACD,SAAS,EAAE;YACT,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,UAAU;YACjB,KAAK,EAAE,SAAS;SACjB;QACD,MAAM,EAAE;YACN,KAAK,EAAE,aAAa;YACpB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,YAAY;YACnB,KAAK,EAAE,WAAW;YAClB,KAAK,EAAE,SAAS;SACjB;KACF;IACD,WAAW;IACX,IAAI,EAAE;QACJ,IAAI,EAAE,MAAM;QACZ,KAAK,EAAE,SAAS;QAChB,IAAI,EAAE,wCAAwC;QAC9C,OAAO,EAAE,wCAAwC;QACjD,OAAO,EAAE,wCAAwC;QACjD,OAAO,EAAE;YACP,IAAI,EAAE,GAAG;YACT,KAAK,EAAE,GAAG;YACV,OAAO,EAAE,GAAG;YACZ,MAAM,EAAE,GAAG;YACX,IAAI,EAAE,GAAG;YACT,KAAK,EAAE,GAAG;SACX;KACF,GACF,CAAC","sourcesContent":["/**\n * Legacy Default Theme\n */\nimport { ThemeDefault } from \"./theme-default\";\n\nexport const ThemeLegacyDefault = {\n /* Get default theme */\n ...ThemeDefault,\n\n /* Custom */\n /* Colors */\n color: {\n primary: {\n '100': '204,217,231',\n '300': '85,128,174',\n '500': '0,65,134',\n '700': '0,43,89',\n '900': '0,13,27'\n },\n secondary: {\n '100': '238,232,206',\n '300': '198,180,92',\n '500': '170,142,11',\n '700': '113,95,7',\n '900': '34,28,2'\n },\n accent: {\n '100': '249,232,213',\n '300': '228,160,79',\n '500': '223,141,44',\n '700': '149,94,29',\n '900': '45,28,9'\n }\n },\n /* Fonts */\n font: {\n size: '14px',\n color: '#4A4A4A',\n body: \"'Roboto', Arial, Helvetica, sans-serif\",\n heading: \"'Roboto', Arial, Helvetica, sans-serif\",\n display: \"'Roboto', Arial, Helvetica, sans-serif\",\n weights: {\n thin: 100,\n light: 300,\n regular: 400,\n medium: 500,\n bold: 700,\n black: 900\n },\n }\n};\n"]}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
<svg width="
|
|
2
|
-
<
|
|
3
|
-
<circle
|
|
4
|
-
<path
|
|
5
|
-
<path
|
|
6
|
-
<path
|
|
7
|
-
</g>
|
|
1
|
+
<svg width="80" height="80" viewBox="0 0 80 80" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<rect width="80" height="80" fill="white"/>
|
|
3
|
+
<circle cx="27" cy="74" r="4" fill="#71C5E8"/>
|
|
4
|
+
<path d="M32.5 53.5V44.5L47.5 45.5V53.5L53.5 55L40 71.5L27.5 55L32.5 53.5Z" fill="#449CD5"/>
|
|
5
|
+
<path d="M27 25C27 17.8203 32.8203 12 40 12C47.1797 12 53 17.8203 53 25V34C53 41.1797 47.1797 47 40 47C32.8203 47 27 41.1797 27 34V25Z" fill="#71C5E8"/>
|
|
6
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M40.0583 12.9167C33.5867 12.9167 28.3333 18.17 28.3333 24.6417V33.8146C28.3333 37.8235 30.511 41.4328 33.589 43.7646C33.9529 44.0403 34.1667 44.4705 34.1667 44.9271V53.6333C34.1667 54.287 33.7317 54.8608 33.1023 55.0374L28.8783 56.2226L40 69.8158L51.1217 56.2226L46.8977 55.0375C46.2683 54.8609 45.8333 54.287 45.8333 53.6334V47.7878C44.071 48.6166 42.126 49.1218 40.0748 49.2272C39.2705 49.2686 38.5849 48.65 38.5436 47.8457C38.5022 47.0413 39.1208 46.3557 39.9252 46.3144C46.5329 45.9749 51.7833 40.5156 51.7833 33.8146V24.6417C51.7833 18.17 46.53 12.9167 40.0583 12.9167ZM48.7063 46.0296C52.353 43.2083 54.7 38.7886 54.7 33.8146V24.6417C54.7 16.5592 48.1408 10 40.0583 10C31.9758 10 25.4167 16.5592 25.4167 24.6417V33.8146C25.4167 38.634 27.8824 42.8445 31.25 45.6319V52.5279L15.2664 57.0125C15.231 57.0225 15.196 57.0337 15.1615 57.0463C9.05855 59.2685 5 65.0659 5 71.5562V78.5416C5 79.3471 5.65292 80 6.45833 80C7.26375 80 7.91667 79.3471 7.91667 78.5416V71.5562C7.91667 66.3102 11.1858 61.6218 16.109 59.8054L25.4166 57.1939L25.4167 68.5171C22.9007 69.1646 21.0417 71.4485 21.0417 74.1666C21.0417 77.3883 23.6534 80 26.875 80C30.0967 80 32.7084 77.3883 32.7084 74.1666C32.7084 71.4485 30.8493 69.1646 28.3334 68.5171L28.3333 60.1625L38.5416 72.6393L38.5417 78.5417C38.5417 79.3471 39.1946 80 40 80C40.8054 80 41.4583 79.3471 41.4583 78.5417L41.4583 72.6393L53.9744 57.3419C54.0439 57.2569 54.1023 57.1664 54.1496 57.0722L57.5 58.0123L57.5 61.0288C53.9761 62.6418 51.6667 66.1687 51.6667 70.1125V78.5416C51.6667 79.347 52.3196 80 53.125 80H55.0646C55.87 80 56.5229 79.347 56.5229 78.5416C56.5229 77.7362 55.87 77.0833 55.0646 77.0833H54.5834V70.1125C54.5834 67.232 56.3229 64.6639 58.9584 63.5745C61.5938 64.6639 63.3333 67.232 63.3333 70.1125V77.0833H62.8521C62.0467 77.0833 61.3938 77.7362 61.3938 78.5416C61.3938 79.347 62.0467 80 62.8521 80H64.7917C65.5971 80 66.25 79.347 66.25 78.5416V70.1125C66.25 66.1687 63.9406 62.6418 60.4167 61.0288L60.4166 58.8306L63.891 59.8055C68.8142 61.6218 72.0833 66.3103 72.0833 71.5563V78.5417C72.0833 79.3471 72.7362 80 73.5417 80C74.3471 80 75 79.3471 75 78.5417V71.5563C75 65.066 70.9414 59.2685 64.8385 57.0464C64.804 57.0338 64.769 57.0225 64.7336 57.0126L48.75 52.5279V46.3854C48.75 46.2627 48.7348 46.1435 48.7063 46.0296ZM26.875 71.25C25.2642 71.25 23.9584 72.5558 23.9584 74.1666C23.9584 75.7775 25.2642 77.0833 26.875 77.0833C28.4859 77.0833 29.7917 75.7775 29.7917 74.1666C29.7917 72.5558 28.4859 71.25 26.875 71.25ZM16.6666 72.7083C17.472 72.7083 18.125 73.3612 18.125 74.1667V78.5417C18.125 79.3471 17.472 80 16.6666 80C15.8612 80 15.2083 79.3471 15.2083 78.5417V74.1667C15.2083 73.3612 15.8612 72.7083 16.6666 72.7083Z" fill="#002855"/>
|
|
8
7
|
</svg>
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
<svg width="70" height="70" viewBox="0 0 70 70" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<g id="doctor">
|
|
3
|
+
<circle id="Ellipse 2" cx="22" cy="64" r="4" fill="#71C5E8"/>
|
|
4
|
+
<path id="Vector 1" d="M27.5 43.5V34.5L42.5 35.5V43.5L48.5 45L35 61.5L22.5 45L27.5 43.5Z" fill="#449CD5"/>
|
|
5
|
+
<path id="Rectangle 1" d="M22 15C22 7.8203 27.8203 2 35 2C42.1797 2 48 7.8203 48 15V24C48 31.1797 42.1797 37 35 37C27.8203 37 22 31.1797 22 24V15Z" fill="#71C5E8"/>
|
|
6
|
+
<path id="Vector (Stroke)" fill-rule="evenodd" clip-rule="evenodd" d="M35.0583 2.91667C28.5867 2.91667 23.3333 8.17 23.3333 14.6417V23.8146C23.3333 27.8235 25.511 31.4328 28.589 33.7646C28.9529 34.0403 29.1667 34.4705 29.1667 34.9271V43.6333C29.1667 44.287 28.7317 44.8608 28.1023 45.0374L23.8783 46.2226L35 59.8158L46.1217 46.2226L41.8977 45.0375C41.2683 44.8609 40.8333 44.287 40.8333 43.6334V37.7878C39.071 38.6166 37.126 39.1218 35.0748 39.2272C34.2705 39.2686 33.5849 38.65 33.5436 37.8457C33.5023 37.0413 34.1208 36.3557 34.9252 36.3144C41.5329 35.9749 46.7833 30.5156 46.7833 23.8146V14.6417C46.7833 8.17 41.53 2.91667 35.0583 2.91667ZM43.7063 36.0296C47.353 33.2083 49.7 28.7886 49.7 23.8146V14.6417C49.7 6.55917 43.1408 0 35.0583 0C26.9758 0 20.4167 6.55917 20.4167 14.6417V23.8146C20.4167 28.634 22.8824 32.8445 26.25 35.6319V42.5279L10.2664 47.0125C10.231 47.0225 10.196 47.0337 10.1615 47.0463C4.05855 49.2685 0 55.0659 0 61.5562V68.5416C0 69.3471 0.652918 70 1.45833 70C2.26375 70 2.91667 69.3471 2.91667 68.5416V61.5562C2.91667 56.3102 6.18578 51.6218 11.109 49.8055L20.4166 47.1939L20.4167 58.5171C17.9007 59.1646 16.0417 61.4485 16.0417 64.1666C16.0417 67.3883 18.6534 70 21.875 70C25.0967 70 27.7084 67.3883 27.7084 64.1666C27.7084 61.4485 25.8493 59.1646 23.3334 58.5171L23.3333 50.1625L33.5416 62.6393L33.5417 68.5417C33.5417 69.3471 34.1946 70 35 70C35.8054 70 36.4583 69.3471 36.4583 68.5417L36.4583 62.6393L48.9744 47.3419C49.0439 47.2569 49.1023 47.1664 49.1496 47.0722L52.5 48.0123L52.5 51.0288C48.9761 52.6418 46.6667 56.1687 46.6667 60.1125V68.5416C46.6667 69.347 47.3196 69.9999 48.125 69.9999H50.0646C50.87 69.9999 51.5229 69.347 51.5229 68.5416C51.5229 67.7362 50.87 67.0833 50.0646 67.0833H49.5834V60.1125C49.5834 57.232 51.3229 54.6639 53.9584 53.5745C56.5938 54.6639 58.3333 57.232 58.3333 60.1125V67.0833H57.8521C57.0467 67.0833 56.3938 67.7362 56.3938 68.5416C56.3938 69.347 57.0467 69.9999 57.8521 69.9999H59.7917C60.5971 69.9999 61.25 69.347 61.25 68.5416V60.1125C61.25 56.1687 58.9406 52.6418 55.4167 51.0288L55.4166 48.8306L58.891 49.8055C63.8142 51.6218 67.0833 56.3103 67.0833 61.5563V68.5417C67.0833 69.3471 67.7362 70 68.5417 70C69.3471 70 70 69.3471 70 68.5417V61.5563C70 55.066 65.9414 49.2685 59.8385 47.0464C59.804 47.0338 59.769 47.0225 59.7336 47.0126L43.75 42.5279V36.3854C43.75 36.2627 43.7348 36.1435 43.7063 36.0296ZM21.875 61.25C20.2642 61.25 18.9584 62.5558 18.9584 64.1666C18.9584 65.7775 20.2642 67.0833 21.875 67.0833C23.4859 67.0833 24.7917 65.7775 24.7917 64.1666C24.7917 62.5558 23.4859 61.25 21.875 61.25ZM11.6666 62.7083C12.472 62.7083 13.125 63.3612 13.125 64.1667V68.5417C13.125 69.3471 12.472 70 11.6666 70C10.8612 70 10.2083 69.3471 10.2083 68.5417V64.1667C10.2083 63.3612 10.8612 62.7083 11.6666 62.7083Z" fill="#002855"/>
|
|
7
|
+
</g>
|
|
8
|
+
</svg>
|