@maggioli-design-system/mds-table-row 5.2.0 → 5.3.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.
Files changed (64) hide show
  1. package/dist/cjs/{index-cb928c36.js → index-27c9aefd.js} +146 -108
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/mds-table-row.cjs.entry.js +17 -8
  4. package/dist/cjs/mds-table-row.cjs.js +2 -2
  5. package/dist/collection/collection-manifest.json +1 -1
  6. package/dist/collection/common/browser.js +7 -0
  7. package/dist/collection/components/mds-table-row/mds-table-row.css +122 -132
  8. package/dist/collection/components/mds-table-row/mds-table-row.js +11 -6
  9. package/dist/components/mds-table-row.js +16 -7
  10. package/dist/documentation.json +10 -2
  11. package/dist/esm/{index-8134a00a.js → index-81f966aa.js} +146 -108
  12. package/dist/esm/loader.js +2 -2
  13. package/dist/esm/mds-table-row.entry.js +17 -8
  14. package/dist/esm/mds-table-row.js +3 -3
  15. package/dist/esm-es5/index-81f966aa.js +1 -0
  16. package/dist/esm-es5/loader.js +1 -1
  17. package/dist/esm-es5/mds-table-row.entry.js +2 -2
  18. package/dist/esm-es5/mds-table-row.js +1 -1
  19. package/dist/mds-table-row/mds-table-row.esm.js +1 -1
  20. package/dist/mds-table-row/mds-table-row.js +1 -1
  21. package/dist/mds-table-row/p-133f1581.system.js +2 -0
  22. package/dist/mds-table-row/p-25b773c1.js +2 -0
  23. package/dist/mds-table-row/p-4727e0b3.system.entry.js +6 -0
  24. package/dist/mds-table-row/p-869d0b15.entry.js +6 -0
  25. package/dist/mds-table-row/p-e71445fa.system.js +1 -0
  26. package/dist/stats.json +44 -35
  27. package/dist/types/common/browser.d.ts +2 -0
  28. package/dist/types/common/locale.d.ts +1 -1
  29. package/dist/types/components/mds-table-row/mds-table-row.d.ts +1 -0
  30. package/documentation.json +10 -2
  31. package/package.json +4 -4
  32. package/readme.md +4 -3
  33. package/src/common/browser.ts +10 -0
  34. package/src/common/locale.ts +2 -2
  35. package/src/components/mds-table-row/css/mds-table-row-actions.css +16 -10
  36. package/src/components/mds-table-row/css/mds-table-row-interactive.css +0 -1
  37. package/src/components/mds-table-row/css/mds-table-row-pref-animation.css +5 -14
  38. package/src/components/mds-table-row/css/mds-table-row-selected.css +0 -1
  39. package/src/components/mds-table-row/css/mds-table-row-sorted.css +0 -2
  40. package/src/components/mds-table-row/mds-table-row.css +1 -7
  41. package/src/components/mds-table-row/mds-table-row.tsx +14 -3
  42. package/src/components/mds-table-row/readme.md +4 -3
  43. package/src/fixtures/icons.json +2 -0
  44. package/src/fixtures/iconsauce.json +1 -0
  45. package/src/tailwind/components.css +2 -48
  46. package/src/tailwind/index.css +4 -0
  47. package/www/build/mds-table-row.esm.js +1 -1
  48. package/www/build/mds-table-row.js +1 -1
  49. package/www/build/p-133f1581.system.js +2 -0
  50. package/www/build/p-25b773c1.js +2 -0
  51. package/www/build/p-4727e0b3.system.entry.js +6 -0
  52. package/www/build/p-869d0b15.entry.js +6 -0
  53. package/www/build/p-e71445fa.system.js +1 -0
  54. package/dist/esm-es5/index-8134a00a.js +0 -1
  55. package/dist/mds-table-row/p-11048c96.system.js +0 -1
  56. package/dist/mds-table-row/p-22d4881a.js +0 -2
  57. package/dist/mds-table-row/p-64bc1c7b.entry.js +0 -6
  58. package/dist/mds-table-row/p-88f814c9.system.js +0 -2
  59. package/dist/mds-table-row/p-c5e9ab44.system.entry.js +0 -6
  60. package/www/build/p-11048c96.system.js +0 -1
  61. package/www/build/p-22d4881a.js +0 -2
  62. package/www/build/p-64bc1c7b.entry.js +0 -6
  63. package/www/build/p-88f814c9.system.js +0 -2
  64. package/www/build/p-c5e9ab44.system.entry.js +0 -6
@@ -1,5 +1,125 @@
1
- @tailwind components;
2
- @tailwind utilities;
1
+ :host {
2
+ --mds-table-row-color-hover: var(--mds-table-color, rgb(var(--tone-neutral-02)));
3
+ --mds-table-row-color-alt: var(--mds-table-color-alt, rgb(var(--tone-neutral-02)));
4
+ --mds-table-row-background-hover: var(--mds-table-background, rgb(var(--tone-neutral)));
5
+ --mds-table-row-background-alt: var(--mds-table-background-alt, rgb(var(--tone-neutral)));
6
+ --mds-table-row-actions-gap: var(--mds-table-actions-gap, 1rem);
7
+ transition-duration: 200ms;
8
+ transition-timing-function: cubic-bezier(0, 0, 0.2, 1);
9
+
10
+ color: var(--mds-table-row-color);
11
+ display: table-row;
12
+ position: relative;
13
+ transition-property: color;
14
+
15
+ }
16
+
17
+ .selection-cell {
18
+ vertical-align: middle;
19
+ }
20
+
21
+ .checkbox-wrapper {
22
+ display: flex;
23
+ }
24
+
25
+ :host([interactive]:hover) {
26
+ --mds-table-row-actions-background: var(--mds-table-row-background-hover);
27
+ --mds-table-row-background: var(--mds-table-row-background-hover);
28
+ --mds-table-row-color: var(--mds-table-row-color-hover);
29
+ }
30
+
31
+ :host([selected]) {
32
+ --mds-table-row-background: var(--mds-table-row-background-hover);
33
+ --mds-table-row-color: var(--mds-table-row-color-hover);
34
+ }
35
+
36
+ :host([sorted]) {
37
+ --mds-table-row-background: var(--mds-table-row-background-alt);
38
+ --mds-table-row-color: var(--mds-table-row-color-alt);
39
+ }
40
+
41
+ :host([sorted][selected]) {
42
+ --mds-table-row-background: var(--mds-table-row-background-hover);
43
+ --mds-table-row-color: var(--mds-table-row-color-hover);
44
+ }
45
+
46
+ .actions-view {
47
+ align-items: center;
48
+ display: flex;
49
+ inset: 0;
50
+ justify-content: end;
51
+ pointer-events: none;
52
+ position: absolute;
53
+ }
54
+
55
+ .actions {
56
+ --mds-table-row-actions-background: var(--mds-table-row-background);
57
+
58
+ align-items: center;
59
+ background-color: var(--mds-table-row-actions-background);
60
+ border-bottom-left-radius: calc(0.5rem + var(--mds-table-border-width) * 2);
61
+ border-top-left-radius: calc(0.5rem + var(--mds-table-border-width) * 2);
62
+ display: inline-flex;
63
+ gap: var(--mds-table-row-actions-gap);
64
+ inset: 0;
65
+ margin-right: 100%;
66
+ padding: calc(var(--mds-table-border-width) * 2);
67
+ padding-right: 0;
68
+ pointer-events: auto;
69
+ position: sticky;
70
+ right: 0;
71
+ transform: translateX(100%);
72
+ transition-duration: 500ms;
73
+ transition-property: transform, background-color, padding-right;
74
+ transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);
75
+ }
76
+
77
+ :host(:hover) .actions {
78
+ transform: translateX(100%);
79
+ }
80
+
81
+ :host([overlay-actions]) .actions {
82
+ padding-right: var(--mds-table-cell-padding);
83
+ transform: translateX(100%);
84
+ }
85
+
86
+ :host([overlay-actions]:hover) .actions {
87
+ --mds-table-row-actions-background: var(--mds-table-row-background);
88
+
89
+ transform: translateX(0);
90
+ }
91
+
92
+ :host-context(mds-table[interactive="false"]):host(:hover) .actions,
93
+ :host-context(mds-table:not([interactive])):host(:hover) .actions {
94
+ --mds-table-row-actions-background: var(--mds-table-row-background-hover);
95
+ }
96
+
97
+ :host-context(mds-table[selection]:not([interactive])):host(:not([selected]):hover) .actions,
98
+ :host-context(mds-table[selection][interactive="false"]):host(:not([selected]):hover) .actions,
99
+ :host-context(mds-table[selection]:not([interactive])):host([selected="false"]:hover) .actions,
100
+ :host-context(mds-table[selection][interactive="false"]):host([selected="false"]:hover) .actions {
101
+ --mds-table-row-actions-background: var(--mds-table-row-background-alt);
102
+ }
103
+
104
+ .actions-cell--disable,
105
+ .actions-cell--disable .actions {
106
+ position: static !important;
107
+ }
108
+
109
+ .actions-cell--disable .actions {
110
+ margin-right: 0 !important;
111
+ transform: translateX(0) !important;
112
+ }
113
+
114
+ :host-context(.pref-animation-reduce) {
115
+ transition-duration: 0s;
116
+ }
117
+
118
+ @media (prefers-reduced-motion) {
119
+ :host-context(.pref-animation-system) {
120
+ transition-duration: 0s;
121
+ }
122
+ }
3
123
 
4
124
  :host(:not(:is([hydrated], .hydrated))) {
5
125
  animation-duration: 0s;
@@ -120,133 +240,3 @@ mds-zero:not(:is([hydrated], .hydrated))
120
240
  visibility: hidden;
121
241
  }
122
242
 
123
-
124
- :host {
125
-
126
- --mds-table-row-color-hover: var(--mds-table-color, rgb(var(--tone-neutral-02)));
127
- --mds-table-row-color-alt: var(--mds-table-color-alt, rgb(var(--tone-neutral-02)));
128
- --mds-table-row-background-hover: var(--mds-table-background, rgb(var(--tone-neutral)));
129
- --mds-table-row-background-alt: var(--mds-table-background-alt, rgb(var(--tone-neutral)));
130
- --mds-table-row-actions-gap: var(--mds-table-actions-gap, 1rem);
131
- transition-duration: 200ms;
132
- transition-timing-function: cubic-bezier(0, 0, 0.2, 1);
133
-
134
- color: var(--mds-table-row-color);
135
- display: table-row;
136
- position: relative;
137
- transition-property: color;
138
-
139
- }
140
-
141
- .selection-cell {
142
- vertical-align: middle;
143
- }
144
-
145
- .checkbox-wrapper {
146
- display: flex;
147
- }
148
-
149
- :host([interactive]:hover) {
150
-
151
- --mds-table-row-actions-background: var(--mds-table-row-background-hover);
152
- --mds-table-row-background: var(--mds-table-row-background-hover);
153
- --mds-table-row-color: var(--mds-table-row-color-hover);
154
- }
155
-
156
- :host([selected]) {
157
-
158
- --mds-table-row-background: var(--mds-table-row-background-hover);
159
- --mds-table-row-color: var(--mds-table-row-color-hover);
160
- }
161
-
162
- :host([sorted]) {
163
-
164
- --mds-table-row-background: var(--mds-table-row-background-alt);
165
- --mds-table-row-color: var(--mds-table-row-color-alt);
166
- }
167
-
168
- :host([sorted][selected]) {
169
-
170
- --mds-table-row-background: var(--mds-table-row-background-hover);
171
- --mds-table-row-color: var(--mds-table-row-color-hover);
172
- }
173
-
174
- .actions-view {
175
- align-items: center;
176
- display: flex;
177
- inset: 0;
178
- justify-content: end;
179
- pointer-events: none;
180
- position: absolute;
181
- }
182
-
183
- .actions {
184
-
185
- --mds-table-row-actions-background: var(--mds-table-row-background);
186
-
187
- align-items: center;
188
- background-color: var(--mds-table-row-actions-background);
189
- border-bottom-left-radius: calc(0.5rem + var(--mds-table-border-width) * 2);
190
- border-top-left-radius: calc(0.5rem + var(--mds-table-border-width) * 2);
191
- display: inline-flex;
192
- gap: var(--mds-table-row-actions-gap);
193
- inset: 0;
194
- margin-right: 100%;
195
- padding: calc(var(--mds-table-border-width) * 2);
196
- padding-right: 0;
197
- pointer-events: auto;
198
- position: sticky;
199
- right: 0;
200
- transform: translateX(100%);
201
- transition-duration: 500ms;
202
- transition-property: transform, background-color, padding-right;
203
- transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);
204
- }
205
-
206
- :host(:hover) .actions {
207
- transform: translateX(100%);
208
- }
209
-
210
- :host([overlay-actions]) .actions {
211
- padding-right: var(--mds-table-cell-padding);
212
- transform: translateX(100%);
213
- }
214
-
215
- :host([overlay-actions]:hover) .actions {
216
-
217
- --mds-table-row-actions-background: var(--mds-table-row-background);
218
-
219
- transform: translateX(0);
220
- }
221
-
222
- :host(:hover):host-context(mds-table[interactive="false"]) .actions,
223
- :host(:hover):host-context(mds-table:not([interactive])) .actions {
224
-
225
- --mds-table-row-actions-background: var(--mds-table-row-background-hover);
226
- }
227
-
228
- :host(:not([selected]):hover):host-context(mds-table[selection]:not([interactive])) .actions,
229
- :host(:not([selected]):hover):host-context(mds-table[selection][interactive="false"]) .actions,
230
- :host([selected="false"]:hover):host-context(mds-table[selection]:not([interactive])) .actions,
231
- :host([selected="false"]:hover):host-context(mds-table[selection][interactive="false"]) .actions {
232
-
233
- --mds-table-row-actions-background: var(--mds-table-row-background-alt);
234
- }
235
-
236
- @container style(--magma-pref-animation: reduce) {
237
- :host,
238
- .actions {
239
- transition-duration: 0s;
240
- }
241
- }
242
-
243
- @container style(--magma-pref-animation: system) {
244
-
245
- @media (prefers-reduced-motion) {
246
- :host,
247
- .actions {
248
- transition-duration: 0s;
249
- }
250
- }
251
- }
252
-
@@ -4,11 +4,15 @@ import localeEl from "./meta/locale.el.json";
4
4
  import localeEn from "./meta/locale.en.json";
5
5
  import localeEs from "./meta/locale.es.json";
6
6
  import localeIt from "./meta/locale.it.json";
7
+ import { isSafari } from "../../common/browser";
7
8
  /**
8
9
  * @slot default - Put `mds-table-cell` element/s.
10
+ * @slot action - Put `mds-button` element/s or other kind of actions as aside menu for the single row.
9
11
  */
12
+ // TODO [bug, style]: on Safari actions menu is visually broken
10
13
  export class MdsTableRow {
11
14
  constructor() {
15
+ this.hasActions = true;
12
16
  this.t = new Locale({
13
17
  el: localeEl,
14
18
  en: localeEn,
@@ -28,7 +32,7 @@ export class MdsTableRow {
28
32
  }
29
33
  componentWillLoad() {
30
34
  this.language = this.t.lang(this.host);
31
- this.hasActions = this.host.querySelector('[slot="action"]') !== null;
35
+ this.hasActions = this.host.querySelector(':scope > [slot="action"]') !== null;
32
36
  }
33
37
  componentDidLoad() {
34
38
  var _a;
@@ -38,15 +42,16 @@ export class MdsTableRow {
38
42
  }
39
43
  }
40
44
  render() {
41
- return (h(Host, { key: '4905591b94a0af846d25e3cf55fe5805ecec76be', role: "row" }, this.selectable &&
42
- h("mds-table-cell", { key: '07f8596969f20148250cc42fde0a806435825274', class: "selection-cell" }, h("div", { key: '2d0bb74f3f5edaf6180c68a60457b374dcd7a4bd', class: "checkbox-wrapper" }, h("mds-input-switch", { key: 'e04fafd6a53ed1c6a4208b0317419fe21d08f28e', title: this.t.get(this.selected ? 'unselectRow' : 'selectRow'), lang: this.language, type: "checkbox", checked: this.selected, onMdsInputSwitchChange: this.handleSelectionChange }))), h("slot", { key: 'd71c2ec9e675fd8190eeeb7d816a5e2566c6afc4' }), this.hasActions &&
43
- h("mds-table-cell", { key: '0ede2c5f98d7541920c4170d70c21f9f61ac93cb', class: "actions-cell" }, h("div", { key: '8a097d4b04bd594778f51bedfe438fe1fd3479b3', class: "actions-sizer", style: {
45
+ return (h(Host, { key: 'ddc3467a490c2bd90fe51e21a5fe67268a09cabd', role: "row" }, this.selectable &&
46
+ h("mds-table-cell", { key: 'e0aae0041d28b4a39e2cdfef98f8ceb34703613b', class: "selection-cell" }, h("div", { key: 'daf5de2fcfdb0f1863109feb96b533f9bdec1e43', class: "checkbox-wrapper" }, h("mds-input-switch", { key: 'd27bd2000b73115b7c9c2ad7705fcda40d134c04', title: this.t.get(this.selected ? 'unselectRow' : 'selectRow'), lang: this.language, type: "checkbox", checked: this.selected, onMdsInputSwitchChange: this.handleSelectionChange }))), h("slot", { key: '2eb2218ac36175a75569199cb837c00ab56ef3d0' }), this.hasActions && isSafari() &&
47
+ h("mds-table-cell", { key: '0c74ae109c1112d79fc9a65412d032105fb1cdef', class: "actions-cell actions-cell--disable" }, h("div", { key: '969b05e04cb68ec781ba5227de80a8b0357e299c', class: "actions" }, h("slot", { key: '04ee8a48cf0ac01a0bc25b7e819e57767a6443a7', name: "action" }))), this.hasActions && !isSafari() &&
48
+ h("mds-table-cell", { key: '39dba4bf1fc6c2892705608bca1f68e70ce47c7c', class: "actions-cell" }, h("div", { key: '2cab6097ba0bfe85f258ee9f569d92f75fd58208', class: "actions-sizer", style: {
44
49
  minHeight: '1px',
45
50
  maxWidth: this.sizerWidth,
46
51
  minWidth: this.sizerWidth,
47
- } }), h("div", { key: '31f1fe8d7e4ee01f33f1c6a5b76e23fd875dfd82', class: "actions-view" }, h("div", { key: '762785e31a306ba3c1e7654218bdf8cb33044cd3', class: "actions", style: {
52
+ } }), h("div", { key: '1c77e27a925fe8fc003fcdd17f760f35a306027b', class: "actions-view" }, h("div", { key: '962a79184fa4cb6de61d443a65d9481b24cbb603', class: "actions", style: {
48
53
  marginRight: `calc(${this.sizerWidth} + var(--mds-table-cell-padding))`,
49
- } }, h("slot", { key: '05ea2b5edc71e58859e55e52c1ab65ca0c5354f8', name: "action" }))))));
54
+ } }, h("slot", { key: 'fde4f3d477475c8dfdb3346e84e3125f964b7676', name: "action" }))))));
50
55
  }
51
56
  static get is() { return "mds-table-row"; }
52
57
  static get encapsulation() { return "shadow"; }
@@ -870,7 +870,14 @@ const localeIt = {
870
870
  unselectRow: unselectRow
871
871
  };
872
872
 
873
- const mdsTableRowCss = "@tailwind components;\n@tailwind utilities;\n\n:host(:not(:is([hydrated], .hydrated))) {\n -webkit-animation-duration: 0s;\n animation-duration: 0s;\n border-color: transparent;\n -webkit-box-shadow: 0 0 0 transparent;\n box-shadow: 0 0 0 transparent;\n opacity: 0;\n outline-color: transparent;\n -webkit-transition-delay: 0s;\n transition-delay: 0s;\n -webkit-transition-duration: 0s;\n transition-duration: 0s;\n visibility: hidden;\n}\n\n/* TODO refact(stencil): Uses only used selector from parent shadowDOM component */\n\nmds-accordion:not(:is([hydrated], .hydrated)),\nmds-accordion-item:not(:is([hydrated], .hydrated)),\nmds-accordion-timer:not(:is([hydrated], .hydrated)),\nmds-accordion-timer-item:not(:is([hydrated], .hydrated)),\nmds-author:not(:is([hydrated], .hydrated)),\nmds-avatar:not(:is([hydrated], .hydrated)),\nmds-badge:not(:is([hydrated], .hydrated)),\nmds-banner:not(:is([hydrated], .hydrated)),\nmds-benchmark-bar:not(:is([hydrated], .hydrated)),\nmds-bibliography:not(:is([hydrated], .hydrated)),\nmds-breadcrumb:not(:is([hydrated], .hydrated)),\nmds-breadcrumb-item:not(:is([hydrated], .hydrated)),\nmds-button:not(:is([hydrated], .hydrated)),\nmds-card:not(:is([hydrated], .hydrated)),\nmds-card-content:not(:is([hydrated], .hydrated)),\nmds-card-footer:not(:is([hydrated], .hydrated)),\nmds-card-header:not(:is([hydrated], .hydrated)),\nmds-card-media:not(:is([hydrated], .hydrated)),\nmds-chip:not(:is([hydrated], .hydrated)),\nmds-details:not(:is([hydrated], .hydrated)),\nmds-dropdown:not(:is([hydrated], .hydrated)),\nmds-entity:not(:is([hydrated], .hydrated)),\nmds-file:not(:is([hydrated], .hydrated)),\nmds-file-preview:not(:is([hydrated], .hydrated)),\nmds-filter:not(:is([hydrated], .hydrated)),\nmds-filter-item:not(:is([hydrated], .hydrated)),\nmds-header:not(:is([hydrated], .hydrated)),\nmds-header-bar:not(:is([hydrated], .hydrated)),\nmds-help:not(:is([hydrated], .hydrated)),\nmds-horizontal-scroll:not(:is([hydrated], .hydrated)),\nmds-hr:not(:is([hydrated], .hydrated)),\nmds-icon:not(:is([hydrated], .hydrated)),\nmds-img:not(:is([hydrated], .hydrated)),\nmds-input:not(:is([hydrated], .hydrated)),\nmds-input-field:not(:is([hydrated], .hydrated)),\nmds-input-range:not(:is([hydrated], .hydrated)),\nmds-input-select:not(:is([hydrated], .hydrated)),\nmds-input-switch:not(:is([hydrated], .hydrated)),\nmds-input-tip:not(:is([hydrated], .hydrated)),\nmds-input-tip-item:not(:is([hydrated], .hydrated)),\nmds-input-upload:not(:is([hydrated], .hydrated)),\nmds-keyboard:not(:is([hydrated], .hydrated)),\nmds-keyboard-key:not(:is([hydrated], .hydrated)),\nmds-kpi:not(:is([hydrated], .hydrated)),\nmds-kpi-item:not(:is([hydrated], .hydrated)),\nmds-label:not(:is([hydrated], .hydrated)),\nmds-list:not(:is([hydrated], .hydrated)),\nmds-list-item:not(:is([hydrated], .hydrated)),\nmds-modal:not(:is([hydrated], .hydrated)),\nmds-note:not(:is([hydrated], .hydrated)),\nmds-notification:not(:is([hydrated], .hydrated)),\nmds-paginator:not(:is([hydrated], .hydrated)),\nmds-paginator-item:not(:is([hydrated], .hydrated)),\nmds-pref:not(:is([hydrated], .hydrated)),\nmds-pref-animation:not(:is([hydrated], .hydrated)),\nmds-pref-consumption:not(:is([hydrated], .hydrated)),\nmds-pref-contrast:not(:is([hydrated], .hydrated)),\nmds-pref-language:not(:is([hydrated], .hydrated)),\nmds-pref-language-item:not(:is([hydrated], .hydrated)),\nmds-pref-theme:not(:is([hydrated], .hydrated)),\nmds-price-table:not(:is([hydrated], .hydrated)),\nmds-price-table-features:not(:is([hydrated], .hydrated)),\nmds-price-table-features-cell:not(:is([hydrated], .hydrated)),\nmds-price-table-features-row:not(:is([hydrated], .hydrated)),\nmds-price-table-header:not(:is([hydrated], .hydrated)),\nmds-price-table-list:not(:is([hydrated], .hydrated)),\nmds-price-table-list-item:not(:is([hydrated], .hydrated)),\nmds-progress:not(:is([hydrated], .hydrated)),\nmds-push-notification:not(:is([hydrated], .hydrated)),\nmds-push-notifications:not(:is([hydrated], .hydrated)),\nmds-quote:not(:is([hydrated], .hydrated)),\nmds-separator:not(:is([hydrated], .hydrated)),\nmds-spinner:not(:is([hydrated], .hydrated)),\nmds-stepper-bar:not(:is([hydrated], .hydrated)),\nmds-stepper-bar-item:not(:is([hydrated], .hydrated)),\nmds-tab:not(:is([hydrated], .hydrated)),\nmds-tab-bar:not(:is([hydrated], .hydrated)),\nmds-tab-bar-item:not(:is([hydrated], .hydrated)),\nmds-tab-item:not(:is([hydrated], .hydrated)),\nmds-table:not(:is([hydrated], .hydrated)),\nmds-table-body:not(:is([hydrated], .hydrated)),\nmds-table-cell:not(:is([hydrated], .hydrated)),\nmds-table-footer:not(:is([hydrated], .hydrated)),\nmds-table-header:not(:is([hydrated], .hydrated)),\nmds-table-header-cell:not(:is([hydrated], .hydrated)),\nmds-table-row:not(:is([hydrated], .hydrated)),\nmds-text:not(:is([hydrated], .hydrated)),\nmds-toast:not(:is([hydrated], .hydrated)),\nmds-tooltip:not(:is([hydrated], .hydrated)),\nmds-tree:not(:is([hydrated], .hydrated)),\nmds-tree-item:not(:is([hydrated], .hydrated)),\nmds-url-view:not(:is([hydrated], .hydrated)),\nmds-usage:not(:is([hydrated], .hydrated)),\nmds-video-wall:not(:is([hydrated], .hydrated)),\nmds-zero:not(:is([hydrated], .hydrated))\n{\n -webkit-animation-duration: 0s;\n animation-duration: 0s;\n border-color: transparent;\n -webkit-box-shadow: 0 0 0 transparent;\n box-shadow: 0 0 0 transparent;\n opacity: 0;\n outline-color: transparent;\n -webkit-transition-delay: 0s;\n transition-delay: 0s;\n -webkit-transition-duration: 0s;\n transition-duration: 0s;\n visibility: hidden;\n}\n\n\n:host {\n\n --mds-table-row-color-hover: var(--mds-table-color, rgb(var(--tone-neutral-02)));\n --mds-table-row-color-alt: var(--mds-table-color-alt, rgb(var(--tone-neutral-02)));\n --mds-table-row-background-hover: var(--mds-table-background, rgb(var(--tone-neutral)));\n --mds-table-row-background-alt: var(--mds-table-background-alt, rgb(var(--tone-neutral)));\n --mds-table-row-actions-gap: var(--mds-table-actions-gap, 1rem);\n -webkit-transition-duration: 200ms;\n transition-duration: 200ms;\n -webkit-transition-timing-function: cubic-bezier(0, 0, 0.2, 1);\n transition-timing-function: cubic-bezier(0, 0, 0.2, 1);\n\n color: var(--mds-table-row-color);\n display: table-row;\n position: relative;\n -webkit-transition-property: color;\n transition-property: color;\n\n}\n\n.selection-cell {\n vertical-align: middle;\n}\n\n.checkbox-wrapper {\n display: -ms-flexbox;\n display: flex;\n}\n\n:host([interactive]:hover) {\n\n --mds-table-row-actions-background: var(--mds-table-row-background-hover);\n --mds-table-row-background: var(--mds-table-row-background-hover);\n --mds-table-row-color: var(--mds-table-row-color-hover);\n}\n\n:host([selected]) {\n\n --mds-table-row-background: var(--mds-table-row-background-hover);\n --mds-table-row-color: var(--mds-table-row-color-hover);\n}\n\n:host([sorted]) {\n\n --mds-table-row-background: var(--mds-table-row-background-alt);\n --mds-table-row-color: var(--mds-table-row-color-alt);\n}\n\n:host([sorted][selected]) {\n\n --mds-table-row-background: var(--mds-table-row-background-hover);\n --mds-table-row-color: var(--mds-table-row-color-hover);\n}\n\n.actions-view {\n -ms-flex-align: center;\n align-items: center;\n display: -ms-flexbox;\n display: flex;\n inset: 0;\n -ms-flex-pack: end;\n justify-content: end;\n pointer-events: none;\n position: absolute;\n}\n\n.actions {\n\n --mds-table-row-actions-background: var(--mds-table-row-background);\n\n -ms-flex-align: center;\n\n align-items: center;\n background-color: var(--mds-table-row-actions-background);\n border-bottom-left-radius: calc(0.5rem + var(--mds-table-border-width) * 2);\n border-top-left-radius: calc(0.5rem + var(--mds-table-border-width) * 2);\n display: -ms-inline-flexbox;\n display: inline-flex;\n gap: var(--mds-table-row-actions-gap);\n inset: 0;\n margin-right: 100%;\n padding: calc(var(--mds-table-border-width) * 2);\n padding-right: 0;\n pointer-events: auto;\n position: -webkit-sticky;\n position: sticky;\n right: 0;\n -webkit-transform: translateX(100%);\n transform: translateX(100%);\n -webkit-transition-duration: 500ms;\n transition-duration: 500ms;\n -webkit-transition-property: background-color, padding-right, -webkit-transform;\n transition-property: background-color, padding-right, -webkit-transform;\n transition-property: transform, background-color, padding-right;\n transition-property: transform, background-color, padding-right, -webkit-transform;\n -webkit-transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n transition-timing-function: cubic-bezier(0.19, 1, 0.22, 1);\n}\n\n:host(:hover) .actions {\n -webkit-transform: translateX(100%);\n transform: translateX(100%);\n}\n\n:host([overlay-actions]) .actions {\n padding-right: var(--mds-table-cell-padding);\n -webkit-transform: translateX(100%);\n transform: translateX(100%);\n}\n\n:host([overlay-actions]:hover) .actions {\n\n --mds-table-row-actions-background: var(--mds-table-row-background);\n\n -webkit-transform: translateX(0);\n\n transform: translateX(0);\n}\n\n:host(:hover):host-context(mds-table[interactive=\"false\"]) .actions,\n:host(:hover):host-context(mds-table:not([interactive])) .actions {\n\n --mds-table-row-actions-background: var(--mds-table-row-background-hover);\n}\n\n:host(:not([selected]):hover):host-context(mds-table[selection]:not([interactive])) .actions,\n:host(:not([selected]):hover):host-context(mds-table[selection][interactive=\"false\"]) .actions,\n:host([selected=\"false\"]:hover):host-context(mds-table[selection]:not([interactive])) .actions,\n:host([selected=\"false\"]:hover):host-context(mds-table[selection][interactive=\"false\"]) .actions {\n\n --mds-table-row-actions-background: var(--mds-table-row-background-alt);\n}\n\n@container style(--magma-pref-animation: reduce) {\n :host,\n .actions {\n -webkit-transition-duration: 0s;\n transition-duration: 0s;\n }\n}\n\n@container style(--magma-pref-animation: system) {\n\n @media (prefers-reduced-motion) {\n :host,\n .actions {\n -webkit-transition-duration: 0s;\n transition-duration: 0s;\n }\n }\n}\n\n";
873
+ const isSafari = () => {
874
+ if (navigator) {
875
+ return /^((?!chrome|android).)*safari/i.test(navigator.userAgent);
876
+ }
877
+ return false;
878
+ };
879
+
880
+ const mdsTableRowCss = ":host{--mds-table-row-color-hover:var(--mds-table-color, rgb(var(--tone-neutral-02)));--mds-table-row-color-alt:var(--mds-table-color-alt, rgb(var(--tone-neutral-02)));--mds-table-row-background-hover:var(--mds-table-background, rgb(var(--tone-neutral)));--mds-table-row-background-alt:var(--mds-table-background-alt, rgb(var(--tone-neutral)));--mds-table-row-actions-gap:var(--mds-table-actions-gap, 1rem);-webkit-transition-duration:200ms;transition-duration:200ms;-webkit-transition-timing-function:cubic-bezier(0, 0, 0.2, 1);transition-timing-function:cubic-bezier(0, 0, 0.2, 1);color:var(--mds-table-row-color);display:table-row;position:relative;-webkit-transition-property:color;transition-property:color}.selection-cell{vertical-align:middle}.checkbox-wrapper{display:-ms-flexbox;display:flex}:host([interactive]:hover){--mds-table-row-actions-background:var(--mds-table-row-background-hover);--mds-table-row-background:var(--mds-table-row-background-hover);--mds-table-row-color:var(--mds-table-row-color-hover)}:host([selected]){--mds-table-row-background:var(--mds-table-row-background-hover);--mds-table-row-color:var(--mds-table-row-color-hover)}:host([sorted]){--mds-table-row-background:var(--mds-table-row-background-alt);--mds-table-row-color:var(--mds-table-row-color-alt)}:host([sorted][selected]){--mds-table-row-background:var(--mds-table-row-background-hover);--mds-table-row-color:var(--mds-table-row-color-hover)}.actions-view{-ms-flex-align:center;align-items:center;display:-ms-flexbox;display:flex;inset:0;-ms-flex-pack:end;justify-content:end;pointer-events:none;position:absolute}.actions{--mds-table-row-actions-background:var(--mds-table-row-background);-ms-flex-align:center;align-items:center;background-color:var(--mds-table-row-actions-background);border-bottom-left-radius:calc(0.5rem + var(--mds-table-border-width) * 2);border-top-left-radius:calc(0.5rem + var(--mds-table-border-width) * 2);display:-ms-inline-flexbox;display:inline-flex;gap:var(--mds-table-row-actions-gap);inset:0;margin-right:100%;padding:calc(var(--mds-table-border-width) * 2);padding-right:0;pointer-events:auto;position:-webkit-sticky;position:sticky;right:0;-webkit-transform:translateX(100%);transform:translateX(100%);-webkit-transition-duration:500ms;transition-duration:500ms;-webkit-transition-property:background-color, padding-right, -webkit-transform;transition-property:background-color, padding-right, -webkit-transform;transition-property:transform, background-color, padding-right;transition-property:transform, background-color, padding-right, -webkit-transform;-webkit-transition-timing-function:cubic-bezier(0.19, 1, 0.22, 1);transition-timing-function:cubic-bezier(0.19, 1, 0.22, 1)}:host(:hover) .actions{-webkit-transform:translateX(100%);transform:translateX(100%)}:host([overlay-actions]) .actions{padding-right:var(--mds-table-cell-padding);-webkit-transform:translateX(100%);transform:translateX(100%)}:host([overlay-actions]:hover) .actions{--mds-table-row-actions-background:var(--mds-table-row-background);-webkit-transform:translateX(0);transform:translateX(0)}:host-context(mds-table[interactive=\"false\"]):host(:hover) .actions,:host-context(mds-table:not([interactive])):host(:hover) .actions{--mds-table-row-actions-background:var(--mds-table-row-background-hover)}:host-context(mds-table[selection]:not([interactive])):host(:not([selected]):hover) .actions,:host-context(mds-table[selection][interactive=\"false\"]):host(:not([selected]):hover) .actions,:host-context(mds-table[selection]:not([interactive])):host([selected=\"false\"]:hover) .actions,:host-context(mds-table[selection][interactive=\"false\"]):host([selected=\"false\"]:hover) .actions{--mds-table-row-actions-background:var(--mds-table-row-background-alt)}.actions-cell--disable,.actions-cell--disable .actions{position:static !important}.actions-cell--disable .actions{margin-right:0 !important;-webkit-transform:translateX(0) !important;transform:translateX(0) !important}:host-context(.pref-animation-reduce){-webkit-transition-duration:0s;transition-duration:0s}@media (prefers-reduced-motion){:host-context(.pref-animation-system){-webkit-transition-duration:0s;transition-duration:0s}}:host(:not(:is([hydrated],.hydrated))){-webkit-animation-duration:0s;animation-duration:0s;border-color:transparent;-webkit-box-shadow:0 0 0 transparent;box-shadow:0 0 0 transparent;opacity:0;outline-color:transparent;-webkit-transition-delay:0s;transition-delay:0s;-webkit-transition-duration:0s;transition-duration:0s;visibility:hidden}mds-accordion:not(:is([hydrated],.hydrated)),mds-accordion-item:not(:is([hydrated],.hydrated)),mds-accordion-timer:not(:is([hydrated],.hydrated)),mds-accordion-timer-item:not(:is([hydrated],.hydrated)),mds-author:not(:is([hydrated],.hydrated)),mds-avatar:not(:is([hydrated],.hydrated)),mds-badge:not(:is([hydrated],.hydrated)),mds-banner:not(:is([hydrated],.hydrated)),mds-benchmark-bar:not(:is([hydrated],.hydrated)),mds-bibliography:not(:is([hydrated],.hydrated)),mds-breadcrumb:not(:is([hydrated],.hydrated)),mds-breadcrumb-item:not(:is([hydrated],.hydrated)),mds-button:not(:is([hydrated],.hydrated)),mds-card:not(:is([hydrated],.hydrated)),mds-card-content:not(:is([hydrated],.hydrated)),mds-card-footer:not(:is([hydrated],.hydrated)),mds-card-header:not(:is([hydrated],.hydrated)),mds-card-media:not(:is([hydrated],.hydrated)),mds-chip:not(:is([hydrated],.hydrated)),mds-details:not(:is([hydrated],.hydrated)),mds-dropdown:not(:is([hydrated],.hydrated)),mds-entity:not(:is([hydrated],.hydrated)),mds-file:not(:is([hydrated],.hydrated)),mds-file-preview:not(:is([hydrated],.hydrated)),mds-filter:not(:is([hydrated],.hydrated)),mds-filter-item:not(:is([hydrated],.hydrated)),mds-header:not(:is([hydrated],.hydrated)),mds-header-bar:not(:is([hydrated],.hydrated)),mds-help:not(:is([hydrated],.hydrated)),mds-horizontal-scroll:not(:is([hydrated],.hydrated)),mds-hr:not(:is([hydrated],.hydrated)),mds-icon:not(:is([hydrated],.hydrated)),mds-img:not(:is([hydrated],.hydrated)),mds-input:not(:is([hydrated],.hydrated)),mds-input-field:not(:is([hydrated],.hydrated)),mds-input-range:not(:is([hydrated],.hydrated)),mds-input-select:not(:is([hydrated],.hydrated)),mds-input-switch:not(:is([hydrated],.hydrated)),mds-input-tip:not(:is([hydrated],.hydrated)),mds-input-tip-item:not(:is([hydrated],.hydrated)),mds-input-upload:not(:is([hydrated],.hydrated)),mds-keyboard:not(:is([hydrated],.hydrated)),mds-keyboard-key:not(:is([hydrated],.hydrated)),mds-kpi:not(:is([hydrated],.hydrated)),mds-kpi-item:not(:is([hydrated],.hydrated)),mds-label:not(:is([hydrated],.hydrated)),mds-list:not(:is([hydrated],.hydrated)),mds-list-item:not(:is([hydrated],.hydrated)),mds-modal:not(:is([hydrated],.hydrated)),mds-note:not(:is([hydrated],.hydrated)),mds-notification:not(:is([hydrated],.hydrated)),mds-paginator:not(:is([hydrated],.hydrated)),mds-paginator-item:not(:is([hydrated],.hydrated)),mds-pref:not(:is([hydrated],.hydrated)),mds-pref-animation:not(:is([hydrated],.hydrated)),mds-pref-consumption:not(:is([hydrated],.hydrated)),mds-pref-contrast:not(:is([hydrated],.hydrated)),mds-pref-language:not(:is([hydrated],.hydrated)),mds-pref-language-item:not(:is([hydrated],.hydrated)),mds-pref-theme:not(:is([hydrated],.hydrated)),mds-price-table:not(:is([hydrated],.hydrated)),mds-price-table-features:not(:is([hydrated],.hydrated)),mds-price-table-features-cell:not(:is([hydrated],.hydrated)),mds-price-table-features-row:not(:is([hydrated],.hydrated)),mds-price-table-header:not(:is([hydrated],.hydrated)),mds-price-table-list:not(:is([hydrated],.hydrated)),mds-price-table-list-item:not(:is([hydrated],.hydrated)),mds-progress:not(:is([hydrated],.hydrated)),mds-push-notification:not(:is([hydrated],.hydrated)),mds-push-notifications:not(:is([hydrated],.hydrated)),mds-quote:not(:is([hydrated],.hydrated)),mds-separator:not(:is([hydrated],.hydrated)),mds-spinner:not(:is([hydrated],.hydrated)),mds-stepper-bar:not(:is([hydrated],.hydrated)),mds-stepper-bar-item:not(:is([hydrated],.hydrated)),mds-tab:not(:is([hydrated],.hydrated)),mds-tab-bar:not(:is([hydrated],.hydrated)),mds-tab-bar-item:not(:is([hydrated],.hydrated)),mds-tab-item:not(:is([hydrated],.hydrated)),mds-table:not(:is([hydrated],.hydrated)),mds-table-body:not(:is([hydrated],.hydrated)),mds-table-cell:not(:is([hydrated],.hydrated)),mds-table-footer:not(:is([hydrated],.hydrated)),mds-table-header:not(:is([hydrated],.hydrated)),mds-table-header-cell:not(:is([hydrated],.hydrated)),mds-table-row:not(:is([hydrated],.hydrated)),mds-text:not(:is([hydrated],.hydrated)),mds-toast:not(:is([hydrated],.hydrated)),mds-tooltip:not(:is([hydrated],.hydrated)),mds-tree:not(:is([hydrated],.hydrated)),mds-tree-item:not(:is([hydrated],.hydrated)),mds-url-view:not(:is([hydrated],.hydrated)),mds-usage:not(:is([hydrated],.hydrated)),mds-video-wall:not(:is([hydrated],.hydrated)),mds-zero:not(:is([hydrated],.hydrated)){-webkit-animation-duration:0s;animation-duration:0s;border-color:transparent;-webkit-box-shadow:0 0 0 transparent;box-shadow:0 0 0 transparent;opacity:0;outline-color:transparent;-webkit-transition-delay:0s;transition-delay:0s;-webkit-transition-duration:0s;transition-duration:0s;visibility:hidden}";
874
881
  const MdsTableRowStyle0 = mdsTableRowCss;
875
882
 
876
883
  const MdsTableRow$1 = /*@__PURE__*/ proxyCustomElement(class MdsTableRow extends HTMLElement {
@@ -878,6 +885,7 @@ const MdsTableRow$1 = /*@__PURE__*/ proxyCustomElement(class MdsTableRow extends
878
885
  super();
879
886
  this.__registerHost();
880
887
  this.__attachShadow();
888
+ this.hasActions = true;
881
889
  this.t = new Locale({
882
890
  el: localeEl,
883
891
  en: localeEn,
@@ -897,7 +905,7 @@ const MdsTableRow$1 = /*@__PURE__*/ proxyCustomElement(class MdsTableRow extends
897
905
  }
898
906
  componentWillLoad() {
899
907
  this.language = this.t.lang(this.host);
900
- this.hasActions = this.host.querySelector('[slot="action"]') !== null;
908
+ this.hasActions = this.host.querySelector(':scope > [slot="action"]') !== null;
901
909
  }
902
910
  componentDidLoad() {
903
911
  var _a;
@@ -907,15 +915,16 @@ const MdsTableRow$1 = /*@__PURE__*/ proxyCustomElement(class MdsTableRow extends
907
915
  }
908
916
  }
909
917
  render() {
910
- return (h(Host, { key: '4905591b94a0af846d25e3cf55fe5805ecec76be', role: "row" }, this.selectable &&
911
- h("mds-table-cell", { key: '07f8596969f20148250cc42fde0a806435825274', class: "selection-cell" }, h("div", { key: '2d0bb74f3f5edaf6180c68a60457b374dcd7a4bd', class: "checkbox-wrapper" }, h("mds-input-switch", { key: 'e04fafd6a53ed1c6a4208b0317419fe21d08f28e', title: this.t.get(this.selected ? 'unselectRow' : 'selectRow'), lang: this.language, type: "checkbox", checked: this.selected, onMdsInputSwitchChange: this.handleSelectionChange }))), h("slot", { key: 'd71c2ec9e675fd8190eeeb7d816a5e2566c6afc4' }), this.hasActions &&
912
- h("mds-table-cell", { key: '0ede2c5f98d7541920c4170d70c21f9f61ac93cb', class: "actions-cell" }, h("div", { key: '8a097d4b04bd594778f51bedfe438fe1fd3479b3', class: "actions-sizer", style: {
918
+ return (h(Host, { key: 'ddc3467a490c2bd90fe51e21a5fe67268a09cabd', role: "row" }, this.selectable &&
919
+ h("mds-table-cell", { key: 'e0aae0041d28b4a39e2cdfef98f8ceb34703613b', class: "selection-cell" }, h("div", { key: 'daf5de2fcfdb0f1863109feb96b533f9bdec1e43', class: "checkbox-wrapper" }, h("mds-input-switch", { key: 'd27bd2000b73115b7c9c2ad7705fcda40d134c04', title: this.t.get(this.selected ? 'unselectRow' : 'selectRow'), lang: this.language, type: "checkbox", checked: this.selected, onMdsInputSwitchChange: this.handleSelectionChange }))), h("slot", { key: '2eb2218ac36175a75569199cb837c00ab56ef3d0' }), this.hasActions && isSafari() &&
920
+ h("mds-table-cell", { key: '0c74ae109c1112d79fc9a65412d032105fb1cdef', class: "actions-cell actions-cell--disable" }, h("div", { key: '969b05e04cb68ec781ba5227de80a8b0357e299c', class: "actions" }, h("slot", { key: '04ee8a48cf0ac01a0bc25b7e819e57767a6443a7', name: "action" }))), this.hasActions && !isSafari() &&
921
+ h("mds-table-cell", { key: '39dba4bf1fc6c2892705608bca1f68e70ce47c7c', class: "actions-cell" }, h("div", { key: '2cab6097ba0bfe85f258ee9f569d92f75fd58208', class: "actions-sizer", style: {
913
922
  minHeight: '1px',
914
923
  maxWidth: this.sizerWidth,
915
924
  minWidth: this.sizerWidth,
916
- } }), h("div", { key: '31f1fe8d7e4ee01f33f1c6a5b76e23fd875dfd82', class: "actions-view" }, h("div", { key: '762785e31a306ba3c1e7654218bdf8cb33044cd3', class: "actions", style: {
925
+ } }), h("div", { key: '1c77e27a925fe8fc003fcdd17f760f35a306027b', class: "actions-view" }, h("div", { key: '962a79184fa4cb6de61d443a65d9481b24cbb603', class: "actions", style: {
917
926
  marginRight: `calc(${this.sizerWidth} + var(--mds-table-cell-padding))`,
918
- } }, h("slot", { key: '05ea2b5edc71e58859e55e52c1ab65ca0c5354f8', name: "action" }))))));
927
+ } }, h("slot", { key: 'fde4f3d477475c8dfdb3346e84e3125f964b7676', name: "action" }))))));
919
928
  }
920
929
  get host() { return this; }
921
930
  static get style() { return MdsTableRowStyle0; }
@@ -1,8 +1,8 @@
1
1
  {
2
- "timestamp": "2025-02-25T15:13:43",
2
+ "timestamp": "2025-03-10T12:58:27",
3
3
  "compiler": {
4
4
  "name": "@stencil/core",
5
- "version": "4.25.1",
5
+ "version": "4.27.2",
6
6
  "typescriptVersion": "5.5.4"
7
7
  },
8
8
  "components": [
@@ -15,6 +15,10 @@
15
15
  {
16
16
  "name": "slot",
17
17
  "text": "default - Put `mds-table-cell` element/s."
18
+ },
19
+ {
20
+ "name": "slot",
21
+ "text": "action - Put `mds-button` element/s or other kind of actions as aside menu for the single row."
18
22
  }
19
23
  ],
20
24
  "usage": {},
@@ -179,6 +183,10 @@
179
183
  "listeners": [],
180
184
  "styles": [],
181
185
  "slots": [
186
+ {
187
+ "name": "action",
188
+ "docs": "Put `mds-button` element/s or other kind of actions as aside menu for the single row."
189
+ },
182
190
  {
183
191
  "name": "default",
184
192
  "docs": "Put `mds-table-cell` element/s."