@empathyco/x-components 6.0.0-alpha.27 → 6.0.0-alpha.29
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 +18 -0
- package/design-system/deprecated-full-theme.css +241 -241
- package/js/components/modals/base-modal.vue.js.map +1 -1
- package/js/components/modals/base-modal.vue2.js +13 -6
- package/js/components/modals/base-modal.vue2.js.map +1 -1
- package/package.json +3 -3
- package/types/components/modals/base-modal.vue.d.ts.map +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,24 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [6.0.0-alpha.29](https://github.com/empathyco/x/compare/@empathyco/x-components@6.0.0-alpha.28...@empathyco/x-components@6.0.0-alpha.29) (2025-01-13)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Styling
|
|
10
|
+
|
|
11
|
+
* **tailwind:** extend tailwind config to be used by the demo (#1668) ([f33992e](https://github.com/empathyco/x/commit/f33992ed8743367677e1e35fb7dd07e6dcce7424))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
## [6.0.0-alpha.28](https://github.com/empathyco/x/compare/@empathyco/x-components@6.0.0-alpha.27...@empathyco/x-components@6.0.0-alpha.28) (2025-01-09)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
### Features
|
|
19
|
+
|
|
20
|
+
* **components:** make reference selector for `BaseModal` reactive (#1686) ([b25c2af](https://github.com/empathyco/x/commit/b25c2af800880ecd4ce36369be3e55a626be55e5))
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
6
24
|
## [6.0.0-alpha.27](https://github.com/empathyco/x/compare/@empathyco/x-components@6.0.0-alpha.26...@empathyco/x-components@6.0.0-alpha.27) (2025-01-09)
|
|
7
25
|
|
|
8
26
|
|
|
@@ -1,5 +1,20 @@
|
|
|
1
1
|
|
|
2
2
|
|
|
3
|
+
.x-uppercase {
|
|
4
|
+
text-transform: uppercase;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.x-lowercase {
|
|
8
|
+
text-transform: lowercase;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
.x-capitalize {
|
|
12
|
+
text-transform: capitalize;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.x-normal-case {
|
|
16
|
+
text-transform: none;
|
|
17
|
+
}
|
|
3
18
|
.x-underline {
|
|
4
19
|
-webkit-text-decoration-line: underline;
|
|
5
20
|
text-decoration-line: underline;
|
|
@@ -964,21 +979,6 @@
|
|
|
964
979
|
.x-line-height--loose {
|
|
965
980
|
line-height: 2 !important;
|
|
966
981
|
}
|
|
967
|
-
.x-uppercase {
|
|
968
|
-
text-transform: uppercase;
|
|
969
|
-
}
|
|
970
|
-
|
|
971
|
-
.x-lowercase {
|
|
972
|
-
text-transform: lowercase;
|
|
973
|
-
}
|
|
974
|
-
|
|
975
|
-
.x-capitalize {
|
|
976
|
-
text-transform: capitalize;
|
|
977
|
-
}
|
|
978
|
-
|
|
979
|
-
.x-normal-case {
|
|
980
|
-
text-transform: none;
|
|
981
|
-
}
|
|
982
982
|
.x-line-clamp--2 {
|
|
983
983
|
overflow: hidden !important;
|
|
984
984
|
display: -webkit-box !important;
|
|
@@ -1102,49 +1102,6 @@
|
|
|
1102
1102
|
font-size: var(--x-size-base-20) !important;
|
|
1103
1103
|
line-height: 1.5;
|
|
1104
1104
|
}
|
|
1105
|
-
.x-flex-1 {
|
|
1106
|
-
flex: 1 1 0% !important;
|
|
1107
|
-
}
|
|
1108
|
-
|
|
1109
|
-
.x-flex-auto {
|
|
1110
|
-
flex: 1 1 auto !important;
|
|
1111
|
-
}
|
|
1112
|
-
|
|
1113
|
-
.x-flex-initial {
|
|
1114
|
-
flex: 0 1 auto !important;
|
|
1115
|
-
}
|
|
1116
|
-
|
|
1117
|
-
.x-flex-no-shrink {
|
|
1118
|
-
flex: 1 0 auto !important;
|
|
1119
|
-
}
|
|
1120
|
-
|
|
1121
|
-
.x-flex-none {
|
|
1122
|
-
flex: none !important;
|
|
1123
|
-
}
|
|
1124
|
-
|
|
1125
|
-
.x-self-auto {
|
|
1126
|
-
align-self: auto !important;
|
|
1127
|
-
}
|
|
1128
|
-
|
|
1129
|
-
.x-self-start {
|
|
1130
|
-
align-self: flex-start !important;
|
|
1131
|
-
}
|
|
1132
|
-
|
|
1133
|
-
.x-self-end {
|
|
1134
|
-
align-self: flex-end !important;
|
|
1135
|
-
}
|
|
1136
|
-
|
|
1137
|
-
.x-self-center {
|
|
1138
|
-
align-self: center !important;
|
|
1139
|
-
}
|
|
1140
|
-
|
|
1141
|
-
.x-self-stretch {
|
|
1142
|
-
align-self: stretch !important;
|
|
1143
|
-
}
|
|
1144
|
-
|
|
1145
|
-
.x-self-baseline {
|
|
1146
|
-
align-self: baseline !important;
|
|
1147
|
-
}
|
|
1148
1105
|
.x-font-color--lead {
|
|
1149
1106
|
color: var(--x-color-base-lead) !important;
|
|
1150
1107
|
}
|
|
@@ -1188,6 +1145,49 @@
|
|
|
1188
1145
|
.x-font-color--transparent {
|
|
1189
1146
|
color: var(--x-color-base-transparent) !important;
|
|
1190
1147
|
}
|
|
1148
|
+
.x-flex-1 {
|
|
1149
|
+
flex: 1 1 0% !important;
|
|
1150
|
+
}
|
|
1151
|
+
|
|
1152
|
+
.x-flex-auto {
|
|
1153
|
+
flex: 1 1 auto !important;
|
|
1154
|
+
}
|
|
1155
|
+
|
|
1156
|
+
.x-flex-initial {
|
|
1157
|
+
flex: 0 1 auto !important;
|
|
1158
|
+
}
|
|
1159
|
+
|
|
1160
|
+
.x-flex-no-shrink {
|
|
1161
|
+
flex: 1 0 auto !important;
|
|
1162
|
+
}
|
|
1163
|
+
|
|
1164
|
+
.x-flex-none {
|
|
1165
|
+
flex: none !important;
|
|
1166
|
+
}
|
|
1167
|
+
|
|
1168
|
+
.x-self-auto {
|
|
1169
|
+
align-self: auto !important;
|
|
1170
|
+
}
|
|
1171
|
+
|
|
1172
|
+
.x-self-start {
|
|
1173
|
+
align-self: flex-start !important;
|
|
1174
|
+
}
|
|
1175
|
+
|
|
1176
|
+
.x-self-end {
|
|
1177
|
+
align-self: flex-end !important;
|
|
1178
|
+
}
|
|
1179
|
+
|
|
1180
|
+
.x-self-center {
|
|
1181
|
+
align-self: center !important;
|
|
1182
|
+
}
|
|
1183
|
+
|
|
1184
|
+
.x-self-stretch {
|
|
1185
|
+
align-self: stretch !important;
|
|
1186
|
+
}
|
|
1187
|
+
|
|
1188
|
+
.x-self-baseline {
|
|
1189
|
+
align-self: baseline !important;
|
|
1190
|
+
}
|
|
1191
1191
|
.x-fill--lead {
|
|
1192
1192
|
fill: var(--x-color-base-lead) !important;
|
|
1193
1193
|
}
|
|
@@ -3436,21 +3436,6 @@
|
|
|
3436
3436
|
--x-size-line-height-small: var(--x-size-line-height-base-s);
|
|
3437
3437
|
--x-string-text-decoration-small: none;
|
|
3438
3438
|
}
|
|
3439
|
-
.x-text--bold.x-text {
|
|
3440
|
-
--x-number-font-weight-text: var(--x-number-font-weight-base-bold);
|
|
3441
|
-
}
|
|
3442
|
-
.x-text--bold.x-title1 {
|
|
3443
|
-
--x-number-font-weight-title1: var(--x-number-font-weight-base-bold);
|
|
3444
|
-
}
|
|
3445
|
-
.x-text--bold.x-title2 {
|
|
3446
|
-
--x-number-font-weight-title2: var(--x-number-font-weight-base-bold);
|
|
3447
|
-
}
|
|
3448
|
-
.x-text--bold.x-title3 {
|
|
3449
|
-
--x-number-font-weight-title3: var(--x-number-font-weight-base-bold);
|
|
3450
|
-
}
|
|
3451
|
-
.x-text--bold.x-small {
|
|
3452
|
-
--x-number-font-weight-small: var(--x-number-font-weight-base-bold);
|
|
3453
|
-
}
|
|
3454
3439
|
:root {
|
|
3455
3440
|
--x-font-family-base: "Montserrat", sans-serif;
|
|
3456
3441
|
--x-size-font-base-xs: 12px;
|
|
@@ -3553,6 +3538,21 @@
|
|
|
3553
3538
|
overflow: hidden;
|
|
3554
3539
|
white-space: nowrap;
|
|
3555
3540
|
}
|
|
3541
|
+
.x-text--bold.x-text {
|
|
3542
|
+
--x-number-font-weight-text: var(--x-number-font-weight-base-bold);
|
|
3543
|
+
}
|
|
3544
|
+
.x-text--bold.x-title1 {
|
|
3545
|
+
--x-number-font-weight-title1: var(--x-number-font-weight-base-bold);
|
|
3546
|
+
}
|
|
3547
|
+
.x-text--bold.x-title2 {
|
|
3548
|
+
--x-number-font-weight-title2: var(--x-number-font-weight-base-bold);
|
|
3549
|
+
}
|
|
3550
|
+
.x-text--bold.x-title3 {
|
|
3551
|
+
--x-number-font-weight-title3: var(--x-number-font-weight-base-bold);
|
|
3552
|
+
}
|
|
3553
|
+
.x-text--bold.x-small {
|
|
3554
|
+
--x-number-font-weight-small: var(--x-number-font-weight-base-bold);
|
|
3555
|
+
}
|
|
3556
3556
|
:root {
|
|
3557
3557
|
--x-color-text-accent: var(--x-color-base-accent);
|
|
3558
3558
|
}
|
|
@@ -3566,6 +3566,18 @@
|
|
|
3566
3566
|
--x-size-border-radius-bottom-right-tag-pill: var(--x-size-border-radius-tag-pill);
|
|
3567
3567
|
--x-size-border-radius-bottom-left-tag-pill: var(--x-size-border-radius-tag-pill);
|
|
3568
3568
|
}
|
|
3569
|
+
:root {
|
|
3570
|
+
--x-color-background-tag-ghost: transparent;
|
|
3571
|
+
--x-color-border-tag-ghost: transparent;
|
|
3572
|
+
--x-color-background-tag-selected-ghost: transparent;
|
|
3573
|
+
--x-color-border-tag-selected-ghost: transparent;
|
|
3574
|
+
--x-color-background-tag-curated-ghost: transparent;
|
|
3575
|
+
--x-color-border-tag-curated-ghost: transparent;
|
|
3576
|
+
--x-color-background-tag-curated-selected-ghost: transparent;
|
|
3577
|
+
--x-color-border-tag-curated-selected-ghost: transparent;
|
|
3578
|
+
--x-number-font-weight-tag-selected-ghost: var(--x-number-font-weight-base-bold);
|
|
3579
|
+
--x-number-font-weight-tag-curated-selected-ghost: var(--x-number-font-weight-base-bold);
|
|
3580
|
+
}
|
|
3569
3581
|
:root {
|
|
3570
3582
|
--x-size-border-radius-tag-pill: var(--x-size-border-radius-base-pill);
|
|
3571
3583
|
--x-size-border-radius-top-left-tag-pill: var(--x-size-border-radius-tag-pill);
|
|
@@ -3596,6 +3608,24 @@
|
|
|
3596
3608
|
--x-number-font-weight-tag-selected-ghost: var(--x-number-font-weight-base-bold);
|
|
3597
3609
|
--x-number-font-weight-tag-curated-selected-ghost: var(--x-number-font-weight-base-bold);
|
|
3598
3610
|
}
|
|
3611
|
+
|
|
3612
|
+
.x-tag--ghost.x-tag,
|
|
3613
|
+
.x-tag--ghost .x-tag {
|
|
3614
|
+
--x-color-background-tag-default: var(--x-color-background-tag-ghost);
|
|
3615
|
+
--x-color-border-tag-default: var(--x-color-border-tag-ghost);
|
|
3616
|
+
--x-color-background-tag-default-curated: var(--x-color-background-tag-curated-ghost);
|
|
3617
|
+
--x-color-border-tag-default-curated: var(--x-color-border-tag-curated-ghost);
|
|
3618
|
+
--x-color-background-tag-default-selected: var(--x-color-background-tag-selected-ghost);
|
|
3619
|
+
--x-color-border-tag-default-selected: var(--x-color-border-tag-selected-ghost);
|
|
3620
|
+
--x-color-background-tag-default-curated-selected: var(
|
|
3621
|
+
--x-color-background-tag-curated-selected-ghost
|
|
3622
|
+
);
|
|
3623
|
+
--x-color-border-tag-default-curated-selected: var(--x-color-border-tag-curated-selected-ghost);
|
|
3624
|
+
--x-number-font-weight-tag-default-selected: var(--x-number-font-weight-tag-selected-ghost);
|
|
3625
|
+
--x-number-font-weight-tag-default-curated-selected: var(
|
|
3626
|
+
--x-number-font-weight-tag-curated-selected-ghost
|
|
3627
|
+
);
|
|
3628
|
+
}
|
|
3599
3629
|
:root {
|
|
3600
3630
|
--x-color-background-tag-default: var(--x-color-base-neutral-100);
|
|
3601
3631
|
--x-color-border-tag-default: var(--x-color-text-tag-default);
|
|
@@ -3642,36 +3672,6 @@
|
|
|
3642
3672
|
--x-number-font-weight-tag-default-selected
|
|
3643
3673
|
);
|
|
3644
3674
|
}
|
|
3645
|
-
:root {
|
|
3646
|
-
--x-color-background-tag-ghost: transparent;
|
|
3647
|
-
--x-color-border-tag-ghost: transparent;
|
|
3648
|
-
--x-color-background-tag-selected-ghost: transparent;
|
|
3649
|
-
--x-color-border-tag-selected-ghost: transparent;
|
|
3650
|
-
--x-color-background-tag-curated-ghost: transparent;
|
|
3651
|
-
--x-color-border-tag-curated-ghost: transparent;
|
|
3652
|
-
--x-color-background-tag-curated-selected-ghost: transparent;
|
|
3653
|
-
--x-color-border-tag-curated-selected-ghost: transparent;
|
|
3654
|
-
--x-number-font-weight-tag-selected-ghost: var(--x-number-font-weight-base-bold);
|
|
3655
|
-
--x-number-font-weight-tag-curated-selected-ghost: var(--x-number-font-weight-base-bold);
|
|
3656
|
-
}
|
|
3657
|
-
|
|
3658
|
-
.x-tag--ghost.x-tag,
|
|
3659
|
-
.x-tag--ghost .x-tag {
|
|
3660
|
-
--x-color-background-tag-default: var(--x-color-background-tag-ghost);
|
|
3661
|
-
--x-color-border-tag-default: var(--x-color-border-tag-ghost);
|
|
3662
|
-
--x-color-background-tag-default-curated: var(--x-color-background-tag-curated-ghost);
|
|
3663
|
-
--x-color-border-tag-default-curated: var(--x-color-border-tag-curated-ghost);
|
|
3664
|
-
--x-color-background-tag-default-selected: var(--x-color-background-tag-selected-ghost);
|
|
3665
|
-
--x-color-border-tag-default-selected: var(--x-color-border-tag-selected-ghost);
|
|
3666
|
-
--x-color-background-tag-default-curated-selected: var(
|
|
3667
|
-
--x-color-background-tag-curated-selected-ghost
|
|
3668
|
-
);
|
|
3669
|
-
--x-color-border-tag-default-curated-selected: var(--x-color-border-tag-curated-selected-ghost);
|
|
3670
|
-
--x-number-font-weight-tag-default-selected: var(--x-number-font-weight-tag-selected-ghost);
|
|
3671
|
-
--x-number-font-weight-tag-default-curated-selected: var(
|
|
3672
|
-
--x-number-font-weight-tag-curated-selected-ghost
|
|
3673
|
-
);
|
|
3674
|
-
}
|
|
3675
3675
|
:root {
|
|
3676
3676
|
--x-color-background-tag-default: var(--x-color-base-neutral-100);
|
|
3677
3677
|
--x-color-border-tag-default: var(--x-color-text-tag-default);
|
|
@@ -4454,14 +4454,6 @@
|
|
|
4454
4454
|
--x-color-background-scroll-bar-hover: transparent;
|
|
4455
4455
|
--x-color-thumb-scroll-bar-hover: var(--x-color-base-neutral-70);
|
|
4456
4456
|
}
|
|
4457
|
-
/* @deprecated */
|
|
4458
|
-
:root {
|
|
4459
|
-
--x-size-padding-row-02: var(--x-size-base-02);
|
|
4460
|
-
--x-size-padding-row-03: var(--x-size-base-03);
|
|
4461
|
-
--x-size-padding-row-04: var(--x-size-base-04);
|
|
4462
|
-
--x-size-padding-row-05: var(--x-size-base-05);
|
|
4463
|
-
--x-size-padding-row-06: var(--x-size-base-06);
|
|
4464
|
-
}
|
|
4465
4457
|
:root {
|
|
4466
4458
|
--x-string-overflow-scroll: auto;
|
|
4467
4459
|
--x-color-background-scroll-bar: transparent;
|
|
@@ -4508,6 +4500,14 @@
|
|
|
4508
4500
|
--x-size-padding-row-05: var(--x-size-base-05);
|
|
4509
4501
|
--x-size-padding-row-06: var(--x-size-base-06);
|
|
4510
4502
|
}
|
|
4503
|
+
/* @deprecated */
|
|
4504
|
+
:root {
|
|
4505
|
+
--x-size-padding-row-02: var(--x-size-base-02);
|
|
4506
|
+
--x-size-padding-row-03: var(--x-size-base-03);
|
|
4507
|
+
--x-size-padding-row-04: var(--x-size-base-04);
|
|
4508
|
+
--x-size-padding-row-05: var(--x-size-base-05);
|
|
4509
|
+
--x-size-padding-row-06: var(--x-size-base-06);
|
|
4510
|
+
}
|
|
4511
4511
|
|
|
4512
4512
|
/* @deprecated */
|
|
4513
4513
|
.x-row--padding-02 {
|
|
@@ -4661,14 +4661,6 @@
|
|
|
4661
4661
|
--x-size-span-row-item: 1;
|
|
4662
4662
|
--x-size-start-row-item: 0;
|
|
4663
4663
|
}
|
|
4664
|
-
:root {
|
|
4665
|
-
--x-size-gap-row: 0;
|
|
4666
|
-
--x-size-padding-row: 0;
|
|
4667
|
-
--x-size-justify-row: stretch;
|
|
4668
|
-
--x-size-align-row: center;
|
|
4669
|
-
--x-size-span-row-item: 1;
|
|
4670
|
-
--x-size-start-row-item: 0;
|
|
4671
|
-
}
|
|
4672
4664
|
|
|
4673
4665
|
.x-row {
|
|
4674
4666
|
display: grid;
|
|
@@ -4789,6 +4781,14 @@
|
|
|
4789
4781
|
.x-row--align-stretch {
|
|
4790
4782
|
--x-size-align-row: stretch;
|
|
4791
4783
|
}
|
|
4784
|
+
:root {
|
|
4785
|
+
--x-size-gap-row: 0;
|
|
4786
|
+
--x-size-padding-row: 0;
|
|
4787
|
+
--x-size-justify-row: stretch;
|
|
4788
|
+
--x-size-align-row: center;
|
|
4789
|
+
--x-size-span-row-item: 1;
|
|
4790
|
+
--x-size-start-row-item: 0;
|
|
4791
|
+
}
|
|
4792
4792
|
:root {
|
|
4793
4793
|
--x-color-border-result-default: var(--x-color-base-lead);
|
|
4794
4794
|
--x-color-border-result-overlay-default: var(--x-color-border-result-default);
|
|
@@ -4879,14 +4879,14 @@
|
|
|
4879
4879
|
:root {
|
|
4880
4880
|
--x-size-border-radius-result-card: var(--x-size-border-radius-base-s);
|
|
4881
4881
|
}
|
|
4882
|
+
:root {
|
|
4883
|
+
--x-size-border-radius-result-card: var(--x-size-border-radius-base-s);
|
|
4884
|
+
}
|
|
4882
4885
|
|
|
4883
4886
|
.x-result.x-result--card {
|
|
4884
4887
|
overflow: hidden;
|
|
4885
4888
|
--x-size-border-radius-result-default: var(--x-size-border-radius-result-card);
|
|
4886
4889
|
}
|
|
4887
|
-
:root {
|
|
4888
|
-
--x-size-border-radius-result-card: var(--x-size-border-radius-base-s);
|
|
4889
|
-
}
|
|
4890
4890
|
:root {
|
|
4891
4891
|
--x-size-height-progress-bar-line-default: var(--x-size-base-02);
|
|
4892
4892
|
--x-size-width-progress-bar-line-default: var(--x-size-base-20);
|
|
@@ -6023,6 +6023,28 @@
|
|
|
6023
6023
|
--x-size-gap-list-19: var(--x-size-base-19);
|
|
6024
6024
|
--x-size-gap-list-20: var(--x-size-base-20);
|
|
6025
6025
|
}
|
|
6026
|
+
:root {
|
|
6027
|
+
--x-size-gap-list-01: var(--x-size-base-01);
|
|
6028
|
+
--x-size-gap-list-02: var(--x-size-base-02);
|
|
6029
|
+
--x-size-gap-list-03: var(--x-size-base-03);
|
|
6030
|
+
--x-size-gap-list-04: var(--x-size-base-04);
|
|
6031
|
+
--x-size-gap-list-05: var(--x-size-base-05);
|
|
6032
|
+
--x-size-gap-list-06: var(--x-size-base-06);
|
|
6033
|
+
--x-size-gap-list-07: var(--x-size-base-07);
|
|
6034
|
+
--x-size-gap-list-08: var(--x-size-base-08);
|
|
6035
|
+
--x-size-gap-list-09: var(--x-size-base-09);
|
|
6036
|
+
--x-size-gap-list-10: var(--x-size-base-10);
|
|
6037
|
+
--x-size-gap-list-11: var(--x-size-base-11);
|
|
6038
|
+
--x-size-gap-list-12: var(--x-size-base-12);
|
|
6039
|
+
--x-size-gap-list-13: var(--x-size-base-13);
|
|
6040
|
+
--x-size-gap-list-14: var(--x-size-base-14);
|
|
6041
|
+
--x-size-gap-list-15: var(--x-size-base-15);
|
|
6042
|
+
--x-size-gap-list-16: var(--x-size-base-16);
|
|
6043
|
+
--x-size-gap-list-17: var(--x-size-base-17);
|
|
6044
|
+
--x-size-gap-list-18: var(--x-size-base-18);
|
|
6045
|
+
--x-size-gap-list-19: var(--x-size-base-19);
|
|
6046
|
+
--x-size-gap-list-20: var(--x-size-base-20);
|
|
6047
|
+
}
|
|
6026
6048
|
|
|
6027
6049
|
.x-list--gap-01.x-list {
|
|
6028
6050
|
gap: var(--x-size-gap-list-01);
|
|
@@ -6523,28 +6545,6 @@
|
|
|
6523
6545
|
margin-bottom: var(--x-size-gap-list-20);
|
|
6524
6546
|
}
|
|
6525
6547
|
}
|
|
6526
|
-
:root {
|
|
6527
|
-
--x-size-gap-list-01: var(--x-size-base-01);
|
|
6528
|
-
--x-size-gap-list-02: var(--x-size-base-02);
|
|
6529
|
-
--x-size-gap-list-03: var(--x-size-base-03);
|
|
6530
|
-
--x-size-gap-list-04: var(--x-size-base-04);
|
|
6531
|
-
--x-size-gap-list-05: var(--x-size-base-05);
|
|
6532
|
-
--x-size-gap-list-06: var(--x-size-base-06);
|
|
6533
|
-
--x-size-gap-list-07: var(--x-size-base-07);
|
|
6534
|
-
--x-size-gap-list-08: var(--x-size-base-08);
|
|
6535
|
-
--x-size-gap-list-09: var(--x-size-base-09);
|
|
6536
|
-
--x-size-gap-list-10: var(--x-size-base-10);
|
|
6537
|
-
--x-size-gap-list-11: var(--x-size-base-11);
|
|
6538
|
-
--x-size-gap-list-12: var(--x-size-base-12);
|
|
6539
|
-
--x-size-gap-list-13: var(--x-size-base-13);
|
|
6540
|
-
--x-size-gap-list-14: var(--x-size-base-14);
|
|
6541
|
-
--x-size-gap-list-15: var(--x-size-base-15);
|
|
6542
|
-
--x-size-gap-list-16: var(--x-size-base-16);
|
|
6543
|
-
--x-size-gap-list-17: var(--x-size-base-17);
|
|
6544
|
-
--x-size-gap-list-18: var(--x-size-base-18);
|
|
6545
|
-
--x-size-gap-list-19: var(--x-size-base-19);
|
|
6546
|
-
--x-size-gap-list-20: var(--x-size-base-20);
|
|
6547
|
-
}
|
|
6548
6548
|
:root {
|
|
6549
6549
|
--x-string-flow-list: column nowrap;
|
|
6550
6550
|
--x-size-padding-list: 0;
|
|
@@ -7064,13 +7064,6 @@
|
|
|
7064
7064
|
--x-size-border-radius-bottom-right-input-pill: var(--x-size-border-radius-input-pill);
|
|
7065
7065
|
--x-size-border-radius-bottom-left-input-pill: var(--x-size-border-radius-input-pill);
|
|
7066
7066
|
}
|
|
7067
|
-
:root {
|
|
7068
|
-
--x-size-border-radius-input-pill: var(--x-size-border-radius-base-pill);
|
|
7069
|
-
--x-size-border-radius-top-left-input-pill: var(--x-size-border-radius-input-pill);
|
|
7070
|
-
--x-size-border-radius-top-right-input-pill: var(--x-size-border-radius-input-pill);
|
|
7071
|
-
--x-size-border-radius-bottom-right-input-pill: var(--x-size-border-radius-input-pill);
|
|
7072
|
-
--x-size-border-radius-bottom-left-input-pill: var(--x-size-border-radius-input-pill);
|
|
7073
|
-
}
|
|
7074
7067
|
|
|
7075
7068
|
.x-input--pill.x-input,
|
|
7076
7069
|
.x-input--pill .x-input {
|
|
@@ -7080,6 +7073,35 @@
|
|
|
7080
7073
|
--x-size-border-radius-bottom-right-input-default: var(--x-size-border-radius-input-pill);
|
|
7081
7074
|
--x-size-border-radius-bottom-left-input-default: var(--x-size-border-radius-input-pill);
|
|
7082
7075
|
}
|
|
7076
|
+
:root {
|
|
7077
|
+
--x-size-border-radius-input-pill: var(--x-size-border-radius-base-pill);
|
|
7078
|
+
--x-size-border-radius-top-left-input-pill: var(--x-size-border-radius-input-pill);
|
|
7079
|
+
--x-size-border-radius-top-right-input-pill: var(--x-size-border-radius-input-pill);
|
|
7080
|
+
--x-size-border-radius-bottom-right-input-pill: var(--x-size-border-radius-input-pill);
|
|
7081
|
+
--x-size-border-radius-bottom-left-input-pill: var(--x-size-border-radius-input-pill);
|
|
7082
|
+
}
|
|
7083
|
+
:root {
|
|
7084
|
+
--x-size-padding-top-input-line: var(--x-size-base-03);
|
|
7085
|
+
--x-size-padding-right-input-line: 0;
|
|
7086
|
+
--x-size-padding-bottom-input-line: var(--x-size-base-03);
|
|
7087
|
+
--x-size-padding-left-input-line: 0;
|
|
7088
|
+
--x-size-border-width-top-input-line: 0;
|
|
7089
|
+
--x-size-border-width-right-input-line: 0;
|
|
7090
|
+
--x-size-border-width-bottom-input-line: var(--x-size-border-width-base);
|
|
7091
|
+
--x-size-border-width-left-input-line: 0;
|
|
7092
|
+
}
|
|
7093
|
+
|
|
7094
|
+
.x-input--line .x-input,
|
|
7095
|
+
.x-input--line.x-input {
|
|
7096
|
+
--x-size-padding-top-input-default: var(--x-size-padding-top-input-line);
|
|
7097
|
+
--x-size-padding-right-input-default: var(--x-size-padding-right-input-line);
|
|
7098
|
+
--x-size-padding-bottom-input-default: var(--x-size-padding-bottom-input-line);
|
|
7099
|
+
--x-size-padding-left-input-default: var(--x-size-padding-left-input-line);
|
|
7100
|
+
--x-size-border-width-top-input-default: var(--x-size-border-width-top-input-line);
|
|
7101
|
+
--x-size-border-width-right-input-default: var(--x-size-border-width-right-input-line);
|
|
7102
|
+
--x-size-border-width-bottom-input-default: var(--x-size-border-width-bottom-input-line);
|
|
7103
|
+
--x-size-border-width-left-input-default: var(--x-size-border-width-left-input-line);
|
|
7104
|
+
}
|
|
7083
7105
|
:root {
|
|
7084
7106
|
--x-size-padding-top-input-line: var(--x-size-base-03);
|
|
7085
7107
|
--x-size-padding-right-input-line: 0;
|
|
@@ -7118,28 +7140,6 @@
|
|
|
7118
7140
|
--x-size-line-height-input-placeholder-default: var(--x-size-line-height-input-default);
|
|
7119
7141
|
--x-number-font-weight-input-placeholder-default: var(--x-number-font-weight-input-default);
|
|
7120
7142
|
}
|
|
7121
|
-
:root {
|
|
7122
|
-
--x-size-padding-top-input-line: var(--x-size-base-03);
|
|
7123
|
-
--x-size-padding-right-input-line: 0;
|
|
7124
|
-
--x-size-padding-bottom-input-line: var(--x-size-base-03);
|
|
7125
|
-
--x-size-padding-left-input-line: 0;
|
|
7126
|
-
--x-size-border-width-top-input-line: 0;
|
|
7127
|
-
--x-size-border-width-right-input-line: 0;
|
|
7128
|
-
--x-size-border-width-bottom-input-line: var(--x-size-border-width-base);
|
|
7129
|
-
--x-size-border-width-left-input-line: 0;
|
|
7130
|
-
}
|
|
7131
|
-
|
|
7132
|
-
.x-input--line .x-input,
|
|
7133
|
-
.x-input--line.x-input {
|
|
7134
|
-
--x-size-padding-top-input-default: var(--x-size-padding-top-input-line);
|
|
7135
|
-
--x-size-padding-right-input-default: var(--x-size-padding-right-input-line);
|
|
7136
|
-
--x-size-padding-bottom-input-default: var(--x-size-padding-bottom-input-line);
|
|
7137
|
-
--x-size-padding-left-input-default: var(--x-size-padding-left-input-line);
|
|
7138
|
-
--x-size-border-width-top-input-default: var(--x-size-border-width-top-input-line);
|
|
7139
|
-
--x-size-border-width-right-input-default: var(--x-size-border-width-right-input-line);
|
|
7140
|
-
--x-size-border-width-bottom-input-default: var(--x-size-border-width-bottom-input-line);
|
|
7141
|
-
--x-size-border-width-left-input-default: var(--x-size-border-width-left-input-line);
|
|
7142
|
-
}
|
|
7143
7143
|
:root {
|
|
7144
7144
|
--x-color-background-input-default: var(--x-color-base-neutral-100);
|
|
7145
7145
|
--x-color-border-input-default: var(--x-color-base-neutral-70);
|
|
@@ -7318,15 +7318,15 @@
|
|
|
7318
7318
|
--x-size-width-icon-l: var(--x-size-base-06);
|
|
7319
7319
|
--x-size-height-icon-l: var(--x-size-base-06);
|
|
7320
7320
|
}
|
|
7321
|
+
:root {
|
|
7322
|
+
--x-size-width-icon-l: var(--x-size-base-06);
|
|
7323
|
+
--x-size-height-icon-l: var(--x-size-base-06);
|
|
7324
|
+
}
|
|
7321
7325
|
|
|
7322
7326
|
.x-icon--l {
|
|
7323
7327
|
--x-size-width-icon-default: var(--x-size-width-icon-l);
|
|
7324
7328
|
--x-size-height-icon-default: var(--x-size-height-icon-l);
|
|
7325
7329
|
}
|
|
7326
|
-
:root {
|
|
7327
|
-
--x-size-width-icon-l: var(--x-size-base-06);
|
|
7328
|
-
--x-size-height-icon-l: var(--x-size-base-06);
|
|
7329
|
-
}
|
|
7330
7330
|
:root {
|
|
7331
7331
|
--x-color-stroke-icon-default: currentColor;
|
|
7332
7332
|
--x-color-fill-icon-default: none;
|
|
@@ -7336,6 +7336,11 @@
|
|
|
7336
7336
|
--x-string-stroke-linejoin-icon-default: mitter;
|
|
7337
7337
|
--x-size-stroke-width-icon-default: 1px;
|
|
7338
7338
|
}
|
|
7339
|
+
:root {
|
|
7340
|
+
--x-size-padding-grid: 0;
|
|
7341
|
+
--x-size-gap-grid: var(--x-size-base-03);
|
|
7342
|
+
--x-size-min-width-grid-item: 150px;
|
|
7343
|
+
}
|
|
7339
7344
|
:root {
|
|
7340
7345
|
--x-color-stroke-icon-default: currentColor;
|
|
7341
7346
|
--x-color-fill-icon-default: none;
|
|
@@ -7371,11 +7376,6 @@
|
|
|
7371
7376
|
--x-size-gap-grid: var(--x-size-base-03);
|
|
7372
7377
|
--x-size-min-width-grid-item: 150px;
|
|
7373
7378
|
}
|
|
7374
|
-
:root {
|
|
7375
|
-
--x-size-padding-grid: 0;
|
|
7376
|
-
--x-size-gap-grid: var(--x-size-base-03);
|
|
7377
|
-
--x-size-min-width-grid-item: 150px;
|
|
7378
|
-
}
|
|
7379
7379
|
|
|
7380
7380
|
.x-grid-list {
|
|
7381
7381
|
margin: 0;
|
|
@@ -7397,6 +7397,12 @@
|
|
|
7397
7397
|
.x-grid-list--cols-auto .x-grid-list__item {
|
|
7398
7398
|
min-width: var(--x-size-min-width-grid-item);
|
|
7399
7399
|
}
|
|
7400
|
+
.x-filter--justified.x-filter > *:last-child:not(.x-filter__label),
|
|
7401
|
+
.x-filter--justified.x-facet-filter > *:last-child:not(.x-filter__label),
|
|
7402
|
+
.x-filter--justified .x-filter > *:last-child:not(.x-filter__label),
|
|
7403
|
+
.x-filter--justified .x-facet-filter > *:last-child:not(.x-filter__label) {
|
|
7404
|
+
margin-left: auto;
|
|
7405
|
+
}
|
|
7400
7406
|
:root {
|
|
7401
7407
|
--x-size-margin-filter-children: 0;
|
|
7402
7408
|
--x-size-padding-top-filter-children: 0;
|
|
@@ -7404,12 +7410,6 @@
|
|
|
7404
7410
|
--x-size-padding-bottom-filter-children: 0;
|
|
7405
7411
|
--x-size-padding-left-filter-children: var(--x-size-base-05);
|
|
7406
7412
|
}
|
|
7407
|
-
.x-filter--justified.x-filter > *:last-child:not(.x-filter__label),
|
|
7408
|
-
.x-filter--justified.x-facet-filter > *:last-child:not(.x-filter__label),
|
|
7409
|
-
.x-filter--justified .x-filter > *:last-child:not(.x-filter__label),
|
|
7410
|
-
.x-filter--justified .x-facet-filter > *:last-child:not(.x-filter__label) {
|
|
7411
|
-
margin-left: auto;
|
|
7412
|
-
}
|
|
7413
7413
|
:root {
|
|
7414
7414
|
--x-size-margin-filter-children: 0;
|
|
7415
7415
|
--x-size-padding-top-filter-children: 0;
|
|
@@ -8029,13 +8029,13 @@
|
|
|
8029
8029
|
:root {
|
|
8030
8030
|
--x-size-width-dropdown-l: 202px;
|
|
8031
8031
|
}
|
|
8032
|
+
:root {
|
|
8033
|
+
--x-size-width-dropdown-l: 202px;
|
|
8034
|
+
}
|
|
8032
8035
|
|
|
8033
8036
|
.x-dropdown.x-dropdown--l {
|
|
8034
8037
|
--x-size-width-dropdown-toggle-default: var(--x-size-width-dropdown-l);
|
|
8035
8038
|
}
|
|
8036
|
-
:root {
|
|
8037
|
-
--x-size-width-dropdown-l: 202px;
|
|
8038
|
-
}
|
|
8039
8039
|
:root {
|
|
8040
8040
|
--x-size-border-radius-dropdown-default: var(--x-size-border-radius-base-none);
|
|
8041
8041
|
--x-size-border-radius-top-left-dropdown-default: var(--x-size-border-radius-dropdown-default);
|
|
@@ -8448,16 +8448,6 @@
|
|
|
8448
8448
|
--x-size-border-width-bottom-button-secondary: var(--x-size-border-width-button-secondary);
|
|
8449
8449
|
--x-size-border-width-left-button-secondary: var(--x-size-border-width-button-secondary);
|
|
8450
8450
|
}
|
|
8451
|
-
:root {
|
|
8452
|
-
--x-color-background-button-secondary: transparent;
|
|
8453
|
-
--x-color-border-button-secondary: var(--x-color-border-button-default);
|
|
8454
|
-
--x-color-text-button-secondary: var(--x-color-border-button-default);
|
|
8455
|
-
--x-size-border-width-button-secondary: var(--x-size-border-width-base);
|
|
8456
|
-
--x-size-border-width-top-button-secondary: var(--x-size-border-width-button-secondary);
|
|
8457
|
-
--x-size-border-width-right-button-secondary: var(--x-size-border-width-button-secondary);
|
|
8458
|
-
--x-size-border-width-bottom-button-secondary: var(--x-size-border-width-button-secondary);
|
|
8459
|
-
--x-size-border-width-left-button-secondary: var(--x-size-border-width-button-secondary);
|
|
8460
|
-
}
|
|
8461
8451
|
|
|
8462
8452
|
.x-button--secondary.x-button,
|
|
8463
8453
|
.x-button--secondary .x-button {
|
|
@@ -8476,6 +8466,23 @@
|
|
|
8476
8466
|
--x-size-border-radius-bottom-right-button-round: var(--x-size-border-radius-button-round);
|
|
8477
8467
|
--x-size-border-radius-bottom-left-button-round: var(--x-size-border-radius-button-round);
|
|
8478
8468
|
}
|
|
8469
|
+
:root {
|
|
8470
|
+
--x-color-background-button-secondary: transparent;
|
|
8471
|
+
--x-color-border-button-secondary: var(--x-color-border-button-default);
|
|
8472
|
+
--x-color-text-button-secondary: var(--x-color-border-button-default);
|
|
8473
|
+
--x-size-border-width-button-secondary: var(--x-size-border-width-base);
|
|
8474
|
+
--x-size-border-width-top-button-secondary: var(--x-size-border-width-button-secondary);
|
|
8475
|
+
--x-size-border-width-right-button-secondary: var(--x-size-border-width-button-secondary);
|
|
8476
|
+
--x-size-border-width-bottom-button-secondary: var(--x-size-border-width-button-secondary);
|
|
8477
|
+
--x-size-border-width-left-button-secondary: var(--x-size-border-width-button-secondary);
|
|
8478
|
+
}
|
|
8479
|
+
:root {
|
|
8480
|
+
--x-size-border-radius-button-round: var(--x-size-border-radius-base-pill);
|
|
8481
|
+
--x-size-border-radius-top-left-button-round: var(--x-size-border-radius-button-round);
|
|
8482
|
+
--x-size-border-radius-top-right-button-round: var(--x-size-border-radius-button-round);
|
|
8483
|
+
--x-size-border-radius-bottom-right-button-round: var(--x-size-border-radius-button-round);
|
|
8484
|
+
--x-size-border-radius-bottom-left-button-round: var(--x-size-border-radius-button-round);
|
|
8485
|
+
}
|
|
8479
8486
|
|
|
8480
8487
|
.x-button--round.x-button,
|
|
8481
8488
|
.x-button--round .x-button {
|
|
@@ -8494,23 +8501,6 @@
|
|
|
8494
8501
|
--x-size-padding-left-button-default: 0;
|
|
8495
8502
|
--x-size-padding-right-button-default: 0;
|
|
8496
8503
|
}
|
|
8497
|
-
:root {
|
|
8498
|
-
--x-size-border-radius-button-round: var(--x-size-border-radius-base-pill);
|
|
8499
|
-
--x-size-border-radius-top-left-button-round: var(--x-size-border-radius-button-round);
|
|
8500
|
-
--x-size-border-radius-top-right-button-round: var(--x-size-border-radius-button-round);
|
|
8501
|
-
--x-size-border-radius-bottom-right-button-round: var(--x-size-border-radius-button-round);
|
|
8502
|
-
--x-size-border-radius-bottom-left-button-round: var(--x-size-border-radius-button-round);
|
|
8503
|
-
}
|
|
8504
|
-
:root {
|
|
8505
|
-
--x-color-background-button-primary: var(--x-color-background-button-default);
|
|
8506
|
-
--x-color-border-button-primary: var(--x-color-border-button-default);
|
|
8507
|
-
--x-color-text-button-primary: var(--x-color-text-button-default);
|
|
8508
|
-
--x-size-border-width-button-primary: var(--x-size-border-width-base);
|
|
8509
|
-
--x-size-border-width-top-button-primary: var(--x-size-border-width-button-primary);
|
|
8510
|
-
--x-size-border-width-right-button-primary: var(--x-size-border-width-button-primary);
|
|
8511
|
-
--x-size-border-width-bottom-button-primary: var(--x-size-border-width-button-primary);
|
|
8512
|
-
--x-size-border-width-left-button-primary: var(--x-size-border-width-button-primary);
|
|
8513
|
-
}
|
|
8514
8504
|
:root {
|
|
8515
8505
|
--x-color-background-button-primary: var(--x-color-background-button-default);
|
|
8516
8506
|
--x-color-border-button-primary: var(--x-color-border-button-default);
|
|
@@ -8532,6 +8522,16 @@
|
|
|
8532
8522
|
--x-size-border-width-bottom-button-default: var(--x-size-border-width-bottom-button-primary);
|
|
8533
8523
|
--x-size-border-width-left-button-default: var(--x-size-border-width-left-button-primary);
|
|
8534
8524
|
}
|
|
8525
|
+
:root {
|
|
8526
|
+
--x-color-background-button-primary: var(--x-color-background-button-default);
|
|
8527
|
+
--x-color-border-button-primary: var(--x-color-border-button-default);
|
|
8528
|
+
--x-color-text-button-primary: var(--x-color-text-button-default);
|
|
8529
|
+
--x-size-border-width-button-primary: var(--x-size-border-width-base);
|
|
8530
|
+
--x-size-border-width-top-button-primary: var(--x-size-border-width-button-primary);
|
|
8531
|
+
--x-size-border-width-right-button-primary: var(--x-size-border-width-button-primary);
|
|
8532
|
+
--x-size-border-width-bottom-button-primary: var(--x-size-border-width-button-primary);
|
|
8533
|
+
--x-size-border-width-left-button-primary: var(--x-size-border-width-button-primary);
|
|
8534
|
+
}
|
|
8535
8535
|
:root {
|
|
8536
8536
|
--x-size-border-radius-button-pill: var(--x-size-border-radius-base-pill);
|
|
8537
8537
|
--x-size-border-radius-top-left-button-pill: var(--x-size-border-radius-button-pill);
|
|
@@ -8703,16 +8703,6 @@
|
|
|
8703
8703
|
--x-size-border-radius-bottom-right-button-card: var(--x-size-border-radius-button-card);
|
|
8704
8704
|
--x-size-border-radius-bottom-left-button-card: var(--x-size-border-radius-button-card);
|
|
8705
8705
|
}
|
|
8706
|
-
:root {
|
|
8707
|
-
--x-color-background-badge-default: var(--x-color-base-neutral-10);
|
|
8708
|
-
--x-color-text-badge-default: var(--x-color-base-neutral-100);
|
|
8709
|
-
--x-color-border-badge-default: var(--x-color-base-neutral-10);
|
|
8710
|
-
--x-size-border-radius-badge-default: var(--x-size-border-radius-base-pill);
|
|
8711
|
-
--x-size-border-width-badge-default: 0;
|
|
8712
|
-
--x-size-width-badge-default: 1.5em;
|
|
8713
|
-
--x-number-font-weight-badge-default: var(--x-number-font-weight-base-regular);
|
|
8714
|
-
--x-size-font-badge-default: var(--x-size-font-base-xs);
|
|
8715
|
-
}
|
|
8716
8706
|
:root {
|
|
8717
8707
|
--x-size-border-radius-button-card: var(--x-size-border-radius-base-s);
|
|
8718
8708
|
--x-size-border-radius-top-left-button-card: var(--x-size-border-radius-button-card);
|
|
@@ -8745,6 +8735,16 @@
|
|
|
8745
8735
|
--x-number-font-weight-badge-default: var(--x-number-font-weight-base-regular);
|
|
8746
8736
|
--x-size-font-badge-default: var(--x-size-font-base-xs);
|
|
8747
8737
|
}
|
|
8738
|
+
:root {
|
|
8739
|
+
--x-color-background-badge-default: var(--x-color-base-neutral-10);
|
|
8740
|
+
--x-color-text-badge-default: var(--x-color-base-neutral-100);
|
|
8741
|
+
--x-color-border-badge-default: var(--x-color-base-neutral-10);
|
|
8742
|
+
--x-size-border-radius-badge-default: var(--x-size-border-radius-base-pill);
|
|
8743
|
+
--x-size-border-width-badge-default: 0;
|
|
8744
|
+
--x-size-width-badge-default: 1.5em;
|
|
8745
|
+
--x-number-font-weight-badge-default: var(--x-number-font-weight-base-regular);
|
|
8746
|
+
--x-size-font-badge-default: var(--x-size-font-base-xs);
|
|
8747
|
+
}
|
|
8748
8748
|
|
|
8749
8749
|
[dir="ltr"] .x-badge {
|
|
8750
8750
|
right: calc(var(--x-size-width-badge-default) / 4);
|
|
@@ -8784,6 +8784,19 @@
|
|
|
8784
8784
|
.x-badge-container {
|
|
8785
8785
|
position: relative;
|
|
8786
8786
|
}
|
|
8787
|
+
:root {
|
|
8788
|
+
--x-color-base-lead: #243d48;
|
|
8789
|
+
--x-color-base-auxiliary: #bfe1ec;
|
|
8790
|
+
--x-color-base-neutral-10: #1a1a1a;
|
|
8791
|
+
--x-color-base-neutral-35: #595959;
|
|
8792
|
+
--x-color-base-neutral-70: #b3b3b3;
|
|
8793
|
+
--x-color-base-neutral-95: #f2f2f2;
|
|
8794
|
+
--x-color-base-neutral-100: #ffffff;
|
|
8795
|
+
--x-color-base-accent: #0086b2;
|
|
8796
|
+
--x-color-base-enable: #00705c;
|
|
8797
|
+
--x-color-base-disable: #e11f26;
|
|
8798
|
+
--x-color-base-transparent: transparent;
|
|
8799
|
+
}
|
|
8787
8800
|
:root {
|
|
8788
8801
|
--x-size-base-01: 2px;
|
|
8789
8802
|
--x-size-base-02: 4px;
|
|
@@ -8806,19 +8819,6 @@
|
|
|
8806
8819
|
--x-size-base-19: 280px;
|
|
8807
8820
|
--x-size-base-20: 344px;
|
|
8808
8821
|
}
|
|
8809
|
-
:root {
|
|
8810
|
-
--x-color-base-lead: #243d48;
|
|
8811
|
-
--x-color-base-auxiliary: #bfe1ec;
|
|
8812
|
-
--x-color-base-neutral-10: #1a1a1a;
|
|
8813
|
-
--x-color-base-neutral-35: #595959;
|
|
8814
|
-
--x-color-base-neutral-70: #b3b3b3;
|
|
8815
|
-
--x-color-base-neutral-95: #f2f2f2;
|
|
8816
|
-
--x-color-base-neutral-100: #ffffff;
|
|
8817
|
-
--x-color-base-accent: #0086b2;
|
|
8818
|
-
--x-color-base-enable: #00705c;
|
|
8819
|
-
--x-color-base-disable: #e11f26;
|
|
8820
|
-
--x-color-base-transparent: transparent;
|
|
8821
|
-
}
|
|
8822
8822
|
:root {
|
|
8823
8823
|
--x-size-border-radius-base-none: 0;
|
|
8824
8824
|
--x-size-border-radius-base-s: var(--x-size-base-02);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-modal.vue.js","sources":["../../../../src/components/modals/base-modal.vue"],"sourcesContent":["<template>\n <div v-show=\"isWaitingForLeave || open\" ref=\"modalRef\" class=\"x-modal\" data-test=\"modal\">\n <component\n :is=\"animation\"\n @before-leave=\"isWaitingForLeave = true\"\n @after-leave=\"isWaitingForLeave = false\"\n >\n <div\n v-if=\"open\"\n ref=\"modalContentRef\"\n class=\"x-modal__content\"\n data-test=\"modal-content\"\n role=\"dialog\"\n :class=\"contentClass\"\n >\n <!-- @slot (Required) Modal container content -->\n <slot />\n </div>\n </component>\n <component :is=\"overlayAnimation\">\n <div\n v-if=\"open\"\n @click=\"emitOverlayClicked\"\n @keydown=\"emitOverlayClicked\"\n class=\"x-modal__overlay\"\n :class=\"overlayClass\"\n data-test=\"modal-overlay\"\n />\n </component>\n </div>\n</template>\n\n<script lang=\"ts\">\n import { defineComponent, nextTick, onBeforeUnmount, onMounted, ref, watch } from 'vue';\n import { useDebounce } from '../../composables';\n import { AnimationProp } from '../../types';\n import { getTargetElement, FOCUSABLE_SELECTORS } from '../../utils';\n import { Fade, NoAnimation } from '../animations';\n\n /**\n * Base component with no XPlugin dependencies that serves as a utility for constructing more\n * complex modals.\n *\n * @public\n */\n export default defineComponent({\n name: 'BaseModal',\n props: {\n /** Determines if the modal is open or not. */\n open: {\n type: Boolean,\n required: true\n },\n /**\n * Determines if the focused element changes to one inside the modal when it opens. Either the\n * first element with a positive tabindex or just the first focusable element.\n */\n focusOnOpen: {\n type: Boolean,\n default: true\n },\n /**\n * The reference selector of a DOM element to use as reference to position the modal.\n * This selector can be an ID or a class, if it is a class, it will use the first\n * element that matches.\n */\n referenceSelector: String,\n /** Animation to use for opening/closing the modal.This animation only affects the content. */\n animation: {\n type: AnimationProp,\n default: () => NoAnimation\n },\n /**\n * Animation to use for the overlay (backdrop) part of the modal. By default, it uses\n * a fade transition.\n */\n overlayAnimation: {\n type: AnimationProp,\n default: () => Fade\n },\n /** Class inherited by content element. */\n contentClass: String,\n /** Class inherited by overlay element. */\n overlayClass: String\n },\n emits: ['click:overlay', 'focusin:body'],\n setup(props, { emit }) {\n /** Reference to the modal element in the DOM. */\n const modalRef = ref<HTMLDivElement>();\n /** Reference to the modal content element in the DOM. */\n const modalContentRef = ref<HTMLDivElement>();\n\n /** The previous value of the body overflow style. */\n const previousBodyOverflow = ref('');\n /** The previous value of the HTML element overflow style. */\n const previousHTMLOverflow = ref('');\n /** Boolean to delay the leave animation until it has completed. */\n const isWaitingForLeave = ref(false);\n /** The reference element to use to find the modal's position. */\n let referenceElement: HTMLElement;\n\n /** Disables the scroll of both the body and the window. */\n function disableScroll() {\n previousBodyOverflow.value = document.body.style.overflow;\n previousHTMLOverflow.value = document.documentElement.style.overflow;\n document.body.style.overflow = document.documentElement.style.overflow = 'hidden';\n }\n\n /** Restores the scroll of both the body and the window. */\n function enableScroll() {\n document.body.style.overflow = previousBodyOverflow.value;\n document.documentElement.style.overflow = previousHTMLOverflow.value;\n }\n\n /**\n * Emits the `click:overlay` event if the click has been triggered in the overlay layer.\n *\n * @param event - The click event.\n */\n function emitOverlayClicked(event: Event) {\n emit('click:overlay', event);\n }\n\n /**\n * Emits the `focusin:body` event if a focus event has been triggered outside the modal.\n *\n * @param event - The focusin event.\n */\n function emitFocusInBody(event: FocusEvent) {\n if (!modalContentRef.value?.contains(getTargetElement(event))) {\n emit('focusin:body', event);\n }\n }\n\n /**\n * Adds listeners to the body element ot detect if the modal should be closed.\n *\n * @remarks TODO find a better solution and remove the timeout\n * To avoid emit the focusin on opening X that provokes closing it immediately.\n * This is because this event was emitted after the open of main modal when the user clicks\n * on the customer website search box (focus event). This way we avoid add the listener before\n * the open and the avoid the event that provokes the close.\n */\n function addBodyListeners() {\n setTimeout(() => {\n document.body.addEventListener('focusin', emitFocusInBody);\n });\n }\n\n /** Removes the body listeners. */\n function removeBodyListeners() {\n document.body.removeEventListener('focusin', emitFocusInBody);\n }\n\n /**\n * Sets the focused element to the first element either the first element with a positive\n * tabindex or, if there isn't any, the first focusable element inside the modal.\n */\n function setFocus() {\n const candidates: HTMLElement[] = Array.from(\n modalContentRef.value?.querySelectorAll(FOCUSABLE_SELECTORS) ?? []\n );\n const element = candidates.find(element => element.tabIndex) ?? candidates[0];\n element?.focus();\n }\n\n /**\n * Syncs the body to the open state of the modal, adding or removing styles and listeners.\n *\n * @remarks nextTick() to wait for `modalContentRef` to be updated to look for focusable\n * candidates inside.\n *\n * @param isOpen - True when the modal is opened.\n */\n async function syncBody(isOpen: boolean) {\n if (isOpen) {\n disableScroll();\n addBodyListeners();\n if (props.focusOnOpen) {\n await nextTick();\n setFocus();\n }\n } else {\n enableScroll();\n removeBodyListeners();\n }\n }\n\n /**\n * Updates the position of the modal setting the top of the element depending\n * on the selector. The modal will be placed under this selector.\n */\n const debouncedUpdatePosition = useDebounce(\n () => {\n const { height, y } = referenceElement?.getBoundingClientRect() ?? { height: 0, y: 0 };\n modalRef.value!.style.top = `${height + y}px`;\n modalRef.value!.style.bottom = '0';\n modalRef.value!.style.height = 'auto';\n },\n 100,\n { leading: true }\n );\n\n let resizeObserver: ResizeObserver;\n\n onMounted(() => {\n watch(() => props.open, syncBody);\n if (props.open) {\n syncBody(true);\n }\n\n resizeObserver = new ResizeObserver(debouncedUpdatePosition);\n\n if (props.referenceSelector) {\n const element = document.querySelector(props.referenceSelector) as HTMLElement;\n if (element) {\n referenceElement = element;\n resizeObserver.observe(element);\n }\n }\n });\n\n onBeforeUnmount(() => {\n if (props.open) {\n removeBodyListeners();\n enableScroll();\n }\n resizeObserver.disconnect();\n });\n\n return {\n emitOverlayClicked,\n isWaitingForLeave,\n modalContentRef,\n modalRef\n };\n }\n });\n</script>\n\n<style lang=\"css\" scoped>\n .x-modal {\n position: fixed;\n top: 0;\n left: 0;\n display: flex;\n align-items: flex-start;\n justify-content: flex-start;\n width: 100%;\n height: 100%;\n z-index: 1;\n }\n\n .x-modal__content {\n display: flex;\n flex-flow: column nowrap;\n z-index: 1;\n }\n\n .x-modal__overlay {\n width: 100%;\n height: 100%;\n position: absolute;\n background-color: rgb(0, 0, 0);\n opacity: 0.3;\n }\n</style>\n\n<docs lang=\"mdx\">\n## Examples\n\nThe `BaseModal` is a simple component that serves to create complex modals. Its open state has to be\npassed via prop. There is a prop, `referenceSelector`, used to place the modal under some element\ninstead of set the top of the element directly. It also accepts an animation to use for opening &\nclosing.\n\nIt emits a `click:overlay` event when any part out of the content is clicked, but only if the modal\nis open.\n\n```vue\n<template>\n <div>\n <button @click=\"open = true\">Open modal</button>\n <BaseModal\n :animation=\"fadeAndSlide\"\n :open=\"open\"\n @click:overlay=\"open = false\"\n referenceSelector=\".header\"\n >\n <h1>Hello</h1>\n <p>The modal is working</p>\n <button @click=\"open = false\">Close modal</button>\n </BaseModal>\n </div>\n</template>\n\n<script>\n import { BaseModal, FadeAndSlide } from '@empathyco/x-components';\n import Vue from 'vue';\n\n Vue.component('fadeAndSlide', FadeAndSlide);\n\n export default {\n components: {\n BaseModal\n },\n data() {\n return {\n open: false\n };\n }\n };\n</script>\n```\n\n### Customized usage\n\n#### Customizing the content with classes\n\nThe `contentClass` prop can be used to add classes to the modal content.\n\n```vue\n<template>\n <div>\n <button @click=\"open = true\">Open modal</button>\n <BaseModal\n :animation=\"fadeAndSlide\"\n :open=\"open\"\n @click:overlay=\"open = false\"\n referenceSelector=\".header\"\n contentClass=\"x-bg-neutral-75\"\n >\n <h1>Hello</h1>\n <p>The modal is working</p>\n <button @click=\"open = false\">Close modal</button>\n </BaseModal>\n </div>\n</template>\n\n<script>\n import { BaseModal, FadeAndSlide } from '@empathyco/x-components';\n import Vue from 'vue';\n\n Vue.component('fadeAndSlide', FadeAndSlide);\n\n export default {\n components: {\n BaseModal\n },\n data() {\n return {\n open: false\n };\n }\n };\n</script>\n```\n\n#### Customizing the overlay with classes\n\nThe `overlayClass` prop can be used to add classes to the modal overlay.\n\n```vue\n<template>\n <div>\n <button @click=\"open = true\">Open modal</button>\n <BaseModal\n :animation=\"fadeAndSlide\"\n :open=\"open\"\n @click:overlay=\"open = false\"\n referenceSelector=\".header\"\n overlayClass=\"x-bg-neutral-75\"\n >\n <h1>Hello</h1>\n <p>The modal is working</p>\n <button @click=\"open = false\">Close modal</button>\n </BaseModal>\n </div>\n</template>\n\n<script>\n import { BaseModal, FadeAndSlide } from '@empathyco/x-components';\n import Vue from 'vue';\n\n Vue.component('fadeAndSlide', FadeAndSlide);\n\n export default {\n components: {\n BaseModal\n },\n data() {\n return {\n open: false\n };\n }\n };\n</script>\n```\n\n## Vue Events\n\nA list of events that the component will emit:\n\n- `click:overlay`: the event is emitted after the user clicks any part out of the content but only\n if the modal is open. The event payload is the mouse event that triggers it.\n- `focusin:body`: the event is emitted after the user focus in any part out of the content but only\n if the modal is open. The event payload is the focus event that triggers it.\n</docs>\n"],"names":["animation","_withDirectives","_openBlock","_createElementBlock","isWaitingForLeave","_createBlock","_withCtx","_normalizeClass","_renderSlot","_createCommentVNode","_resolveDynamicComponent","overlayClass"],"mappings":";;;;;MACyD,UAAe,GAAA;AAAA,EAAC,GAAA,EAAA,UAAA;AAAA,EAAA,KAAA,EAAA,SAAA;;;AACrE,SAAA,WAAA,CAAA,IAAA,EAAA,MAAA,EAFJ,MAGWA,EAAAA,MAAAA,EAAAA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AAA,EAAA,IAAA,EAAA;AAAA,QADZ,OAAA,EAAAJ,OAAA,CAAA,MAAA;AAAA,UAAA,IAAA,CApBN,IAsBc,IAAAJ,SAAA,EAAA,EAAAC,kBAAA;AAAA,YAAA,KAAA;AAAA,YAAA;AAAA,cACL,GAAA,EAAA,CAAA;AAAA,cACD,OAAA,EAxBR,MAwBc,CAAA,CAAA,CAAA,KAAA,MAAA,CAAA,CAAA,CAAA,GAAA,CAAA,GAAA,IAAA,KACEQ,IAAY,CAAA,kBAAA,IAAA,IAAA,CAAA,kBAAA,CAAA,GAAA,IAAA,CAAA,CAAA;AAAA,cACpB,SAAA,EAAS,OAAC,CAAe,CAAA,KAAA,MAAA,CAAA,CAAA,CAAA,GAAA,CAAA,GAAA,IAAA,KAAA,IAAA,CAAA,kBAAA,IAAA,IAAA,CAAA,kBAAA,CAAA,GAAA,IAAA,CAAA,CAAA;AAAA,cAAA,KAAA,EAAAJ,cAAA,CAAA,CAAA,kBAAA,EAAA,IAAA,CAAA,YAAA,CAAA,CAAA;AA1BjC,cAAA,WAAA,EAAA,eAAA;AAAA,aAAA;;;;AAAA,WAAA,IAAAE,kBAAA,CAAA,MAAA,EAAA,IAAA,CAAA;AAAA,SAAA,CAAA;;;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"base-modal.vue.js","sources":["../../../../src/components/modals/base-modal.vue"],"sourcesContent":["<template>\n <div v-show=\"isWaitingForLeave || open\" ref=\"modalRef\" class=\"x-modal\" data-test=\"modal\">\n <component\n :is=\"animation\"\n @before-leave=\"isWaitingForLeave = true\"\n @after-leave=\"isWaitingForLeave = false\"\n >\n <div\n v-if=\"open\"\n ref=\"modalContentRef\"\n class=\"x-modal__content\"\n data-test=\"modal-content\"\n role=\"dialog\"\n :class=\"contentClass\"\n >\n <!-- @slot (Required) Modal container content -->\n <slot />\n </div>\n </component>\n <component :is=\"overlayAnimation\">\n <div\n v-if=\"open\"\n @click=\"emitOverlayClicked\"\n @keydown=\"emitOverlayClicked\"\n class=\"x-modal__overlay\"\n :class=\"overlayClass\"\n data-test=\"modal-overlay\"\n />\n </component>\n </div>\n</template>\n\n<script lang=\"ts\">\n import { defineComponent, nextTick, onBeforeUnmount, onMounted, ref, watch } from 'vue';\n import { useDebounce } from '../../composables';\n import { AnimationProp } from '../../types';\n import { getTargetElement, FOCUSABLE_SELECTORS } from '../../utils';\n import { Fade, NoAnimation } from '../animations';\n\n /**\n * Base component with no XPlugin dependencies that serves as a utility for constructing more\n * complex modals.\n *\n * @public\n */\n export default defineComponent({\n name: 'BaseModal',\n props: {\n /** Determines if the modal is open or not. */\n open: {\n type: Boolean,\n required: true\n },\n /**\n * Determines if the focused element changes to one inside the modal when it opens. Either the\n * first element with a positive tabindex or just the first focusable element.\n */\n focusOnOpen: {\n type: Boolean,\n default: true\n },\n /**\n * The reference selector of a DOM element to use as reference to position the modal.\n * This selector can be an ID or a class, if it is a class, it will use the first\n * element that matches.\n */\n referenceSelector: String,\n /** Animation to use for opening/closing the modal.This animation only affects the content. */\n animation: {\n type: AnimationProp,\n default: () => NoAnimation\n },\n /**\n * Animation to use for the overlay (backdrop) part of the modal. By default, it uses\n * a fade transition.\n */\n overlayAnimation: {\n type: AnimationProp,\n default: () => Fade\n },\n /** Class inherited by content element. */\n contentClass: String,\n /** Class inherited by overlay element. */\n overlayClass: String\n },\n emits: ['click:overlay', 'focusin:body'],\n setup(props, { emit }) {\n /** Reference to the modal element in the DOM. */\n const modalRef = ref<HTMLDivElement>();\n /** Reference to the modal content element in the DOM. */\n const modalContentRef = ref<HTMLDivElement>();\n\n /** The previous value of the body overflow style. */\n const previousBodyOverflow = ref('');\n /** The previous value of the HTML element overflow style. */\n const previousHTMLOverflow = ref('');\n /** Boolean to delay the leave animation until it has completed. */\n const isWaitingForLeave = ref(false);\n /** The reference element to use to find the modal's position. */\n let referenceElement: HTMLElement | undefined;\n\n /** Disables the scroll of both the body and the window. */\n function disableScroll() {\n previousBodyOverflow.value = document.body.style.overflow;\n previousHTMLOverflow.value = document.documentElement.style.overflow;\n document.body.style.overflow = document.documentElement.style.overflow = 'hidden';\n }\n\n /** Restores the scroll of both the body and the window. */\n function enableScroll() {\n document.body.style.overflow = previousBodyOverflow.value;\n document.documentElement.style.overflow = previousHTMLOverflow.value;\n }\n\n /**\n * Emits the `click:overlay` event if the click has been triggered in the overlay layer.\n *\n * @param event - The click event.\n */\n function emitOverlayClicked(event: Event) {\n emit('click:overlay', event);\n }\n\n /**\n * Emits the `focusin:body` event if a focus event has been triggered outside the modal.\n *\n * @param event - The focusin event.\n */\n function emitFocusInBody(event: FocusEvent) {\n if (!modalContentRef.value?.contains(getTargetElement(event))) {\n emit('focusin:body', event);\n }\n }\n\n /**\n * Adds listeners to the body element ot detect if the modal should be closed.\n *\n * @remarks TODO find a better solution and remove the timeout\n * To avoid emit the focusin on opening X that provokes closing it immediately.\n * This is because this event was emitted after the open of main modal when the user clicks\n * on the customer website search box (focus event). This way we avoid add the listener before\n * the open and the avoid the event that provokes the close.\n */\n function addBodyListeners() {\n setTimeout(() => {\n document.body.addEventListener('focusin', emitFocusInBody);\n });\n }\n\n /** Removes the body listeners. */\n function removeBodyListeners() {\n document.body.removeEventListener('focusin', emitFocusInBody);\n }\n\n /**\n * Sets the focused element to the first element either the first element with a positive\n * tabindex or, if there isn't any, the first focusable element inside the modal.\n */\n function setFocus() {\n const candidates: HTMLElement[] = Array.from(\n modalContentRef.value?.querySelectorAll(FOCUSABLE_SELECTORS) ?? []\n );\n const element = candidates.find(element => element.tabIndex) ?? candidates[0];\n element?.focus();\n }\n\n /**\n * Syncs the body to the open state of the modal, adding or removing styles and listeners.\n *\n * @remarks nextTick() to wait for `modalContentRef` to be updated to look for focusable\n * candidates inside.\n *\n * @param isOpen - True when the modal is opened.\n */\n async function syncBody(isOpen: boolean) {\n if (isOpen) {\n disableScroll();\n addBodyListeners();\n if (props.focusOnOpen) {\n await nextTick();\n setFocus();\n }\n } else {\n enableScroll();\n removeBodyListeners();\n }\n }\n\n /**\n * Updates the position of the modal setting the top of the element depending\n * on the selector. The modal will be placed under this selector.\n */\n const debouncedUpdatePosition = useDebounce(\n () => {\n const { height, y } = referenceElement?.getBoundingClientRect() ?? { height: 0, y: 0 };\n modalRef.value!.style.top = `${height + y}px`;\n modalRef.value!.style.bottom = '0';\n modalRef.value!.style.height = 'auto';\n },\n 100,\n { leading: true }\n );\n\n let resizeObserver: ResizeObserver;\n\n onMounted(() => {\n watch(() => props.open, syncBody);\n if (props.open) {\n syncBody(true);\n }\n\n resizeObserver = new ResizeObserver(debouncedUpdatePosition);\n\n watch(\n () => props.referenceSelector,\n () => {\n resizeObserver.disconnect();\n\n if (props.referenceSelector) {\n const element = document.querySelector(props.referenceSelector) as HTMLElement;\n if (element) {\n referenceElement = element;\n resizeObserver.observe(element);\n }\n } else {\n referenceElement = undefined;\n debouncedUpdatePosition();\n }\n },\n { immediate: true }\n );\n });\n\n onBeforeUnmount(() => {\n if (props.open) {\n removeBodyListeners();\n enableScroll();\n }\n resizeObserver.disconnect();\n });\n\n return {\n emitOverlayClicked,\n isWaitingForLeave,\n modalContentRef,\n modalRef\n };\n }\n });\n</script>\n\n<style lang=\"css\" scoped>\n .x-modal {\n position: fixed;\n top: 0;\n left: 0;\n display: flex;\n align-items: flex-start;\n justify-content: flex-start;\n width: 100%;\n height: 100%;\n z-index: 1;\n }\n\n .x-modal__content {\n display: flex;\n flex-flow: column nowrap;\n z-index: 1;\n }\n\n .x-modal__overlay {\n width: 100%;\n height: 100%;\n position: absolute;\n background-color: rgb(0, 0, 0);\n opacity: 0.3;\n }\n</style>\n\n<docs lang=\"mdx\">\n## Examples\n\nThe `BaseModal` is a simple component that serves to create complex modals. Its open state has to be\npassed via prop. There is a prop, `referenceSelector`, used to place the modal under some element\ninstead of set the top of the element directly. It also accepts an animation to use for opening &\nclosing.\n\nIt emits a `click:overlay` event when any part out of the content is clicked, but only if the modal\nis open.\n\n```vue\n<template>\n <div>\n <button @click=\"open = true\">Open modal</button>\n <BaseModal\n :animation=\"fadeAndSlide\"\n :open=\"open\"\n @click:overlay=\"open = false\"\n referenceSelector=\".header\"\n >\n <h1>Hello</h1>\n <p>The modal is working</p>\n <button @click=\"open = false\">Close modal</button>\n </BaseModal>\n </div>\n</template>\n\n<script>\n import { BaseModal, FadeAndSlide } from '@empathyco/x-components';\n import Vue from 'vue';\n\n Vue.component('fadeAndSlide', FadeAndSlide);\n\n export default {\n components: {\n BaseModal\n },\n data() {\n return {\n open: false\n };\n }\n };\n</script>\n```\n\n### Customized usage\n\n#### Customizing the content with classes\n\nThe `contentClass` prop can be used to add classes to the modal content.\n\n```vue\n<template>\n <div>\n <button @click=\"open = true\">Open modal</button>\n <BaseModal\n :animation=\"fadeAndSlide\"\n :open=\"open\"\n @click:overlay=\"open = false\"\n referenceSelector=\".header\"\n contentClass=\"x-bg-neutral-75\"\n >\n <h1>Hello</h1>\n <p>The modal is working</p>\n <button @click=\"open = false\">Close modal</button>\n </BaseModal>\n </div>\n</template>\n\n<script>\n import { BaseModal, FadeAndSlide } from '@empathyco/x-components';\n import Vue from 'vue';\n\n Vue.component('fadeAndSlide', FadeAndSlide);\n\n export default {\n components: {\n BaseModal\n },\n data() {\n return {\n open: false\n };\n }\n };\n</script>\n```\n\n#### Customizing the overlay with classes\n\nThe `overlayClass` prop can be used to add classes to the modal overlay.\n\n```vue\n<template>\n <div>\n <button @click=\"open = true\">Open modal</button>\n <BaseModal\n :animation=\"fadeAndSlide\"\n :open=\"open\"\n @click:overlay=\"open = false\"\n referenceSelector=\".header\"\n overlayClass=\"x-bg-neutral-75\"\n >\n <h1>Hello</h1>\n <p>The modal is working</p>\n <button @click=\"open = false\">Close modal</button>\n </BaseModal>\n </div>\n</template>\n\n<script>\n import { BaseModal, FadeAndSlide } from '@empathyco/x-components';\n import Vue from 'vue';\n\n Vue.component('fadeAndSlide', FadeAndSlide);\n\n export default {\n components: {\n BaseModal\n },\n data() {\n return {\n open: false\n };\n }\n };\n</script>\n```\n\n## Vue Events\n\nA list of events that the component will emit:\n\n- `click:overlay`: the event is emitted after the user clicks any part out of the content but only\n if the modal is open. The event payload is the mouse event that triggers it.\n- `focusin:body`: the event is emitted after the user focus in any part out of the content but only\n if the modal is open. The event payload is the focus event that triggers it.\n</docs>\n"],"names":["animation","_withDirectives","_openBlock","_createElementBlock","isWaitingForLeave","_createBlock","_withCtx","_normalizeClass","_renderSlot","_createCommentVNode","_resolveDynamicComponent","overlayClass"],"mappings":";;;;;MACyD,UAAe,GAAA;AAAA,EAAC,GAAA,EAAA,UAAA;AAAA,EAAA,KAAA,EAAA,SAAA;;;AACrE,SAAA,WAAA,CAAA,IAAA,EAAA,MAAA,EAFJ,MAGWA,EAAAA,MAAAA,EAAAA,KAAAA,EAAAA,QAAAA,EAAAA;SACJC,cAAY,EAAAC,SAAA,EAAA,EAAAC,kBAAA;AAAA,IAAEC,KAAAA;AAAAA,IAAAA,UAAAA;AAAAA,IAAAA;AAAAA,OAAAA,SAAAA,EACH,EAAAC,WAAA;AAAA,QAAED,uBAAAA,CAAAA,IAAAA,CAAAA,SAAAA,CAAAA;AAAAA,QAAAA;AAAAA,UAAAA,aAAAA,EAAAA,MAAAA,CAAAA,CAAAA,CAAAA,KAAAA,MAAAA,CAAAA,CAAAA,CAAAA,GAAAA,CAAAA,MAAAA,KAAAA,IAAAA,CAAAA,iBAAAA,GAAAA,IAAAA,CAAAA;UALpB,YAiBY,EAAA,MAAA,CAAA,CAAA,CAAA,KAAA,MAAA,CAAA,CAAA,CAAA,GAAA,CAAA,MAAA,KAAA,IAAA,CAAA,iBAAA,GAAA,KAAA,CAAA;AAAA,SAAA;;AAVN,UAAA,OAAA,EAAAE,OAAA,CAAA,MAAA;AAAA,YAAA,IAAA,CAPN,IASY,IAAAJ,SAAA,EAAA,EAAAC,kBAAA;AAAA,cAAiB,KAAA;AAAA,cAAA;AAAA,gBACrB,GAAK,EAAA,CAAA;AAAA,gBACL,GAAA,EAAA,iBAAA;AAAA,gBACA,OAAKI,cAAQ,CAAA,C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 -188,13 +188,20 @@ var _sfc_main = defineComponent({
|
|
|
188
188
|
syncBody(true);
|
|
189
189
|
}
|
|
190
190
|
resizeObserver = new ResizeObserver(debouncedUpdatePosition);
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
if (
|
|
194
|
-
|
|
195
|
-
|
|
191
|
+
watch(() => props.referenceSelector, () => {
|
|
192
|
+
resizeObserver.disconnect();
|
|
193
|
+
if (props.referenceSelector) {
|
|
194
|
+
const element = document.querySelector(props.referenceSelector);
|
|
195
|
+
if (element) {
|
|
196
|
+
referenceElement = element;
|
|
197
|
+
resizeObserver.observe(element);
|
|
198
|
+
}
|
|
196
199
|
}
|
|
197
|
-
|
|
200
|
+
else {
|
|
201
|
+
referenceElement = undefined;
|
|
202
|
+
debouncedUpdatePosition();
|
|
203
|
+
}
|
|
204
|
+
}, { immediate: true });
|
|
198
205
|
});
|
|
199
206
|
onBeforeUnmount(() => {
|
|
200
207
|
if (props.open) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-modal.vue2.js","sources":["../../../../src/components/modals/base-modal.vue"],"sourcesContent":["<template>\n <div v-show=\"isWaitingForLeave || open\" ref=\"modalRef\" class=\"x-modal\" data-test=\"modal\">\n <component\n :is=\"animation\"\n @before-leave=\"isWaitingForLeave = true\"\n @after-leave=\"isWaitingForLeave = false\"\n >\n <div\n v-if=\"open\"\n ref=\"modalContentRef\"\n class=\"x-modal__content\"\n data-test=\"modal-content\"\n role=\"dialog\"\n :class=\"contentClass\"\n >\n <!-- @slot (Required) Modal container content -->\n <slot />\n </div>\n </component>\n <component :is=\"overlayAnimation\">\n <div\n v-if=\"open\"\n @click=\"emitOverlayClicked\"\n @keydown=\"emitOverlayClicked\"\n class=\"x-modal__overlay\"\n :class=\"overlayClass\"\n data-test=\"modal-overlay\"\n />\n </component>\n </div>\n</template>\n\n<script lang=\"ts\">\n import { defineComponent, nextTick, onBeforeUnmount, onMounted, ref, watch } from 'vue';\n import { useDebounce } from '../../composables';\n import { AnimationProp } from '../../types';\n import { getTargetElement, FOCUSABLE_SELECTORS } from '../../utils';\n import { Fade, NoAnimation } from '../animations';\n\n /**\n * Base component with no XPlugin dependencies that serves as a utility for constructing more\n * complex modals.\n *\n * @public\n */\n export default defineComponent({\n name: 'BaseModal',\n props: {\n /** Determines if the modal is open or not. */\n open: {\n type: Boolean,\n required: true\n },\n /**\n * Determines if the focused element changes to one inside the modal when it opens. Either the\n * first element with a positive tabindex or just the first focusable element.\n */\n focusOnOpen: {\n type: Boolean,\n default: true\n },\n /**\n * The reference selector of a DOM element to use as reference to position the modal.\n * This selector can be an ID or a class, if it is a class, it will use the first\n * element that matches.\n */\n referenceSelector: String,\n /** Animation to use for opening/closing the modal.This animation only affects the content. */\n animation: {\n type: AnimationProp,\n default: () => NoAnimation\n },\n /**\n * Animation to use for the overlay (backdrop) part of the modal. By default, it uses\n * a fade transition.\n */\n overlayAnimation: {\n type: AnimationProp,\n default: () => Fade\n },\n /** Class inherited by content element. */\n contentClass: String,\n /** Class inherited by overlay element. */\n overlayClass: String\n },\n emits: ['click:overlay', 'focusin:body'],\n setup(props, { emit }) {\n /** Reference to the modal element in the DOM. */\n const modalRef = ref<HTMLDivElement>();\n /** Reference to the modal content element in the DOM. */\n const modalContentRef = ref<HTMLDivElement>();\n\n /** The previous value of the body overflow style. */\n const previousBodyOverflow = ref('');\n /** The previous value of the HTML element overflow style. */\n const previousHTMLOverflow = ref('');\n /** Boolean to delay the leave animation until it has completed. */\n const isWaitingForLeave = ref(false);\n /** The reference element to use to find the modal's position. */\n let referenceElement: HTMLElement;\n\n /** Disables the scroll of both the body and the window. */\n function disableScroll() {\n previousBodyOverflow.value = document.body.style.overflow;\n previousHTMLOverflow.value = document.documentElement.style.overflow;\n document.body.style.overflow = document.documentElement.style.overflow = 'hidden';\n }\n\n /** Restores the scroll of both the body and the window. */\n function enableScroll() {\n document.body.style.overflow = previousBodyOverflow.value;\n document.documentElement.style.overflow = previousHTMLOverflow.value;\n }\n\n /**\n * Emits the `click:overlay` event if the click has been triggered in the overlay layer.\n *\n * @param event - The click event.\n */\n function emitOverlayClicked(event: Event) {\n emit('click:overlay', event);\n }\n\n /**\n * Emits the `focusin:body` event if a focus event has been triggered outside the modal.\n *\n * @param event - The focusin event.\n */\n function emitFocusInBody(event: FocusEvent) {\n if (!modalContentRef.value?.contains(getTargetElement(event))) {\n emit('focusin:body', event);\n }\n }\n\n /**\n * Adds listeners to the body element ot detect if the modal should be closed.\n *\n * @remarks TODO find a better solution and remove the timeout\n * To avoid emit the focusin on opening X that provokes closing it immediately.\n * This is because this event was emitted after the open of main modal when the user clicks\n * on the customer website search box (focus event). This way we avoid add the listener before\n * the open and the avoid the event that provokes the close.\n */\n function addBodyListeners() {\n setTimeout(() => {\n document.body.addEventListener('focusin', emitFocusInBody);\n });\n }\n\n /** Removes the body listeners. */\n function removeBodyListeners() {\n document.body.removeEventListener('focusin', emitFocusInBody);\n }\n\n /**\n * Sets the focused element to the first element either the first element with a positive\n * tabindex or, if there isn't any, the first focusable element inside the modal.\n */\n function setFocus() {\n const candidates: HTMLElement[] = Array.from(\n modalContentRef.value?.querySelectorAll(FOCUSABLE_SELECTORS) ?? []\n );\n const element = candidates.find(element => element.tabIndex) ?? candidates[0];\n element?.focus();\n }\n\n /**\n * Syncs the body to the open state of the modal, adding or removing styles and listeners.\n *\n * @remarks nextTick() to wait for `modalContentRef` to be updated to look for focusable\n * candidates inside.\n *\n * @param isOpen - True when the modal is opened.\n */\n async function syncBody(isOpen: boolean) {\n if (isOpen) {\n disableScroll();\n addBodyListeners();\n if (props.focusOnOpen) {\n await nextTick();\n setFocus();\n }\n } else {\n enableScroll();\n removeBodyListeners();\n }\n }\n\n /**\n * Updates the position of the modal setting the top of the element depending\n * on the selector. The modal will be placed under this selector.\n */\n const debouncedUpdatePosition = useDebounce(\n () => {\n const { height, y } = referenceElement?.getBoundingClientRect() ?? { height: 0, y: 0 };\n modalRef.value!.style.top = `${height + y}px`;\n modalRef.value!.style.bottom = '0';\n modalRef.value!.style.height = 'auto';\n },\n 100,\n { leading: true }\n );\n\n let resizeObserver: ResizeObserver;\n\n onMounted(() => {\n watch(() => props.open, syncBody);\n if (props.open) {\n syncBody(true);\n }\n\n resizeObserver = new ResizeObserver(debouncedUpdatePosition);\n\n if (props.referenceSelector) {\n const element = document.querySelector(props.referenceSelector) as HTMLElement;\n if (element) {\n referenceElement = element;\n resizeObserver.observe(element);\n }\n }\n });\n\n onBeforeUnmount(() => {\n if (props.open) {\n removeBodyListeners();\n enableScroll();\n }\n resizeObserver.disconnect();\n });\n\n return {\n emitOverlayClicked,\n isWaitingForLeave,\n modalContentRef,\n modalRef\n };\n }\n });\n</script>\n\n<style lang=\"css\" scoped>\n .x-modal {\n position: fixed;\n top: 0;\n left: 0;\n display: flex;\n align-items: flex-start;\n justify-content: flex-start;\n width: 100%;\n height: 100%;\n z-index: 1;\n }\n\n .x-modal__content {\n display: flex;\n flex-flow: column nowrap;\n z-index: 1;\n }\n\n .x-modal__overlay {\n width: 100%;\n height: 100%;\n position: absolute;\n background-color: rgb(0, 0, 0);\n opacity: 0.3;\n }\n</style>\n\n<docs lang=\"mdx\">\n## Examples\n\nThe `BaseModal` is a simple component that serves to create complex modals. Its open state has to be\npassed via prop. There is a prop, `referenceSelector`, used to place the modal under some element\ninstead of set the top of the element directly. It also accepts an animation to use for opening &\nclosing.\n\nIt emits a `click:overlay` event when any part out of the content is clicked, but only if the modal\nis open.\n\n```vue\n<template>\n <div>\n <button @click=\"open = true\">Open modal</button>\n <BaseModal\n :animation=\"fadeAndSlide\"\n :open=\"open\"\n @click:overlay=\"open = false\"\n referenceSelector=\".header\"\n >\n <h1>Hello</h1>\n <p>The modal is working</p>\n <button @click=\"open = false\">Close modal</button>\n </BaseModal>\n </div>\n</template>\n\n<script>\n import { BaseModal, FadeAndSlide } from '@empathyco/x-components';\n import Vue from 'vue';\n\n Vue.component('fadeAndSlide', FadeAndSlide);\n\n export default {\n components: {\n BaseModal\n },\n data() {\n return {\n open: false\n };\n }\n };\n</script>\n```\n\n### Customized usage\n\n#### Customizing the content with classes\n\nThe `contentClass` prop can be used to add classes to the modal content.\n\n```vue\n<template>\n <div>\n <button @click=\"open = true\">Open modal</button>\n <BaseModal\n :animation=\"fadeAndSlide\"\n :open=\"open\"\n @click:overlay=\"open = false\"\n referenceSelector=\".header\"\n contentClass=\"x-bg-neutral-75\"\n >\n <h1>Hello</h1>\n <p>The modal is working</p>\n <button @click=\"open = false\">Close modal</button>\n </BaseModal>\n </div>\n</template>\n\n<script>\n import { BaseModal, FadeAndSlide } from '@empathyco/x-components';\n import Vue from 'vue';\n\n Vue.component('fadeAndSlide', FadeAndSlide);\n\n export default {\n components: {\n BaseModal\n },\n data() {\n return {\n open: false\n };\n }\n };\n</script>\n```\n\n#### Customizing the overlay with classes\n\nThe `overlayClass` prop can be used to add classes to the modal overlay.\n\n```vue\n<template>\n <div>\n <button @click=\"open = true\">Open modal</button>\n <BaseModal\n :animation=\"fadeAndSlide\"\n :open=\"open\"\n @click:overlay=\"open = false\"\n referenceSelector=\".header\"\n overlayClass=\"x-bg-neutral-75\"\n >\n <h1>Hello</h1>\n <p>The modal is working</p>\n <button @click=\"open = false\">Close modal</button>\n </BaseModal>\n </div>\n</template>\n\n<script>\n import { BaseModal, FadeAndSlide } from '@empathyco/x-components';\n import Vue from 'vue';\n\n Vue.component('fadeAndSlide', FadeAndSlide);\n\n export default {\n components: {\n BaseModal\n },\n data() {\n return {\n open: false\n };\n }\n };\n</script>\n```\n\n## Vue Events\n\nA list of events that the component will emit:\n\n- `click:overlay`: the event is emitted after the user clicks any part out of the content but only\n if the modal is open. The event payload is the mouse event that triggers it.\n- `focusin:body`: the event is emitted after the user focus in any part out of the content but only\n if the modal is open. The event payload is the focus event that triggers it.\n</docs>\n"],"names":["NoAnimation"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAuCE;;;;;AAKE;AACF,gBAAe,eAAe,CAAC;AAC7B,IAAA,IA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K,CAAC,iBAAiB,EAAE;gBAC3B,MAAM,OAAM,GAAI,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,iBAAiB,CAAgB,CAAA;AAC9E,gBAAA,IAAI,OAAO,EAAE;oBACX,mBAAmB,OAAO,CAAA;AAC1B,oBAAA,cAAc,CAAC,OAAO,CAAC,OAAO,CAAC,CAAA;AACjC,iBAAA;AACF,aAAA;AACF,SAAC,CAAC,CAAA;QAEF,eAAe,CAAC,MAAM;YACpB,IAAI,KAAK,CAAC,IAAI,EAAE;AACd,gBAAA,mBAAmB,EAAE,CAAA;AACrB,gBAAA,YAAY,EAAE,CAAA;AAChB,aAAA;YACA,cAAc,CAAC,UAAU,EAAE,CAAA;AAC7B,SAAC,CAAC,CAAA;QAEF,OAAO;YACL,kBAAkB;YAClB,iBAAiB;YACjB,eAAe;YACf,QAAO;SACR,CAAA;KACH;AACD,CAAA,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"base-modal.vue2.js","sources":["../../../../src/components/modals/base-modal.vue"],"sourcesContent":["<template>\n <div v-show=\"isWaitingForLeave || open\" ref=\"modalRef\" class=\"x-modal\" data-test=\"modal\">\n <component\n :is=\"animation\"\n @before-leave=\"isWaitingForLeave = true\"\n @after-leave=\"isWaitingForLeave = false\"\n >\n <div\n v-if=\"open\"\n ref=\"modalContentRef\"\n class=\"x-modal__content\"\n data-test=\"modal-content\"\n role=\"dialog\"\n :class=\"contentClass\"\n >\n <!-- @slot (Required) Modal container content -->\n <slot />\n </div>\n </component>\n <component :is=\"overlayAnimation\">\n <div\n v-if=\"open\"\n @click=\"emitOverlayClicked\"\n @keydown=\"emitOverlayClicked\"\n class=\"x-modal__overlay\"\n :class=\"overlayClass\"\n data-test=\"modal-overlay\"\n />\n </component>\n </div>\n</template>\n\n<script lang=\"ts\">\n import { defineComponent, nextTick, onBeforeUnmount, onMounted, ref, watch } from 'vue';\n import { useDebounce } from '../../composables';\n import { AnimationProp } from '../../types';\n import { getTargetElement, FOCUSABLE_SELECTORS } from '../../utils';\n import { Fade, NoAnimation } from '../animations';\n\n /**\n * Base component with no XPlugin dependencies that serves as a utility for constructing more\n * complex modals.\n *\n * @public\n */\n export default defineComponent({\n name: 'BaseModal',\n props: {\n /** Determines if the modal is open or not. */\n open: {\n type: Boolean,\n required: true\n },\n /**\n * Determines if the focused element changes to one inside the modal when it opens. Either the\n * first element with a positive tabindex or just the first focusable element.\n */\n focusOnOpen: {\n type: Boolean,\n default: true\n },\n /**\n * The reference selector of a DOM element to use as reference to position the modal.\n * This selector can be an ID or a class, if it is a class, it will use the first\n * element that matches.\n */\n referenceSelector: String,\n /** Animation to use for opening/closing the modal.This animation only affects the content. */\n animation: {\n type: AnimationProp,\n default: () => NoAnimation\n },\n /**\n * Animation to use for the overlay (backdrop) part of the modal. By default, it uses\n * a fade transition.\n */\n overlayAnimation: {\n type: AnimationProp,\n default: () => Fade\n },\n /** Class inherited by content element. */\n contentClass: String,\n /** Class inherited by overlay element. */\n overlayClass: String\n },\n emits: ['click:overlay', 'focusin:body'],\n setup(props, { emit }) {\n /** Reference to the modal element in the DOM. */\n const modalRef = ref<HTMLDivElement>();\n /** Reference to the modal content element in the DOM. */\n const modalContentRef = ref<HTMLDivElement>();\n\n /** The previous value of the body overflow style. */\n const previousBodyOverflow = ref('');\n /** The previous value of the HTML element overflow style. */\n const previousHTMLOverflow = ref('');\n /** Boolean to delay the leave animation until it has completed. */\n const isWaitingForLeave = ref(false);\n /** The reference element to use to find the modal's position. */\n let referenceElement: HTMLElement | undefined;\n\n /** Disables the scroll of both the body and the window. */\n function disableScroll() {\n previousBodyOverflow.value = document.body.style.overflow;\n previousHTMLOverflow.value = document.documentElement.style.overflow;\n document.body.style.overflow = document.documentElement.style.overflow = 'hidden';\n }\n\n /** Restores the scroll of both the body and the window. */\n function enableScroll() {\n document.body.style.overflow = previousBodyOverflow.value;\n document.documentElement.style.overflow = previousHTMLOverflow.value;\n }\n\n /**\n * Emits the `click:overlay` event if the click has been triggered in the overlay layer.\n *\n * @param event - The click event.\n */\n function emitOverlayClicked(event: Event) {\n emit('click:overlay', event);\n }\n\n /**\n * Emits the `focusin:body` event if a focus event has been triggered outside the modal.\n *\n * @param event - The focusin event.\n */\n function emitFocusInBody(event: FocusEvent) {\n if (!modalContentRef.value?.contains(getTargetElement(event))) {\n emit('focusin:body', event);\n }\n }\n\n /**\n * Adds listeners to the body element ot detect if the modal should be closed.\n *\n * @remarks TODO find a better solution and remove the timeout\n * To avoid emit the focusin on opening X that provokes closing it immediately.\n * This is because this event was emitted after the open of main modal when the user clicks\n * on the customer website search box (focus event). This way we avoid add the listener before\n * the open and the avoid the event that provokes the close.\n */\n function addBodyListeners() {\n setTimeout(() => {\n document.body.addEventListener('focusin', emitFocusInBody);\n });\n }\n\n /** Removes the body listeners. */\n function removeBodyListeners() {\n document.body.removeEventListener('focusin', emitFocusInBody);\n }\n\n /**\n * Sets the focused element to the first element either the first element with a positive\n * tabindex or, if there isn't any, the first focusable element inside the modal.\n */\n function setFocus() {\n const candidates: HTMLElement[] = Array.from(\n modalContentRef.value?.querySelectorAll(FOCUSABLE_SELECTORS) ?? []\n );\n const element = candidates.find(element => element.tabIndex) ?? candidates[0];\n element?.focus();\n }\n\n /**\n * Syncs the body to the open state of the modal, adding or removing styles and listeners.\n *\n * @remarks nextTick() to wait for `modalContentRef` to be updated to look for focusable\n * candidates inside.\n *\n * @param isOpen - True when the modal is opened.\n */\n async function syncBody(isOpen: boolean) {\n if (isOpen) {\n disableScroll();\n addBodyListeners();\n if (props.focusOnOpen) {\n await nextTick();\n setFocus();\n }\n } else {\n enableScroll();\n removeBodyListeners();\n }\n }\n\n /**\n * Updates the position of the modal setting the top of the element depending\n * on the selector. The modal will be placed under this selector.\n */\n const debouncedUpdatePosition = useDebounce(\n () => {\n const { height, y } = referenceElement?.getBoundingClientRect() ?? { height: 0, y: 0 };\n modalRef.value!.style.top = `${height + y}px`;\n modalRef.value!.style.bottom = '0';\n modalRef.value!.style.height = 'auto';\n },\n 100,\n { leading: true }\n );\n\n let resizeObserver: ResizeObserver;\n\n onMounted(() => {\n watch(() => props.open, syncBody);\n if (props.open) {\n syncBody(true);\n }\n\n resizeObserver = new ResizeObserver(debouncedUpdatePosition);\n\n watch(\n () => props.referenceSelector,\n () => {\n resizeObserver.disconnect();\n\n if (props.referenceSelector) {\n const element = document.querySelector(props.referenceSelector) as HTMLElement;\n if (element) {\n referenceElement = element;\n resizeObserver.observe(element);\n }\n } else {\n referenceElement = undefined;\n debouncedUpdatePosition();\n }\n },\n { immediate: true }\n );\n });\n\n onBeforeUnmount(() => {\n if (props.open) {\n removeBodyListeners();\n enableScroll();\n }\n resizeObserver.disconnect();\n });\n\n return {\n emitOverlayClicked,\n isWaitingForLeave,\n modalContentRef,\n modalRef\n };\n }\n });\n</script>\n\n<style lang=\"css\" scoped>\n .x-modal {\n position: fixed;\n top: 0;\n left: 0;\n display: flex;\n align-items: flex-start;\n justify-content: flex-start;\n width: 100%;\n height: 100%;\n z-index: 1;\n }\n\n .x-modal__content {\n display: flex;\n flex-flow: column nowrap;\n z-index: 1;\n }\n\n .x-modal__overlay {\n width: 100%;\n height: 100%;\n position: absolute;\n background-color: rgb(0, 0, 0);\n opacity: 0.3;\n }\n</style>\n\n<docs lang=\"mdx\">\n## Examples\n\nThe `BaseModal` is a simple component that serves to create complex modals. Its open state has to be\npassed via prop. There is a prop, `referenceSelector`, used to place the modal under some element\ninstead of set the top of the element directly. It also accepts an animation to use for opening &\nclosing.\n\nIt emits a `click:overlay` event when any part out of the content is clicked, but only if the modal\nis open.\n\n```vue\n<template>\n <div>\n <button @click=\"open = true\">Open modal</button>\n <BaseModal\n :animation=\"fadeAndSlide\"\n :open=\"open\"\n @click:overlay=\"open = false\"\n referenceSelector=\".header\"\n >\n <h1>Hello</h1>\n <p>The modal is working</p>\n <button @click=\"open = false\">Close modal</button>\n </BaseModal>\n </div>\n</template>\n\n<script>\n import { BaseModal, FadeAndSlide } from '@empathyco/x-components';\n import Vue from 'vue';\n\n Vue.component('fadeAndSlide', FadeAndSlide);\n\n export default {\n components: {\n BaseModal\n },\n data() {\n return {\n open: false\n };\n }\n };\n</script>\n```\n\n### Customized usage\n\n#### Customizing the content with classes\n\nThe `contentClass` prop can be used to add classes to the modal content.\n\n```vue\n<template>\n <div>\n <button @click=\"open = true\">Open modal</button>\n <BaseModal\n :animation=\"fadeAndSlide\"\n :open=\"open\"\n @click:overlay=\"open = false\"\n referenceSelector=\".header\"\n contentClass=\"x-bg-neutral-75\"\n >\n <h1>Hello</h1>\n <p>The modal is working</p>\n <button @click=\"open = false\">Close modal</button>\n </BaseModal>\n </div>\n</template>\n\n<script>\n import { BaseModal, FadeAndSlide } from '@empathyco/x-components';\n import Vue from 'vue';\n\n Vue.component('fadeAndSlide', FadeAndSlide);\n\n export default {\n components: {\n BaseModal\n },\n data() {\n return {\n open: false\n };\n }\n };\n</script>\n```\n\n#### Customizing the overlay with classes\n\nThe `overlayClass` prop can be used to add classes to the modal overlay.\n\n```vue\n<template>\n <div>\n <button @click=\"open = true\">Open modal</button>\n <BaseModal\n :animation=\"fadeAndSlide\"\n :open=\"open\"\n @click:overlay=\"open = false\"\n referenceSelector=\".header\"\n overlayClass=\"x-bg-neutral-75\"\n >\n <h1>Hello</h1>\n <p>The modal is working</p>\n <button @click=\"open = false\">Close modal</button>\n </BaseModal>\n </div>\n</template>\n\n<script>\n import { BaseModal, FadeAndSlide } from '@empathyco/x-components';\n import Vue from 'vue';\n\n Vue.component('fadeAndSlide', FadeAndSlide);\n\n export default {\n components: {\n BaseModal\n },\n data() {\n return {\n open: false\n };\n }\n };\n</script>\n```\n\n## Vue Events\n\nA list of events that the component will emit:\n\n- `click:overlay`: the event is emitted after the user clicks any part out of the content but only\n if the modal is open. The event payload is the mouse event that triggers it.\n- `focusin:body`: the event is emitted after the user focus in any part out of the content but only\n if the modal is open. The event payload is the focus event that triggers it.\n</docs>\n"],"names":["NoAnimation"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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BAAiB,IAAI,cAAc,CAAC,uBAAuB,CAAC,CAAA;YAE5D,KAAK,CACH,MAAM,KAAK,CAAC,iBAAiB,EAC7B,MAAM;gBACJ,cAAc,CAAC,UAAU,EAAE,CAAA;gBAE3B,IAAI,KAAK,CAAC,iBAAiB,EAAE;oBAC3B,MAAM,OAAM,GAAI,QAAQ,CAAC,aAAa,CAAC,KAAK,CAAC,iBAAiB,CAAgB,CAAA;AAC9E,oBAAA,IAAI,OAAO,EAAE;wBACX,mBAAmB,OAAO,CAAA;AAC1B,wBAAA,cAAc,CAAC,OAAO,CAAC,OAAO,CAAC,CAAA;AACjC,qBAAA;AACA,iBAAA;AAAK,qBAAA;oBACL,gBAAe,GAAI,SAAS,CAAA;AAC5B,oBAAA,uBAAuB,EAAE,CAAA;AAC3B,iBAAA;AACF,aAAC,EACD,EAAE,SAAS,EAAE,IAAK,EAAA,CACnB,CAAA;AACH,SAAC,CAAC,CAAA;QAEF,eAAe,CAAC,MAAM;YACpB,IAAI,KAAK,CAAC,IAAI,EAAE;AACd,gBAAA,mBAAmB,EAAE,CAAA;AACrB,gBAAA,YAAY,EAAE,CAAA;AAChB,aAAA;YACA,cAAc,CAAC,UAAU,EAAE,CAAA;AAC7B,SAAC,CAAC,CAAA;QAEF,OAAO;YACL,kBAAkB;YAClB,iBAAiB;YACjB,eAAe;YACf,QAAO;SACR,CAAA;KACH;AACD,CAAA,CAAC;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@empathyco/x-components",
|
|
3
|
-
"version": "6.0.0-alpha.
|
|
3
|
+
"version": "6.0.0-alpha.29",
|
|
4
4
|
"description": "Empathy X Components",
|
|
5
5
|
"author": "Empathy Systems Corporation S.L.",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -92,7 +92,7 @@
|
|
|
92
92
|
"devDependencies": {
|
|
93
93
|
"@badeball/cypress-cucumber-preprocessor": "~20.0.0",
|
|
94
94
|
"@bahmutov/cypress-esbuild-preprocessor": "~2.2.0",
|
|
95
|
-
"@empathyco/x-tailwindcss": "^2.0.0-alpha.
|
|
95
|
+
"@empathyco/x-tailwindcss": "^2.0.0-alpha.2",
|
|
96
96
|
"@microsoft/api-documenter": "~7.23.0",
|
|
97
97
|
"@microsoft/api-extractor": "~7.39.0",
|
|
98
98
|
"@testing-library/jest-dom": "~5.17.0",
|
|
@@ -138,5 +138,5 @@
|
|
|
138
138
|
"access": "public",
|
|
139
139
|
"directory": "dist"
|
|
140
140
|
},
|
|
141
|
-
"gitHead": "
|
|
141
|
+
"gitHead": "9a0889059626e7e9a253cd0e2326868672c4cd88"
|
|
142
142
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-modal.vue?vue&type=script&lang.d.ts","sourceRoot":"","sources":["../../../../src/components/modals/base-modal.vue?vue&type=script&lang.ts"],"names":[],"mappings":"AAOE;;;;;GAKG;;IAIC,8CAA8C;;;;;IAK9C;;;OAGG;;;;;IAKH;;;;OAIG;;IAEH,8FAA8F;;;;;IAK9F;;;OAGG;;;;;IAKH,0CAA0C;;IAE1C,0CAA0C;;;gCAqCP,KAAK;;;;;IAvExC,8CAA8C;;;;;IAK9C;;;OAGG;;;;;IAKH;;;;OAIG;;IAEH,8FAA8F;;;;;IAK9F;;;OAGG;;;;;IAKH,0CAA0C;;IAE1C,0CAA0C;;;;;;;;;;AArC9C,
|
|
1
|
+
{"version":3,"file":"base-modal.vue?vue&type=script&lang.d.ts","sourceRoot":"","sources":["../../../../src/components/modals/base-modal.vue?vue&type=script&lang.ts"],"names":[],"mappings":"AAOE;;;;;GAKG;;IAIC,8CAA8C;;;;;IAK9C;;;OAGG;;;;;IAKH;;;;OAIG;;IAEH,8FAA8F;;;;;IAK9F;;;OAGG;;;;;IAKH,0CAA0C;;IAE1C,0CAA0C;;;gCAqCP,KAAK;;;;;IAvExC,8CAA8C;;;;;IAK9C;;;OAGG;;;;;IAKH;;;;OAIG;;IAEH,8FAA8F;;;;;IAK9F;;;OAGG;;;;;IAKH,0CAA0C;;IAE1C,0CAA0C;;;;;;;;;;AArC9C,wBA2MG"}
|