@eunomia/elements 1.0.0-beta.6 → 1.0.0-beta.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/cdn/components/chunks/{chunk-JYIIWN2P.js → chunk-36KLGY6U.js} +8 -8
- package/dist/cdn/components/chunks/chunk-3BMACIDO.js +1 -0
- package/dist/cdn/components/chunks/{chunk-KDN4O5W2.js → chunk-3PNGQEG4.js} +3 -3
- package/dist/cdn/components/chunks/{chunk-ZKZV2YG5.js → chunk-5XPOGBPL.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-LMVW522V.js → chunk-62RLISRD.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-PMPSJG5V.js → chunk-6FYW5TQU.js} +3 -3
- package/dist/cdn/components/chunks/chunk-AK2DIJX7.js +1 -0
- package/dist/cdn/components/chunks/chunk-B5XMGWM7.js +10 -0
- package/dist/cdn/components/chunks/chunk-BVASCT2V.js +109 -0
- package/dist/cdn/components/chunks/{chunk-VYFR364B.js → chunk-DGI7TKCU.js} +14 -9
- package/dist/cdn/components/chunks/chunk-GVS6IUKC.js +1 -0
- package/dist/cdn/components/chunks/chunk-GWLD2I3P.js +8 -0
- package/dist/cdn/components/chunks/{chunk-UDVB4LAE.js → chunk-I4ERDXSM.js} +5 -3
- package/dist/cdn/components/chunks/{chunk-QZ5SHR3I.js → chunk-J3SZBXM6.js} +2 -2
- package/dist/cdn/components/chunks/{chunk-MOMYII3P.js → chunk-LVKMAHMU.js} +10 -0
- package/dist/cdn/components/chunks/{chunk-XDPRWUKN.js → chunk-MQQJ6DID.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-SZYEBMG6.js → chunk-PXF554MD.js} +1 -1
- package/dist/cdn/components/chunks/chunk-QL5GSW2A.js +1 -0
- package/dist/cdn/components/chunks/{chunk-7KKWYPHY.js → chunk-QXQ25SQS.js} +21 -19
- package/dist/cdn/components/chunks/{chunk-L2ADCEN7.js → chunk-SVGWCKWT.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-MQQ4BGVJ.js → chunk-TFTRCIIK.js} +7 -6
- package/dist/cdn/components/chunks/chunk-TLBXTBMM.js +46 -0
- package/dist/cdn/components/chunks/chunk-UVHVQRPT.js +1 -0
- package/dist/cdn/components/chunks/chunk-WW4BTWMH.js +1 -0
- package/dist/cdn/components/chunks/{chunk-2Y2EU2CI.js → chunk-Z3OFIE7S.js} +1 -1
- package/dist/cdn/components/eun-alert.js +13 -6
- package/dist/cdn/components/eun-animate.js +3 -3
- package/dist/cdn/components/eun-badge.js +1 -1
- package/dist/cdn/components/eun-button.js +1 -1
- package/dist/cdn/components/eun-calendar.js +2 -2
- package/dist/cdn/components/eun-card.js +4 -4
- package/dist/cdn/components/eun-carousel.js +21 -18
- package/dist/cdn/components/eun-check-card.js +1 -1
- package/dist/cdn/components/eun-checkbox-list.js +11 -8
- package/dist/cdn/components/eun-checkbox.js +1 -1
- package/dist/cdn/components/eun-chip.js +3 -3
- package/dist/cdn/components/eun-color-picker.js +60 -68
- package/dist/cdn/components/eun-counter.js +10 -10
- package/dist/cdn/components/eun-date-picker.js +47 -46
- package/dist/cdn/components/eun-description-list.js +2 -2
- package/dist/cdn/components/eun-divider.js +3 -3
- package/dist/cdn/components/eun-drawer.js +5 -5
- package/dist/cdn/components/eun-dropdown-button.js +1 -1
- package/dist/cdn/components/eun-fab.js +2 -2
- package/dist/cdn/components/eun-icon.js +1 -1
- package/dist/cdn/components/eun-image-card.js +1 -1
- package/dist/cdn/components/eun-image-carousel.js +10 -10
- package/dist/cdn/components/eun-infinite-list.js +1 -1
- package/dist/cdn/components/eun-input-file.js +21 -21
- package/dist/cdn/components/eun-input-phone.js +10 -9
- package/dist/cdn/components/eun-input.js +1 -1
- package/dist/cdn/components/eun-link.js +2 -2
- package/dist/cdn/components/eun-loader.js +1 -1
- package/dist/cdn/components/eun-modal.js +13 -13
- package/dist/cdn/components/eun-pagination.js +16 -16
- package/dist/cdn/components/eun-password-strength.js +14 -10
- package/dist/cdn/components/eun-radio-card.js +1 -1
- package/dist/cdn/components/eun-radio-list.js +11 -8
- package/dist/cdn/components/eun-radio.js +1 -1
- package/dist/cdn/components/eun-rating.js +276 -0
- package/dist/cdn/components/eun-scheduler-event-editor.js +10 -10
- package/dist/cdn/components/eun-scheduler-event.js +1 -1
- package/dist/cdn/components/eun-scheduler.js +28 -28
- package/dist/cdn/components/eun-search.js +19 -21
- package/dist/cdn/components/eun-select.js +27 -27
- package/dist/cdn/components/eun-sidebar.js +10 -8
- package/dist/cdn/components/eun-skeleton.js +1 -1
- package/dist/cdn/components/eun-slider.js +3 -3
- package/dist/cdn/components/eun-sliding-card.js +1 -1
- package/dist/cdn/components/eun-step.js +5 -4
- package/dist/cdn/components/eun-stepper.js +25 -25
- package/dist/cdn/components/eun-switch.js +1 -1
- package/dist/cdn/components/eun-tab-group.js +4 -4
- package/dist/cdn/components/eun-tab.js +1 -1
- package/dist/cdn/components/eun-table-action-bar.js +1 -1
- package/dist/cdn/components/eun-table.js +1 -1
- package/dist/cdn/components/eun-tag.js +3 -3
- package/dist/cdn/components/eun-textarea.js +39 -34
- package/dist/cdn/components/eun-time-picker.js +15 -14
- package/dist/cdn/components/eun-toast.js +19 -10
- package/dist/cdn/components/eun-toggle-group.js +6 -4
- package/dist/cdn/components/eun-toggle-item.js +1 -1
- package/dist/cdn/components/eun-toggle.js +2 -2
- package/dist/cdn/components/eun-toolbar.js +5 -5
- package/dist/cdn/components/eun-tooltip.js +3 -3
- package/dist/components/action/button/button.d.ts +2 -1
- package/dist/components/action/button/button.js +3 -2
- package/dist/components/action/button/button.styles.js +10 -5
- package/dist/components/action/dropdown-button/dropdown-button.js +10 -5
- package/dist/components/action/toggle/toggle-group.js +1 -1
- package/dist/components/action/toggle/toggle-group.styles.js +4 -2
- package/dist/components/action/toggle/toggle.js +1 -1
- package/dist/components/alert/alert/alert.d.ts +9 -7
- package/dist/components/alert/alert/alert.js +11 -14
- package/dist/components/alert/alert/alert.styles.js +9 -2
- package/dist/components/alert/drawer/drawer.d.ts +5 -5
- package/dist/components/alert/drawer/drawer.js +8 -12
- package/dist/components/alert/drawer/drawer.styles.js +1 -1
- package/dist/components/alert/modal/modal.d.ts +10 -10
- package/dist/components/alert/modal/modal.js +13 -25
- package/dist/components/alert/toast/toast.d.ts +7 -5
- package/dist/components/alert/toast/toast.js +9 -13
- package/dist/components/alert/toast/toast.styles.js +15 -6
- package/dist/components/content/badge/badge.js +2 -2
- package/dist/components/content/card/card.js +1 -1
- package/dist/components/content/card/card.styles.js +2 -2
- package/dist/components/content/chip/chip.d.ts +4 -4
- package/dist/components/content/chip/chip.js +8 -8
- package/dist/components/content/description-list/description-list.js +3 -3
- package/dist/components/content/icon/icon.d.ts +3 -0
- package/dist/components/content/icon/icon.js +3 -0
- package/dist/components/content/icon/icon.style.d.ts +2 -0
- package/dist/components/content/icon/icon.style.js +4 -0
- package/dist/components/content/image-carousel/image-carousel.d.ts +12 -12
- package/dist/components/content/image-carousel/image-carousel.js +24 -24
- package/dist/components/content/password-strength/password-strength.d.ts +21 -6
- package/dist/components/content/password-strength/password-strength.js +37 -16
- package/dist/components/content/password-strength/password-strength.styles.js +4 -0
- package/dist/components/content/tag/tag.js +2 -2
- package/dist/components/content/tooltip/tooltip.js +3 -3
- package/dist/components/form/checkbox/check-card.d.ts +1 -0
- package/dist/components/form/checkbox/check-card.js +1 -0
- package/dist/components/form/checkbox/checkbox-list.d.ts +17 -0
- package/dist/components/form/checkbox/checkbox-list.js +39 -10
- package/dist/components/form/checkbox/checkbox.d.ts +1 -0
- package/dist/components/form/checkbox/checkbox.js +3 -1
- package/dist/components/form/checkbox/checkbox.styles.js +3 -2
- package/dist/components/form/color-picker/color-picker.d.ts +41 -28
- package/dist/components/form/color-picker/color-picker.js +66 -50
- package/dist/components/form/color-picker/color-picker.styles.js +1 -1
- package/dist/components/form/counter/counter.d.ts +22 -18
- package/dist/components/form/counter/counter.js +59 -61
- package/dist/components/form/date-picker/date-picker.d.ts +27 -6
- package/dist/components/form/date-picker/date-picker.js +75 -54
- package/dist/components/form/input/input.d.ts +38 -39
- package/dist/components/form/input/input.js +85 -109
- package/dist/components/form/input-file/input-file.d.ts +26 -13
- package/dist/components/form/input-file/input-file.js +35 -35
- package/dist/components/form/input-file/input-file.styles.js +4 -4
- package/dist/components/form/input-phone/input-phone.d.ts +22 -5
- package/dist/components/form/input-phone/input-phone.js +41 -13
- package/dist/components/form/radio/radio-card.d.ts +1 -0
- package/dist/components/form/radio/radio-card.js +1 -0
- package/dist/components/form/radio/radio-list.d.ts +23 -7
- package/dist/components/form/radio/radio-list.js +47 -22
- package/dist/components/form/radio/radio.d.ts +1 -0
- package/dist/components/form/radio/radio.js +1 -0
- package/dist/components/form/rating/rating.d.ts +349 -0
- package/dist/components/form/rating/rating.js +665 -0
- package/dist/components/form/rating/rating.styles.d.ts +1 -0
- package/dist/components/form/rating/rating.styles.js +213 -0
- package/dist/components/form/search/search.d.ts +8 -8
- package/dist/components/form/search/search.js +23 -41
- package/dist/components/form/select/select.d.ts +23 -10
- package/dist/components/form/select/select.js +59 -41
- package/dist/components/form/shared-styles/listbox.styles.js +10 -0
- package/dist/components/form/slider/slider.d.ts +7 -8
- package/dist/components/form/slider/slider.js +9 -12
- package/dist/components/form/switch/switch.d.ts +1 -0
- package/dist/components/form/switch/switch.js +1 -0
- package/dist/components/form/textarea/textarea.d.ts +89 -23
- package/dist/components/form/textarea/textarea.js +192 -43
- package/dist/components/form/time-picker/time-picker-columns.d.ts +2 -2
- package/dist/components/form/time-picker/time-picker-columns.js +8 -8
- package/dist/components/form/time-picker/time-picker.d.ts +24 -8
- package/dist/components/form/time-picker/time-picker.js +59 -38
- package/dist/components/layout/animate/animate.js +1 -1
- package/dist/components/layout/animate/animate.styles.js +2 -2
- package/dist/components/layout/divider/divider.js +1 -1
- package/dist/components/layout/divider/divider.styles.js +1 -1
- package/dist/components/loader/loader/loader.js +2 -2
- package/dist/components/loader/loader/loader.styles.js +14 -12
- package/dist/components/loader/skeleton/skeleton.js +1 -1
- package/dist/components/navigation/carousel/carousel.d.ts +31 -7
- package/dist/components/navigation/carousel/carousel.js +74 -35
- package/dist/components/navigation/carousel/carousel.styles.js +5 -2
- package/dist/components/navigation/pagination/pagination.d.ts +23 -21
- package/dist/components/navigation/pagination/pagination.js +30 -53
- package/dist/components/navigation/sidebar/sidebar.d.ts +15 -13
- package/dist/components/navigation/sidebar/sidebar.js +21 -33
- package/dist/components/navigation/sidebar/sidebar.styles.js +5 -3
- package/dist/components/navigation/stepper/step.js +9 -8
- package/dist/components/navigation/stepper/stepper.js +12 -5
- package/dist/components/navigation/tabs/tab-group/tab-group.js +2 -2
- package/dist/components/navigation/tabs/tab-group/tab-group.styles.js +2 -2
- package/dist/components/navigation/toolbar/toolbar.d.ts +13 -13
- package/dist/components/navigation/toolbar/toolbar.js +20 -34
- package/dist/features/scheduler/calendar/calendar.js +1 -1
- package/dist/features/scheduler/scheduler/scheduler.d.ts +7 -7
- package/dist/features/scheduler/scheduler/scheduler.js +15 -24
- package/dist/features/scheduler/scheduler-event/scheduler-event.js +3 -3
- package/dist/features/scheduler/scheduler-event/scheduler-event.styles.js +1 -1
- package/dist/features/scheduler/scheduler-event-editor/scheduler-event-editor.d.ts +6 -4
- package/dist/features/scheduler/scheduler-event-editor/scheduler-event-editor.js +6 -7
- package/dist/i18n/en.d.ts +68 -0
- package/dist/i18n/en.js +68 -0
- package/dist/i18n/fr.js +68 -2
- package/dist/index.d.ts +2 -0
- package/dist/index.js +1 -0
- package/dist/mixins/button.mixin.js +3 -2
- package/dist/mixins/check.mixin.js +11 -10
- package/dist/mixins/disabled.mixin.d.ts +5 -0
- package/dist/mixins/disabled.mixin.js +21 -1
- package/dist/mixins/editable.mixin.js +28 -5
- package/dist/mixins/field-appearance.mixin.js +3 -2
- package/dist/mixins/form.mixin.d.ts +4 -0
- package/dist/mixins/form.mixin.js +87 -13
- package/dist/mixins/localizable.mixin.d.ts +1 -1
- package/dist/mixins/localizable.mixin.js +1 -1
- package/dist/mixins/radio.mixin.js +11 -10
- package/dist/mixins/readonly.mixin.d.ts +2 -1
- package/dist/mixins/readonly.mixin.js +10 -3
- package/dist/ssr/alert-ssr.css +187 -0
- package/dist/ssr/badge-ssr.css +67 -0
- package/dist/ssr/breadcrumb-ssr.css +41 -0
- package/dist/ssr/card-ssr.css +27 -15
- package/dist/ssr/carousel-ssr.css +238 -0
- package/dist/ssr/checkbox-ssr.css +67 -0
- package/dist/ssr/chip-ssr.css +242 -0
- package/dist/ssr/collapse-ssr.css +151 -0
- package/dist/ssr/field-ssr.css +163 -0
- package/dist/ssr/icon-ssr.css +266 -0
- package/dist/ssr/image-carousel-ssr.css +24 -0
- package/dist/ssr/links-ssr.css +7 -1
- package/dist/ssr/pagination-ssr.css +4 -0
- package/dist/ssr/rating-ssr.css +254 -0
- package/dist/ssr/sidebar-ssr.css +9 -1
- package/dist/ssr/skeleton-ssr.css +63 -0
- package/dist/ssr/tabs-ssr.css +129 -0
- package/dist/ssr/toggle-group-ssr.css +182 -0
- package/dist/ssr/toolbar-ssr.css +31 -2
- package/dist/utils/implicit-submission.utils.d.ts +18 -0
- package/dist/utils/implicit-submission.utils.js +79 -0
- package/dist/utils/listbox-options.utils.d.ts +11 -0
- package/dist/utils/listbox-options.utils.js +41 -3
- package/package.json +26 -7
- package/dist/cdn/components/chunks/chunk-4PI6RDUS.js +0 -1
- package/dist/cdn/components/chunks/chunk-A3X4KD2X.js +0 -1
- package/dist/cdn/components/chunks/chunk-BQFJR2UP.js +0 -110
- package/dist/cdn/components/chunks/chunk-G5SBDQQ3.js +0 -1
- package/dist/cdn/components/chunks/chunk-KSZRQRN4.js +0 -1
- package/dist/cdn/components/chunks/chunk-PE4DAXHQ.js +0 -3
- package/dist/cdn/components/chunks/chunk-RS7TWEMQ.js +0 -1
- package/dist/cdn/components/chunks/chunk-VOTRXBDS.js +0 -38
|
@@ -1,110 +0,0 @@
|
|
|
1
|
-
import{a as L}from"./chunk-G5SBDQQ3.js";import{a as E}from"./chunk-L74LXUGL.js";import{a as V}from"./chunk-UYZR4JXZ.js";import{a as T}from"./chunk-4PI6RDUS.js";import{a as M}from"./chunk-BO3JOEWM.js";import{a as o,c as w,d as x,e as $,f as d}from"./chunk-VOTRXBDS.js";import{a as h}from"./chunk-YYCEPZUN.js";import{a as v}from"./chunk-RS7TWEMQ.js";import{a as l}from"./chunk-PPCHQG7P.js";import{a as p}from"./chunk-O7PHBLH2.js";import{a as t,f as u,h as b,j as i,k as m,l as f,n as y,p as r,r as n,u as g}from"./chunk-YITWLCD3.js";var C=b`
|
|
2
|
-
.has-trailing-action #field {
|
|
3
|
-
padding-inline-end: calc(
|
|
4
|
-
calc(var(--eun-space-l, 32px) * 1.2) + var(--eun-space-xs, 4px)
|
|
5
|
-
);
|
|
6
|
-
}
|
|
7
|
-
#field[type="search"]::-webkit-search-cancel-button {
|
|
8
|
-
appearance: none;
|
|
9
|
-
display: none;
|
|
10
|
-
}
|
|
11
|
-
`,S=[V,C];var P="eun-input",A=v($(g)),F=T(M(x(L(w(A))))),e=class extends F{constructor(){super(...arguments);this.type="text";this.clearable=!1;this.autocomplete="off";this.emptyValueLabel="No value set";this.confirmLabel="Save";this.cancelLabel="Cancel";this.ariaLabelClear="Clear field";this.ariaLabelShowPassword="Show password";this.ariaLabelHidePassword="Hide password";this.showPassword=!1;this.handleIconSlotChange=()=>{this.requestUpdate()};this.checkLocalValidators=()=>E(this.fieldEl,["valueMissing","typeMismatch","patternMismatch","tooShort","tooLong","rangeUnderflow","rangeOverflow","stepMismatch","badInput"])}get defaultValue(){return super.defaultValue}set defaultValue(a){super.defaultValue=a}focusTarget(){return this.fieldEl}updated(a){super.updated(a),a.has("editing")&&this.editing&&this.fieldEl?.focus(),a.has("disabled")&&(this.disabled?this.setAttribute("tabindex","-1"):this.removeAttribute("tabindex"))}getFocusAnchor(){return this.fieldEl??void 0}focus(){super.focus?.(),this.focusTarget()?.focus()}handleInput(a){this.value=a.target.value,this.dispatchEvent(new h(this.value))}handleClear(){this.value="",this.dispatchEvent(new h(this.value)),this.fieldEl?.focus()}togglePasswordVisibility(){this.showPassword=!this.showPassword}renderReadonlyDisplay(){let a=!!this.value?.trim().length;return r`
|
|
12
|
-
<div
|
|
13
|
-
id="readonly-display"
|
|
14
|
-
role="button"
|
|
15
|
-
tabindex="0"
|
|
16
|
-
aria-label=${l(this.label)}
|
|
17
|
-
@click=${this.startEdit}
|
|
18
|
-
@keydown=${s=>(s.key==="Enter"||s.key===" ")&&this.startEdit()}
|
|
19
|
-
>
|
|
20
|
-
<span class=${p({empty:!a})}
|
|
21
|
-
>${a?this.value:this.emptyValueLabel}</span
|
|
22
|
-
>
|
|
23
|
-
</div>
|
|
24
|
-
`}renderTrailingAddon(a){return n}hasTrailingAddon(){return!1}renderField(a){let s=this.type==="password",c=this.clearable&&!s&&!!this.value&&!this.disabled;return r`
|
|
25
|
-
<div
|
|
26
|
-
id="field-wrapper"
|
|
27
|
-
class=${p({"has-icon":!!this.icon||!!this.iconSlotEls?.length,"has-trailing-action":c||s||this.hasTrailingAddon()})}
|
|
28
|
-
>
|
|
29
|
-
<slot name="icon" @slotchange=${this.handleIconSlotChange}>
|
|
30
|
-
${this.icon?r`<eun-icon id="icon" name=${this.icon} size="16"></eun-icon>`:n}
|
|
31
|
-
</slot>
|
|
32
|
-
<input
|
|
33
|
-
id="field"
|
|
34
|
-
type=${s?this.showPassword?"text":"password":this.type}
|
|
35
|
-
.value=${this.value??""}
|
|
36
|
-
placeholder=${l(this.placeholder)}
|
|
37
|
-
autocomplete=${this.autocomplete}
|
|
38
|
-
?disabled=${this.disabled}
|
|
39
|
-
?readonly=${this.readonly}
|
|
40
|
-
?required=${this.required}
|
|
41
|
-
minlength=${l(this.minlength)}
|
|
42
|
-
maxlength=${l(this.maxlength)}
|
|
43
|
-
pattern=${l(this.pattern)}
|
|
44
|
-
min=${l(this.min)}
|
|
45
|
-
max=${l(this.max)}
|
|
46
|
-
step=${l(this.step)}
|
|
47
|
-
inputmode=${this.type==="number"?"numeric":this.type==="email"?"email":n}
|
|
48
|
-
aria-invalid=${this.showError}
|
|
49
|
-
aria-label=${l(this.label)}
|
|
50
|
-
aria-describedby=${a?"description":n}
|
|
51
|
-
@input=${this.handleInput}
|
|
52
|
-
/>
|
|
53
|
-
${o(c,()=>r`
|
|
54
|
-
<button
|
|
55
|
-
type="button"
|
|
56
|
-
id="clear"
|
|
57
|
-
@click=${this.handleClear}
|
|
58
|
-
aria-label=${this.ariaLabelClear}
|
|
59
|
-
tabindex="-1"
|
|
60
|
-
>
|
|
61
|
-
<eun-icon name="cancel" size="16"></eun-icon>
|
|
62
|
-
</button>
|
|
63
|
-
`)}
|
|
64
|
-
${o(s,()=>r`
|
|
65
|
-
<button
|
|
66
|
-
type="button"
|
|
67
|
-
id="password-toggle"
|
|
68
|
-
@click=${this.togglePasswordVisibility}
|
|
69
|
-
aria-label=${this.showPassword?this.ariaLabelHidePassword:this.ariaLabelShowPassword}
|
|
70
|
-
aria-pressed=${this.showPassword}
|
|
71
|
-
tabindex="-1"
|
|
72
|
-
>
|
|
73
|
-
<eun-icon
|
|
74
|
-
name=${this.showPassword?"visibility_off":"visibility"}
|
|
75
|
-
size="16"
|
|
76
|
-
></eun-icon>
|
|
77
|
-
</button>
|
|
78
|
-
`)}
|
|
79
|
-
${this.renderTrailingAddon(c)}
|
|
80
|
-
</div>
|
|
81
|
-
${o(this.readonlyAvailable,()=>r`
|
|
82
|
-
<div id="edit-actions">
|
|
83
|
-
<eun-button
|
|
84
|
-
class="confirm"
|
|
85
|
-
size="s"
|
|
86
|
-
color="primary"
|
|
87
|
-
appearance="default"
|
|
88
|
-
rounded
|
|
89
|
-
type="button"
|
|
90
|
-
@click=${this.confirmEdit}
|
|
91
|
-
>${this.confirmLabel}</eun-button
|
|
92
|
-
>
|
|
93
|
-
<eun-button
|
|
94
|
-
class="cancel"
|
|
95
|
-
size="s"
|
|
96
|
-
appearance="flat"
|
|
97
|
-
rounded
|
|
98
|
-
type="button"
|
|
99
|
-
@click=${this.cancelEdit}
|
|
100
|
-
>${this.cancelLabel}</eun-button
|
|
101
|
-
>
|
|
102
|
-
</div>
|
|
103
|
-
`)}
|
|
104
|
-
`}render(){let a=this.readonlyAvailable&&!this.editing,s=this.renderDescription();return r`
|
|
105
|
-
<div id="wrapper">
|
|
106
|
-
${this.renderFormLabels(a?void 0:"field")}
|
|
107
|
-
${a?this.renderReadonlyDisplay():this.renderField(s!==n)}
|
|
108
|
-
${s}
|
|
109
|
-
</div>
|
|
110
|
-
`}};e.styles=[S,d.base,d.errorMessages,d.hintMessages],t([i({reflect:!0})],e.prototype,"type",2),t([i({attribute:"default-value"})],e.prototype,"defaultValue",1),t([i()],e.prototype,"placeholder",2),t([i()],e.prototype,"icon",2),t([i({type:Boolean})],e.prototype,"clearable",2),t([i()],e.prototype,"autocomplete",2),t([i({type:Number})],e.prototype,"minlength",2),t([i({type:Number})],e.prototype,"maxlength",2),t([i()],e.prototype,"pattern",2),t([i()],e.prototype,"min",2),t([i()],e.prototype,"max",2),t([i()],e.prototype,"step",2),t([i({attribute:"empty-value-label"})],e.prototype,"emptyValueLabel",2),t([i({attribute:"confirm-label"})],e.prototype,"confirmLabel",2),t([i({attribute:"cancel-label"})],e.prototype,"cancelLabel",2),t([i({attribute:"aria-label-clear"})],e.prototype,"ariaLabelClear",2),t([i({attribute:"aria-label-show-password"})],e.prototype,"ariaLabelShowPassword",2),t([i({attribute:"aria-label-hide-password"})],e.prototype,"ariaLabelHidePassword",2),t([m()],e.prototype,"showPassword",2),t([f("#field")],e.prototype,"fieldEl",2),t([y({slot:"icon"})],e.prototype,"iconSlotEls",2),e=t([u(P)],e);export{P as a,e as b};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as r,j as a}from"./chunk-YITWLCD3.js";var e=class t extends Event{static{this.eventName="euncommit"}constructor(){super(t.eventName,{bubbles:!0,composed:!1})}};var c=t=>{class i extends t{constructor(){super(...arguments);this.readonlyAvailable=!1;this.editing=!1}startEdit(){this.disabled||!this.readonlyAvailable||this.editing||(this.valueOnEditStart=this.value,this.editing=!0)}confirmEdit(){this.checkValidity(this.value)&&(this.editing=!1,this.dispatchEvent(new e))}cancelEdit(){this.value=this.valueOnEditStart,this.editing=!1}}return r([a({type:Boolean,attribute:"readonly-available",reflect:!0})],i.prototype,"readonlyAvailable",2),r([a({type:Boolean,reflect:!0})],i.prototype,"editing",2),i};export{c as a};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var t="en";function r(){return t}var n={datePicker:{previousMonth:"Previous month",chooseMonthYear:"Choose month and year",nextMonth:"Next month",previousYear:"Previous year",chooseYear:"Choose year",nextYear:"Next year",previousYears:"Previous years",nextYears:"Next years",time:"Time",amPm:"AM/PM",hour:"Hour",minute:"Minute",heading:{day:{single:"Select a date",range:"Select a date range"},month:{single:"Select a month",range:"Select a month range"},year:{single:"Select a year",range:"Select a year range"}},modalPreview:{day:{single:"Select date",range:"Select date range"},month:{single:"Select month",range:"Select month range"},year:{single:"Select year",range:"Select year range"}}},timePicker:{amPm:"AM/PM",hour:"Hour",minute:"Minute",time:"Time",selectATime:"Select a time",mustBeAtOrAfter:e=>`Time must be at or after ${e}`,mustBeAtOrBefore:e=>`Time must be at or before ${e}`},scheduler:{calendarView:"Calendar view"},carousel:{ofTotal:(e,i)=>`${e} of ${i}`,slideNavigation:"Slide navigation",previous:"Previous slide",next:"Next slide",goToSlide:(e,i)=>`Go to slide ${e} of ${i}`},imageCarousel:{gallery:"Image gallery",previous:"Previous image",next:"Next image",expand:"View full-size image",lightbox:"Image viewer",selectImage:"Select image",showImage:(e,i)=>`Show image ${e} of ${i}`,imageNavigation:"Image navigation",goToImage:(e,i)=>`Go to image ${e} of ${i}`,allImages:"All images"},chip:{remove:"Remove"},infiniteList:{loadingMore:"Loading more items\u2026",itemsLoaded:e=>`${e} more item${e>1?"s":""} loaded`},table:{loadingMore:"Loading more rows\u2026",selected:"selected",selectAll:"Select all",deselectAll:"Deselect all",selectAllRows:"Select all rows",deselectAllRows:"Deselect all rows",selectRow:"Select row",selectionActions:"Selection actions",clearSelection:"Clear selection",rowActions:"Row actions",rowsLoaded:e=>`${e} more row${e>1?"s":""} loaded`},link:{opensInNewTab:"opens in a new tab"},validation:{valueMissing:"This field is required",tooShort:(e,i)=>`Please lengthen this text to ${e} characters or more (you are currently using ${i} characters).`,tooLong:(e,i)=>`Please shorten this text to ${e} characters or less (you are currently using ${i} characters).`,invalidDate:"Enter a valid date",invalidTime:"Enter a valid time"}};var a={datePicker:{previousMonth:"Mois pr\xE9c\xE9dent",chooseMonthYear:"Choisir le mois et l'ann\xE9e",nextMonth:"Mois suivant",previousYear:"Ann\xE9e pr\xE9c\xE9dente",chooseYear:"Choisir l'ann\xE9e",nextYear:"Ann\xE9e suivante",previousYears:"Ann\xE9es pr\xE9c\xE9dentes",nextYears:"Ann\xE9es suivantes",time:"Heure",amPm:"AM/PM",hour:"Heure",minute:"Minute",heading:{day:{single:"S\xE9lectionner une date",range:"S\xE9lectionner une plage de dates"},month:{single:"S\xE9lectionner un mois",range:"S\xE9lectionner une plage de mois"},year:{single:"S\xE9lectionner une ann\xE9e",range:"S\xE9lectionner une plage d'ann\xE9es"}},modalPreview:{day:{single:"S\xE9lectionner une date",range:"S\xE9lectionner une plage de dates"},month:{single:"S\xE9lectionner un mois",range:"S\xE9lectionner une plage de mois"},year:{single:"S\xE9lectionner une ann\xE9e",range:"S\xE9lectionner une plage d'ann\xE9es"}}},timePicker:{amPm:"AM/PM",hour:"Heure",minute:"Minute",time:"Heure",selectATime:"S\xE9lectionner une heure",mustBeAtOrAfter:e=>`L'heure doit \xEAtre \xE0 ${e} ou apr\xE8s`,mustBeAtOrBefore:e=>`L'heure doit \xEAtre \xE0 ${e} ou avant`},scheduler:{calendarView:"Vue du calendrier"},carousel:{ofTotal:(e,i)=>`${e} sur ${i}`,slideNavigation:"Navigation des diapositives",previous:"Diapositive pr\xE9c\xE9dente",next:"Diapositive suivante",goToSlide:(e,i)=>`Aller \xE0 la diapositive ${e} sur ${i}`},imageCarousel:{gallery:"Galerie d'images",previous:"Image pr\xE9c\xE9dente",next:"Image suivante",expand:"Voir l'image en taille r\xE9elle",lightbox:"Visionneuse d'images",selectImage:"S\xE9lectionner une image",showImage:(e,i)=>`Afficher l'image ${e} sur ${i}`,imageNavigation:"Navigation des images",goToImage:(e,i)=>`Aller \xE0 l'image ${e} sur ${i}`,allImages:"Toutes les images"},chip:{remove:"Retirer"},infiniteList:{loadingMore:"Chargement d'autres \xE9l\xE9ments\u2026",itemsLoaded:e=>e>1?`${e} \xE9l\xE9ments suppl\xE9mentaires charg\xE9s`:`${e} \xE9l\xE9ment suppl\xE9mentaire charg\xE9`},table:{loadingMore:"Chargement d'autres lignes\u2026",selected:"s\xE9lectionn\xE9e(s)",selectAll:"Tout s\xE9lectionner",deselectAll:"Tout d\xE9s\xE9lectionner",selectAllRows:"S\xE9lectionner toutes les lignes",deselectAllRows:"D\xE9s\xE9lectionner toutes les lignes",selectRow:"S\xE9lectionner la ligne",selectionActions:"Actions de s\xE9lection",clearSelection:"Vider la s\xE9lection",rowActions:"Actions de la ligne",rowsLoaded:e=>e>1?`${e} lignes suppl\xE9mentaires charg\xE9es`:`${e} ligne suppl\xE9mentaire charg\xE9e`},link:{opensInNewTab:"ouvre dans un nouvel onglet"},validation:{valueMissing:"Ce champ est obligatoire",tooShort:(e,i)=>`Saisissez au moins ${e} caract\xE8res (actuellement ${i}).`,tooLong:(e,i)=>`Saisissez au plus ${e} caract\xE8res (actuellement ${i}).`,invalidDate:"Saisissez une date valide",invalidTime:"Saisissez une heure valide"}};var d={en:n,fr:a};export{r as a,d as b};
|
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
import{p as i}from"./chunk-YITWLCD3.js";function l(e){let n=[];for(let t of e)if(t instanceof HTMLOptionElement)n.push({value:t.value,label:t.textContent?.trim()??t.value});else if(t instanceof HTMLOptGroupElement)for(let o of Array.from(t.querySelectorAll("option")))n.push({value:o.value,label:o.textContent?.trim()??o.value,group:t.label});return n}function p(e,n){if(!n)return e;let t=e.toLowerCase().indexOf(n);return t===-1?e:i`${e.slice(0,t)}<mark
|
|
2
|
-
>${e.slice(t,t+n.length)}</mark
|
|
3
|
-
>${e.slice(t+n.length)}`}export{l as a,p as b};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as i,j as r}from"./chunk-YITWLCD3.js";var l=s=>{class e extends s{constructor(){super(...arguments);this.disabled=!1}updated(t){super.updated(t),t.has("disabled")&&(this.setAttribute("tabindex",this.disabled?"-1":"0"),this.disabled?this.setAttribute("aria-disabled","true"):this.removeAttribute("aria-disabled"))}}return i([r({type:Boolean,reflect:!0})],e.prototype,"disabled",2),e};export{l as a};
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import{a as y}from"./chunk-YYCEPZUN.js";import{a as b,b as m}from"./chunk-KSZRQRN4.js";import{a as r,h as p,j as n,k as o,p as u,r as v}from"./chunk-YITWLCD3.js";function V(l,i,c){return l?i(l):c?.(l)}var k=["valid","hideError","disabled","touched","dirty","validationRequested","error"],F=l=>k.some(i=>l.has(i)),B=l=>{class i extends l{constructor(...e){super(...e);this.hideError=!1;this.checkable=!1;this.checked=!1;this.dirty=!1;this.touched=!1;this.validationRequested=!1;this.controlled=!1;this.#e=()=>{this.dirty||(this.dirty=!0)};this.#t=()=>{this.touched||(this.touched=!0)};this.#i=()=>{this.validationRequested=!0};this.internals||(this.internals=this.attachInternals())}static{this.formAssociated=!0}#e;#t;#i;get showError(){return!this.valid&&!this.hideError&&!this.disabled&&(this.touched||this.dirty||this.validationRequested||!!this.error)}get pristine(){return!this.dirty}get untouched(){return!this.touched}get defaultValue(){return this.internalDefaultValue}set defaultValue(e){let t=this.value==null||Array.isArray(this.value)&&this.value.length===0;e!=null&&(this.defaultValue==null||this.defaultValue==="")&&t&&(this.value=e),this.internalDefaultValue=e}get value(){return this.valueState}set value(e){this.valueState=e,this.setFormValue(e)}get description(){return this.showError?this.errorMessages.length?this.errorMessages:this.validationMessage.length?this.validationMessage:this.hint:this.hint}get form(){return this.internals.form}get type(){return this.localName}getValueToValidate(){return this.checkable?this.checked:this.value}connectedCallback(){super.connectedCallback?.(),this.checkable&&this.checked&&this.setFormValue(this.value),this.checkable||this.defaultValue===void 0||this.defaultValue===""||(this.value=this.defaultValue),this.checkValidity(this.value),this.addEventListener(y.eventName,this.#e),this.addEventListener("focusout",this.#t),this.addEventListener("invalid",this.#i)}disconnectedCallback(){this.removeEventListener(y.eventName,this.#e),this.removeEventListener("focusout",this.#t),this.removeEventListener("invalid",this.#i),super.disconnectedCallback?.()}willUpdate(e){(e.has("value")||e.has("valueState")||e.has("checked")||e.has("validators")||e.has("required")||e.has("error"))&&this.checkValidity(),super.willUpdate(e)}setFormValue(e){let t=new FormData;if(this.disabled||this.checkable&&!this.checked){this.internals.setFormValue(t);return}let s=this.name||this.getAttribute("name");if(!s){this.internals.setFormValue(t);return}Array.isArray(e)?e.forEach(a=>t.append(s,a instanceof File?a:String(a))):e!=null&&(e instanceof File?t.append(s,e):t.append(s,this.checkable&&!this.value?"on":String(e))),this.internals.setFormValue(t)}formResetCallback(){this.controlled||(this.checkable?this.checked=!1:this.value=this.defaultValue),this.dirty=!1,this.touched=!1,this.validationRequested=!1}renderDescription(){return this.renderError()}renderError(){let{description:e}=this;return e?.length?this.showError?u`
|
|
2
|
-
<p id="description" class="error-messages">
|
|
3
|
-
${V(Array.isArray(e),()=>e.map(t=>u`<span>${t}</span>`),()=>u`<span>${e}</span>`)}
|
|
4
|
-
</p>
|
|
5
|
-
`:u`
|
|
6
|
-
<p id="description" class="hint-messages">
|
|
7
|
-
<span>${e}</span>
|
|
8
|
-
</p>
|
|
9
|
-
`:v}}return r([n({reflect:!0})],i.prototype,"name",2),r([n()],i.prototype,"hint",2),r([n({type:Boolean,attribute:"hide-error"})],i.prototype,"hideError",2),r([o()],i.prototype,"valueState",2),r([o()],i.prototype,"dirty",2),r([o()],i.prototype,"touched",2),r([o()],i.prototype,"validationRequested",2),r([n({type:Boolean})],i.prototype,"controlled",2),r([n({attribute:"default-value",converter:{fromAttribute:e=>e?e.split(","):void 0,toAttribute:e=>e?.join(",")??null}})],i.prototype,"defaultValue",1),r([n()],i.prototype,"value",1),i};var $=l=>{class i extends l{constructor(){super(...arguments);this.readonly=!1}updated(e){super.updated(e),e.has("readonly")&&this.setAttribute("aria-readonly",String(this.readonly))}}return r([n({type:Boolean,reflect:!0})],i.prototype,"readonly",2),i};var G=l=>{class i extends l{constructor(...e){super(...e);this.required=!1;this.valid=!0;this.errorMessages=[];this.internals||(this.internals=this.attachInternals())}get validationDictionary(){let e=this.locale;return m[e??b()]??m.en}get validity(){return this.internals.validity}get validationMessage(){return this.internals.validationMessage}get willValidate(){return this.internals.willValidate}checkLocalValidators(){return{validity:{}}}buildCommonValidators(){let{value:e}=this,t={},s,a=e==null||typeof e=="string"&&e.trim()===""||e instanceof Array&&!e.length;return this.required&&a&&(t.valueMissing=!0,s=this.validationDictionary.validation.valueMissing),{validity:t,message:s}}checkValidity(e=this.getValueToValidate()){let t=this.checkLocalValidators(),s=this.buildCommonValidators(),a={...t.validity,...s.validity},d=s.message||t.message,h=this.error?[this.error]:[];this.validators?.forEach(E=>this.collectErrors(h,E,e)),this.errorMessages=h,h.length>0&&(a.customError=!0,d=h.join(" ; ")),this.valid=!Object.values(a).some(Boolean);let f=this.getFocusAnchor?.();return this.valid||f||!this.getFocusAnchor?this.setValidity(a,d,f):this.updateComplete.then(()=>this.setValidity(a,d,f)),this.valid}reportValidity(e=this.getValueToValidate()){return this.checkValidity(e),this.internals.reportValidity()}collectErrors(e,t,s){if("~standard"in t){let a=t["~standard"].validate(s);if(a instanceof Promise)throw new TypeError("Validation schemas must be synchronous");a.issues&&e.push(...a.issues.map(d=>d.message))}return"isValid"in t&&(typeof t.isValid=="function"?!t.isValid(s,this.getValidityData()):t.isValid===!1)&&e.push(t.message),"isInvalid"in t&&t.isInvalid({value:s})&&e.push(t.message),e}setValidity(e,t,s){let a=this.validationMessage;this.internals.setValidity(e,t,s),t!==a&&this.requestUpdate("valid")}getValueToValidate(){return this.value}getValidityData(){return{}}}return r([n({type:Array})],i.prototype,"validators",2),r([n({type:Boolean})],i.prototype,"required",2),r([n()],i.prototype,"error",2),r([o()],i.prototype,"valid",2),i};var T=p`
|
|
10
|
-
#description {
|
|
11
|
-
font-family: var(--eun-font-family, "Mulish", sans-serif);
|
|
12
|
-
display: block;
|
|
13
|
-
margin-block-start: var(--eun-space-xs, 4px);
|
|
14
|
-
font-size: var(--field-message-font-size, var(--eun-font-size-xs, 12px));
|
|
15
|
-
margin-block: 0;
|
|
16
|
-
}
|
|
17
|
-
#description span {
|
|
18
|
-
display: block;
|
|
19
|
-
margin-top: var(--eun-space-xs, 4px);
|
|
20
|
-
}
|
|
21
|
-
`,M=p`
|
|
22
|
-
.error-messages {
|
|
23
|
-
color: var(--_errorColor);
|
|
24
|
-
}
|
|
25
|
-
`,x=p`
|
|
26
|
-
.hint-messages {
|
|
27
|
-
color: var(--_hintColor);
|
|
28
|
-
}
|
|
29
|
-
`,W={base:T,errorMessages:M,hintMessages:x};export{V as a,F as b,B as c,$ as d,G as e,W as f};
|
|
30
|
-
/*! Bundled license information:
|
|
31
|
-
|
|
32
|
-
lit-html/directives/when.js:
|
|
33
|
-
(**
|
|
34
|
-
* @license
|
|
35
|
-
* Copyright 2021 Google LLC
|
|
36
|
-
* SPDX-License-Identifier: BSD-3-Clause
|
|
37
|
-
*)
|
|
38
|
-
*/
|