@ds-autonomie/web-components 1.16.2 → 1.17.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/CHANGELOG.md +25 -0
- package/dist/chunks/{chunk.VJRDVQTS.js → chunk.2AZX4GK4.js} +1 -1
- package/dist/chunks/{chunk.BHQ3BNQA.js → chunk.2DYZ4544.js} +3 -3
- package/dist/chunks/{chunk.RG342A22.js → chunk.2GIZK5OL.js} +5 -5
- package/dist/chunks/{chunk.A2AK34DU.js → chunk.2MXY6CAL.js} +1 -1
- package/dist/chunks/{chunk.BROIFXIH.js → chunk.3355NB7L.js} +1 -1
- package/dist/chunks/{chunk.MXDA7QXL.js → chunk.33YIN2OK.js} +12 -9
- package/dist/chunks/{chunk.CZFGLE3Y.js → chunk.4FP4K3F5.js} +20 -0
- package/dist/chunks/{chunk.V7MYOBN4.js → chunk.4L7EJLR4.js} +5 -5
- package/dist/chunks/{chunk.2UZSRWJ7.js → chunk.4QUJBAX3.js} +5 -0
- package/dist/chunks/{chunk.5MXBL3PY.js → chunk.4WWQYBFA.js} +1 -1
- package/dist/chunks/{chunk.JHPIOVRD.js → chunk.5ATFMWVP.js} +4 -4
- package/dist/chunks/{chunk.Z5LJXDHJ.js → chunk.5IKJNP4W.js} +23 -12
- package/dist/chunks/{chunk.PNTPO2DN.js → chunk.6QGIFSKH.js} +21 -11
- package/dist/chunks/{chunk.JXWCUSV3.js → chunk.6SIIMZ3D.js} +1 -1
- package/dist/chunks/{chunk.AMIXGL74.js → chunk.A4O4JY6G.js} +20 -3
- package/dist/chunks/{chunk.RBXTMFL6.js → chunk.A5S4PSDJ.js} +1 -1
- package/dist/chunks/{chunk.R6572W75.js → chunk.AFGTS4PG.js} +10 -7
- package/dist/chunks/{chunk.EAP74BQL.js → chunk.AISSZCX4.js} +29 -32
- package/dist/chunks/{chunk.ORNTGXRO.js → chunk.ARYKCY32.js} +1 -0
- package/dist/chunks/{chunk.KKAOTWJY.js → chunk.ATFH7NZ3.js} +23 -1
- package/dist/chunks/{chunk.N43R5DJN.js → chunk.B64MRSFM.js} +1 -1
- package/dist/chunks/{chunk.7KF6Z37I.js → chunk.BBGXYE4Z.js} +1 -1
- package/dist/chunks/{chunk.ZYY6O4PU.js → chunk.BGU7HA72.js} +4 -4
- package/dist/chunks/{chunk.ZLGBX4RI.js → chunk.BUFBFNGF.js} +1 -1
- package/dist/chunks/{chunk.7DHGAM7P.js → chunk.CBBSK53B.js} +2 -2
- package/dist/chunks/{chunk.V5J2RAQ5.js → chunk.CFISAFUN.js} +90 -1
- package/dist/chunks/{chunk.YG7TOAY3.js → chunk.CJ35H7EE.js} +4 -4
- package/dist/chunks/{chunk.NXQ42SSB.js → chunk.CLHGGIBQ.js} +2 -2
- package/dist/chunks/{chunk.WHTNMZZS.js → chunk.DLMZ2MN2.js} +4 -4
- package/dist/chunks/{chunk.6L6CZSQX.js → chunk.DZLCCB5R.js} +0 -14
- package/dist/chunks/chunk.FWFLQD5T.js +49 -0
- package/dist/chunks/{chunk.SIPW72IF.js → chunk.FZBZ5HAZ.js} +3 -3
- package/dist/chunks/{chunk.GE2PTQVM.js → chunk.GJM5KJMB.js} +1 -1
- package/dist/chunks/{chunk.43EIYNTL.js → chunk.HSLR5GY4.js} +9 -3
- package/dist/chunks/{chunk.N2H4K44W.js → chunk.I3SEN2LI.js} +1 -1
- package/dist/chunks/{chunk.5MB36CJO.js → chunk.IMRGO6QP.js} +1 -1
- package/dist/chunks/{chunk.E475BLMD.js → chunk.JDR7WF3R.js} +1 -1
- package/dist/chunks/{chunk.2PA4QKLT.js → chunk.KKJF6BYU.js} +1 -0
- package/dist/chunks/{chunk.VDOVUA55.js → chunk.KOTPR264.js} +1 -0
- package/dist/chunks/{chunk.D433F3FV.js → chunk.LDRVRUQG.js} +1 -0
- package/dist/chunks/{chunk.3UNYRJRK.js → chunk.LRHTRZGS.js} +1 -1
- package/dist/chunks/{chunk.VXQMFXV5.js → chunk.M7QP6END.js} +20 -2
- package/dist/chunks/{chunk.O2OMAMMI.js → chunk.MDU7KHHW.js} +1 -1
- package/dist/chunks/{chunk.2P44D5YL.js → chunk.MMD7BOR4.js} +3 -1
- package/dist/chunks/{chunk.H2JSXKGD.js → chunk.MPZ56XQK.js} +4 -0
- package/dist/chunks/{chunk.ZWVWEQGL.js → chunk.NDQ5XCHJ.js} +5 -0
- package/dist/chunks/{chunk.A3RCXT25.js → chunk.O6S5WFZL.js} +1 -1
- package/dist/chunks/{chunk.3YSH35MM.js → chunk.O7DWCXXH.js} +1 -1
- package/dist/chunks/{chunk.7J3HDP6J.js → chunk.PKEKVGMQ.js} +1 -1
- package/dist/chunks/{chunk.6L4HRCFK.js → chunk.PTXGBZ6Y.js} +1 -1
- package/dist/chunks/{chunk.JR77AUQ7.js → chunk.PYB3JSR5.js} +1 -1
- package/dist/chunks/{chunk.CWHNW2T5.js → chunk.QGNUX2KV.js} +38 -28
- package/dist/chunks/{chunk.GZMFP7UN.js → chunk.QMCNUEAU.js} +1 -1
- package/dist/chunks/{chunk.45B5UA3U.js → chunk.QVJA3YFE.js} +1 -1
- package/dist/chunks/{chunk.QR4Z7SWH.js → chunk.RBF7AXDI.js} +1 -1
- package/dist/chunks/{chunk.VO6MIHUM.js → chunk.RFQ2Y5SK.js} +2 -0
- package/dist/chunks/{chunk.Z74FEBJS.js → chunk.RIBDMYAF.js} +1 -1
- package/dist/chunks/{chunk.CKBRIIGV.js → chunk.RJUC427U.js} +1 -1
- package/dist/chunks/{chunk.BQ7R6MC6.js → chunk.RSX6EFCX.js} +23 -1
- package/dist/chunks/{chunk.5BCAEDG4.js → chunk.RXNIW3V5.js} +1 -1
- package/dist/chunks/{chunk.QDXCYEAZ.js → chunk.SESHYW6E.js} +1 -1
- package/dist/chunks/{chunk.IDAQJSVV.js → chunk.SS2TFJEH.js} +16 -2
- package/dist/chunks/{chunk.MUGCPHYQ.js → chunk.TZZHA2CW.js} +4 -4
- package/dist/chunks/{chunk.GYJZ3E7K.js → chunk.USOUTPCT.js} +1 -1
- package/dist/chunks/{chunk.EMJZLQCL.js → chunk.UVGAHM33.js} +2 -1
- package/dist/chunks/{chunk.BAU3732X.js → chunk.V3EGD3LC.js} +2 -2
- package/dist/chunks/{chunk.PAF4S7OV.js → chunk.VSC54K2L.js} +17 -1
- package/dist/chunks/{chunk.WPYZYOD5.js → chunk.VZBGTAM3.js} +3 -3
- package/dist/chunks/{chunk.TRKYAEYS.js → chunk.WNP6VKYR.js} +4 -4
- package/dist/chunks/{chunk.KOW5OFDN.js → chunk.WRC4UPSL.js} +1 -1
- package/dist/chunks/{chunk.XD5JM6WF.js → chunk.WYUQG5BJ.js} +20 -0
- package/dist/chunks/{chunk.IQTKA4UT.js → chunk.XNOXIU7B.js} +1 -1
- package/dist/chunks/{chunk.WAROYP2H.js → chunk.YXVKJQFH.js} +1 -1
- package/dist/chunks/{chunk.RCSAV4XJ.js → chunk.ZV7TVP6P.js} +1 -1
- package/dist/components/accordion/accordion.js +6 -6
- package/dist/components/accordion/accordion.styles.js +1 -1
- package/dist/components/alert/alert.d.ts +2 -0
- package/dist/components/alert/alert.js +5 -5
- package/dist/components/anchor-tag/anchor-tag.js +2 -2
- package/dist/components/anchor-tag/anchor-tag.styles.js +1 -1
- package/dist/components/avatar/avatar.js +4 -4
- package/dist/components/breadcrumb/breadcrumb.js +5 -5
- package/dist/components/breadcrumb-item/breadcrumb-item.js +2 -2
- package/dist/components/button/button.js +6 -6
- package/dist/components/calendar/calendar.js +3 -3
- package/dist/components/calendar/calendar.styles.js +1 -1
- package/dist/components/callout/callout.d.ts +23 -0
- package/dist/components/callout/callout.js +75 -0
- package/dist/components/callout/callout.styles.d.ts +2 -0
- package/dist/components/callout/callout.styles.js +8 -0
- package/dist/components/card/card.d.ts +1 -1
- package/dist/components/card/card.js +2 -2
- package/dist/components/card/card.styles.js +1 -1
- package/dist/components/checkbox/checkbox.js +4 -4
- package/dist/components/checkbox-button/checkbox-button.js +5 -5
- package/dist/components/checkbox-button/checkbox-button.styles.js +1 -1
- package/dist/components/checkbox-group/checkbox-group.d.ts +3 -1
- package/dist/components/checkbox-group/checkbox-group.js +2 -2
- package/dist/components/combobox/combobox.d.ts +1 -0
- package/dist/components/combobox/combobox.js +10 -10
- package/dist/components/combobox/combobox.styles.js +1 -1
- package/dist/components/dialog/dialog.js +5 -5
- package/dist/components/download-card/download-card.js +3 -3
- package/dist/components/download-link/download-link.js +5 -5
- package/dist/components/download-link/download-link.styles.js +1 -1
- package/dist/components/drawer/drawer.js +5 -5
- package/dist/components/dropdown/dropdown.js +2 -2
- package/dist/components/error-message-panel/error-message-panel.js +2 -2
- package/dist/components/filter/filter-button/filter-button.js +5 -5
- package/dist/components/filter/filter-counter/filter-counter.js +4 -4
- package/dist/components/filter/filter-date/filter-date.js +11 -11
- package/dist/components/filter/filter-range/filter-range.d.ts +2 -0
- package/dist/components/filter/filter-range/filter-range.js +12 -12
- package/dist/components/filter/filter-select/filter-select.js +9 -9
- package/dist/components/footer/footer.js +3 -3
- package/dist/components/footer-sitemap-item/footer-sitemap-item.js +2 -2
- package/dist/components/footer-sitemap-item/footer-sitemap-item.styles.js +1 -1
- package/dist/components/format-bytes/format-bytes.js +2 -2
- package/dist/components/format-date/format-date.js +2 -2
- package/dist/components/format-number/format-number.js +2 -2
- package/dist/components/header/header.js +3 -3
- package/dist/components/header/header.styles.js +1 -1
- package/dist/components/header-search/header-search.js +2 -2
- package/dist/components/icon/icon.js +3 -3
- package/dist/components/icon/library.js +2 -2
- package/dist/components/icon-button/icon-button.js +3 -3
- package/dist/components/input/input.js +8 -8
- package/dist/components/input-mask/input-mask.js +2 -2
- package/dist/components/input-phone/input-phone.d.ts +2 -1
- package/dist/components/input-phone/input-phone.js +16 -16
- package/dist/components/input-phone/input-phone.styles.js +1 -1
- package/dist/components/menu-accordion/menu-accordion.js +5 -5
- package/dist/components/menu-item/menu-item.js +3 -3
- package/dist/components/navbar/navbar-link/navbar-link.js +3 -3
- package/dist/components/navbar/navbar-menu/navbar-menu.js +5 -5
- package/dist/components/option/option.js +6 -6
- package/dist/components/option/option.styles.js +1 -1
- package/dist/components/pagination/pagination.js +10 -10
- package/dist/components/popup/popup.d.ts +8 -0
- package/dist/components/popup/popup.js +2 -2
- package/dist/components/popup/popup.styles.js +1 -1
- package/dist/components/progress-bar/progress-bar.js +2 -2
- package/dist/components/radio/radio.js +3 -3
- package/dist/components/radio-button/radio-button.js +2 -2
- package/dist/components/radio-button/radio-button.styles.js +1 -1
- package/dist/components/range-slider/range-slider.js +2 -2
- package/dist/components/range-slider/range-slider.styles.js +1 -1
- package/dist/components/relative-time/relative-time.js +2 -2
- package/dist/components/select/select.d.ts +1 -0
- package/dist/components/select/select.js +9 -9
- package/dist/components/select/select.styles.js +1 -1
- package/dist/components/spinner/spinner.js +2 -2
- package/dist/components/step/step.js +6 -6
- package/dist/components/tab/tab.js +2 -2
- package/dist/components/tab-group/tab-group.js +2 -2
- package/dist/components/table/table-action/table-action.js +2 -2
- package/dist/components/table/table-caption/table-caption.js +2 -2
- package/dist/components/table/table-header-row/table-header-row.js +4 -4
- package/dist/components/table/table-row/table-row.js +2 -2
- package/dist/components/tag/tag.js +5 -5
- package/dist/components/tooltip/tooltip.d.ts +1 -1
- package/dist/components/tooltip/tooltip.js +5 -5
- package/dist/components/tooltip/tooltip.styles.js +1 -1
- package/dist/components/tree/tree.js +9 -9
- package/dist/components/tree-item/tree-item.js +7 -7
- package/dist/custom-elements.json +738 -554
- package/dist/design-system.js +149 -149
- package/dist/themes/dsa-wc-theme.css +37 -12
- package/dist/themes/dsa-wc-theme.min.css +1 -1
- package/dist/themes/dsa-wc-theme.styles.js +37 -14
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/utilities/icon-library.js +2 -2
- package/dist/utilities/localize.d.ts +0 -1
- package/dist/utilities/localize.js +1 -1
- package/dist/vscode.html-custom-data.json +162 -121
- package/dist/web-types.json +420 -313
- package/package.json +3 -3
- package/dist/chunks/{chunk.O2PIWM25.js → chunk.D34QDO4H.js} +3 -3
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import {
|
|
2
2
|
DSASelect
|
|
3
|
-
} from "./chunk.
|
|
3
|
+
} from "./chunk.6QGIFSKH.js";
|
|
4
|
+
import {
|
|
5
|
+
input_phone_styles_default
|
|
6
|
+
} from "./chunk.HSLR5GY4.js";
|
|
4
7
|
import {
|
|
5
8
|
frenchFlagOption,
|
|
6
|
-
frenchFlagSelect,
|
|
7
9
|
frenchNumberPrefix,
|
|
8
10
|
phonePrefixOptions
|
|
9
11
|
} from "./chunk.ESYJVRG3.js";
|
|
@@ -15,9 +17,6 @@ import {
|
|
|
15
17
|
import {
|
|
16
18
|
getPhoneConfig
|
|
17
19
|
} from "./chunk.65HTBW2L.js";
|
|
18
|
-
import {
|
|
19
|
-
input_phone_styles_default
|
|
20
|
-
} from "./chunk.43EIYNTL.js";
|
|
21
20
|
import {
|
|
22
21
|
defaultValue
|
|
23
22
|
} from "./chunk.CMJ2SRTL.js";
|
|
@@ -136,22 +135,8 @@ var DSAInputPhone = class extends ShoelaceElement {
|
|
|
136
135
|
this.emit("dsa-input");
|
|
137
136
|
}
|
|
138
137
|
willUpdate(changedProperties) {
|
|
139
|
-
if (changedProperties.has("phonePrefix")
|
|
140
|
-
|
|
141
|
-
this.phonePrefix = changedProperties.get("phonePrefix");
|
|
142
|
-
}
|
|
143
|
-
if (this.phoneNumber.length === 0) {
|
|
144
|
-
this.value = "";
|
|
145
|
-
} else {
|
|
146
|
-
const placeholderLength = stripSpecialChars(this.placeholder).length;
|
|
147
|
-
this.value = `${this.phonePrefix}${this.phoneNumber.substring(
|
|
148
|
-
0,
|
|
149
|
-
placeholderLength
|
|
150
|
-
)}`;
|
|
151
|
-
}
|
|
152
|
-
}
|
|
153
|
-
if (changedProperties.has("value")) {
|
|
154
|
-
this.setPhoneFromValue(this.value);
|
|
138
|
+
if (changedProperties.has("phonePrefix") && !frenchNumberPrefix.includes(this.phonePrefix)) {
|
|
139
|
+
this.phonePrefix = changedProperties.get("phonePrefix");
|
|
155
140
|
}
|
|
156
141
|
}
|
|
157
142
|
setPhoneFromValue(value) {
|
|
@@ -164,22 +149,28 @@ var DSAInputPhone = class extends ShoelaceElement {
|
|
|
164
149
|
const number = value.replace(prefix, "").substring(0, placeholderLength);
|
|
165
150
|
this.phonePrefix = prefix;
|
|
166
151
|
this.phoneNumber = number;
|
|
167
|
-
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
updateValue() {
|
|
155
|
+
if (this.phoneNumber.length === 0) {
|
|
156
|
+
this.value = "";
|
|
157
|
+
} else {
|
|
158
|
+
const placeholderLength = stripSpecialChars(this.placeholder).length;
|
|
159
|
+
this.value = `${this.phonePrefix}${this.phoneNumber.substring(
|
|
160
|
+
0,
|
|
161
|
+
placeholderLength
|
|
162
|
+
)}`;
|
|
168
163
|
}
|
|
169
164
|
}
|
|
170
165
|
// Select handlers
|
|
171
166
|
handlePhonePrefixChange(event) {
|
|
167
|
+
event.stopPropagation();
|
|
172
168
|
const { target } = event;
|
|
173
169
|
if (target instanceof DSASelect) {
|
|
174
170
|
this.phonePrefix = target.value;
|
|
171
|
+
this.updateValue();
|
|
172
|
+
this.emit("dsa-change");
|
|
175
173
|
}
|
|
176
|
-
this.emit("dsa-change");
|
|
177
|
-
}
|
|
178
|
-
handlePhonePrefixKeydown(event) {
|
|
179
|
-
if (event.key === "Tab") {
|
|
180
|
-
this.phonePrefixEl.hide();
|
|
181
|
-
}
|
|
182
|
-
this.emit("dsa-change");
|
|
183
174
|
}
|
|
184
175
|
// Input Mask handlers
|
|
185
176
|
handleChange(event) {
|
|
@@ -187,8 +178,9 @@ var DSAInputPhone = class extends ShoelaceElement {
|
|
|
187
178
|
if (target instanceof HTMLInputElement) {
|
|
188
179
|
const strippedValue = stripSpecialChars(target.value);
|
|
189
180
|
this.phoneNumber = strippedValue;
|
|
181
|
+
this.updateValue();
|
|
182
|
+
this.emit("dsa-change");
|
|
190
183
|
}
|
|
191
|
-
this.emit("dsa-change");
|
|
192
184
|
}
|
|
193
185
|
handleKeyDown(event) {
|
|
194
186
|
const hasModifier = event.metaKey || event.ctrlKey || event.shiftKey || event.altKey;
|
|
@@ -244,6 +236,9 @@ var DSAInputPhone = class extends ShoelaceElement {
|
|
|
244
236
|
await this.updateComplete;
|
|
245
237
|
this.formControlController.updateValidity();
|
|
246
238
|
}
|
|
239
|
+
handlePhoneChange() {
|
|
240
|
+
this.updateValue();
|
|
241
|
+
}
|
|
247
242
|
/** Sets focus on the input. */
|
|
248
243
|
focus(options) {
|
|
249
244
|
this.inputEl.focus(options);
|
|
@@ -355,12 +350,10 @@ var DSAInputPhone = class extends ShoelaceElement {
|
|
|
355
350
|
hoist
|
|
356
351
|
.size=${this.size}
|
|
357
352
|
@dsa-change=${this.handlePhonePrefixChange}
|
|
358
|
-
@keydown=${this.handlePhonePrefixKeydown}
|
|
359
353
|
enterkeyhint="enter"
|
|
360
354
|
display-value
|
|
361
355
|
no-sync-width
|
|
362
356
|
>
|
|
363
|
-
${frenchFlagSelect}
|
|
364
357
|
${phonePrefixOptions.map((option, index) => {
|
|
365
358
|
return html`
|
|
366
359
|
<dsa-option value=${option.value} .size=${this.size}>
|
|
@@ -558,6 +551,10 @@ __decorateClass([
|
|
|
558
551
|
__decorateClass([
|
|
559
552
|
watch("value", { waitUntilFirstUpdate: true })
|
|
560
553
|
], DSAInputPhone.prototype, "handleValueChange", 1);
|
|
554
|
+
__decorateClass([
|
|
555
|
+
watch("phonePrefix"),
|
|
556
|
+
watch("phoneNumber")
|
|
557
|
+
], DSAInputPhone.prototype, "handlePhoneChange", 1);
|
|
561
558
|
DSAInputPhone = __decorateClass([
|
|
562
559
|
customElement("dsa-input-phone")
|
|
563
560
|
], DSAInputPhone);
|
|
@@ -22,8 +22,30 @@ var radio_button_styles_default = css`
|
|
|
22
22
|
border-color: var(--dsa-wc-toggle-button-border-color);
|
|
23
23
|
color: var(--dsa-wc-toggle-button-color);
|
|
24
24
|
border-width: 1px;
|
|
25
|
-
|
|
25
|
+
border-style: solid;
|
|
26
26
|
font-weight: 400;
|
|
27
|
+
height: auto;
|
|
28
|
+
white-space: normal;
|
|
29
|
+
text-align: left;
|
|
30
|
+
line-height: 130%;
|
|
31
|
+
}
|
|
32
|
+
.button--toggle.button--small {
|
|
33
|
+
min-height: var(--dsa-wc-form-input-height-small);
|
|
34
|
+
}
|
|
35
|
+
.button--toggle.button--medium {
|
|
36
|
+
min-height: var(--dsa-wc-form-input-height);
|
|
37
|
+
}
|
|
38
|
+
.button--toggle.button--large {
|
|
39
|
+
min-height: var(--dsa-wc-form-input-height-large);
|
|
40
|
+
}
|
|
41
|
+
.button--toggle.button--small .button__label {
|
|
42
|
+
padding-block: 4px;
|
|
43
|
+
}
|
|
44
|
+
.button--toggle.button--medium .button__label {
|
|
45
|
+
padding-block: 8px;
|
|
46
|
+
}
|
|
47
|
+
.button--toggle.button--large .button__label {
|
|
48
|
+
padding-block: 10px;
|
|
27
49
|
}
|
|
28
50
|
|
|
29
51
|
.button--toggle:hover {
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
DSATreeItem
|
|
3
|
-
} from "./chunk.BROIFXIH.js";
|
|
4
1
|
import {
|
|
5
2
|
tree_styles_default
|
|
6
3
|
} from "./chunk.73T7TU6S.js";
|
|
4
|
+
import {
|
|
5
|
+
DSATreeItem
|
|
6
|
+
} from "./chunk.3355NB7L.js";
|
|
7
7
|
import {
|
|
8
8
|
LocalizeController
|
|
9
|
-
} from "./chunk.
|
|
9
|
+
} from "./chunk.DZLCCB5R.js";
|
|
10
10
|
import {
|
|
11
11
|
watch
|
|
12
12
|
} from "./chunk.6IH66JBY.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
accordion_styles_default
|
|
3
|
-
} from "./chunk.
|
|
3
|
+
} from "./chunk.KOTPR264.js";
|
|
4
4
|
import {
|
|
5
5
|
waitForEvent
|
|
6
6
|
} from "./chunk.B4BZKR24.js";
|
|
@@ -15,7 +15,7 @@ import {
|
|
|
15
15
|
} from "./chunk.V7RJROLH.js";
|
|
16
16
|
import {
|
|
17
17
|
LocalizeController
|
|
18
|
-
} from "./chunk.
|
|
18
|
+
} from "./chunk.DZLCCB5R.js";
|
|
19
19
|
import {
|
|
20
20
|
watch
|
|
21
21
|
} from "./chunk.6IH66JBY.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
popup_styles_default
|
|
3
|
-
} from "./chunk.
|
|
3
|
+
} from "./chunk.WYUQG5BJ.js";
|
|
4
4
|
import {
|
|
5
5
|
ShoelaceElement
|
|
6
6
|
} from "./chunk.YCXTCVAZ.js";
|
|
@@ -43,6 +43,83 @@ var DSAPopup = class extends ShoelaceElement {
|
|
|
43
43
|
this.shift = false;
|
|
44
44
|
this.shiftPadding = 0;
|
|
45
45
|
this.autoSizePadding = 0;
|
|
46
|
+
this.hoverBridge = false;
|
|
47
|
+
this.updateHoverBridge = () => {
|
|
48
|
+
if (this.hoverBridge && this.anchorEl) {
|
|
49
|
+
const anchorRect = this.anchorEl.getBoundingClientRect();
|
|
50
|
+
const popupRect = this.popup.getBoundingClientRect();
|
|
51
|
+
const isVertical = this.placement.includes("top") || this.placement.includes("bottom");
|
|
52
|
+
let topLeftX = 0;
|
|
53
|
+
let topLeftY = 0;
|
|
54
|
+
let topRightX = 0;
|
|
55
|
+
let topRightY = 0;
|
|
56
|
+
let bottomLeftX = 0;
|
|
57
|
+
let bottomLeftY = 0;
|
|
58
|
+
let bottomRightX = 0;
|
|
59
|
+
let bottomRightY = 0;
|
|
60
|
+
if (isVertical) {
|
|
61
|
+
if (anchorRect.top < popupRect.top) {
|
|
62
|
+
topLeftX = anchorRect.left;
|
|
63
|
+
topLeftY = anchorRect.bottom;
|
|
64
|
+
topRightX = anchorRect.right;
|
|
65
|
+
topRightY = anchorRect.bottom;
|
|
66
|
+
bottomLeftX = popupRect.left;
|
|
67
|
+
bottomLeftY = popupRect.top;
|
|
68
|
+
bottomRightX = popupRect.right;
|
|
69
|
+
bottomRightY = popupRect.top;
|
|
70
|
+
} else {
|
|
71
|
+
topLeftX = popupRect.left;
|
|
72
|
+
topLeftY = popupRect.bottom;
|
|
73
|
+
topRightX = popupRect.right;
|
|
74
|
+
topRightY = popupRect.bottom;
|
|
75
|
+
bottomLeftX = anchorRect.left;
|
|
76
|
+
bottomLeftY = anchorRect.top;
|
|
77
|
+
bottomRightX = anchorRect.right;
|
|
78
|
+
bottomRightY = anchorRect.top;
|
|
79
|
+
}
|
|
80
|
+
} else {
|
|
81
|
+
if (anchorRect.left < popupRect.left) {
|
|
82
|
+
topLeftX = anchorRect.right;
|
|
83
|
+
topLeftY = anchorRect.top;
|
|
84
|
+
topRightX = popupRect.left;
|
|
85
|
+
topRightY = popupRect.top;
|
|
86
|
+
bottomLeftX = anchorRect.right;
|
|
87
|
+
bottomLeftY = anchorRect.bottom;
|
|
88
|
+
bottomRightX = popupRect.left;
|
|
89
|
+
bottomRightY = popupRect.bottom;
|
|
90
|
+
} else {
|
|
91
|
+
topLeftX = popupRect.right;
|
|
92
|
+
topLeftY = popupRect.top;
|
|
93
|
+
topRightX = anchorRect.left;
|
|
94
|
+
topRightY = anchorRect.top;
|
|
95
|
+
bottomLeftX = popupRect.right;
|
|
96
|
+
bottomLeftY = popupRect.bottom;
|
|
97
|
+
bottomRightX = anchorRect.left;
|
|
98
|
+
bottomRightY = anchorRect.bottom;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
this.style.setProperty("--hover-bridge-top-left-x", `${topLeftX}px`);
|
|
102
|
+
this.style.setProperty("--hover-bridge-top-left-y", `${topLeftY}px`);
|
|
103
|
+
this.style.setProperty("--hover-bridge-top-right-x", `${topRightX}px`);
|
|
104
|
+
this.style.setProperty("--hover-bridge-top-right-y", `${topRightY}px`);
|
|
105
|
+
this.style.setProperty(
|
|
106
|
+
"--hover-bridge-bottom-left-x",
|
|
107
|
+
`${bottomLeftX}px`
|
|
108
|
+
);
|
|
109
|
+
this.style.setProperty(
|
|
110
|
+
"--hover-bridge-bottom-left-y",
|
|
111
|
+
`${bottomLeftY}px`
|
|
112
|
+
);
|
|
113
|
+
this.style.setProperty(
|
|
114
|
+
"--hover-bridge-bottom-right-x",
|
|
115
|
+
`${bottomRightX}px`
|
|
116
|
+
);
|
|
117
|
+
this.style.setProperty(
|
|
118
|
+
"--hover-bridge-bottom-right-y",
|
|
119
|
+
`${bottomRightY}px`
|
|
120
|
+
);
|
|
121
|
+
}
|
|
122
|
+
};
|
|
46
123
|
}
|
|
47
124
|
async connectedCallback() {
|
|
48
125
|
super.connectedCallback();
|
|
@@ -247,12 +324,21 @@ var DSAPopup = class extends ShoelaceElement {
|
|
|
247
324
|
});
|
|
248
325
|
}
|
|
249
326
|
});
|
|
327
|
+
requestAnimationFrame(() => this.updateHoverBridge());
|
|
250
328
|
this.emit("dsa-reposition");
|
|
251
329
|
}
|
|
252
330
|
render() {
|
|
253
331
|
return html`
|
|
254
332
|
<slot name="anchor" @slotchange=${this.handleAnchorChange}></slot>
|
|
255
333
|
|
|
334
|
+
<span
|
|
335
|
+
part="hover-bridge"
|
|
336
|
+
class=${classMap({
|
|
337
|
+
"popup-hover-bridge": true,
|
|
338
|
+
"popup-hover-bridge--visible": this.hoverBridge && this.active
|
|
339
|
+
})}
|
|
340
|
+
></span>
|
|
341
|
+
|
|
256
342
|
<div
|
|
257
343
|
part="popup"
|
|
258
344
|
class=${classMap({
|
|
@@ -352,6 +438,9 @@ __decorateClass([
|
|
|
352
438
|
__decorateClass([
|
|
353
439
|
property({ attribute: "auto-size-padding", type: Number })
|
|
354
440
|
], DSAPopup.prototype, "autoSizePadding", 2);
|
|
441
|
+
__decorateClass([
|
|
442
|
+
property({ attribute: "hover-bridge", type: Boolean })
|
|
443
|
+
], DSAPopup.prototype, "hoverBridge", 2);
|
|
355
444
|
DSAPopup = __decorateClass([
|
|
356
445
|
customElement("dsa-popup")
|
|
357
446
|
], DSAPopup);
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import {
|
|
2
|
-
footer_styles_default
|
|
3
|
-
} from "./chunk.QDZIXDQB.js";
|
|
4
1
|
import {
|
|
5
2
|
footerLogoSvg
|
|
6
3
|
} from "./chunk.6EHBM4N7.js";
|
|
4
|
+
import {
|
|
5
|
+
footer_styles_default
|
|
6
|
+
} from "./chunk.QDZIXDQB.js";
|
|
7
7
|
import {
|
|
8
8
|
HasSlotController
|
|
9
9
|
} from "./chunk.YIY5RM53.js";
|
|
10
10
|
import {
|
|
11
11
|
LocalizeController
|
|
12
|
-
} from "./chunk.
|
|
12
|
+
} from "./chunk.DZLCCB5R.js";
|
|
13
13
|
import {
|
|
14
14
|
ShoelaceElement
|
|
15
15
|
} from "./chunk.YCXTCVAZ.js";
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk.YOLAIUYX.js";
|
|
4
4
|
import {
|
|
5
5
|
DSAOption
|
|
6
|
-
} from "./chunk.
|
|
6
|
+
} from "./chunk.V3EGD3LC.js";
|
|
7
7
|
import {
|
|
8
8
|
scrollIntoView
|
|
9
9
|
} from "./chunk.EMIT7S33.js";
|
|
@@ -23,7 +23,7 @@ import {
|
|
|
23
23
|
} from "./chunk.V7RJROLH.js";
|
|
24
24
|
import {
|
|
25
25
|
LocalizeController
|
|
26
|
-
} from "./chunk.
|
|
26
|
+
} from "./chunk.DZLCCB5R.js";
|
|
27
27
|
import {
|
|
28
28
|
watch
|
|
29
29
|
} from "./chunk.6IH66JBY.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
checkbox_button_styles_default
|
|
3
|
-
} from "./chunk.
|
|
3
|
+
} from "./chunk.RSX6EFCX.js";
|
|
4
4
|
import {
|
|
5
5
|
HasSlotController
|
|
6
6
|
} from "./chunk.YIY5RM53.js";
|
|
@@ -135,7 +135,7 @@ __decorateClass([
|
|
|
135
135
|
property({ type: Boolean, reflect: true })
|
|
136
136
|
], DSACheckboxButton.prototype, "checked", 2);
|
|
137
137
|
__decorateClass([
|
|
138
|
-
property()
|
|
138
|
+
property({ reflect: true })
|
|
139
139
|
], DSACheckboxButton.prototype, "value", 2);
|
|
140
140
|
__decorateClass([
|
|
141
141
|
property({ type: Boolean, reflect: true })
|
|
@@ -144,10 +144,10 @@ __decorateClass([
|
|
|
144
144
|
property({ reflect: true })
|
|
145
145
|
], DSACheckboxButton.prototype, "size", 2);
|
|
146
146
|
__decorateClass([
|
|
147
|
-
property({ type: Boolean })
|
|
147
|
+
property({ type: Boolean, reflect: true })
|
|
148
148
|
], DSACheckboxButton.prototype, "readonly", 2);
|
|
149
149
|
__decorateClass([
|
|
150
|
-
property({ type: Boolean })
|
|
150
|
+
property({ type: Boolean, reflect: true })
|
|
151
151
|
], DSACheckboxButton.prototype, "error", 2);
|
|
152
152
|
__decorateClass([
|
|
153
153
|
watch("disabled", { waitUntilFirstUpdate: true })
|
|
@@ -17,13 +17,6 @@ var translation = {
|
|
|
17
17
|
hidePassword: "Masquer le mot de passe",
|
|
18
18
|
loading: "Chargement",
|
|
19
19
|
nextSlide: "Diapositive suivante",
|
|
20
|
-
numOptionsSelected: (num) => {
|
|
21
|
-
if (num === 0)
|
|
22
|
-
return "Aucune option s\xE9lectionn\xE9e";
|
|
23
|
-
if (num === 1)
|
|
24
|
-
return "1 option s\xE9lectionn\xE9e";
|
|
25
|
-
return `${num} options s\xE9lectionn\xE9es`;
|
|
26
|
-
},
|
|
27
20
|
previousSlide: "Diapositive pr\xE9c\xE9dente",
|
|
28
21
|
progress: "Progr\xE8s",
|
|
29
22
|
remove: "Retirer",
|
|
@@ -137,13 +130,6 @@ var translation2 = {
|
|
|
137
130
|
hidePassword: "Hide password",
|
|
138
131
|
loading: "Loading",
|
|
139
132
|
nextSlide: "Next slide",
|
|
140
|
-
numOptionsSelected: (num) => {
|
|
141
|
-
if (num === 0)
|
|
142
|
-
return "No options selected";
|
|
143
|
-
if (num === 1)
|
|
144
|
-
return "1 option selected";
|
|
145
|
-
return `${num} options selected`;
|
|
146
|
-
},
|
|
147
133
|
previousSlide: "Previous slide",
|
|
148
134
|
progress: "Progress",
|
|
149
135
|
remove: "Remove",
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import {
|
|
2
|
+
component_styles_default
|
|
3
|
+
} from "./chunk.TUVJKY7S.js";
|
|
4
|
+
|
|
5
|
+
// src/components/callout/callout.styles.ts
|
|
6
|
+
import { css } from "lit";
|
|
7
|
+
var callout_styles_default = css`
|
|
8
|
+
${component_styles_default}
|
|
9
|
+
|
|
10
|
+
:host {
|
|
11
|
+
display: contents;
|
|
12
|
+
|
|
13
|
+
/* For better DX, we'll reset the margin here so the base part can inherit it */
|
|
14
|
+
margin: 0;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.callout {
|
|
18
|
+
position: relative;
|
|
19
|
+
display: flex;
|
|
20
|
+
align-items: stretch;
|
|
21
|
+
border-left: var(--dsa-wc-callout-border-left);
|
|
22
|
+
border-radius: var(--dsa-wc-callout-border-radius);
|
|
23
|
+
font: var(--dsa-wc-callout-message-font);
|
|
24
|
+
color: var(--dsa-wc-callout-message-color);
|
|
25
|
+
padding: var(--dsa-wc-callout-padding);
|
|
26
|
+
margin: inherit;
|
|
27
|
+
background-color: var(--dsa-wc-callout-default-background-color);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.callout__title {
|
|
31
|
+
font: var(--dsa-wc-callout-title-font);
|
|
32
|
+
word-wrap: break-word;
|
|
33
|
+
color: var(--dsa-wc-callout-title-color);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
.callout__message {
|
|
37
|
+
word-wrap: break-word;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.callout__text {
|
|
41
|
+
display: flex;
|
|
42
|
+
flex-direction: column;
|
|
43
|
+
gap: var(--dsa-wc-callout-text-gap);
|
|
44
|
+
}
|
|
45
|
+
`;
|
|
46
|
+
|
|
47
|
+
export {
|
|
48
|
+
callout_styles_default
|
|
49
|
+
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
radio_button_styles_default
|
|
3
|
-
} from "./chunk.KKAOTWJY.js";
|
|
4
1
|
import {
|
|
5
2
|
DSARadioGroup
|
|
6
3
|
} from "./chunk.CW4ML3IS.js";
|
|
4
|
+
import {
|
|
5
|
+
radio_button_styles_default
|
|
6
|
+
} from "./chunk.ATFH7NZ3.js";
|
|
7
7
|
import {
|
|
8
8
|
HasSlotController
|
|
9
9
|
} from "./chunk.YIY5RM53.js";
|
|
@@ -213,6 +213,7 @@ var input_phone_styles_default = css`
|
|
|
213
213
|
|
|
214
214
|
/* Select */
|
|
215
215
|
.input-phone__select {
|
|
216
|
+
flex-shrink: 0;
|
|
216
217
|
min-width: var(--input-phone__select__min-width);
|
|
217
218
|
}
|
|
218
219
|
|
|
@@ -221,12 +222,17 @@ var input_phone_styles_default = css`
|
|
|
221
222
|
border-right: none;
|
|
222
223
|
height: auto;
|
|
223
224
|
font-size: inherit;
|
|
225
|
+
padding: 4px 4px 4px 8px;
|
|
224
226
|
}
|
|
225
227
|
|
|
226
228
|
.input-phone__select::part(popup) {
|
|
227
229
|
display: unset;
|
|
228
230
|
}
|
|
229
231
|
|
|
232
|
+
.input-phone__select::part(display-input) {
|
|
233
|
+
text-align: center;
|
|
234
|
+
}
|
|
235
|
+
|
|
230
236
|
:not(.form-control--readonly):not(form-control--disabled)
|
|
231
237
|
> dsa-select:not(.input-phone__select-error) {
|
|
232
238
|
--dsa-wc-internal-select-on-base-active-background-color: var(
|
|
@@ -304,7 +310,7 @@ var input_phone_styles_default = css`
|
|
|
304
310
|
* Size modifiers
|
|
305
311
|
*/
|
|
306
312
|
.form-control--small {
|
|
307
|
-
--input-phone__select__min-width:
|
|
313
|
+
--input-phone__select__min-width: 54px;
|
|
308
314
|
}
|
|
309
315
|
.form-control--small .input-phone__input,
|
|
310
316
|
.form-control--small dsa-select::part(combobox) {
|
|
@@ -319,7 +325,7 @@ var input_phone_styles_default = css`
|
|
|
319
325
|
}
|
|
320
326
|
|
|
321
327
|
.form-control--medium {
|
|
322
|
-
--input-phone__select__min-width:
|
|
328
|
+
--input-phone__select__min-width: 68px;
|
|
323
329
|
}
|
|
324
330
|
.form-control--medium dsa-select::part(combobox) {
|
|
325
331
|
height: var(--dsa-wc-input-phone-height);
|
|
@@ -331,7 +337,7 @@ var input_phone_styles_default = css`
|
|
|
331
337
|
}
|
|
332
338
|
|
|
333
339
|
.form-control--large {
|
|
334
|
-
--input-phone__select__min-width:
|
|
340
|
+
--input-phone__select__min-width: 68px;
|
|
335
341
|
}
|
|
336
342
|
.form-control--large
|
|
337
343
|
.input-phone___input.form-control--large
|