@iamproperty/components 7.2.1--beta3 → 7.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/css/components/actionbar.component.css +1 -1
- package/assets/css/components/actionbar.component.css.map +1 -1
- package/assets/css/components/barchart.component.css +1 -1
- package/assets/css/components/barchart.component.css.map +1 -1
- package/assets/css/components/bento-grid.component.css +1 -1
- package/assets/css/components/bento-grid.component.css.map +1 -1
- package/assets/css/components/bento-grid.global.css +1 -0
- package/assets/css/components/bento-grid.global.css.map +1 -0
- package/assets/css/components/card.component.css +1 -1
- package/assets/css/components/card.component.css.map +1 -1
- package/assets/css/components/carousel.component.css +1 -1
- package/assets/css/components/carousel.component.css.map +1 -1
- package/assets/css/components/doughnutchart.component.css +1 -1
- package/assets/css/components/doughnutchart.component.css.map +1 -1
- package/assets/css/components/table-basic.global.css.map +1 -1
- package/assets/css/components/table.global.css.map +1 -1
- package/assets/css/core.min.css +1 -1
- package/assets/css/core.min.css.map +1 -1
- package/assets/css/mobile-core.min.css +1 -1
- package/assets/css/mobile-core.min.css.map +1 -1
- package/assets/css/mobile.min.css +1 -1
- package/assets/css/mobile.min.css.map +1 -1
- package/assets/css/style.min.css +1 -1
- package/assets/css/style.min.css.map +1 -1
- package/assets/js/components/accordion/accordion.component.min.js +1 -1
- package/assets/js/components/actionbar/actionbar.component.js +8 -7
- package/assets/js/components/actionbar/actionbar.component.min.js +10 -8
- package/assets/js/components/actionbar/actionbar.component.min.js.map +1 -1
- package/assets/js/components/address-lookup/address-lookup.component.min.js +1 -1
- package/assets/js/components/applied-filters/applied-filters.component.min.js +1 -1
- package/assets/js/components/barchart/barchart.component.min.js +2 -2
- package/assets/js/components/bento-grid/bento-grid.component.js +22 -3
- package/assets/js/components/bento-grid/bento-grid.component.min.js +5 -4
- package/assets/js/components/bento-grid/bento-grid.component.min.js.map +1 -1
- package/assets/js/components/card/card.component.min.js +2 -2
- package/assets/js/components/carousel/carousel.component.min.js +2 -2
- package/assets/js/components/collapsible-side/collapsible-side.component.min.js +1 -1
- package/assets/js/components/doughnutchart/doughnutchart.component.min.js +2 -2
- package/assets/js/components/fileupload/fileupload.component.min.js +1 -1
- package/assets/js/components/filter-card/filter-card.component.min.js +1 -1
- package/assets/js/components/filterlist/filterlist.component.min.js +1 -1
- package/assets/js/components/header/header.component.min.js +1 -1
- package/assets/js/components/inline-edit/inline-edit.component.min.js +1 -1
- package/assets/js/components/marketing/marketing.component.min.js +1 -1
- package/assets/js/components/menu/menu.component.min.js +1 -1
- package/assets/js/components/multi-step/multi-step.component.min.js +1 -1
- package/assets/js/components/multiselect/multiselect.component.min.js +1 -1
- package/assets/js/components/nav/nav.component.min.js +1 -1
- package/assets/js/components/notification/notification.component.min.js +1 -1
- package/assets/js/components/pagination/pagination.component.min.js +1 -1
- package/assets/js/components/rank/rank.component.min.js +1 -1
- package/assets/js/components/rankings/rankings.component.js +9 -10
- package/assets/js/components/rankings/rankings.component.min.js +4 -4
- package/assets/js/components/rankings/rankings.component.min.js.map +1 -1
- package/assets/js/components/record-card/record-card.component.min.js +1 -1
- package/assets/js/components/search/search.component.min.js +1 -1
- package/assets/js/components/slider/slider.component.min.js +1 -1
- package/assets/js/components/table/table.component.min.js +1 -1
- package/assets/js/components/table-ajax/table-ajax.component.min.js +1 -1
- package/assets/js/components/table-basic/table-basic.component.min.js +1 -1
- package/assets/js/components/table-no-submit/table-no-submit.component.min.js +1 -1
- package/assets/js/components/table-submit/table-submit.component.min.js +1 -1
- package/assets/js/components/tabs/tabs.component.min.js +1 -1
- package/assets/js/components/video-card/video-card.component.min.js +1 -1
- package/assets/js/scripts.bundle.js +1 -1
- package/assets/js/scripts.bundle.js.map +1 -1
- package/assets/js/scripts.bundle.min.js +1 -1
- package/assets/js/scripts.bundle.min.js.map +1 -1
- package/assets/js/scripts.js +32 -32
- package/assets/sass/_components.scss +0 -187
- package/assets/sass/_functions/variables.scss +2 -1
- package/assets/sass/components/actionbar.component.scss +28 -0
- package/assets/sass/components/bento-grid.component.scss +32 -14
- package/assets/sass/components/bento-grid.global.scss +249 -0
- package/assets/sass/components/table-basic.global.scss +0 -1
- package/assets/sass/components/table.global.scss +4 -9
- package/assets/sass/elements/buttons--global.scss +1 -0
- package/assets/sass/elements/lists.scss +5 -1
- package/assets/sass/elements/popover.scss +4 -1
- package/assets/ts/components/actionbar/actionbar.component.ts +11 -7
- package/assets/ts/components/bento-grid/bento-grid.component.ts +23 -3
- package/assets/ts/components/rankings/rankings.component.ts +4 -4
- package/assets/ts/modules/table.ts +8 -14
- package/assets/ts/scripts.ts +1 -1
- package/dist/components.es.js +18 -18
- package/dist/components.umd.js +76 -69
- package/package.json +1 -1
- package/src/components/BentoGrid/BentoGrid.vue +1 -1
|
@@ -11,58 +11,73 @@
|
|
|
11
11
|
display: block;
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
+
.wrapper {
|
|
15
|
+
margin-bottom: 2rem;
|
|
16
|
+
}
|
|
17
|
+
|
|
14
18
|
::slotted(details) {
|
|
15
19
|
margin-bottom: 1rem;
|
|
16
20
|
border-radius: 1rem;
|
|
17
21
|
padding: 0 !important;
|
|
18
22
|
position: relative;
|
|
19
23
|
overflow: hidden;
|
|
24
|
+
|
|
25
|
+
display: block;
|
|
26
|
+
width: 100%;
|
|
27
|
+
min-height: rem(200);
|
|
20
28
|
}
|
|
21
29
|
|
|
22
|
-
@container (width >
|
|
30
|
+
@container (width > 54em) {
|
|
23
31
|
.wrapper {
|
|
24
|
-
aspect-ratio: 1.
|
|
32
|
+
aspect-ratio: 1.81 / 1;
|
|
25
33
|
position: relative;
|
|
26
34
|
display: block;
|
|
27
35
|
overflow: hidden;
|
|
28
36
|
border-radius: 1rem;
|
|
29
|
-
|
|
30
37
|
--content-max-width: 28rem;
|
|
38
|
+
--height: 50%;
|
|
39
|
+
margin-bottom: 3rem;
|
|
31
40
|
}
|
|
32
41
|
|
|
33
42
|
::slotted(details) {
|
|
34
43
|
position: absolute;
|
|
35
44
|
top: 0;
|
|
36
45
|
left: 0;
|
|
37
|
-
width: calc(
|
|
38
|
-
height: calc(
|
|
46
|
+
width: calc(58.5% - 0.5rem) !important;
|
|
47
|
+
height: calc(var(--height) - 0.5rem);
|
|
39
48
|
z-index: 1;
|
|
40
49
|
border-radius: 1rem;
|
|
41
50
|
margin: 0;
|
|
51
|
+
aspect-ratio: unset;
|
|
52
|
+
|
|
53
|
+
will-change: transform;
|
|
42
54
|
}
|
|
43
55
|
|
|
44
56
|
::slotted(details.animating) {
|
|
45
|
-
transition: 1s !important;
|
|
46
57
|
z-index: 10 !important;
|
|
58
|
+
|
|
59
|
+
@media screen and (prefers-reduced-motion: no-preference) {
|
|
60
|
+
transition: 0.8s !important;
|
|
61
|
+
}
|
|
47
62
|
}
|
|
48
63
|
|
|
49
64
|
::slotted(details:nth-child(2)) {
|
|
50
65
|
top: 0;
|
|
51
|
-
left: calc(
|
|
52
|
-
width: calc(
|
|
53
|
-
height: calc(
|
|
66
|
+
left: calc(58.5% + 0.5rem);
|
|
67
|
+
width: calc(41.5% - 0.5rem) !important;
|
|
68
|
+
height: calc(var(--height) - 0.5rem);
|
|
54
69
|
}
|
|
55
70
|
::slotted(details:nth-child(3)) {
|
|
56
|
-
top: calc(
|
|
71
|
+
top: calc(var(--height) + 0.5rem);
|
|
57
72
|
left: 0;
|
|
58
73
|
width: calc(50% - 0.5rem) !important;
|
|
59
|
-
height: calc(
|
|
74
|
+
height: calc(var(--height) - 0.5rem);
|
|
60
75
|
}
|
|
61
76
|
::slotted(details:nth-child(4)) {
|
|
62
|
-
top: calc(
|
|
77
|
+
top: calc(var(--height) + 0.5rem);
|
|
63
78
|
left: calc(50% + 0.5rem);
|
|
64
79
|
width: calc(50% - 0.5rem) !important;
|
|
65
|
-
height: calc(
|
|
80
|
+
height: calc(var(--height) - 0.5rem);
|
|
66
81
|
}
|
|
67
82
|
|
|
68
83
|
::slotted(details[open]) {
|
|
@@ -80,7 +95,6 @@
|
|
|
80
95
|
left: 50%;
|
|
81
96
|
height: 100%;
|
|
82
97
|
width: 100%;
|
|
83
|
-
background: red;
|
|
84
98
|
}
|
|
85
99
|
|
|
86
100
|
::slotted(details[open]:not(.animating)) {
|
|
@@ -88,4 +102,8 @@
|
|
|
88
102
|
overflow-x: clip;
|
|
89
103
|
overscroll-behavior: contain;
|
|
90
104
|
}
|
|
105
|
+
|
|
106
|
+
:host(:has(details)) .wrapper {
|
|
107
|
+
aspect-ratio: 3 / 1;
|
|
108
|
+
}
|
|
91
109
|
}
|
|
@@ -0,0 +1,249 @@
|
|
|
1
|
+
@use '../_func.scss' as *;
|
|
2
|
+
|
|
3
|
+
iam-bento-grid {
|
|
4
|
+
details {
|
|
5
|
+
summary {
|
|
6
|
+
position: relative;
|
|
7
|
+
height: 100%;
|
|
8
|
+
width: 100%;
|
|
9
|
+
max-width: 100%;
|
|
10
|
+
padding: 1.5rem;
|
|
11
|
+
margin-bottom: 0;
|
|
12
|
+
|
|
13
|
+
[role='presentation'] {
|
|
14
|
+
display: block;
|
|
15
|
+
font-family: var(--font-body);
|
|
16
|
+
font-weight: normal;
|
|
17
|
+
font-size: 1rem;
|
|
18
|
+
position: relative;
|
|
19
|
+
width: fit-content;
|
|
20
|
+
transition: opacity 0.8s;
|
|
21
|
+
will-change: opacity;
|
|
22
|
+
|
|
23
|
+
@media screen and (prefers-reduced-motion: no-preference) {
|
|
24
|
+
transition: opacity 0.8s;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
&:before {
|
|
28
|
+
display: block;
|
|
29
|
+
content: ' ';
|
|
30
|
+
position: absolute;
|
|
31
|
+
top: 100%;
|
|
32
|
+
left: 50%;
|
|
33
|
+
width: 100%;
|
|
34
|
+
height: 0;
|
|
35
|
+
border: 1px solid currentColor;
|
|
36
|
+
transform: translate(-50%, 0);
|
|
37
|
+
will-change: transform;
|
|
38
|
+
|
|
39
|
+
@media screen and (prefers-reduced-motion: no-preference) {
|
|
40
|
+
transition: 0.8s;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
&:after {
|
|
45
|
+
display: inline-block;
|
|
46
|
+
content: '\f061';
|
|
47
|
+
top: 100%;
|
|
48
|
+
margin-left: 0.5em;
|
|
49
|
+
line-height: 1em;
|
|
50
|
+
font-size: 1em;
|
|
51
|
+
font-family: 'Font Awesome 6 Pro';
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
&::after {
|
|
56
|
+
opacity: 0;
|
|
57
|
+
content: '\e092';
|
|
58
|
+
pointer-events: all;
|
|
59
|
+
left: auto;
|
|
60
|
+
position: absolute;
|
|
61
|
+
top: 1rem;
|
|
62
|
+
right: 1rem;
|
|
63
|
+
line-height: 1em;
|
|
64
|
+
font-size: 0.5em;
|
|
65
|
+
|
|
66
|
+
font-family: 'Font Awesome 6 Pro';
|
|
67
|
+
font-weight: 300;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
&:hover {
|
|
71
|
+
[role='presentation'] {
|
|
72
|
+
display: block;
|
|
73
|
+
font-family: var(--font-body);
|
|
74
|
+
font-weight: normal;
|
|
75
|
+
font-size: 1rem;
|
|
76
|
+
position: relative;
|
|
77
|
+
width: fit-content;
|
|
78
|
+
|
|
79
|
+
&:before {
|
|
80
|
+
width: 80%;
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
&[style]:before {
|
|
87
|
+
content: '';
|
|
88
|
+
position: absolute;
|
|
89
|
+
display: block;
|
|
90
|
+
top: 60%;
|
|
91
|
+
left: 70%;
|
|
92
|
+
height: 50%;
|
|
93
|
+
aspect-ratio: 2 / 1;
|
|
94
|
+
|
|
95
|
+
background-image: var(--bg);
|
|
96
|
+
background-repeat: no-repeat;
|
|
97
|
+
background-size: cover;
|
|
98
|
+
border-radius: 0.5rem;
|
|
99
|
+
|
|
100
|
+
-webkit-box-shadow: 0px 0px 15px -5px rgba(0, 0, 0, 0.5);
|
|
101
|
+
-moz-box-shadow: 0px 0px 15px -5px rgba(0, 0, 0, 0.5);
|
|
102
|
+
box-shadow: 0px 0px 15px -5px rgba(0, 0, 0, 0.5);
|
|
103
|
+
|
|
104
|
+
will-change: top, left, height;
|
|
105
|
+
|
|
106
|
+
@media screen and (prefers-reduced-motion: no-preference) {
|
|
107
|
+
transition: 0.8s;
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
&[open]:before {
|
|
112
|
+
top: 100%;
|
|
113
|
+
left: 100%;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
&::details-content {
|
|
117
|
+
opacity: 0;
|
|
118
|
+
padding: 0 1.5rem 1.5rem 1.5rem;
|
|
119
|
+
overflow: auto;
|
|
120
|
+
will-change: top, left, height;
|
|
121
|
+
|
|
122
|
+
@media screen and (prefers-reduced-motion: no-preference) {
|
|
123
|
+
transition: 0.8s;
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
details {
|
|
129
|
+
summary:hover {
|
|
130
|
+
[role='presentation'] {
|
|
131
|
+
opacity: 1;
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
details[open] {
|
|
137
|
+
position: relative;
|
|
138
|
+
|
|
139
|
+
&:not(.animating)::details-content {
|
|
140
|
+
opacity: 1;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
> *:last-child {
|
|
144
|
+
margin-bottom: 0;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
summary {
|
|
148
|
+
pointer-events: none;
|
|
149
|
+
width: 100%;
|
|
150
|
+
max-width: 100%;
|
|
151
|
+
height: fit-content;
|
|
152
|
+
|
|
153
|
+
[role='presentation'] {
|
|
154
|
+
opacity: 0;
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
[role='presentation'] {
|
|
158
|
+
margin-bottom: -2rem;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
&:after {
|
|
162
|
+
opacity: 1;
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
@supports selector(::details-content) {
|
|
169
|
+
.notice {
|
|
170
|
+
display: none;
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
iam-bento-grid {
|
|
175
|
+
@container (width > 40em) {
|
|
176
|
+
details {
|
|
177
|
+
summary {
|
|
178
|
+
padding-right: 30%;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
&[style]:before {
|
|
182
|
+
top: 40%;
|
|
183
|
+
left: 60%;
|
|
184
|
+
height: 75%;
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
&[style]:hover:before {
|
|
188
|
+
top: 35%;
|
|
189
|
+
left: 57%;
|
|
190
|
+
height: 75%;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
&[open][style]:before {
|
|
194
|
+
top: 100%;
|
|
195
|
+
left: 100%;
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
iam-bento-grid {
|
|
202
|
+
@container (width > 54em) {
|
|
203
|
+
details {
|
|
204
|
+
|
|
205
|
+
overflow: hidden;
|
|
206
|
+
|
|
207
|
+
summary {
|
|
208
|
+
padding-right: 30%;
|
|
209
|
+
|
|
210
|
+
[role='presentation'] {
|
|
211
|
+
opacity: 0;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
:is(:hover, :focus) [role='presentation'] {
|
|
215
|
+
opacity: 1;
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
&::after {
|
|
219
|
+
top: 1.5rem;
|
|
220
|
+
right: 1.5rem;
|
|
221
|
+
line-height: 1em;
|
|
222
|
+
font-size: 0.75em;
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
&[style]:before {
|
|
227
|
+
top: 38%;
|
|
228
|
+
left: 45%;
|
|
229
|
+
height: 80%;
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
&[style]:hover:before {
|
|
233
|
+
top: 35%;
|
|
234
|
+
left: 38%;
|
|
235
|
+
height: 80%;
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
&[open][style]:before {
|
|
239
|
+
left: calc(50% + 0.5rem) !important;
|
|
240
|
+
top: 30% !important;
|
|
241
|
+
height: 80% !important;
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
details:nth-child(4) ~ details {
|
|
246
|
+
display: none;
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
}
|
|
@@ -22,7 +22,7 @@ $selector: 'iam-table, iam-table-basic, iam-table-no-submit, iam-table-submit';
|
|
|
22
22
|
|
|
23
23
|
:is(#{$selector}) iam-actionbar {
|
|
24
24
|
margin: 0 1.5rem 1rem 1.5rem;
|
|
25
|
-
|
|
25
|
+
|
|
26
26
|
@container (width < 23.4375em) {
|
|
27
27
|
box-shadow: 0px 6px 12px rgba(0, 0, 0, 0.11);
|
|
28
28
|
border-radius: 0.5rem;
|
|
@@ -280,7 +280,6 @@ $selector: 'iam-table, iam-table-basic, iam-table-no-submit, iam-table-submit';
|
|
|
280
280
|
|
|
281
281
|
.th--fixed:has(+ th:not(.th--fixed)),
|
|
282
282
|
.td--fixed:has(+ td:not(.td--fixed)) {
|
|
283
|
-
|
|
284
283
|
background: linear-gradient(90deg, var(--row-bg) calc(100% - 1rem), transparent 100%);
|
|
285
284
|
}
|
|
286
285
|
|
|
@@ -299,7 +298,6 @@ $selector: 'iam-table, iam-table-basic, iam-table-no-submit, iam-table-submit';
|
|
|
299
298
|
padding-left: calc(rem(48 + 48 + 6))!important;
|
|
300
299
|
}
|
|
301
300
|
|
|
302
|
-
|
|
303
301
|
.th--fixed + .th--fixed + .th--fixed,
|
|
304
302
|
.td--fixed + .td--fixed + .td--fixed {
|
|
305
303
|
left: rem(48 + 48);
|
|
@@ -309,7 +307,7 @@ $selector: 'iam-table, iam-table-basic, iam-table-no-submit, iam-table-submit';
|
|
|
309
307
|
.td--fixed + .td--fixed + .td--fixed + td:not(.td--fixed) {
|
|
310
308
|
padding-left: calc(rem(48 + 48 + 48 + 6))!important;
|
|
311
309
|
}
|
|
312
|
-
|
|
310
|
+
|
|
313
311
|
.dialog__wrapper {
|
|
314
312
|
z-index: 10;
|
|
315
313
|
}
|
|
@@ -393,18 +391,15 @@ $icon-sort-desc: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg'
|
|
|
393
391
|
|
|
394
392
|
// #region max height tables
|
|
395
393
|
|
|
396
|
-
|
|
397
|
-
iam-table-basic:is(.mh-lg,.mh-md,.mh-sm) {
|
|
398
|
-
|
|
394
|
+
iam-table-basic:is(.mh-lg, .mh-md, .mh-sm) {
|
|
399
395
|
thead {
|
|
400
396
|
position: sticky;
|
|
401
397
|
top: 0;
|
|
402
398
|
z-index: 9999;
|
|
403
399
|
|
|
404
400
|
tr {
|
|
405
|
-
|
|
406
401
|
background: var(--row-bg);
|
|
407
|
-
background: linear-gradient(0deg,var(--colour-primary) 2px, var(--row-bg) 2px);
|
|
402
|
+
background: linear-gradient(0deg, var(--colour-primary) 2px, var(--row-bg) 2px);
|
|
408
403
|
border: none;
|
|
409
404
|
}
|
|
410
405
|
}
|
|
@@ -53,6 +53,10 @@ $darkMode: 'true' !default;
|
|
|
53
53
|
max-width: $content-max-width;
|
|
54
54
|
}
|
|
55
55
|
|
|
56
|
+
.tick-list--white {
|
|
57
|
+
--tick-colour: white;
|
|
58
|
+
}
|
|
59
|
+
|
|
56
60
|
.tick-list {
|
|
57
61
|
padding-left: 0;
|
|
58
62
|
|
|
@@ -72,7 +76,7 @@ $darkMode: 'true' !default;
|
|
|
72
76
|
font-size: 1.25em;
|
|
73
77
|
line-height: 1;
|
|
74
78
|
|
|
75
|
-
color: var(--colour-complete);
|
|
79
|
+
color: var(--tick-colour, var(--colour-complete));
|
|
76
80
|
font-family: 'Font Awesome 6 Pro';
|
|
77
81
|
font-size: 400;
|
|
78
82
|
}
|
|
@@ -14,7 +14,10 @@ $darkMode: 'true' !default;
|
|
|
14
14
|
|
|
15
15
|
&:has(dialog[open], dialog:popover-open) > button {
|
|
16
16
|
background: var(--colour-btn-secondary-bg-hover);
|
|
17
|
-
|
|
17
|
+
|
|
18
|
+
&:not(.btn-action) {
|
|
19
|
+
color: var(--colour-btn-secondary-hover);
|
|
20
|
+
}
|
|
18
21
|
filter: brightness(85%);
|
|
19
22
|
transition:
|
|
20
23
|
background 0.1s,
|
|
@@ -40,16 +40,13 @@ class iamActionbar extends HTMLElement {
|
|
|
40
40
|
const assetLocation = document.body.hasAttribute('data-assets-location')
|
|
41
41
|
? document.body.getAttribute('data-assets-location')
|
|
42
42
|
: '/assets';
|
|
43
|
-
|
|
44
|
-
? document.body.getAttribute('data-core-css')
|
|
45
|
-
: `${assetLocation}/css/core.min.css`;
|
|
43
|
+
|
|
46
44
|
const loadCSS = `@import "${assetLocation}/css/components/actionbar.component.css";`;
|
|
47
45
|
const loadExtraCSS = `@import "${assetLocation}/css/components/actionbar.global.css";`;
|
|
48
46
|
|
|
49
47
|
const template = document.createElement('template');
|
|
50
48
|
template.innerHTML = `
|
|
51
49
|
<style>
|
|
52
|
-
@import "${coreCSS}";
|
|
53
50
|
${loadCSS}
|
|
54
51
|
${this.hasAttribute('css') ? `@import "${this.getAttribute('css')}";` : ``}
|
|
55
52
|
</style>
|
|
@@ -62,7 +59,7 @@ class iamActionbar extends HTMLElement {
|
|
|
62
59
|
<slot></slot>
|
|
63
60
|
<div class="body">
|
|
64
61
|
<div class="dialog__wrapper dialog__wrapper--right dialog-overflow d-none show">
|
|
65
|
-
<button class="btn btn-secondary btn-compact fa-ellipsis-vertical m-0">More actions</button>
|
|
62
|
+
<button class="btn btn-secondary btn-compact btn-sm fa-ellipsis-vertical m-0">More actions</button>
|
|
66
63
|
<dialog class="dialog--list" part="overflow">
|
|
67
64
|
<slot name="overflow"></slot>
|
|
68
65
|
<slot name="menu"></slot>
|
|
@@ -89,7 +86,7 @@ class iamActionbar extends HTMLElement {
|
|
|
89
86
|
<slot name="selected"></slot>
|
|
90
87
|
<div class="body">
|
|
91
88
|
<div class="dialog__wrapper dialog__wrapper--right dialog-overflow d-none show">
|
|
92
|
-
<button class="btn btn-secondary btn-compact fa-ellipsis-vertical m-0">More actions</button>
|
|
89
|
+
<button class="btn btn-secondary btn-compact btn-sm fa-ellipsis-vertical m-0">More actions</button>
|
|
93
90
|
<dialog class="dialog--list" part="selected-overflow">
|
|
94
91
|
<slot name="selected-overflow"></slot>
|
|
95
92
|
</dialog>
|
|
@@ -109,6 +106,9 @@ class iamActionbar extends HTMLElement {
|
|
|
109
106
|
|
|
110
107
|
</div>
|
|
111
108
|
</div>
|
|
109
|
+
<div class="no-columns">
|
|
110
|
+
<span class="d-block">No columns selected</span>
|
|
111
|
+
</div>
|
|
112
112
|
`;
|
|
113
113
|
this.shadowRoot.appendChild(template.content.cloneNode(true));
|
|
114
114
|
|
|
@@ -186,7 +186,7 @@ class iamActionbar extends HTMLElement {
|
|
|
186
186
|
if (view == 'list') icon = 'fa-grip-lines';
|
|
187
187
|
else if (view == 'small') icon = 'fa-bars';
|
|
188
188
|
|
|
189
|
-
btns += `<button class="btn btn-action btn-compact mb-0 fa-regular ${icon}">${view}</button>`;
|
|
189
|
+
btns += `<button class="btn btn-action btn-compact btn-sm mb-0 fa-regular ${icon}">${view}</button>`;
|
|
190
190
|
});
|
|
191
191
|
|
|
192
192
|
actionbarWrapper?.insertAdjacentHTML('afterbegin', `<div class="views m-0">${btns}</div>`);
|
|
@@ -410,6 +410,8 @@ class iamActionbar extends HTMLElement {
|
|
|
410
410
|
columnsHidden += this.hasAttribute(`data-hide-col${index + 1}`) ? `${index + 1},` : '';
|
|
411
411
|
});
|
|
412
412
|
|
|
413
|
+
this.setAttribute('data-columns-shown', checklistHolder.querySelectorAll('input:checked').length);
|
|
414
|
+
|
|
413
415
|
const dispatchedEvent = new CustomEvent('columm-filters-set', {
|
|
414
416
|
detail: {
|
|
415
417
|
columnsHidden: columnsHidden.slice(0, -1),
|
|
@@ -432,6 +434,8 @@ class iamActionbar extends HTMLElement {
|
|
|
432
434
|
});
|
|
433
435
|
}
|
|
434
436
|
|
|
437
|
+
this.setAttribute('data-columns-shown', checklistHolder.querySelectorAll('input:checked').length);
|
|
438
|
+
|
|
435
439
|
if (this.hasAttribute('data-filter-columns') && !this.hasAttribute('data-filter-columns-save')) {
|
|
436
440
|
checklistHolder?.addEventListener('change', (event) => {
|
|
437
441
|
if (event && event.target instanceof HTMLElement && event.target.closest('input')) {
|
|
@@ -7,10 +7,10 @@ declare global {
|
|
|
7
7
|
window.dataLayer = window.dataLayer || [];
|
|
8
8
|
window.dataLayer.push({
|
|
9
9
|
event: 'customElementRegistered',
|
|
10
|
-
element: '
|
|
10
|
+
element: 'bento-grid',
|
|
11
11
|
});
|
|
12
12
|
|
|
13
|
-
class
|
|
13
|
+
class iamBentoGrid extends HTMLElement {
|
|
14
14
|
constructor() {
|
|
15
15
|
super();
|
|
16
16
|
this.attachShadow({ mode: 'open' });
|
|
@@ -19,6 +19,7 @@ class iamAccordion extends HTMLElement {
|
|
|
19
19
|
? document.body.getAttribute('data-assets-location')
|
|
20
20
|
: '/assets';
|
|
21
21
|
const loadCSS = `@import "${assetLocation}/css/components/bento-grid.component.css";`;
|
|
22
|
+
const loadExtraCSS = `@import "${assetLocation}/css/components/bento-grid.global.css";`;
|
|
22
23
|
|
|
23
24
|
const template = document.createElement('template');
|
|
24
25
|
template.innerHTML = `
|
|
@@ -32,6 +33,9 @@ class iamAccordion extends HTMLElement {
|
|
|
32
33
|
</div>
|
|
33
34
|
`;
|
|
34
35
|
this.shadowRoot?.appendChild(template.content.cloneNode(true));
|
|
36
|
+
|
|
37
|
+
if (!document.getElementById('bentogridGlobal'))
|
|
38
|
+
document.head.insertAdjacentHTML('beforeend', `<style id="bentogridGlobal">${loadExtraCSS}</style>`);
|
|
35
39
|
}
|
|
36
40
|
|
|
37
41
|
connectedCallback(): void {
|
|
@@ -59,9 +63,25 @@ class iamAccordion extends HTMLElement {
|
|
|
59
63
|
setTimeout(() => {
|
|
60
64
|
details?.classList.remove('animating');
|
|
61
65
|
}, 1100);
|
|
66
|
+
|
|
67
|
+
if (details?.hasAttribute('open')) {
|
|
68
|
+
const customEvent = new CustomEvent('item-closed', {
|
|
69
|
+
detail: {
|
|
70
|
+
title: summary?.textContent,
|
|
71
|
+
},
|
|
72
|
+
});
|
|
73
|
+
this.dispatchEvent(customEvent);
|
|
74
|
+
} else {
|
|
75
|
+
const customEvent = new CustomEvent('item-opened', {
|
|
76
|
+
detail: {
|
|
77
|
+
title: summary?.textContent,
|
|
78
|
+
},
|
|
79
|
+
});
|
|
80
|
+
this.dispatchEvent(customEvent);
|
|
81
|
+
}
|
|
62
82
|
}
|
|
63
83
|
});
|
|
64
84
|
}
|
|
65
85
|
}
|
|
66
86
|
|
|
67
|
-
export default
|
|
87
|
+
export default iamBentoGrid;
|
|
@@ -34,24 +34,24 @@ class iamRankings extends HTMLElement {
|
|
|
34
34
|
|
|
35
35
|
connectedCallback(): void {
|
|
36
36
|
|
|
37
|
-
const position = this.hasAttribute('data-position') ? this.getAttribute('data-position') : this.textContent?.trim();
|
|
38
|
-
|
|
39
|
-
this.setAttribute('data-position', position);
|
|
40
37
|
|
|
41
38
|
const firstText = this.shadowRoot?.querySelector('.first-position');
|
|
42
39
|
const secondText = this.shadowRoot?.querySelector('.second-position');
|
|
43
40
|
const thirdText = this.shadowRoot?.querySelector('.third-position');
|
|
41
|
+
const max = this.hasAttribute('data-max') ? this.getAttribute('data-max') : 100;
|
|
44
42
|
|
|
45
43
|
firstText?.innerHTML = this.querySelector('tbody tr:nth-child(1) :is(td,th):nth-child(1)')?.textContent;
|
|
46
44
|
secondText?.innerHTML = this.querySelector('tbody tr:nth-child(2) :is(td,th):nth-child(1)')?.textContent;
|
|
47
45
|
thirdText?.innerHTML = this.querySelector('tbody tr:nth-child(3) :is(td,th):nth-child(1)')?.textContent;
|
|
48
46
|
|
|
47
|
+
|
|
48
|
+
|
|
49
49
|
this.querySelectorAll('tbody tr').forEach((element) => {
|
|
50
50
|
|
|
51
51
|
const value = element.querySelector('td:last-child')?.textContent?.trim();
|
|
52
52
|
|
|
53
53
|
if(!element.querySelector(':first-child progress'))
|
|
54
|
-
element.querySelector(':first-child')?.innerHTML += `<progress max="
|
|
54
|
+
element.querySelector(':first-child')?.innerHTML += `<progress max="${max}" value="${value}"></progress>`;
|
|
55
55
|
});
|
|
56
56
|
|
|
57
57
|
trackComponent(this, 'iam-rank', ['select-card']);
|
|
@@ -265,12 +265,13 @@ export const createMobileButton = (component, table): void => {
|
|
|
265
265
|
|
|
266
266
|
if (table.querySelectorAll('thead tr th').length < 4 && !component.hasAttribute('data-expandable')) return false;
|
|
267
267
|
|
|
268
|
-
|
|
269
|
-
|
|
270
268
|
//If the expand column already exists we don't need to add a new one.
|
|
271
269
|
Array.from(table.querySelectorAll('thead tr')).forEach((row) => {
|
|
272
270
|
if (!table.querySelectorAll('thead tr th.expand-button-heading').length) {
|
|
273
|
-
row.insertAdjacentHTML(
|
|
271
|
+
row.insertAdjacentHTML(
|
|
272
|
+
'afterbegin',
|
|
273
|
+
`<th class="${component.hasAttribute('data-expandable') ? 'th--fixed ' : ''}expand-button-heading"></th>`
|
|
274
|
+
);
|
|
274
275
|
}
|
|
275
276
|
});
|
|
276
277
|
|
|
@@ -278,11 +279,10 @@ export const createMobileButton = (component, table): void => {
|
|
|
278
279
|
const preExpanded = row.getAttribute('data-view') === 'full' ? 'aria-expanded' : '';
|
|
279
280
|
row.insertAdjacentHTML(
|
|
280
281
|
'afterbegin',
|
|
281
|
-
`<td class="${component.hasAttribute('data-expandable') ? 'td--fixed ' : ''
|
|
282
|
+
`<td class="${component.hasAttribute('data-expandable') ? 'td--fixed ' : ''}td--expand"><button class="btn btn-compact btn-secondary btn-sm" data-expand-button ${preExpanded} data-index="${index}">Expand</button></td>`
|
|
282
283
|
);
|
|
283
284
|
});
|
|
284
285
|
|
|
285
|
-
|
|
286
286
|
table.addEventListener('click', (event) => {
|
|
287
287
|
if (event && event.target instanceof HTMLElement && event.target.closest('[data-expand-button]')) {
|
|
288
288
|
const button = event.target.closest('[data-expand-button]');
|
|
@@ -349,19 +349,13 @@ export const setupAdvancedTable = (component, table): void => {
|
|
|
349
349
|
|
|
350
350
|
const tr = btn.closest('tr');
|
|
351
351
|
const td = btn.closest('td');
|
|
352
|
-
|
|
353
|
-
|
|
354
352
|
|
|
355
|
-
const trChildren = Array.prototype.slice.call(
|
|
356
|
-
const cellIndex = trChildren.indexOf(
|
|
353
|
+
const trChildren = Array.prototype.slice.call(tr.children);
|
|
354
|
+
const cellIndex = trChildren.indexOf(td);
|
|
357
355
|
|
|
358
356
|
td.classList.add('td--fixed');
|
|
359
|
-
table.querySelector(`thead tr th:nth-child(${cellIndex+1})`).classList.add('th--fixed');
|
|
360
|
-
|
|
357
|
+
table.querySelector(`thead tr th:nth-child(${cellIndex + 1})`).classList.add('th--fixed');
|
|
361
358
|
});
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
359
|
};
|
|
366
360
|
// #region Advanced table functions
|
|
367
361
|
export const addSelectboxes = (component, table, actionbar): void => {
|