origam 2.43.0 → 2.44.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 +85 -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/Btn/OrigamBtn.vue +31 -10
- 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/DatePickerField/OrigamDatePickerField.vue +3 -5
- 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/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/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/index.cjs +12 -0
- package/dist/src/composables/index.d.ts +1 -0
- package/dist/src/composables/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/Stepper/stepper-item.interface.d.ts +11 -2
- package/dist/src/interfaces/Stepper/stepper.interface.d.ts +7 -0
- package/dist/src/types/tokens.type.d.ts +1 -1
- 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);
|
|
@@ -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
|
|
|
@@ -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 {
|
|
@@ -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
|
|
@@ -978,7 +978,8 @@ const labelProps = computed(() => {
|
|
|
978
978
|
const defaultLabelProps = origamLabelRef.value?.filterProps(props, [
|
|
979
979
|
"text",
|
|
980
980
|
"class",
|
|
981
|
-
"style"
|
|
981
|
+
"style",
|
|
982
|
+
"id"
|
|
982
983
|
]);
|
|
983
984
|
return {
|
|
984
985
|
class: ["origam-field__label"],
|
|
@@ -1015,7 +1016,8 @@ const floatingLabelProps = computed(() => {
|
|
|
1015
1016
|
const defaultFloatingLabelProps = origamFloatingLabelRef.value?.filterProps(props, [
|
|
1016
1017
|
"text",
|
|
1017
1018
|
"class",
|
|
1018
|
-
"style"
|
|
1019
|
+
"style",
|
|
1020
|
+
"id"
|
|
1019
1021
|
]);
|
|
1020
1022
|
return {
|
|
1021
1023
|
class: ["origam-field__label", "origam-field__label--floating"],
|
|
@@ -1152,7 +1154,7 @@ onMounted(() => {
|
|
|
1152
1154
|
const duration = parseFloat(style.transitionDuration) * 1e3 || 150;
|
|
1153
1155
|
const scale = parseFloat(targetStyle.getPropertyValue("--origam-field__label---font-size"));
|
|
1154
1156
|
const color = targetStyle.getPropertyValue("color");
|
|
1155
|
-
el.style.
|
|
1157
|
+
el.style.clipPath = "none";
|
|
1156
1158
|
targetEl.style.visibility = "hidden";
|
|
1157
1159
|
animate(el, {
|
|
1158
1160
|
transform: `translate(${x}px, ${y}px) scale(${scale})`,
|
|
@@ -1163,7 +1165,7 @@ onMounted(() => {
|
|
|
1163
1165
|
easing: EASING.STANDARD,
|
|
1164
1166
|
direction: newVal ? "normal" : "reverse"
|
|
1165
1167
|
}).finished.then(() => {
|
|
1166
|
-
el.style.removeProperty("
|
|
1168
|
+
el.style.removeProperty("clip-path");
|
|
1167
1169
|
targetEl.style.removeProperty("visibility");
|
|
1168
1170
|
});
|
|
1169
1171
|
});
|
|
@@ -1499,7 +1501,7 @@ defineExpose({
|
|
|
1499
1501
|
* lecteur — et le lot ne peut pas le verifier sur les trois
|
|
1500
1502
|
* composants sans changer de perimetre.
|
|
1501
1503
|
*/
|
|
1502
|
-
min-height: max(calc(var(--origam-input__control---height, 36px) + var(--origam-input---density, 0px)), 1.
|
|
1504
|
+
min-height: max(calc(var(--origam-input__control---height, 36px) + var(--origam-input---density, 0px)), calc(1rem * var(--origam-input---line-height, 1.5)) + var(--origam-field__input---padding-top) + var(--origam-field__input---padding-bottom));
|
|
1503
1505
|
min-width: 0;
|
|
1504
1506
|
padding-inline: var(--origam-field__input---padding-start) var(--origam-field__input---padding-end);
|
|
1505
1507
|
padding-top: var(--origam-field__input---padding-top);
|
|
@@ -1532,6 +1534,8 @@ defineExpose({
|
|
|
1532
1534
|
textarea {
|
|
1533
1535
|
letter-spacing: inherit;
|
|
1534
1536
|
border: none;
|
|
1537
|
+
// #1280 — remet a zero le padding UA (1px 2px) : le texte demarre au retrait du champ.
|
|
1538
|
+
padding: 0;
|
|
1535
1539
|
|
|
1536
1540
|
&::placeholder {
|
|
1537
1541
|
color: var(--origam-field---placeholder-color, currentColor);
|
|
@@ -1558,7 +1562,7 @@ defineExpose({
|
|
|
1558
1562
|
opacity: 0;
|
|
1559
1563
|
transition: inherit;
|
|
1560
1564
|
white-space: nowrap;
|
|
1561
|
-
min-height: max(var(--origam-input__control---height, 36px), 1.
|
|
1565
|
+
min-height: max(var(--origam-input__control---height, 36px), calc(1rem * var(--origam-input---line-height, 1.5)) + var(--origam-field__input---padding-top, 0px) + var(--origam-field__input---padding-bottom, 0px));
|
|
1562
1566
|
padding-top: calc(var(--origam-field---padding-top, 4px) + calc(var(--origam-input---padding-top, 16px) + var(--origam-input---density, 0px)));
|
|
1563
1567
|
padding-bottom: var(--origam-field---padding-bottom, 6px);
|
|
1564
1568
|
}
|
|
@@ -1721,11 +1725,17 @@ defineExpose({
|
|
|
1721
1725
|
}
|
|
1722
1726
|
|
|
1723
1727
|
&--active {
|
|
1728
|
+
/*
|
|
1729
|
+
* Le label d'origine reste visible pour les technologies d'assistance
|
|
1730
|
+
* (axe ne lit que le PREMIER label[for] : `visibility: hidden` y vidait
|
|
1731
|
+
* le nom accessible, #1149) ; il est seulement rogne visuellement.
|
|
1732
|
+
*/
|
|
1724
1733
|
#{$this}__label {
|
|
1725
|
-
|
|
1734
|
+
clip-path: inset(50%);
|
|
1726
1735
|
|
|
1727
1736
|
&--floating {
|
|
1728
1737
|
visibility: unset;
|
|
1738
|
+
clip-path: none;
|
|
1729
1739
|
}
|
|
1730
1740
|
}
|
|
1731
1741
|
|
|
@@ -153,8 +153,8 @@
|
|
|
153
153
|
@click="handleControlClick"
|
|
154
154
|
@mousedown="handleControlMousedown"
|
|
155
155
|
@click:clear="handleClear"
|
|
156
|
-
@click:prepend-inner="
|
|
157
|
-
@click:append-inner="
|
|
156
|
+
@click:prepend-inner="prependInnerRelay"
|
|
157
|
+
@click:append-inner="appendInnerRelay"
|
|
158
158
|
>
|
|
159
159
|
<template
|
|
160
160
|
v-if="slots.loader"
|
|
@@ -1321,7 +1321,7 @@ const model = useVModel(props, "modelValue", () => props.multiple ? [] : null, (
|
|
|
1321
1321
|
* Composables
|
|
1322
1322
|
********************************************************/
|
|
1323
1323
|
const { onClickPrepend, onClickAppend: handleClickAppend } = useAdjacent(props, toRef(props, "prependIcon"), toRef(props, "appendIcon"));
|
|
1324
|
-
const {
|
|
1324
|
+
const { appendInnerRelay, prependInnerRelay } = useAdjacentInner(props);
|
|
1325
1325
|
/*********************************************************
|
|
1326
1326
|
* Reference Html
|
|
1327
1327
|
*
|
|
@@ -595,7 +595,7 @@ const { typographyStyles: rootTypographyStyles } = useTypography(props, "message
|
|
|
595
595
|
* cablees a un comportement invente. Elles avertissent une fois, en
|
|
596
596
|
* dev, avec la raison exacte. Meme traitement que la famille Chart.
|
|
597
597
|
********************************************************/
|
|
598
|
-
useUnsupportedProp("OrigamMessages", "active", "visibility is driven by `messages` being non-empty, never by this prop.", () => props.active
|
|
598
|
+
useUnsupportedProp("OrigamMessages", "active", "visibility is driven by `messages` being non-empty, never by this prop.", () => props.active === true);
|
|
599
599
|
const { typographyStyles: childTypographyStyles } = useTypography(props, "messages__message");
|
|
600
600
|
/*********************************************************
|
|
601
601
|
* Composables
|
|
@@ -85,8 +85,8 @@
|
|
|
85
85
|
@click:clear="handleClear"
|
|
86
86
|
@click:prepend="handleClickPrepend"
|
|
87
87
|
@click:append="handleClickAppend"
|
|
88
|
-
@click:prepend-inner="
|
|
89
|
-
@click:append-inner="
|
|
88
|
+
@click:prepend-inner="prependInnerRelay"
|
|
89
|
+
@click:append-inner="appendInnerRelay"
|
|
90
90
|
>
|
|
91
91
|
<template
|
|
92
92
|
v-if="slots.prepend"
|
|
@@ -113,11 +113,11 @@
|
|
|
113
113
|
</template>
|
|
114
114
|
|
|
115
115
|
<template
|
|
116
|
-
v-if="
|
|
116
|
+
v-if="hasPrependControls || slots.prependInner"
|
|
117
117
|
#prependInner
|
|
118
118
|
>
|
|
119
119
|
<div
|
|
120
|
-
v-if="
|
|
120
|
+
v-if="hasPrependControls"
|
|
121
121
|
class="origam-number-field__control"
|
|
122
122
|
>
|
|
123
123
|
<template v-if="split">
|
|
@@ -1222,7 +1222,7 @@ const { isFocused, onFocus, onBlur } = useFocus(props);
|
|
|
1222
1222
|
/*********************************************************
|
|
1223
1223
|
* Composables
|
|
1224
1224
|
********************************************************/
|
|
1225
|
-
const {
|
|
1225
|
+
const { appendInnerRelay, prependInnerRelay } = useAdjacentInner(props);
|
|
1226
1226
|
/*********************************************************
|
|
1227
1227
|
* click:prepend / click:append relay
|
|
1228
1228
|
*
|
|
@@ -1537,6 +1537,14 @@ const textFieldProps = computed(() => {
|
|
|
1537
1537
|
"validationValue"
|
|
1538
1538
|
]);
|
|
1539
1539
|
});
|
|
1540
|
+
/*********************************************************
|
|
1541
|
+
* hasPrependControls
|
|
1542
|
+
*
|
|
1543
|
+
* @description
|
|
1544
|
+
* #1449 — the prepend-inner controls only exist in `split` mode
|
|
1545
|
+
* (otherwise they live in appendInner).
|
|
1546
|
+
********************************************************/
|
|
1547
|
+
const hasPrependControls = computed(() => props.split && !props.hideControls);
|
|
1540
1548
|
const hasAppendInner = computed(() => {
|
|
1541
1549
|
return slots.appendInner || !props.hideControls;
|
|
1542
1550
|
});
|
|
@@ -29,8 +29,8 @@
|
|
|
29
29
|
:focused="(isFocused && focusAll) || focusIndex === i"
|
|
30
30
|
v-bind="{...fieldProps(i)}"
|
|
31
31
|
@click:clear="handleClear"
|
|
32
|
-
@click:append-inner="
|
|
33
|
-
@click:prepend-inner="
|
|
32
|
+
@click:append-inner="appendInnerRelay"
|
|
33
|
+
@click:prepend-inner="prependInnerRelay"
|
|
34
34
|
>
|
|
35
35
|
<template
|
|
36
36
|
v-if="slots.prependInner"
|
|
@@ -141,7 +141,6 @@
|
|
|
141
141
|
>
|
|
142
142
|
<origam-messages
|
|
143
143
|
:id="messagesId"
|
|
144
|
-
:active="hasMessages"
|
|
145
144
|
:messages="validationMessages"
|
|
146
145
|
/>
|
|
147
146
|
</div>
|
|
@@ -149,7 +148,7 @@
|
|
|
149
148
|
</template>
|
|
150
149
|
|
|
151
150
|
<script lang="ts" setup>
|
|
152
|
-
import { computed, nextTick, onBeforeUnmount, ref, StyleValue, useAttrs, useSlots, watch } from "vue";
|
|
151
|
+
import { computed, getCurrentInstance, nextTick, onBeforeUnmount, ref, StyleValue, useAttrs, useSlots, watch } from "vue";
|
|
153
152
|
import OrigamField from "../Field/OrigamField.vue";
|
|
154
153
|
import OrigamOverlay from "../Overlay/OrigamOverlay.vue";
|
|
155
154
|
import OrigamProgress from "../Progress/OrigamProgress.vue";
|
|
@@ -165,7 +164,7 @@ import { useStyle } from "../../composables/Commons/style.composable";
|
|
|
165
164
|
import { OTP_INPUT_FIELD_TYPE } from "../../enums/OtpInputField/otp-input-field.enum";
|
|
166
165
|
import { PROGRESS_TYPE } from "../../enums/Progress/progress.enum";
|
|
167
166
|
import { filterInputAttrs } from "../../utils/Input/input.util";
|
|
168
|
-
import { focusChild, wrapInArray } from "../../utils/Commons/commons.util";
|
|
167
|
+
import { focusChild, hasEvent, wrapInArray } from "../../utils/Commons/commons.util";
|
|
169
168
|
import { forwardRefs } from "../../utils/Commons/forwardRefs.util";
|
|
170
169
|
import { getUid } from "../../utils/Commons/getCurrentInstance.util";
|
|
171
170
|
/*********************************************************
|
|
@@ -1155,6 +1154,10 @@ const handleClear = (e) => {
|
|
|
1155
1154
|
* `handleClear` above: relay on THIS component's own instance whichever
|
|
1156
1155
|
* cell the click came from.
|
|
1157
1156
|
********************************************************/
|
|
1157
|
+
const vm = getCurrentInstance();
|
|
1158
|
+
const hasListener = (name) => hasEvent(vm?.vnode.props ?? {}, name);
|
|
1159
|
+
const appendInnerRelay = computed(() => hasListener("click:appendInner") ? handleClickAppendInner : undefined);
|
|
1160
|
+
const prependInnerRelay = computed(() => hasListener("click:prependInner") ? handleClickPrependInner : undefined);
|
|
1158
1161
|
const handleClickAppendInner = (e) => {
|
|
1159
1162
|
emits("click:appendInner", e);
|
|
1160
1163
|
};
|
|
@@ -33,8 +33,8 @@
|
|
|
33
33
|
@click="handleControlClick"
|
|
34
34
|
@mousedown="handleControlMousedown"
|
|
35
35
|
@click:clear="handleClear"
|
|
36
|
-
@click:prepend-inner="
|
|
37
|
-
@click:append-inner="
|
|
36
|
+
@click:prepend-inner="prependInnerRelay"
|
|
37
|
+
@click:append-inner="appendInnerRelay"
|
|
38
38
|
>
|
|
39
39
|
<template
|
|
40
40
|
v-if="slots.loader"
|
|
@@ -1213,7 +1213,7 @@ const model = useVModel(props, "modelValue");
|
|
|
1213
1213
|
/*********************************************************
|
|
1214
1214
|
* Composables
|
|
1215
1215
|
********************************************************/
|
|
1216
|
-
const {
|
|
1216
|
+
const { appendInnerRelay, prependInnerRelay } = useAdjacentInner(props);
|
|
1217
1217
|
/*********************************************************
|
|
1218
1218
|
* Icon
|
|
1219
1219
|
********************************************************/
|