xv-webcomponents 0.1.30 → 0.1.32
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/dist/cjs/{index-782b9733.js → index-5ee1b884.js} +43 -2
- package/dist/cjs/index-5ee1b884.js.map +1 -0
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/{utils-aa46f72a.js → utils-22c0eda0.js} +1 -16
- package/dist/cjs/utils-22c0eda0.js.map +1 -0
- package/dist/cjs/{xv-accordion-v2_28.cjs.entry.js → xv-accordion-v2_26.cjs.entry.js} +191 -440
- package/dist/cjs/xv-accordion-v2_26.cjs.entry.js.map +1 -0
- package/dist/cjs/xv-breadcrumbs-v2.cjs.entry.js +1 -1
- package/dist/cjs/xv-webcomponents.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +1 -3
- package/dist/collection/components/xv-checkbox/xv-checkbox.css +4 -1
- package/dist/collection/components/xv-checkbox/xv-checkbox.js +1 -1
- package/dist/collection/components/xv-checkbox/xv-checkbox.js.map +1 -1
- package/dist/collection/components/xv-dropdown/xv-dropdown-item/xv-dropdown-item.js +1 -1
- package/dist/collection/components/xv-dropdown/xv-dropdown.css +1 -1
- package/dist/collection/components/xv-dropdown/xv-dropdown.js +41 -11
- package/dist/collection/components/xv-dropdown/xv-dropdown.js.map +1 -1
- package/dist/collection/components/xv-footer/xv-footer.js +1 -1
- package/dist/collection/components/xv-header/xv-header.js +1 -1
- package/dist/collection/components/xv-link/xv-link.css +5 -0
- package/dist/collection/components/xv-link/xv-link.js +3 -3
- package/dist/collection/components/xv-link/xv-link.js.map +1 -1
- package/dist/collection/components/xv-modal/xv-modal.css +8 -4
- package/dist/collection/components/xv-modal/xv-modal.js +31 -7
- package/dist/collection/components/xv-modal/xv-modal.js.map +1 -1
- package/dist/collection/components/xv-notification/xv-notification.js +3 -3
- package/dist/collection/components/xv-notification/xv-notification.js.map +1 -1
- package/dist/collection/components/xv-overflow-menu/xv-overflow-menu-item/xv-overflow-menu-item.js +1 -1
- package/dist/collection/components/xv-overflow-menu/xv-overflow-menu.css +3 -0
- package/dist/collection/components/xv-overflow-menu/xv-overflow-menu.js +1 -1
- package/dist/collection/components/xv-progress-indicator/xv-progress-indicator-item/xv-progress-indicator-item.js +1 -1
- package/dist/collection/components/xv-progress-indicator/xv-progress-indicator.js +2 -2
- package/dist/collection/components/xv-progress-indicator/xv-progress-indicator.js.map +1 -1
- package/dist/collection/components/xv-table/_vars.js +9 -0
- package/dist/collection/components/xv-table/_vars.js.map +1 -0
- package/dist/collection/components/xv-table/xv-table-cell/xv-table-cell.css +93 -0
- package/dist/collection/components/xv-table/xv-table-cell/xv-table-cell.js +160 -0
- package/dist/collection/components/xv-table/xv-table-cell/xv-table-cell.js.map +1 -0
- package/dist/collection/components/xv-table/xv-table-expand/xv-table-expand.css +55 -114
- package/dist/collection/components/xv-table/xv-table-expand/xv-table-expand.js +28 -151
- package/dist/collection/components/xv-table/xv-table-expand/xv-table-expand.js.map +1 -1
- package/dist/collection/components/xv-table/xv-table-row/xv-table-row.css +27 -34
- package/dist/collection/components/xv-table/xv-table-row/xv-table-row.js +165 -106
- package/dist/collection/components/xv-table/xv-table-row/xv-table-row.js.map +1 -1
- package/dist/collection/components/xv-table/xv-table.css +101 -141
- package/dist/collection/components/xv-table/xv-table.js +70 -196
- package/dist/collection/components/xv-table/xv-table.js.map +1 -1
- package/dist/collection/components/xv-tabs/xv-tab/xv-tab.css +7 -0
- package/dist/collection/components/xv-tabs/xv-tab/xv-tab.js +44 -3
- package/dist/collection/components/xv-tabs/xv-tab/xv-tab.js.map +1 -1
- package/dist/collection/components/xv-tabs/xv-tabs.css +60 -12
- package/dist/collection/components/xv-tabs/xv-tabs.js +97 -48
- package/dist/collection/components/xv-tabs/xv-tabs.js.map +1 -1
- package/dist/collection/components/xv-tag/xv-tag.js +1 -1
- package/dist/collection/components/xv-text-input/xv-text-input.js +53 -10
- package/dist/collection/components/xv-text-input/xv-text-input.js.map +1 -1
- package/dist/collection/components/xv-tooltip/xv-tooltip.css +6 -1
- package/dist/collection/components/xv-tooltip/xv-tooltip.js +22 -3
- package/dist/collection/components/xv-tooltip/xv-tooltip.js.map +1 -1
- package/dist/esm/{index-83ab73b7.js → index-590eb7d2.js} +43 -3
- package/dist/esm/index-590eb7d2.js.map +1 -0
- package/dist/esm/index.js +1 -1
- package/dist/esm/loader.js +3 -3
- package/dist/esm/{utils-0d1c18d5.js → utils-a9c71376.js} +2 -16
- package/dist/esm/utils-a9c71376.js.map +1 -0
- package/dist/esm/{xv-accordion-v2_28.entry.js → xv-accordion-v2_26.entry.js} +191 -438
- package/dist/esm/xv-accordion-v2_26.entry.js.map +1 -0
- package/dist/esm/xv-breadcrumbs-v2.entry.js +1 -1
- package/dist/esm/xv-webcomponents.js +3 -3
- package/dist/types/components/xv-dropdown/xv-dropdown.d.ts +2 -0
- package/dist/types/components/xv-link/xv-link.d.ts +1 -1
- package/dist/types/components/xv-modal/xv-modal.d.ts +5 -1
- package/dist/types/components/xv-table/_vars.d.ts +19 -0
- package/dist/types/components/xv-table/xv-table-cell/xv-table-cell.d.ts +12 -0
- package/dist/types/components/xv-table/xv-table-expand/xv-table-expand.d.ts +4 -20
- package/dist/types/components/xv-table/xv-table-row/xv-table-row.d.ts +16 -46
- package/dist/types/components/xv-table/xv-table.d.ts +10 -32
- package/dist/types/components/xv-tabs/xv-tab/xv-tab.d.ts +2 -0
- package/dist/types/components/xv-tabs/xv-tabs.d.ts +15 -11
- package/dist/types/components/xv-text-input/xv-text-input.d.ts +3 -0
- package/dist/types/components/xv-tooltip/xv-tooltip.d.ts +1 -0
- package/dist/types/components.d.ts +127 -265
- package/dist/xv-webcomponents/index.esm.js +1 -1
- package/dist/xv-webcomponents/p-51113bf3.entry.js +2 -0
- package/dist/xv-webcomponents/p-51113bf3.entry.js.map +1 -0
- package/dist/xv-webcomponents/p-612356e6.js +3 -0
- package/dist/xv-webcomponents/p-612356e6.js.map +1 -0
- package/dist/xv-webcomponents/p-c09a0bfe.entry.js +2 -0
- package/dist/xv-webcomponents/p-f98a1845.js +2 -0
- package/dist/xv-webcomponents/p-f98a1845.js.map +1 -0
- package/dist/xv-webcomponents/xv-webcomponents.esm.js +1 -1
- package/dist/xv-webcomponents/xv-webcomponents.esm.js.map +1 -1
- package/package.json +1 -1
- package/dist/cjs/index-782b9733.js.map +0 -1
- package/dist/cjs/utils-aa46f72a.js.map +0 -1
- package/dist/cjs/xv-accordion-v2_28.cjs.entry.js.map +0 -1
- package/dist/collection/components/xv-table/defs.js +0 -28
- package/dist/collection/components/xv-table/defs.js.map +0 -1
- package/dist/collection/components/xv-table/xv-table-col/xv-table-col.css +0 -13
- package/dist/collection/components/xv-table/xv-table-col/xv-table-col.js +0 -111
- package/dist/collection/components/xv-table/xv-table-col/xv-table-col.js.map +0 -1
- package/dist/collection/components/xv-table/xv-table-header-row/xv-table-header-row.css +0 -80
- package/dist/collection/components/xv-table/xv-table-header-row/xv-table-header-row.js +0 -172
- package/dist/collection/components/xv-table/xv-table-header-row/xv-table-header-row.js.map +0 -1
- package/dist/collection/components/xv-table/xv-table-toolbar/xv-table-toolbar.css +0 -47
- package/dist/collection/components/xv-table/xv-table-toolbar/xv-table-toolbar.js +0 -78
- package/dist/collection/components/xv-table/xv-table-toolbar/xv-table-toolbar.js.map +0 -1
- package/dist/esm/index-83ab73b7.js.map +0 -1
- package/dist/esm/utils-0d1c18d5.js.map +0 -1
- package/dist/esm/xv-accordion-v2_28.entry.js.map +0 -1
- package/dist/types/components/xv-table/defs.d.ts +0 -38
- package/dist/types/components/xv-table/xv-table-col/xv-table-col.d.ts +0 -9
- package/dist/types/components/xv-table/xv-table-header-row/xv-table-header-row.d.ts +0 -28
- package/dist/types/components/xv-table/xv-table-toolbar/xv-table-toolbar.d.ts +0 -6
- package/dist/xv-webcomponents/p-39bf1511.js +0 -2
- package/dist/xv-webcomponents/p-39bf1511.js.map +0 -1
- package/dist/xv-webcomponents/p-5f18d718.entry.js +0 -2
- package/dist/xv-webcomponents/p-840929c5.js +0 -3
- package/dist/xv-webcomponents/p-840929c5.js.map +0 -1
- package/dist/xv-webcomponents/p-cc83f7ea.entry.js +0 -2
- package/dist/xv-webcomponents/p-cc83f7ea.entry.js.map +0 -1
- /package/dist/xv-webcomponents/{p-5f18d718.entry.js.map → p-c09a0bfe.entry.js.map} +0 -0
|
@@ -1,57 +1,52 @@
|
|
|
1
1
|
import { Host, h } from "@stencil/core";
|
|
2
|
-
import {
|
|
2
|
+
import { XV_EXPANDABLE_KEY, XV_TABLE_TAG } from "../_vars";
|
|
3
|
+
import { setAttr, uidGenerator } from "../../../utils/utils";
|
|
3
4
|
export class XvTableRow {
|
|
4
5
|
constructor() {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
this.hovered = false;
|
|
20
|
-
this.checkboxChange = (e) => {
|
|
21
|
-
this.checked = e.detail;
|
|
22
|
-
};
|
|
23
|
-
this.onExpandHandle = async () => {
|
|
24
|
-
this.expanded = !this.expanded;
|
|
25
|
-
const parent = this.el.parentElement;
|
|
26
|
-
if (parent.tagName === TABLE_TAG.EXPAND) {
|
|
27
|
-
await (parent === null || parent === void 0 ? void 0 : parent.toggleExpand(this.expanded));
|
|
28
|
-
}
|
|
6
|
+
this.checkHandle = ({ detail: checked }) => {
|
|
7
|
+
this.checked = checked;
|
|
8
|
+
if (!checked && this.partial)
|
|
9
|
+
this.partial = checked;
|
|
10
|
+
if (!this.name)
|
|
11
|
+
this.name = uidGenerator();
|
|
12
|
+
this.selectRow.emit({
|
|
13
|
+
name: this.name,
|
|
14
|
+
value: this.value,
|
|
15
|
+
checked: this.checked,
|
|
16
|
+
partial: this.partial,
|
|
17
|
+
header: this.header,
|
|
18
|
+
expandable: this.el.getAttribute('slot') === XV_EXPANDABLE_KEY,
|
|
19
|
+
});
|
|
29
20
|
};
|
|
30
21
|
}
|
|
31
22
|
checkedChangeHandle() {
|
|
32
|
-
|
|
33
|
-
name
|
|
23
|
+
if (!this.name)
|
|
24
|
+
this.name = uidGenerator();
|
|
25
|
+
this.checkedChange.emit({
|
|
26
|
+
name: this.name,
|
|
34
27
|
value: this.value,
|
|
35
28
|
checked: this.checked,
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
}
|
|
40
|
-
if (changeData.group) {
|
|
41
|
-
this.checkedGroupChange.emit(changeData);
|
|
42
|
-
}
|
|
43
|
-
else {
|
|
44
|
-
this.checkedChange.emit(changeData);
|
|
45
|
-
}
|
|
29
|
+
partial: this.partial,
|
|
30
|
+
header: this.header,
|
|
31
|
+
expandable: this.el.getAttribute('slot') === XV_EXPANDABLE_KEY,
|
|
32
|
+
});
|
|
46
33
|
}
|
|
47
|
-
|
|
48
|
-
this.
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
34
|
+
setInitialAttrs() {
|
|
35
|
+
if (this.variant || !this.hover) {
|
|
36
|
+
const tableEl = this.el.closest(XV_TABLE_TAG);
|
|
37
|
+
if (!this.hover) {
|
|
38
|
+
this.hover = tableEl.hasAttribute('hover');
|
|
39
|
+
}
|
|
40
|
+
if (this.variant) {
|
|
41
|
+
setAttr(this.el.closest(XV_TABLE_TAG), `variant-${this.variant}`, !!this.variant);
|
|
42
|
+
}
|
|
43
|
+
}
|
|
52
44
|
}
|
|
53
45
|
render() {
|
|
54
|
-
return (h(Host, { key: '
|
|
46
|
+
return (h(Host, { key: 'a83693a0ac8a484e77d6569e9c5e6d5552d1e4bd' }, this.variant !== undefined && (h("xv-table-v2-cell", { key: '79c530cedc2dedfe7a3f30cca998d96e8e26e68d', class: "cell-control" }, this.variant === 'checkbox' && (h("xv-checkbox-v2", { key: 'd5e061b229448bba6d71321cff99aac9947a55d1', name: this.name, partial: this.partial, checked: this.checked || this.partial, disabled: this.disabled, required: this.required, readonly: this.readonly, onEventChange: this.checkHandle })), this.variant === 'radio' && (h("input", { key: 'e39cc7c88c199863810e4b261bc833cac4f5d883', type: "radio", name: this.name, checked: this.checked || this.partial, disabled: this.disabled, required: this.required, readonly: this.readonly })))), h("slot", { key: '17151fe90edcb037bc504f88a33bd206e684c402' })));
|
|
47
|
+
}
|
|
48
|
+
componentWillLoad() {
|
|
49
|
+
this.setInitialAttrs();
|
|
55
50
|
}
|
|
56
51
|
static get is() { return "xv-table-v2-row"; }
|
|
57
52
|
static get encapsulation() { return "shadow"; }
|
|
@@ -67,107 +62,166 @@ export class XvTableRow {
|
|
|
67
62
|
}
|
|
68
63
|
static get properties() {
|
|
69
64
|
return {
|
|
70
|
-
"
|
|
65
|
+
"checked": {
|
|
71
66
|
"type": "boolean",
|
|
72
|
-
"mutable":
|
|
67
|
+
"mutable": true,
|
|
73
68
|
"complexType": {
|
|
74
|
-
"original": "
|
|
69
|
+
"original": "SelectRowDto['checked']",
|
|
75
70
|
"resolved": "boolean",
|
|
76
|
-
"references": {
|
|
71
|
+
"references": {
|
|
72
|
+
"SelectRowDto": {
|
|
73
|
+
"location": "import",
|
|
74
|
+
"path": "../_vars",
|
|
75
|
+
"id": "src/components/xv-table/_vars.ts::SelectRowDto"
|
|
76
|
+
}
|
|
77
|
+
}
|
|
77
78
|
},
|
|
78
79
|
"required": false,
|
|
79
|
-
"optional":
|
|
80
|
+
"optional": true,
|
|
80
81
|
"docs": {
|
|
81
82
|
"tags": [],
|
|
82
|
-
"text": "
|
|
83
|
+
"text": ""
|
|
83
84
|
},
|
|
84
85
|
"getter": false,
|
|
85
86
|
"setter": false,
|
|
86
|
-
"attribute": "
|
|
87
|
-
"reflect": true
|
|
88
|
-
"defaultValue": "false"
|
|
87
|
+
"attribute": "checked",
|
|
88
|
+
"reflect": true
|
|
89
89
|
},
|
|
90
|
-
"
|
|
90
|
+
"partial": {
|
|
91
91
|
"type": "boolean",
|
|
92
92
|
"mutable": true,
|
|
93
93
|
"complexType": {
|
|
94
|
-
"original": "
|
|
94
|
+
"original": "SelectRowDto['partial']",
|
|
95
95
|
"resolved": "boolean",
|
|
96
|
-
"references": {
|
|
96
|
+
"references": {
|
|
97
|
+
"SelectRowDto": {
|
|
98
|
+
"location": "import",
|
|
99
|
+
"path": "../_vars",
|
|
100
|
+
"id": "src/components/xv-table/_vars.ts::SelectRowDto"
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
"required": false,
|
|
105
|
+
"optional": true,
|
|
106
|
+
"docs": {
|
|
107
|
+
"tags": [],
|
|
108
|
+
"text": ""
|
|
109
|
+
},
|
|
110
|
+
"getter": false,
|
|
111
|
+
"setter": false,
|
|
112
|
+
"attribute": "partial",
|
|
113
|
+
"reflect": true
|
|
114
|
+
},
|
|
115
|
+
"name": {
|
|
116
|
+
"type": "string",
|
|
117
|
+
"mutable": true,
|
|
118
|
+
"complexType": {
|
|
119
|
+
"original": "SelectRowDto['name']",
|
|
120
|
+
"resolved": "string",
|
|
121
|
+
"references": {
|
|
122
|
+
"SelectRowDto": {
|
|
123
|
+
"location": "import",
|
|
124
|
+
"path": "../_vars",
|
|
125
|
+
"id": "src/components/xv-table/_vars.ts::SelectRowDto"
|
|
126
|
+
}
|
|
127
|
+
}
|
|
97
128
|
},
|
|
98
129
|
"required": false,
|
|
99
|
-
"optional":
|
|
130
|
+
"optional": true,
|
|
100
131
|
"docs": {
|
|
101
132
|
"tags": [],
|
|
102
|
-
"text": "
|
|
133
|
+
"text": ""
|
|
103
134
|
},
|
|
104
135
|
"getter": false,
|
|
105
136
|
"setter": false,
|
|
106
|
-
"attribute": "
|
|
107
|
-
"reflect": true
|
|
108
|
-
"defaultValue": "false"
|
|
137
|
+
"attribute": "name",
|
|
138
|
+
"reflect": true
|
|
109
139
|
},
|
|
110
|
-
"
|
|
111
|
-
"type": "
|
|
140
|
+
"value": {
|
|
141
|
+
"type": "any",
|
|
112
142
|
"mutable": false,
|
|
143
|
+
"complexType": {
|
|
144
|
+
"original": "SelectRowDto['value']",
|
|
145
|
+
"resolved": "number | object | string",
|
|
146
|
+
"references": {
|
|
147
|
+
"SelectRowDto": {
|
|
148
|
+
"location": "import",
|
|
149
|
+
"path": "../_vars",
|
|
150
|
+
"id": "src/components/xv-table/_vars.ts::SelectRowDto"
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
"required": false,
|
|
155
|
+
"optional": true,
|
|
156
|
+
"docs": {
|
|
157
|
+
"tags": [],
|
|
158
|
+
"text": ""
|
|
159
|
+
},
|
|
160
|
+
"getter": false,
|
|
161
|
+
"setter": false,
|
|
162
|
+
"attribute": "value",
|
|
163
|
+
"reflect": true
|
|
164
|
+
},
|
|
165
|
+
"hover": {
|
|
166
|
+
"type": "boolean",
|
|
167
|
+
"mutable": true,
|
|
113
168
|
"complexType": {
|
|
114
169
|
"original": "boolean",
|
|
115
170
|
"resolved": "boolean",
|
|
116
171
|
"references": {}
|
|
117
172
|
},
|
|
118
173
|
"required": false,
|
|
119
|
-
"optional":
|
|
174
|
+
"optional": true,
|
|
120
175
|
"docs": {
|
|
121
176
|
"tags": [],
|
|
122
|
-
"text": "
|
|
177
|
+
"text": ""
|
|
123
178
|
},
|
|
124
179
|
"getter": false,
|
|
125
180
|
"setter": false,
|
|
126
|
-
"attribute": "
|
|
127
|
-
"reflect": true
|
|
128
|
-
"defaultValue": "false"
|
|
181
|
+
"attribute": "hover",
|
|
182
|
+
"reflect": true
|
|
129
183
|
},
|
|
130
|
-
"
|
|
131
|
-
"type": "
|
|
184
|
+
"readonly": {
|
|
185
|
+
"type": "boolean",
|
|
132
186
|
"mutable": false,
|
|
133
187
|
"complexType": {
|
|
134
|
-
"original": "
|
|
135
|
-
"resolved": "
|
|
188
|
+
"original": "boolean",
|
|
189
|
+
"resolved": "boolean",
|
|
136
190
|
"references": {}
|
|
137
191
|
},
|
|
138
192
|
"required": false,
|
|
139
193
|
"optional": true,
|
|
140
194
|
"docs": {
|
|
141
195
|
"tags": [],
|
|
142
|
-
"text": "
|
|
196
|
+
"text": ""
|
|
143
197
|
},
|
|
144
198
|
"getter": false,
|
|
145
199
|
"setter": false,
|
|
146
|
-
"attribute": "
|
|
200
|
+
"attribute": "readonly",
|
|
147
201
|
"reflect": true
|
|
148
202
|
},
|
|
149
|
-
"
|
|
150
|
-
"type": "
|
|
203
|
+
"required": {
|
|
204
|
+
"type": "boolean",
|
|
151
205
|
"mutable": false,
|
|
152
206
|
"complexType": {
|
|
153
|
-
"original": "
|
|
154
|
-
"resolved": "
|
|
207
|
+
"original": "boolean",
|
|
208
|
+
"resolved": "boolean",
|
|
155
209
|
"references": {}
|
|
156
210
|
},
|
|
157
211
|
"required": false,
|
|
158
212
|
"optional": true,
|
|
159
213
|
"docs": {
|
|
160
214
|
"tags": [],
|
|
161
|
-
"text": "
|
|
215
|
+
"text": ""
|
|
162
216
|
},
|
|
163
217
|
"getter": false,
|
|
164
218
|
"setter": false,
|
|
165
|
-
"attribute": "
|
|
219
|
+
"attribute": "required",
|
|
166
220
|
"reflect": true
|
|
167
221
|
},
|
|
168
|
-
"
|
|
222
|
+
"disabled": {
|
|
169
223
|
"type": "boolean",
|
|
170
|
-
"mutable":
|
|
224
|
+
"mutable": false,
|
|
171
225
|
"complexType": {
|
|
172
226
|
"original": "boolean",
|
|
173
227
|
"resolved": "boolean",
|
|
@@ -177,14 +231,14 @@ export class XvTableRow {
|
|
|
177
231
|
"optional": true,
|
|
178
232
|
"docs": {
|
|
179
233
|
"tags": [],
|
|
180
|
-
"text": "
|
|
234
|
+
"text": ""
|
|
181
235
|
},
|
|
182
236
|
"getter": false,
|
|
183
237
|
"setter": false,
|
|
184
|
-
"attribute": "
|
|
238
|
+
"attribute": "disabled",
|
|
185
239
|
"reflect": true
|
|
186
240
|
},
|
|
187
|
-
"
|
|
241
|
+
"header": {
|
|
188
242
|
"type": "boolean",
|
|
189
243
|
"mutable": false,
|
|
190
244
|
"complexType": {
|
|
@@ -196,19 +250,19 @@ export class XvTableRow {
|
|
|
196
250
|
"optional": true,
|
|
197
251
|
"docs": {
|
|
198
252
|
"tags": [],
|
|
199
|
-
"text": "
|
|
253
|
+
"text": ""
|
|
200
254
|
},
|
|
201
255
|
"getter": false,
|
|
202
256
|
"setter": false,
|
|
203
|
-
"attribute": "
|
|
257
|
+
"attribute": "header",
|
|
204
258
|
"reflect": true
|
|
205
259
|
},
|
|
206
|
-
"
|
|
260
|
+
"variant": {
|
|
207
261
|
"type": "string",
|
|
208
|
-
"mutable":
|
|
262
|
+
"mutable": true,
|
|
209
263
|
"complexType": {
|
|
210
|
-
"original": "
|
|
211
|
-
"resolved": "
|
|
264
|
+
"original": "'checkbox' | 'radio' | ''",
|
|
265
|
+
"resolved": "\"\" | \"checkbox\" | \"radio\"",
|
|
212
266
|
"references": {}
|
|
213
267
|
},
|
|
214
268
|
"required": false,
|
|
@@ -219,18 +273,11 @@ export class XvTableRow {
|
|
|
219
273
|
},
|
|
220
274
|
"getter": false,
|
|
221
275
|
"setter": false,
|
|
222
|
-
"attribute": "
|
|
276
|
+
"attribute": "variant",
|
|
223
277
|
"reflect": true
|
|
224
278
|
}
|
|
225
279
|
};
|
|
226
280
|
}
|
|
227
|
-
static get states() {
|
|
228
|
-
return {
|
|
229
|
-
"id": {},
|
|
230
|
-
"cols": {},
|
|
231
|
-
"hovered": {}
|
|
232
|
-
};
|
|
233
|
-
}
|
|
234
281
|
static get events() {
|
|
235
282
|
return [{
|
|
236
283
|
"method": "checkedChange",
|
|
@@ -243,13 +290,19 @@ export class XvTableRow {
|
|
|
243
290
|
"text": ""
|
|
244
291
|
},
|
|
245
292
|
"complexType": {
|
|
246
|
-
"original": "
|
|
247
|
-
"resolved": "
|
|
248
|
-
"references": {
|
|
293
|
+
"original": "SelectRowDto",
|
|
294
|
+
"resolved": "SelectRowDto",
|
|
295
|
+
"references": {
|
|
296
|
+
"SelectRowDto": {
|
|
297
|
+
"location": "import",
|
|
298
|
+
"path": "../_vars",
|
|
299
|
+
"id": "src/components/xv-table/_vars.ts::SelectRowDto"
|
|
300
|
+
}
|
|
301
|
+
}
|
|
249
302
|
}
|
|
250
303
|
}, {
|
|
251
|
-
"method": "
|
|
252
|
-
"name": "
|
|
304
|
+
"method": "selectRow",
|
|
305
|
+
"name": "selectRow",
|
|
253
306
|
"bubbles": true,
|
|
254
307
|
"cancelable": true,
|
|
255
308
|
"composed": true,
|
|
@@ -258,9 +311,15 @@ export class XvTableRow {
|
|
|
258
311
|
"text": ""
|
|
259
312
|
},
|
|
260
313
|
"complexType": {
|
|
261
|
-
"original": "
|
|
262
|
-
"resolved": "
|
|
263
|
-
"references": {
|
|
314
|
+
"original": "SelectRowDto",
|
|
315
|
+
"resolved": "SelectRowDto",
|
|
316
|
+
"references": {
|
|
317
|
+
"SelectRowDto": {
|
|
318
|
+
"location": "import",
|
|
319
|
+
"path": "../_vars",
|
|
320
|
+
"id": "src/components/xv-table/_vars.ts::SelectRowDto"
|
|
321
|
+
}
|
|
322
|
+
}
|
|
264
323
|
}
|
|
265
324
|
}];
|
|
266
325
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"xv-table-row.js","sourceRoot":"","sources":["../../../../src/components/xv-table/xv-table-row/xv-table-row.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,KAAK,
|
|
1
|
+
{"version":3,"file":"xv-table-row.js","sourceRoot":"","sources":["../../../../src/components/xv-table/xv-table-row/xv-table-row.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,KAAK,EAAgB,KAAK,EAAE,MAAM,eAAe,CAAC;AAC9F,OAAO,EAAgB,iBAAiB,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AACzE,OAAO,EAAE,OAAO,EAAE,YAAY,EA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IAED,iBAAiB;QACf,IAAI,CAAC,eAAe,EAAE,CAAC;IACzB,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Host, h, Element, Prop, Event, EventEmitter, Watch } from '@stencil/core';\nimport { SelectRowDto, XV_EXPANDABLE_KEY, XV_TABLE_TAG } from '../_vars';\nimport { setAttr, uidGenerator } from '../../../utils/utils';\n\n@Component({\n tag: 'xv-table-v2-row',\n styleUrl: 'xv-table-row.scss',\n shadow: true,\n})\nexport class XvTableRow {\n @Element() el: HTMLElement;\n @Prop({ reflect: true, mutable: true }) checked?: SelectRowDto['checked'];\n @Event({ eventName: 'checkedChange' }) checkedChange: EventEmitter<SelectRowDto>;\n @Prop({ reflect: true, mutable: true }) partial?: SelectRowDto['partial'];\n @Prop({ reflect: true, mutable: true }) name?: SelectRowDto['name'];\n @Prop({ reflect: true }) value?: SelectRowDto['value'];\n @Prop({ reflect: true, mutable: true }) hover?: boolean;\n @Prop({ reflect: true }) readonly?: boolean;\n @Prop({ reflect: true }) required?: boolean;\n @Prop({ reflect: true }) disabled?: boolean;\n @Prop({ reflect: true }) header?: boolean;\n @Prop({ reflect: true, mutable: true }) variant?: 'checkbox' | 'radio' | '';\n\n @Event({ eventName: 'selectRow' }) selectRow: EventEmitter<SelectRowDto>;\n\n @Watch('checked')\n checkedChangeHandle() {\n if (!this.name) this.name = uidGenerator();\n this.checkedChange.emit({\n name: this.name,\n value: this.value,\n checked: this.checked,\n partial: this.partial,\n header: this.header,\n expandable: this.el.getAttribute('slot') === XV_EXPANDABLE_KEY,\n });\n }\n\n private checkHandle = ({ detail: checked }: CustomEvent<boolean>) => {\n this.checked = checked;\n if (!checked && this.partial) this.partial = checked;\n\n if (!this.name) this.name = uidGenerator();\n this.selectRow.emit({\n name: this.name,\n value: this.value,\n checked: this.checked,\n partial: this.partial,\n header: this.header,\n expandable: this.el.getAttribute('slot') === XV_EXPANDABLE_KEY,\n });\n };\n\n private setInitialAttrs() {\n if (this.variant || !this.hover) {\n const tableEl = this.el.closest(XV_TABLE_TAG);\n if (!this.hover) {\n this.hover = tableEl.hasAttribute('hover');\n }\n if (this.variant) {\n setAttr(this.el.closest(XV_TABLE_TAG), `variant-${this.variant}`, !!this.variant);\n }\n }\n }\n\n render() {\n return (\n <Host>\n {this.variant !== undefined && (\n <xv-table-v2-cell class=\"cell-control\">\n {this.variant === 'checkbox' && (\n <xv-checkbox-v2\n name={this.name}\n partial={this.partial}\n checked={this.checked || this.partial}\n disabled={this.disabled}\n required={this.required}\n readonly={this.readonly}\n onEventChange={this.checkHandle}\n />\n )}\n {this.variant === 'radio' && (\n <input\n type=\"radio\"\n name={this.name}\n checked={this.checked || this.partial}\n disabled={this.disabled}\n required={this.required}\n readonly={this.readonly}\n />\n )}\n </xv-table-v2-cell>\n )}\n\n <slot />\n </Host>\n );\n }\n\n componentWillLoad() {\n this.setInitialAttrs();\n }\n}\n"]}
|