origam 2.43.0 → 2.44.1
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 +116 -0
- package/dist/src/assets/css/main.css +1 -1
- package/dist/src/assets/css/tokens/dark-pinned.css +5 -1
- package/dist/src/assets/css/tokens/dark-system.css +5 -1
- package/dist/src/assets/css/tokens/dark.css +10 -2
- package/dist/src/assets/css/tokens/light.css +5 -1
- package/dist/src/assets/locales/en.json +3 -0
- package/dist/src/assets/locales/fr.json +3 -0
- package/dist/src/assets/scss/tokens/_dark.scss +10 -2
- package/dist/src/assets/scss/tokens/_light.scss +5 -1
- package/dist/src/components/Audio/OrigamAudio.vue +1 -1
- package/dist/src/components/Btn/OrigamBtn.vue +31 -10
- package/dist/src/components/Chart/OrigamChartRadar.vue +1 -1
- package/dist/src/components/ColorPickerField/OrigamColorPickerField.vue +3 -5
- package/dist/src/components/ConfirmWrapper/OrigamConfirmWrapper.vue +0 -1
- package/dist/src/components/DataTable/OrigamDataTableFooter.vue +3 -1
- package/dist/src/components/DataTable/OrigamDataTableHeaderCell.vue +20 -2
- package/dist/src/components/DatePicker/OrigamDatePickerControls.vue +1 -1
- package/dist/src/components/DatePickerField/OrigamDatePickerField.vue +3 -5
- package/dist/src/components/Drawer/OrigamDrawer.vue +65 -3
- package/dist/src/components/ExpansionPanel/OrigamExpansionPanel.vue +6 -4
- package/dist/src/components/ExpansionPanel/OrigamExpansionPanelContent.vue +1 -1
- package/dist/src/components/ExpansionPanel/OrigamExpansionPanelHeader.vue +1 -1
- package/dist/src/components/Field/OrigamField.vue +17 -7
- package/dist/src/components/FileField/OrigamFileField.vue +3 -3
- package/dist/src/components/Form/OrigamForm.vue +0 -1
- package/dist/src/components/Input/OrigamInput.vue +0 -1
- package/dist/src/components/List/OrigamListChildren.vue +1 -1
- package/dist/src/components/Messages/OrigamMessages.vue +1 -1
- package/dist/src/components/NumberField/OrigamNumberField.vue +13 -5
- package/dist/src/components/OtpInputField/OrigamOtpInputField.vue +8 -5
- package/dist/src/components/PasswordField/OrigamPasswordField.vue +3 -3
- package/dist/src/components/Select/OrigamSelect.vue +22 -5
- package/dist/src/components/Stepper/OrigamStepper.vue +22 -1
- package/dist/src/components/Stepper/OrigamStepperItem.vue +46 -21
- package/dist/src/components/TextField/OrigamTextField.vue +3 -3
- package/dist/src/components/TextareaField/OrigamTextareaField.vue +3 -3
- package/dist/src/components/Toolbar/OrigamToolbar.vue +1 -1
- package/dist/src/components/Video/OrigamVideo.vue +1 -1
- package/dist/src/composables/Commons/adjacentInner.composable.cjs +17 -3
- package/dist/src/composables/Commons/adjacentInner.composable.d.ts +5 -3
- package/dist/src/composables/Commons/adjacentInner.composable.js +18 -4
- package/dist/src/composables/Commons/link.composable.cjs +6 -5
- package/dist/src/composables/Commons/link.composable.js +6 -5
- package/dist/src/composables/Commons/popup-dialog-aria.composable.cjs +26 -0
- package/dist/src/composables/Commons/popup-dialog-aria.composable.d.ts +23 -0
- package/dist/src/composables/Commons/popup-dialog-aria.composable.js +17 -0
- package/dist/src/composables/Commons/stack.composable.cjs +2 -19
- package/dist/src/composables/Commons/stack.composable.d.ts +1 -1
- package/dist/src/composables/Commons/stack.composable.js +3 -20
- package/dist/src/composables/Commons/style.composable.cjs +3 -2
- package/dist/src/composables/Commons/style.composable.js +3 -2
- package/dist/src/composables/index.cjs +12 -0
- package/dist/src/composables/index.d.ts +1 -0
- package/dist/src/composables/index.js +1 -0
- package/dist/src/consts/Commons/style.const.cjs +9 -0
- package/dist/src/consts/Commons/style.const.d.ts +26 -0
- package/dist/src/consts/Commons/style.const.js +3 -0
- package/dist/src/consts/index.cjs +11 -0
- package/dist/src/consts/index.d.ts +1 -0
- package/dist/src/consts/index.js +1 -0
- package/dist/src/directives/Contrast/contrast.directive.cjs +5 -1
- package/dist/src/directives/Contrast/contrast.directive.js +5 -1
- package/dist/src/interfaces/ExpansionPanel/expansion-panel.interface.d.ts +1 -0
- package/dist/src/interfaces/Stepper/stepper-item.interface.d.ts +11 -2
- package/dist/src/interfaces/Stepper/stepper.interface.d.ts +7 -0
- package/dist/src/themes/origam.theme.cjs +0 -2
- package/dist/src/themes/origam.theme.js +2 -2
- package/dist/src/types/tokens.type.d.ts +1 -1
- package/dist/src/utils/Commons/style.util.cjs +30 -0
- package/dist/src/utils/Commons/style.util.d.ts +18 -0
- package/dist/src/utils/Commons/style.util.js +23 -0
- package/dist/src/utils/index.cjs +11 -0
- package/dist/src/utils/index.d.ts +1 -0
- package/dist/src/utils/index.js +1 -0
- package/package.json +1 -1
|
@@ -329,7 +329,6 @@
|
|
|
329
329
|
--origam-btn---text-decoration: none;
|
|
330
330
|
--origam-btn---text-indent: var(--origam-font__letterSpacing---widest);
|
|
331
331
|
--origam-btn---opacity: 1;
|
|
332
|
-
--origam-btn---opacity-disabled: var(--origam-opacity---50);
|
|
333
332
|
--origam-btn---opacity-plain: var(--origam-opacity---70);
|
|
334
333
|
--origam-btn---overlay-opacity-hover: var(--origam-opacity---12);
|
|
335
334
|
--origam-btn---overlay-opacity-active: 0.2;
|
|
@@ -2576,6 +2575,11 @@
|
|
|
2576
2575
|
--origam-stepper---connector-color: var(--origam-color__border---subtle);
|
|
2577
2576
|
--origam-stepper---connector-color-done: var(--origam-color__action--primary---bg);
|
|
2578
2577
|
--origam-stepper---connector-thickness: var(--origam-border__width---thin);
|
|
2578
|
+
--origam-stepper---color-active: var(--origam-stepper---color);
|
|
2579
|
+
--origam-stepper---color-done: var(--origam-stepper---color);
|
|
2580
|
+
--origam-stepper-item__title---white-space: nowrap;
|
|
2581
|
+
--origam-stepper-item__subtitle---white-space: nowrap;
|
|
2582
|
+
--origam-stepper-item--vertical__subtitle---white-space: normal;
|
|
2579
2583
|
--origam-timeline---background-color: var(--origam-color__surface---default);
|
|
2580
2584
|
--origam-timeline---color: var(--origam-color__text---primary);
|
|
2581
2585
|
--origam-timeline---gap: var(--origam-space---4);
|
|
@@ -153,7 +153,6 @@
|
|
|
153
153
|
--origam-btn---text-decoration: none;
|
|
154
154
|
--origam-btn---text-indent: var(--origam-font__letterSpacing---widest);
|
|
155
155
|
--origam-btn---opacity: 1;
|
|
156
|
-
--origam-btn---opacity-disabled: var(--origam-opacity---50);
|
|
157
156
|
--origam-btn---opacity-plain: var(--origam-opacity---70);
|
|
158
157
|
--origam-btn---overlay-opacity-hover: var(--origam-opacity---12);
|
|
159
158
|
--origam-btn---overlay-opacity-active: 0.2;
|
|
@@ -2399,6 +2398,11 @@
|
|
|
2399
2398
|
--origam-stepper---connector-color: var(--origam-color__border---subtle);
|
|
2400
2399
|
--origam-stepper---connector-color-done: var(--origam-color__action--primary---bg);
|
|
2401
2400
|
--origam-stepper---connector-thickness: var(--origam-border__width---thin);
|
|
2401
|
+
--origam-stepper---color-active: var(--origam-stepper---color);
|
|
2402
|
+
--origam-stepper---color-done: var(--origam-stepper---color);
|
|
2403
|
+
--origam-stepper-item__title---white-space: nowrap;
|
|
2404
|
+
--origam-stepper-item__subtitle---white-space: nowrap;
|
|
2405
|
+
--origam-stepper-item--vertical__subtitle---white-space: normal;
|
|
2402
2406
|
--origam-timeline---background-color: var(--origam-color__surface---default);
|
|
2403
2407
|
--origam-timeline---color: var(--origam-color__text---primary);
|
|
2404
2408
|
--origam-timeline---gap: var(--origam-space---4);
|
|
@@ -329,7 +329,6 @@
|
|
|
329
329
|
--origam-btn---text-decoration: none;
|
|
330
330
|
--origam-btn---text-indent: var(--origam-font__letterSpacing---widest);
|
|
331
331
|
--origam-btn---opacity: 1;
|
|
332
|
-
--origam-btn---opacity-disabled: var(--origam-opacity---50);
|
|
333
332
|
--origam-btn---opacity-plain: var(--origam-opacity---70);
|
|
334
333
|
--origam-btn---overlay-opacity-hover: var(--origam-opacity---12);
|
|
335
334
|
--origam-btn---overlay-opacity-active: 0.2;
|
|
@@ -2576,6 +2575,11 @@
|
|
|
2576
2575
|
--origam-stepper---connector-color: var(--origam-color__border---subtle);
|
|
2577
2576
|
--origam-stepper---connector-color-done: var(--origam-color__action--primary---bg);
|
|
2578
2577
|
--origam-stepper---connector-thickness: var(--origam-border__width---thin);
|
|
2578
|
+
--origam-stepper---color-active: var(--origam-stepper---color);
|
|
2579
|
+
--origam-stepper---color-done: var(--origam-stepper---color);
|
|
2580
|
+
--origam-stepper-item__title---white-space: nowrap;
|
|
2581
|
+
--origam-stepper-item__subtitle---white-space: nowrap;
|
|
2582
|
+
--origam-stepper-item--vertical__subtitle---white-space: normal;
|
|
2579
2583
|
--origam-timeline---background-color: var(--origam-color__surface---default);
|
|
2580
2584
|
--origam-timeline---color: var(--origam-color__text---primary);
|
|
2581
2585
|
--origam-timeline---gap: var(--origam-space---4);
|
|
@@ -3382,7 +3386,6 @@
|
|
|
3382
3386
|
--origam-btn---text-decoration: none;
|
|
3383
3387
|
--origam-btn---text-indent: var(--origam-font__letterSpacing---widest);
|
|
3384
3388
|
--origam-btn---opacity: 1;
|
|
3385
|
-
--origam-btn---opacity-disabled: var(--origam-opacity---50);
|
|
3386
3389
|
--origam-btn---opacity-plain: var(--origam-opacity---70);
|
|
3387
3390
|
--origam-btn---overlay-opacity-hover: var(--origam-opacity---12);
|
|
3388
3391
|
--origam-btn---overlay-opacity-active: 0.2;
|
|
@@ -5628,6 +5631,11 @@
|
|
|
5628
5631
|
--origam-stepper---connector-color: var(--origam-color__border---subtle);
|
|
5629
5632
|
--origam-stepper---connector-color-done: var(--origam-color__action--primary---bg);
|
|
5630
5633
|
--origam-stepper---connector-thickness: var(--origam-border__width---thin);
|
|
5634
|
+
--origam-stepper---color-active: var(--origam-stepper---color);
|
|
5635
|
+
--origam-stepper---color-done: var(--origam-stepper---color);
|
|
5636
|
+
--origam-stepper-item__title---white-space: nowrap;
|
|
5637
|
+
--origam-stepper-item__subtitle---white-space: nowrap;
|
|
5638
|
+
--origam-stepper-item--vertical__subtitle---white-space: normal;
|
|
5631
5639
|
--origam-timeline---background-color: var(--origam-color__surface---default);
|
|
5632
5640
|
--origam-timeline---color: var(--origam-color__text---primary);
|
|
5633
5641
|
--origam-timeline---gap: var(--origam-space---4);
|
|
@@ -229,7 +229,6 @@
|
|
|
229
229
|
--origam-btn---text-decoration: none;
|
|
230
230
|
--origam-btn---text-indent: var(--origam-font__letterSpacing---widest);
|
|
231
231
|
--origam-btn---opacity: 1;
|
|
232
|
-
--origam-btn---opacity-disabled: var(--origam-opacity---50);
|
|
233
232
|
--origam-btn---opacity-plain: var(--origam-opacity---70);
|
|
234
233
|
--origam-btn---overlay-opacity-hover: var(--origam-opacity---12);
|
|
235
234
|
--origam-btn---overlay-opacity-active: 0.2;
|
|
@@ -2490,6 +2489,11 @@
|
|
|
2490
2489
|
--origam-stepper---connector-color: var(--origam-color__border---subtle);
|
|
2491
2490
|
--origam-stepper---connector-color-done: var(--origam-color__action--primary---bg);
|
|
2492
2491
|
--origam-stepper---connector-thickness: var(--origam-border__width---thin);
|
|
2492
|
+
--origam-stepper---color-active: var(--origam-stepper---color);
|
|
2493
|
+
--origam-stepper---color-done: var(--origam-stepper---color);
|
|
2494
|
+
--origam-stepper-item__title---white-space: nowrap;
|
|
2495
|
+
--origam-stepper-item__subtitle---white-space: nowrap;
|
|
2496
|
+
--origam-stepper-item--vertical__subtitle---white-space: normal;
|
|
2493
2497
|
--origam-timeline---background-color: var(--origam-color__surface---default);
|
|
2494
2498
|
--origam-timeline---color: var(--origam-color__text---primary);
|
|
2495
2499
|
--origam-timeline---gap: var(--origam-space---4);
|
|
@@ -329,7 +329,6 @@
|
|
|
329
329
|
--origam-btn---text-decoration: none;
|
|
330
330
|
--origam-btn---text-indent: var(--origam-font__letterSpacing---widest);
|
|
331
331
|
--origam-btn---opacity: 1;
|
|
332
|
-
--origam-btn---opacity-disabled: var(--origam-opacity---50);
|
|
333
332
|
--origam-btn---opacity-plain: var(--origam-opacity---70);
|
|
334
333
|
--origam-btn---overlay-opacity-hover: var(--origam-opacity---12);
|
|
335
334
|
--origam-btn---overlay-opacity-active: 0.2;
|
|
@@ -2576,6 +2575,11 @@
|
|
|
2576
2575
|
--origam-stepper---connector-color: var(--origam-color__border---subtle);
|
|
2577
2576
|
--origam-stepper---connector-color-done: var(--origam-color__action--primary---bg);
|
|
2578
2577
|
--origam-stepper---connector-thickness: var(--origam-border__width---thin);
|
|
2578
|
+
--origam-stepper---color-active: var(--origam-stepper---color);
|
|
2579
|
+
--origam-stepper---color-done: var(--origam-stepper---color);
|
|
2580
|
+
--origam-stepper-item__title---white-space: nowrap;
|
|
2581
|
+
--origam-stepper-item__subtitle---white-space: nowrap;
|
|
2582
|
+
--origam-stepper-item--vertical__subtitle---white-space: normal;
|
|
2579
2583
|
--origam-timeline---background-color: var(--origam-color__surface---default);
|
|
2580
2584
|
--origam-timeline---color: var(--origam-color__text---primary);
|
|
2581
2585
|
--origam-timeline---gap: var(--origam-space---4);
|
|
@@ -3382,7 +3386,6 @@
|
|
|
3382
3386
|
--origam-btn---text-decoration: none;
|
|
3383
3387
|
--origam-btn---text-indent: var(--origam-font__letterSpacing---widest);
|
|
3384
3388
|
--origam-btn---opacity: 1;
|
|
3385
|
-
--origam-btn---opacity-disabled: var(--origam-opacity---50);
|
|
3386
3389
|
--origam-btn---opacity-plain: var(--origam-opacity---70);
|
|
3387
3390
|
--origam-btn---overlay-opacity-hover: var(--origam-opacity---12);
|
|
3388
3391
|
--origam-btn---overlay-opacity-active: 0.2;
|
|
@@ -5628,6 +5631,11 @@
|
|
|
5628
5631
|
--origam-stepper---connector-color: var(--origam-color__border---subtle);
|
|
5629
5632
|
--origam-stepper---connector-color-done: var(--origam-color__action--primary---bg);
|
|
5630
5633
|
--origam-stepper---connector-thickness: var(--origam-border__width---thin);
|
|
5634
|
+
--origam-stepper---color-active: var(--origam-stepper---color);
|
|
5635
|
+
--origam-stepper---color-done: var(--origam-stepper---color);
|
|
5636
|
+
--origam-stepper-item__title---white-space: nowrap;
|
|
5637
|
+
--origam-stepper-item__subtitle---white-space: nowrap;
|
|
5638
|
+
--origam-stepper-item--vertical__subtitle---white-space: normal;
|
|
5631
5639
|
--origam-timeline---background-color: var(--origam-color__surface---default);
|
|
5632
5640
|
--origam-timeline---color: var(--origam-color__text---primary);
|
|
5633
5641
|
--origam-timeline---gap: var(--origam-space---4);
|
|
@@ -229,7 +229,6 @@
|
|
|
229
229
|
--origam-btn---text-decoration: none;
|
|
230
230
|
--origam-btn---text-indent: var(--origam-font__letterSpacing---widest);
|
|
231
231
|
--origam-btn---opacity: 1;
|
|
232
|
-
--origam-btn---opacity-disabled: var(--origam-opacity---50);
|
|
233
232
|
--origam-btn---opacity-plain: var(--origam-opacity---70);
|
|
234
233
|
--origam-btn---overlay-opacity-hover: var(--origam-opacity---12);
|
|
235
234
|
--origam-btn---overlay-opacity-active: 0.2;
|
|
@@ -2490,6 +2489,11 @@
|
|
|
2490
2489
|
--origam-stepper---connector-color: var(--origam-color__border---subtle);
|
|
2491
2490
|
--origam-stepper---connector-color-done: var(--origam-color__action--primary---bg);
|
|
2492
2491
|
--origam-stepper---connector-thickness: var(--origam-border__width---thin);
|
|
2492
|
+
--origam-stepper---color-active: var(--origam-stepper---color);
|
|
2493
|
+
--origam-stepper---color-done: var(--origam-stepper---color);
|
|
2494
|
+
--origam-stepper-item__title---white-space: nowrap;
|
|
2495
|
+
--origam-stepper-item__subtitle---white-space: nowrap;
|
|
2496
|
+
--origam-stepper-item--vertical__subtitle---white-space: normal;
|
|
2493
2497
|
--origam-timeline---background-color: var(--origam-color__surface---default);
|
|
2494
2498
|
--origam-timeline---color: var(--origam-color__text---primary);
|
|
2495
2499
|
--origam-timeline---gap: var(--origam-space---4);
|
|
@@ -1618,7 +1618,7 @@ const { colorClasses, colorStyles } = useColorEffect(props);
|
|
|
1618
1618
|
* cablees a un comportement invente. Elles avertissent une fois, en
|
|
1619
1619
|
* dev, avec la raison exacte. Meme traitement que la famille Chart.
|
|
1620
1620
|
********************************************************/
|
|
1621
|
-
useUnsupportedProp("OrigamAudio", "waveformColor", "the waveform paints from `currentColor`; this prop reaches no declaration.", () => props.waveformColor !==
|
|
1621
|
+
useUnsupportedProp("OrigamAudio", "waveformColor", "the waveform paints from `currentColor`; this prop reaches no declaration.", () => props.waveformColor !== "currentColor");
|
|
1622
1622
|
const hasColorProp = computed(() => !!props.color);
|
|
1623
1623
|
const hasBgColorProp = computed(() => !!props.bgColor);
|
|
1624
1624
|
const scrubberColorStyle = computed(() => {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
:is="link.tag.value"
|
|
4
4
|
:id="id"
|
|
5
5
|
v-ripple="isRipple"
|
|
6
|
-
v-contrast
|
|
6
|
+
v-contrast="!isDisabled"
|
|
7
7
|
:data-origam-color-locked="colorLocked"
|
|
8
8
|
:class="btnClasses"
|
|
9
9
|
:disabled="isDisabled || undefined"
|
|
@@ -897,7 +897,13 @@ const isActive = computed(() => {
|
|
|
897
897
|
return group.isSelected.value;
|
|
898
898
|
}
|
|
899
899
|
if (link.isLink.value) {
|
|
900
|
-
|
|
900
|
+
/*********************************************************
|
|
901
|
+
* Link active (#1125)
|
|
902
|
+
*
|
|
903
|
+
* @description
|
|
904
|
+
* Exact match only: a parent route in the matched chain is not "the current page". An explicit `active` still wins (above).
|
|
905
|
+
********************************************************/
|
|
906
|
+
return link.isExactActive?.value;
|
|
901
907
|
}
|
|
902
908
|
return active.value;
|
|
903
909
|
});
|
|
@@ -972,7 +978,13 @@ const { hasAppend, hasPrepend } = useAdjacent(props, prependIcon, appendIcon);
|
|
|
972
978
|
* The capture listener runs first on the target, so it swallows all three.
|
|
973
979
|
********************************************************/
|
|
974
980
|
const handleClickCapture = (e) => {
|
|
975
|
-
|
|
981
|
+
/*********************************************************
|
|
982
|
+
* Disabled anchor (#1097)
|
|
983
|
+
*
|
|
984
|
+
* @description
|
|
985
|
+
* A disabled anchor is no longer shielded by `pointer-events: none`; a native disabled <button> never reaches here.
|
|
986
|
+
********************************************************/
|
|
987
|
+
if (!isLoading.value && !isDisabled.value) return;
|
|
976
988
|
e.preventDefault();
|
|
977
989
|
e.stopImmediatePropagation();
|
|
978
990
|
};
|
|
@@ -1085,7 +1097,7 @@ const btnStyles = computed(() => {
|
|
|
1085
1097
|
borderStyles.value,
|
|
1086
1098
|
paddingStyles.value,
|
|
1087
1099
|
marginStyles.value,
|
|
1088
|
-
colorStyles.value,
|
|
1100
|
+
isDisabled.value ? ["--origam-btn---background-color: var(--origam-btn---background-color-disabled)", "color: var(--origam-btn---color-disabled)"] : colorStyles.value,
|
|
1089
1101
|
dimensionStyles.value,
|
|
1090
1102
|
locationStyles.value,
|
|
1091
1103
|
roundedStyles.value,
|
|
@@ -1595,7 +1607,7 @@ defineExpose({
|
|
|
1595
1607
|
box-shadow: none;
|
|
1596
1608
|
opacity: var(--origam-btn---opacity-plain, var(--origam-opacity---70));
|
|
1597
1609
|
|
|
1598
|
-
&:hover,
|
|
1610
|
+
&:hover:not(#{$this}--disabled),
|
|
1599
1611
|
&:focus-visible {
|
|
1600
1612
|
opacity: 1;
|
|
1601
1613
|
}
|
|
@@ -1654,7 +1666,7 @@ defineExpose({
|
|
|
1654
1666
|
) !important;
|
|
1655
1667
|
}
|
|
1656
1668
|
|
|
1657
|
-
&:hover,
|
|
1669
|
+
&:hover:not(#{$this}--disabled),
|
|
1658
1670
|
&:focus-visible {
|
|
1659
1671
|
background-color: var(
|
|
1660
1672
|
--origam-btn---background-color-ghost-hover,
|
|
@@ -1680,12 +1692,21 @@ defineExpose({
|
|
|
1680
1692
|
--origam-btn---min-width: 100%;
|
|
1681
1693
|
}
|
|
1682
1694
|
|
|
1695
|
+
/*********************************************************
|
|
1696
|
+
* Disabled (#1097)
|
|
1697
|
+
*
|
|
1698
|
+
* @description
|
|
1699
|
+
* The root keeps its pointer events so `cursor: not-allowed` can show (`pointer-events: none` hands the cursor to the parent). A native `disabled` <button> fires no click, an anchor is stopped by `handleClickCapture`, and the hover surfaces are switched off here and on the `plain` / `ghost` hover rules (`:not(--disabled)`).
|
|
1700
|
+
*
|
|
1701
|
+
* @description
|
|
1702
|
+
* No opacity veil: the grey tokens carry the state (owner decision). `opacity: 1` is written directly because `plain` sets its own `opacity` (70 %). `--origam-btn---opacity-disabled` is therefore no longer read.
|
|
1703
|
+
********************************************************/
|
|
1683
1704
|
&--disabled {
|
|
1684
|
-
|
|
1685
|
-
|
|
1705
|
+
cursor: not-allowed;
|
|
1706
|
+
opacity: 1;
|
|
1686
1707
|
|
|
1687
|
-
|
|
1688
|
-
--origam-
|
|
1708
|
+
> #{$this}__overlay {
|
|
1709
|
+
--origam-btn__overlay---opacity: 0;
|
|
1689
1710
|
}
|
|
1690
1711
|
}
|
|
1691
1712
|
|
|
@@ -570,7 +570,7 @@ const { headerTypographyStyles } = useChartHeaderTypography(props);
|
|
|
570
570
|
* comportement fictif : elles avertissent une fois, en dev, avec la
|
|
571
571
|
* raison exacte. Meme traitement que `OrigamChartGauge`.
|
|
572
572
|
********************************************************/
|
|
573
|
-
useUnsupportedProp("OrigamChartRadar", "showTooltip", "no tooltip component is rendered by the radar — `ChartTooltip` appears nowhere in its template.", () => props.showTooltip
|
|
573
|
+
useUnsupportedProp("OrigamChartRadar", "showTooltip", "no tooltip component is rendered by the radar — `ChartTooltip` appears nowhere in its template.", () => props.showTooltip === true);
|
|
574
574
|
const chartAnimationStyle = useChartAnimationStyle(props);
|
|
575
575
|
const { resizeRef: svgRef, width: svgWidth, height: svgHeight } = useChartSize(CHART_SIZE_FALLBACK.radar, { aspectRatio: CHART_ASPECT_RATIO.radial });
|
|
576
576
|
const { onKeydown: onChartKeydown } = useChartRoving(svgRef);
|
|
@@ -136,6 +136,7 @@ import OrigamSheet from "../Sheet/OrigamSheet.vue";
|
|
|
136
136
|
import OrigamTextField from "../TextField/OrigamTextField.vue";
|
|
137
137
|
import OrigamTranslateScale from "../Transition/OrigamTranslateScale.vue";
|
|
138
138
|
import { useLocale } from "../../composables/Commons/locale.composable";
|
|
139
|
+
import { usePopupDialogAria } from "../../composables/Commons/popup-dialog-aria.composable";
|
|
139
140
|
import { filterPropsOf, useProps } from "../../composables/Commons/props.composable";
|
|
140
141
|
import { useTeleportTypography } from "../../composables/Commons/teleport-typography.composable";
|
|
141
142
|
import { useVModel } from "../../composables/Commons/vModel.composable";
|
|
@@ -1159,15 +1160,12 @@ const { typographyStyles: menuTypographyStyles } = useTeleportTypography(origamT
|
|
|
1159
1160
|
"--origam-picker-title---font-size": fontSize,
|
|
1160
1161
|
"--origam-color-picker-edit__label---font-size": fontSize
|
|
1161
1162
|
}));
|
|
1162
|
-
const comboboxAriaAttrs =
|
|
1163
|
-
role: "combobox",
|
|
1164
|
-
"aria-haspopup": "dialog",
|
|
1165
|
-
"aria-expanded": menu.value ? "true" : "false"
|
|
1166
|
-
}));
|
|
1163
|
+
const { comboboxAriaAttrs, menuAriaProps } = usePopupDialogAria("origam-color-picker-field", () => props.label ? t(props.label) : undefined, menu);
|
|
1167
1164
|
const menuProps = computed(() => {
|
|
1168
1165
|
const consumerContentProps = props.menuProps?.contentProps ?? {};
|
|
1169
1166
|
return {
|
|
1170
1167
|
...props.menuProps,
|
|
1168
|
+
...menuAriaProps.value,
|
|
1171
1169
|
activatorProps: {
|
|
1172
1170
|
/*********************************************************
|
|
1173
1171
|
* role + aria-haspopup — #818
|
|
@@ -4,7 +4,8 @@
|
|
|
4
4
|
:class="dataTableFooterClasses"
|
|
5
5
|
:style="dataTableFooterStyles"
|
|
6
6
|
>
|
|
7
|
-
|
|
7
|
+
<!-- #1162 : gutter nul — la marge negative du Row rognait le libelle a gauche -->
|
|
8
|
+
<origam-row :gutters="ROW_GUTTER.NONE">
|
|
8
9
|
<slot name="prepend"/>
|
|
9
10
|
|
|
10
11
|
<div class="origam-data-table-footer__items-per-page">
|
|
@@ -51,6 +52,7 @@ import { usePagination } from "../../composables/DataTable/pagination.composable
|
|
|
51
52
|
import { useProps } from "../../composables/Commons/props.composable";
|
|
52
53
|
import { useStyle } from "../../composables/Commons/style.composable";
|
|
53
54
|
import { DENSITY } from "../../enums/Commons/density.enum";
|
|
55
|
+
import { ROW_GUTTER } from "../../enums/Grids/row.enum";
|
|
54
56
|
import { computed, ref, StyleValue } from "vue";
|
|
55
57
|
/*********************************************************
|
|
56
58
|
* Global
|
|
@@ -30,7 +30,11 @@
|
|
|
30
30
|
</template>
|
|
31
31
|
|
|
32
32
|
<template v-else>
|
|
33
|
-
<
|
|
33
|
+
<component
|
|
34
|
+
:is="column.sortable && !disableSort ? 'button' : 'div'"
|
|
35
|
+
:type="column.sortable && !disableSort ? 'button' : undefined"
|
|
36
|
+
class="origam-data-table-header-cell__content"
|
|
37
|
+
>
|
|
34
38
|
<span>{{ column.title }}</span>
|
|
35
39
|
|
|
36
40
|
<template v-if="column.sortable && !disableSort">
|
|
@@ -51,7 +55,7 @@
|
|
|
51
55
|
{{ sortedItems(column) }}
|
|
52
56
|
</div>
|
|
53
57
|
</template>
|
|
54
|
-
</
|
|
58
|
+
</component>
|
|
55
59
|
</template>
|
|
56
60
|
</slot>
|
|
57
61
|
</template>
|
|
@@ -302,6 +306,20 @@ defineExpose({
|
|
|
302
306
|
display: flex;
|
|
303
307
|
align-items: center;
|
|
304
308
|
gap: var(--origam-data-table-header-cell__content---gap, 4px);
|
|
309
|
+
|
|
310
|
+
/* Native <button> reset: the sort control keeps the former <div> look. */
|
|
311
|
+
&:is(button) {
|
|
312
|
+
appearance: none;
|
|
313
|
+
background: none;
|
|
314
|
+
border: 0;
|
|
315
|
+
padding: 0;
|
|
316
|
+
margin: 0;
|
|
317
|
+
width: 100%;
|
|
318
|
+
font: inherit;
|
|
319
|
+
color: inherit;
|
|
320
|
+
text-align: inherit;
|
|
321
|
+
cursor: inherit;
|
|
322
|
+
}
|
|
305
323
|
}
|
|
306
324
|
|
|
307
325
|
&__sort-badge {
|
|
@@ -170,7 +170,7 @@ const props = defineProps({
|
|
|
170
170
|
* (`viewMode` n'en fait plus partie : il pilote `aria-expanded` et le
|
|
171
171
|
* pivot du chevron des deux boutons mois / annee.)
|
|
172
172
|
********************************************************/
|
|
173
|
-
useUnsupportedProp("OrigamDatePickerControls", "active", "the controls row reflects the picker view state of its parent; it has no active state of its own.", () => props.active
|
|
173
|
+
useUnsupportedProp("OrigamDatePickerControls", "active", "the controls row reflects the picker view state of its parent; it has no active state of its own.", () => props.active === true);
|
|
174
174
|
const emits = defineEmits([
|
|
175
175
|
"click:year",
|
|
176
176
|
"click:month",
|
|
@@ -183,6 +183,7 @@ import OrigamTextField from "../TextField/OrigamTextField.vue";
|
|
|
183
183
|
import OrigamTranslateScale from "../Transition/OrigamTranslateScale.vue";
|
|
184
184
|
import { useDate } from "../../composables/Commons/date.composable";
|
|
185
185
|
import { useLocale } from "../../composables/Commons/locale.composable";
|
|
186
|
+
import { usePopupDialogAria } from "../../composables/Commons/popup-dialog-aria.composable";
|
|
186
187
|
import { filterPropsOf, useProps } from "../../composables/Commons/props.composable";
|
|
187
188
|
import { useTeleportTypography } from "../../composables/Commons/teleport-typography.composable";
|
|
188
189
|
import { useTextColor } from "../../composables/Commons/textColor.composable";
|
|
@@ -1189,15 +1190,12 @@ const { typographyStyles: menuTypographyStyles } = useTeleportTypography(origamT
|
|
|
1189
1190
|
"--origam-date-picker-month__weeks---font-size": fontSize,
|
|
1190
1191
|
"--origam-date-picker-month__day---font-size": fontSize
|
|
1191
1192
|
}));
|
|
1192
|
-
const comboboxAriaAttrs =
|
|
1193
|
-
role: "combobox",
|
|
1194
|
-
"aria-haspopup": "dialog",
|
|
1195
|
-
"aria-expanded": menu.value ? "true" : "false"
|
|
1196
|
-
}));
|
|
1193
|
+
const { comboboxAriaAttrs, menuAriaProps } = usePopupDialogAria("origam-date-picker-field", () => props.label ? t(props.label) : undefined, menu);
|
|
1197
1194
|
const menuProps = computed(() => {
|
|
1198
1195
|
const consumerContentProps = props.menuProps?.contentProps ?? {};
|
|
1199
1196
|
return {
|
|
1200
1197
|
...props.menuProps,
|
|
1198
|
+
...menuAriaProps.value,
|
|
1201
1199
|
activatorProps: {
|
|
1202
1200
|
/*********************************************************
|
|
1203
1201
|
* role + aria-haspopup — #818
|
|
@@ -9,8 +9,11 @@
|
|
|
9
9
|
:is="tag"
|
|
10
10
|
v-if="isActive"
|
|
11
11
|
:id="id"
|
|
12
|
-
|
|
12
|
+
ref="rootEl"
|
|
13
13
|
:aria-label="drawerAriaLabel"
|
|
14
|
+
:aria-modal="isModal ? 'true' : undefined"
|
|
15
|
+
:role="isModal ? 'dialog' : undefined"
|
|
16
|
+
:tabindex="isModal ? -1 : undefined"
|
|
14
17
|
:class="drawerClasses"
|
|
15
18
|
:style="drawerStyles"
|
|
16
19
|
v-bind="{...scopeId, ...$attrs}"
|
|
@@ -55,7 +58,7 @@
|
|
|
55
58
|
</template>
|
|
56
59
|
|
|
57
60
|
<script lang="ts" setup>
|
|
58
|
-
import { computed, ComputedRef, isRef, nextTick, onBeforeMount, onServerPrefetch, Ref, ref, shallowRef, StyleValue, toRef, useSlots, watch } from "vue";
|
|
61
|
+
import { computed, ComputedRef, isRef, nextTick, onBeforeMount, onBeforeUnmount, onServerPrefetch, Ref, ref, shallowRef, StyleValue, toRef, useSlots, watch } from "vue";
|
|
59
62
|
import OrigamOverlayScrim from "../Overlay/OrigamOverlayScrim.vue";
|
|
60
63
|
import OrigamTransition from "../Transition/OrigamTransition.vue";
|
|
61
64
|
import { useBackgroundColor } from "../../composables/Commons/backgroundColor.composable";
|
|
@@ -66,6 +69,7 @@ import { useProps } from "../../composables/Commons/props.composable";
|
|
|
66
69
|
import { useRouter } from "../../composables/Commons/router.composable";
|
|
67
70
|
import { useScopeId } from "../../composables/Commons/scopeId.composable";
|
|
68
71
|
import { useSsrBoot } from "../../composables/Commons/ssrBoot.composable";
|
|
72
|
+
import { useStack } from "../../composables/Commons/stack.composable";
|
|
69
73
|
import { useStateEffect } from "../../composables/Commons/stateEffect.composable";
|
|
70
74
|
import { useStateFlag } from "../../composables/Commons/stateFlag.composable";
|
|
71
75
|
import { useSticky } from "../../composables/Commons/sticky.composable";
|
|
@@ -75,8 +79,10 @@ import { useHydration } from "../../composables/Commons/hydration.composable";
|
|
|
75
79
|
import { useToggleScope } from "../../composables/Commons/toggleScope.composable";
|
|
76
80
|
import { useTouch } from "../../composables/Commons/touch.composable";
|
|
77
81
|
import { useVModel } from "../../composables/Commons/vModel.composable";
|
|
82
|
+
import { IN_BROWSER } from "../../consts/Commons/commons.const";
|
|
78
83
|
import { INLINE } from "../../enums/Commons/anchor.enum";
|
|
79
|
-
import {
|
|
84
|
+
import { KEYBOARD_VALUES } from "../../enums/Commons/hotkey.enum";
|
|
85
|
+
import { focusableChildren, int } from "../../utils/Commons/commons.util";
|
|
80
86
|
/*********************************************************
|
|
81
87
|
* inheritAttrs — #916 / #853
|
|
82
88
|
*
|
|
@@ -794,6 +800,62 @@ onBeforeMount(initActive);
|
|
|
794
800
|
********************************************************/
|
|
795
801
|
onServerPrefetch(initActive);
|
|
796
802
|
/*********************************************************
|
|
803
|
+
* Modal behaviour — #1454
|
|
804
|
+
*
|
|
805
|
+
* @description
|
|
806
|
+
* A `temporary` drawer with a scrim blocks the page behind it, so it is
|
|
807
|
+
* modal: `role="dialog"` + `aria-modal`, focus trapped inside, Escape
|
|
808
|
+
* closes it (top of the global stack only, same `useStack` as the
|
|
809
|
+
* Overlay family), and focus returns to whatever held it before opening.
|
|
810
|
+
********************************************************/
|
|
811
|
+
const isModal = computed(() => isActive.value && isTemporary.value && !!props.scrim);
|
|
812
|
+
const { globalTop } = useStack(isModal, shallowRef(1e3), shallowRef(false));
|
|
813
|
+
let returnFocusEl = null;
|
|
814
|
+
/*********************************************************
|
|
815
|
+
* Tab wrap
|
|
816
|
+
*
|
|
817
|
+
* @description
|
|
818
|
+
* Leaving the last focusable moves focus out of the document (no
|
|
819
|
+
* `focusin` fires), so only a keydown guard can trap it.
|
|
820
|
+
********************************************************/
|
|
821
|
+
const handleModalKeydown = (e) => {
|
|
822
|
+
if (!globalTop.value) return;
|
|
823
|
+
if (e.key === KEYBOARD_VALUES.ESC) {
|
|
824
|
+
isActive.value = false;
|
|
825
|
+
return;
|
|
826
|
+
}
|
|
827
|
+
const el = rootEl.value;
|
|
828
|
+
if (e.key !== KEYBOARD_VALUES.TAB || !el) return;
|
|
829
|
+
const focusable = focusableChildren(el);
|
|
830
|
+
const first = focusable[0] ?? el;
|
|
831
|
+
const last = focusable.at(-1) ?? el;
|
|
832
|
+
const outside = !el.contains(document.activeElement) || document.activeElement === el;
|
|
833
|
+
if (e.shiftKey && (document.activeElement === first || outside)) {
|
|
834
|
+
e.preventDefault();
|
|
835
|
+
last.focus();
|
|
836
|
+
} else if (!e.shiftKey && (document.activeElement === last || outside && !focusable.length)) {
|
|
837
|
+
e.preventDefault();
|
|
838
|
+
first.focus();
|
|
839
|
+
}
|
|
840
|
+
};
|
|
841
|
+
if (IN_BROWSER) {
|
|
842
|
+
watch(isModal, async (val) => {
|
|
843
|
+
if (val) {
|
|
844
|
+
returnFocusEl = document.activeElement;
|
|
845
|
+
window.addEventListener("keydown", handleModalKeydown);
|
|
846
|
+
await nextTick();
|
|
847
|
+
rootEl.value?.focus({ preventScroll: true });
|
|
848
|
+
} else {
|
|
849
|
+
window.removeEventListener("keydown", handleModalKeydown);
|
|
850
|
+
returnFocusEl?.focus({ preventScroll: true });
|
|
851
|
+
returnFocusEl = null;
|
|
852
|
+
}
|
|
853
|
+
}, { immediate: true });
|
|
854
|
+
onBeforeUnmount(() => {
|
|
855
|
+
window.removeEventListener("keydown", handleModalKeydown);
|
|
856
|
+
});
|
|
857
|
+
}
|
|
858
|
+
/*********************************************************
|
|
797
859
|
* Drag
|
|
798
860
|
*
|
|
799
861
|
* @description
|
|
@@ -114,10 +114,11 @@ import { useBothColor } from "../../composables/Commons/bothColor.composable";
|
|
|
114
114
|
import { useDensity } from "../../composables/Commons/density.composable";
|
|
115
115
|
import { useGroupItem } from "../../composables/Commons/groupItem.composable";
|
|
116
116
|
import { useLoader } from "../../composables/Commons/loader.composable";
|
|
117
|
-
import { useProps } from "../../composables/Commons/props.composable";
|
|
117
|
+
import { filterPropsOf, useProps } from "../../composables/Commons/props.composable";
|
|
118
118
|
import { useStateEffect } from "../../composables/Commons/stateEffect.composable";
|
|
119
119
|
import { useStateFlag } from "../../composables/Commons/stateFlag.composable";
|
|
120
120
|
import { useStyle } from "../../composables/Commons/style.composable";
|
|
121
|
+
import { getUid } from "../../utils/Commons/getCurrentInstance.util";
|
|
121
122
|
import vContrast from "../../directives/Contrast/contrast.directive";
|
|
122
123
|
import { ORIGAM_EXPANSION_PANEL_KEY } from "../../consts/ExpansionPanel/expansion-panel.const";
|
|
123
124
|
import { LOADER_KIND } from "../../enums/Commons/loader.enum";
|
|
@@ -785,7 +786,8 @@ if (groupItem !== null) {
|
|
|
785
786
|
provide(ORIGAM_EXPANSION_PANEL_KEY, {
|
|
786
787
|
...groupItem,
|
|
787
788
|
headerId,
|
|
788
|
-
contentId
|
|
789
|
+
contentId,
|
|
790
|
+
uid: getUid()
|
|
789
791
|
});
|
|
790
792
|
}
|
|
791
793
|
/*********************************************************
|
|
@@ -832,7 +834,7 @@ const hasHeader = computed(() => {
|
|
|
832
834
|
* Forwarded props
|
|
833
835
|
********************************************************/
|
|
834
836
|
const expansionPanelHeaderProps = computed(() => {
|
|
835
|
-
return
|
|
837
|
+
return filterPropsOf(OrigamExpansionPanelHeader, props, [
|
|
836
838
|
"class",
|
|
837
839
|
"id",
|
|
838
840
|
"style",
|
|
@@ -840,7 +842,7 @@ const expansionPanelHeaderProps = computed(() => {
|
|
|
840
842
|
]);
|
|
841
843
|
});
|
|
842
844
|
const expansionPanelContentProps = computed(() => {
|
|
843
|
-
return
|
|
845
|
+
return filterPropsOf(OrigamExpansionPanelContent, props, [
|
|
844
846
|
"class",
|
|
845
847
|
"id",
|
|
846
848
|
"style",
|
|
@@ -606,7 +606,7 @@ if (!expansionPanel) throw new Error("[Origam] expansion-panel-content needs to
|
|
|
606
606
|
* `aria-controls` at the REAL id instead of guessing the
|
|
607
607
|
* generated-fallback naming scheme (#519, #520).
|
|
608
608
|
********************************************************/
|
|
609
|
-
const contentDomId = computed(() => props.id || `expansion-panel-content-${expansionPanel.
|
|
609
|
+
const contentDomId = computed(() => props.id || `expansion-panel-content-${expansionPanel.uid}`);
|
|
610
610
|
watchEffect(() => {
|
|
611
611
|
expansionPanel.contentId.value = contentDomId.value;
|
|
612
612
|
});
|
|
@@ -703,7 +703,7 @@ const slots = useSlots();
|
|
|
703
703
|
* `aria-labelledby` at the REAL id instead of guessing the
|
|
704
704
|
* generated-fallback naming scheme (#519, #520).
|
|
705
705
|
********************************************************/
|
|
706
|
-
const headerDomId = computed(() => props.id || `expansion-panel-header-${expansionPanel.
|
|
706
|
+
const headerDomId = computed(() => props.id || `expansion-panel-header-${expansionPanel.uid}`);
|
|
707
707
|
watchEffect(() => {
|
|
708
708
|
expansionPanel.headerId.value = headerDomId.value;
|
|
709
709
|
});
|