@db-ux/wc-core-components 4.5.4-mcp-e4cd7e6 → 4.5.4-table-c758ae7
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/README.md +30 -0
- package/dist/cjs/db-accordion-item.cjs.entry.js +3 -3
- package/dist/cjs/db-accordion.cjs.entry.js +2 -2
- package/dist/cjs/db-badge.cjs.entry.js +2 -2
- package/dist/cjs/db-brand.cjs.entry.js +2 -2
- package/dist/cjs/db-button.cjs.entry.js +2 -2
- package/dist/cjs/db-card.cjs.entry.js +3 -3
- package/dist/cjs/db-checkbox.cjs.entry.js +3 -3
- package/dist/cjs/db-custom-button.cjs.entry.js +3 -3
- package/dist/cjs/db-custom-select-dropdown_5.cjs.entry.js +10 -10
- package/dist/cjs/db-custom-select-form-field.cjs.entry.js +3 -3
- package/dist/cjs/db-custom-select.cjs.entry.js +6 -6
- package/dist/cjs/db-divider.cjs.entry.js +2 -2
- package/dist/cjs/db-drawer.cjs.entry.js +4 -4
- package/dist/cjs/db-header.cjs.entry.js +3 -3
- package/dist/cjs/db-icon.cjs.entry.js +2 -2
- package/dist/cjs/db-infotext.cjs.entry.js +2 -2
- package/dist/cjs/db-link_4.cjs.entry.js +220 -0
- package/dist/cjs/db-navigation-item.cjs.entry.js +2 -2
- package/dist/cjs/db-navigation.cjs.entry.js +3 -3
- package/dist/cjs/db-notification.cjs.entry.js +3 -3
- package/dist/cjs/db-page.cjs.entry.js +3 -3
- package/dist/cjs/db-popover.cjs.entry.js +3 -3
- package/dist/cjs/db-radio.cjs.entry.js +2 -2
- package/dist/cjs/db-section.cjs.entry.js +3 -3
- package/dist/cjs/db-select.cjs.entry.js +3 -3
- package/dist/cjs/db-stack.cjs.entry.js +3 -3
- package/dist/cjs/db-switch.cjs.entry.js +3 -3
- package/dist/cjs/db-tab-item_3.cjs.entry.js +7 -7
- package/dist/cjs/db-table-body_3.cjs.entry.js +173 -0
- package/dist/cjs/{db-link.cjs.entry.js → db-table-caption.cjs.entry.js} +6 -7
- package/dist/cjs/db-table.cjs.entry.js +136 -0
- package/dist/cjs/db-tabs.cjs.entry.js +3 -3
- package/dist/cjs/db-textarea.cjs.entry.js +3 -3
- package/dist/cjs/db-tooltip.cjs.entry.js +3 -3
- package/dist/cjs/db-ux.cjs.js +2 -2
- package/dist/cjs/{index-EqJP9Qyt.js → index-CSakRmZZ.js} +21 -0
- package/dist/cjs/index.cjs.js +20 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +9 -1
- package/dist/collection/components/accordion/accordion.js +1 -1
- package/dist/collection/components/accordion-item/accordion-item.js +2 -2
- package/dist/collection/components/badge/badge.js +1 -1
- package/dist/collection/components/brand/brand.js +2 -2
- package/dist/collection/components/button/button.js +4 -4
- package/dist/collection/components/card/card.js +2 -2
- package/dist/collection/components/checkbox/checkbox.js +3 -3
- package/dist/collection/components/custom-button/custom-button.js +5 -5
- package/dist/collection/components/custom-select/custom-select.js +7 -7
- package/dist/collection/components/custom-select-dropdown/custom-select-dropdown.js +2 -2
- package/dist/collection/components/custom-select-form-field/custom-select-form-field.js +2 -2
- package/dist/collection/components/custom-select-list/custom-select-list.js +2 -2
- package/dist/collection/components/custom-select-list-item/custom-select-list-item.js +2 -2
- package/dist/collection/components/divider/divider.js +1 -1
- package/dist/collection/components/drawer/drawer.js +3 -3
- package/dist/collection/components/header/header.js +2 -2
- package/dist/collection/components/icon/icon.js +2 -2
- package/dist/collection/components/infotext/infotext.js +2 -2
- package/dist/collection/components/input/input.js +6 -6
- package/dist/collection/components/link/link.js +1 -1
- package/dist/collection/components/navigation/navigation.js +2 -2
- package/dist/collection/components/navigation-item/navigation-item.js +2 -2
- package/dist/collection/components/notification/notification.js +3 -3
- package/dist/collection/components/page/page.js +2 -2
- package/dist/collection/components/popover/popover.js +2 -2
- package/dist/collection/components/radio/radio.js +1 -1
- package/dist/collection/components/section/section.js +2 -2
- package/dist/collection/components/select/select.js +4 -4
- package/dist/collection/components/stack/stack.js +2 -2
- package/dist/collection/components/switch/switch.js +6 -6
- package/dist/collection/components/tab-item/tab-item.js +5 -5
- package/dist/collection/components/tab-list/tab-list.js +2 -2
- package/dist/collection/components/tab-panel/tab-panel.js +2 -2
- package/dist/collection/components/table/examples/data.js +258 -0
- package/dist/collection/components/table/index.js +2 -0
- package/dist/collection/components/table/model.js +6 -0
- package/dist/collection/components/table/table.js +456 -0
- package/dist/collection/components/table-body/index.js +2 -0
- package/dist/collection/components/table-body/model.js +1 -0
- package/dist/collection/components/table-body/table-body.js +137 -0
- package/dist/collection/components/table-caption/index.js +2 -0
- package/dist/collection/components/table-caption/model.js +1 -0
- package/dist/collection/components/table-caption/table-caption.js +109 -0
- package/dist/collection/components/table-data-cell/index.js +2 -0
- package/dist/collection/components/table-data-cell/model.js +1 -0
- package/dist/collection/components/table-data-cell/table-data-cell.js +291 -0
- package/dist/collection/components/table-footer/index.js +2 -0
- package/dist/collection/components/table-footer/model.js +1 -0
- package/dist/collection/components/table-footer/table-footer.js +137 -0
- package/dist/collection/components/table-head/index.js +2 -0
- package/dist/collection/components/table-head/model.js +1 -0
- package/dist/collection/components/table-head/table-head.js +140 -0
- package/dist/collection/components/table-header-cell/index.js +2 -0
- package/dist/collection/components/table-header-cell/model.js +1 -0
- package/dist/collection/components/table-header-cell/table-header-cell.js +369 -0
- package/dist/collection/components/table-row/index.js +2 -0
- package/dist/collection/components/table-row/model.js +1 -0
- package/dist/collection/components/table-row/table-row.js +195 -0
- package/dist/collection/components/tabs/tabs.js +2 -2
- package/dist/collection/components/tag/tag.js +3 -3
- package/dist/collection/components/textarea/textarea.js +3 -3
- package/dist/collection/components/tooltip/tooltip.js +2 -2
- package/dist/collection/index.js +16 -0
- package/dist/collection/shared/model.js +1 -1
- package/dist/custom-elements.json +5671 -2660
- package/dist/db-ux/db-ux.esm.js +1 -1
- package/dist/db-ux/index.esm.js +1 -1
- package/dist/db-ux/{p-cdef6789.entry.js → p-003f3468.entry.js} +1 -1
- package/dist/db-ux/{p-516c3f64.entry.js → p-0055d6ce.entry.js} +1 -1
- package/dist/db-ux/{p-c7d1bee4.entry.js → p-032487d0.entry.js} +1 -1
- package/dist/db-ux/{p-83e69c0e.entry.js → p-10acdb01.entry.js} +1 -1
- package/dist/db-ux/{p-3ca07f53.entry.js → p-150c4aeb.entry.js} +1 -1
- package/dist/db-ux/{p-72d1ea3b.entry.js → p-19fe0672.entry.js} +1 -1
- package/dist/db-ux/p-2cdc1311.entry.js +1 -0
- package/dist/db-ux/p-33ca6422.entry.js +1 -0
- package/dist/db-ux/p-42e61221.entry.js +1 -0
- package/dist/db-ux/{p-fdbf8d91.entry.js → p-47bd992d.entry.js} +1 -1
- package/dist/db-ux/{p-fc9fb7cd.entry.js → p-50a16969.entry.js} +1 -1
- package/dist/db-ux/{p-aad2d524.entry.js → p-54d2e18d.entry.js} +1 -1
- package/dist/db-ux/{p-b99e76fd.entry.js → p-5e4de899.entry.js} +1 -1
- package/dist/db-ux/p-68a1d35a.entry.js +1 -0
- package/dist/db-ux/{p-56da8875.entry.js → p-6b87f6f1.entry.js} +1 -1
- package/dist/db-ux/{p-19ae6336.entry.js → p-7387346c.entry.js} +1 -1
- package/dist/db-ux/p-75005663.entry.js +1 -0
- package/dist/db-ux/{p-7f6fae6f.entry.js → p-77ee580e.entry.js} +1 -1
- package/dist/db-ux/{p-669fe992.entry.js → p-7da51a4c.entry.js} +1 -1
- package/dist/db-ux/p-7f2eaa8b.entry.js +1 -0
- package/dist/db-ux/{p-bd1b0142.entry.js → p-823a7488.entry.js} +1 -1
- package/dist/db-ux/p-8826c7fc.entry.js +1 -0
- package/dist/db-ux/{p-a0f6fc10.entry.js → p-8baf5ea2.entry.js} +1 -1
- package/dist/db-ux/{p-4f519859.entry.js → p-8f76eea7.entry.js} +1 -1
- package/dist/db-ux/p-97f5d48e.entry.js +1 -0
- package/dist/db-ux/p-LpjjuLKB.js +2 -0
- package/dist/db-ux/p-a8368ed2.entry.js +1 -0
- package/dist/db-ux/p-c0b8571d.entry.js +1 -0
- package/dist/db-ux/p-d20bd873.entry.js +1 -0
- package/dist/db-ux/{p-4a0870fa.entry.js → p-d603dcc4.entry.js} +1 -1
- package/dist/db-ux/{p-2c30a356.entry.js → p-dbdfc04a.entry.js} +1 -1
- package/dist/db-ux/{p-df2b1979.entry.js → p-e3279b61.entry.js} +1 -1
- package/dist/db-ux/{p-a726cd18.entry.js → p-e367150f.entry.js} +1 -1
- package/dist/db-ux/{p-f49ed233.entry.js → p-e9058123.entry.js} +1 -1
- package/dist/db-ux/p-e9142fec.entry.js +1 -0
- package/dist/esm/db-accordion-item.entry.js +3 -3
- package/dist/esm/db-accordion.entry.js +2 -2
- package/dist/esm/db-badge.entry.js +2 -2
- package/dist/esm/db-brand.entry.js +2 -2
- package/dist/esm/db-button.entry.js +2 -2
- package/dist/esm/db-card.entry.js +3 -3
- package/dist/esm/db-checkbox.entry.js +3 -3
- package/dist/esm/db-custom-button.entry.js +3 -3
- package/dist/esm/db-custom-select-dropdown_5.entry.js +10 -10
- package/dist/esm/db-custom-select-form-field.entry.js +3 -3
- package/dist/esm/db-custom-select.entry.js +6 -6
- package/dist/esm/db-divider.entry.js +2 -2
- package/dist/esm/db-drawer.entry.js +4 -4
- package/dist/esm/db-header.entry.js +3 -3
- package/dist/esm/db-icon.entry.js +2 -2
- package/dist/esm/db-infotext.entry.js +2 -2
- package/dist/esm/db-link_4.entry.js +215 -0
- package/dist/esm/db-navigation-item.entry.js +2 -2
- package/dist/esm/db-navigation.entry.js +3 -3
- package/dist/esm/db-notification.entry.js +3 -3
- package/dist/esm/db-page.entry.js +3 -3
- package/dist/esm/db-popover.entry.js +3 -3
- package/dist/esm/db-radio.entry.js +2 -2
- package/dist/esm/db-section.entry.js +3 -3
- package/dist/esm/db-select.entry.js +3 -3
- package/dist/esm/db-stack.entry.js +3 -3
- package/dist/esm/db-switch.entry.js +3 -3
- package/dist/esm/db-tab-item_3.entry.js +7 -7
- package/dist/esm/db-table-body_3.entry.js +169 -0
- package/dist/esm/{db-link.entry.js → db-table-caption.entry.js} +7 -8
- package/dist/esm/db-table.entry.js +134 -0
- package/dist/esm/db-tabs.entry.js +3 -3
- package/dist/esm/db-textarea.entry.js +3 -3
- package/dist/esm/db-tooltip.entry.js +3 -3
- package/dist/esm/db-ux.js +3 -3
- package/dist/esm/{index-kHKR5QG5.js → index-LpjjuLKB.js} +21 -0
- package/dist/esm/index.js +13 -2
- package/dist/esm/loader.js +3 -3
- package/dist/types/components/table/examples/data.d.ts +9 -0
- package/dist/types/components/table/index.d.ts +2 -0
- package/dist/types/components/table/model.d.ts +74 -0
- package/dist/types/components/table/table.d.ts +37 -0
- package/dist/types/components/table-body/index.d.ts +2 -0
- package/dist/types/components/table-body/model.d.ts +8 -0
- package/dist/types/components/table-body/table-body.d.ts +19 -0
- package/dist/types/components/table-caption/index.d.ts +2 -0
- package/dist/types/components/table-caption/model.d.ts +5 -0
- package/dist/types/components/table-caption/table-caption.d.ts +18 -0
- package/dist/types/components/table-data-cell/index.d.ts +2 -0
- package/dist/types/components/table-data-cell/model.d.ts +5 -0
- package/dist/types/components/table-data-cell/table-data-cell.d.ts +25 -0
- package/dist/types/components/table-footer/index.d.ts +2 -0
- package/dist/types/components/table-footer/model.d.ts +8 -0
- package/dist/types/components/table-footer/table-footer.d.ts +19 -0
- package/dist/types/components/table-head/index.d.ts +2 -0
- package/dist/types/components/table-head/model.d.ts +10 -0
- package/dist/types/components/table-head/table-head.d.ts +58 -0
- package/dist/types/components/table-header-cell/index.d.ts +2 -0
- package/dist/types/components/table-header-cell/model.d.ts +24 -0
- package/dist/types/components/table-header-cell/table-header-cell.d.ts +28 -0
- package/dist/types/components/table-row/index.d.ts +2 -0
- package/dist/types/components/table-row/model.d.ts +30 -0
- package/dist/types/components/table-row/table-row.d.ts +23 -0
- package/dist/types/components.d.ts +278 -0
- package/dist/types/index.d.ts +16 -0
- package/dist/types/shared/model.d.ts +42 -2
- package/dist/vscode.html-custom-data.json +400 -2
- package/dist/web-types.json +692 -4
- package/package.json +3 -3
- package/dist/db-ux/p-05e9aa2e.entry.js +0 -1
- package/dist/db-ux/p-2ed98454.entry.js +0 -1
- package/dist/db-ux/p-33443732.entry.js +0 -1
- package/dist/db-ux/p-58c6c29d.entry.js +0 -1
- package/dist/db-ux/p-85897212.entry.js +0 -1
- package/dist/db-ux/p-8a521b05.entry.js +0 -1
- package/dist/db-ux/p-974fbc69.entry.js +0 -1
- package/dist/db-ux/p-a3aef74b.entry.js +0 -1
- package/dist/db-ux/p-cb093137.entry.js +0 -1
- package/dist/db-ux/p-kHKR5QG5.js +0 -2
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import { cls } from "../../utils";
|
|
2
|
+
import { h } from "@stencil/core";
|
|
3
|
+
/**
|
|
4
|
+
* @slot children - This is a default/unnamed slot
|
|
5
|
+
|
|
6
|
+
*/
|
|
7
|
+
export class DBTableCaption {
|
|
8
|
+
/**
|
|
9
|
+
* Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.
|
|
10
|
+
* @param element the ref for the component
|
|
11
|
+
* @param customElementSelector the custom element like `my-component`
|
|
12
|
+
*/
|
|
13
|
+
enableAttributePassing(element, customElementSelector) {
|
|
14
|
+
const parent = element === null || element === void 0 ? void 0 : element.closest(customElementSelector);
|
|
15
|
+
if (element && parent) {
|
|
16
|
+
const attributes = parent.attributes;
|
|
17
|
+
for (let i = 0; i < attributes.length; i++) {
|
|
18
|
+
const attr = attributes.item(i);
|
|
19
|
+
if (attr && attr.name !== 'data-density' &&
|
|
20
|
+
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
21
|
+
element.setAttribute(attr.name, attr.value);
|
|
22
|
+
parent.removeAttribute(attr.name);
|
|
23
|
+
}
|
|
24
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
25
|
+
element.setAttribute(attr.name, attr.value);
|
|
26
|
+
parent.removeAttribute(attr.name);
|
|
27
|
+
}
|
|
28
|
+
else if (attr && attr.name === "class") {
|
|
29
|
+
const isWebComponent = attr.value.includes("hydrated");
|
|
30
|
+
const value = attr.value.replace("hydrated", "").trim();
|
|
31
|
+
const currentClass = element.getAttribute("class");
|
|
32
|
+
element.setAttribute(attr.name, `${currentClass ? `${currentClass} ` : ""}${value}`);
|
|
33
|
+
if (isWebComponent) {
|
|
34
|
+
// Stencil is using this class for lazy loading component
|
|
35
|
+
parent.setAttribute("class", "hydrated");
|
|
36
|
+
}
|
|
37
|
+
else {
|
|
38
|
+
parent.removeAttribute(attr.name);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
componentDidLoad() {
|
|
45
|
+
this.enableAttributePassing(this._ref, "db-table-caption");
|
|
46
|
+
}
|
|
47
|
+
render() {
|
|
48
|
+
return (h("caption", { key: 'baeddf92648dcbf2965b0c3832e54f196a95dabe', class: cls("db-table-caption", this.className), ref: (el) => {
|
|
49
|
+
this._ref = el;
|
|
50
|
+
}, id: this.id }, h("slot", { key: '46e4b15773e65ae78bd93699c41b463a2783fcd3' })));
|
|
51
|
+
}
|
|
52
|
+
static get is() { return "db-table-caption"; }
|
|
53
|
+
static get properties() {
|
|
54
|
+
return {
|
|
55
|
+
"id": {
|
|
56
|
+
"type": "string",
|
|
57
|
+
"mutable": false,
|
|
58
|
+
"complexType": {
|
|
59
|
+
"original": "DBTableCaptionProps[\"id\"]",
|
|
60
|
+
"resolved": "string",
|
|
61
|
+
"references": {
|
|
62
|
+
"DBTableCaptionProps": {
|
|
63
|
+
"location": "import",
|
|
64
|
+
"path": "./model",
|
|
65
|
+
"id": "src/components/table-caption/model.ts::DBTableCaptionProps",
|
|
66
|
+
"referenceLocation": "DBTableCaptionProps"
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
},
|
|
70
|
+
"required": false,
|
|
71
|
+
"optional": false,
|
|
72
|
+
"docs": {
|
|
73
|
+
"tags": [],
|
|
74
|
+
"text": ""
|
|
75
|
+
},
|
|
76
|
+
"getter": false,
|
|
77
|
+
"setter": false,
|
|
78
|
+
"reflect": false,
|
|
79
|
+
"attribute": "id"
|
|
80
|
+
},
|
|
81
|
+
"className": {
|
|
82
|
+
"type": "string",
|
|
83
|
+
"mutable": false,
|
|
84
|
+
"complexType": {
|
|
85
|
+
"original": "DBTableCaptionProps[\"className\"]",
|
|
86
|
+
"resolved": "string",
|
|
87
|
+
"references": {
|
|
88
|
+
"DBTableCaptionProps": {
|
|
89
|
+
"location": "import",
|
|
90
|
+
"path": "./model",
|
|
91
|
+
"id": "src/components/table-caption/model.ts::DBTableCaptionProps",
|
|
92
|
+
"referenceLocation": "DBTableCaptionProps"
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
},
|
|
96
|
+
"required": false,
|
|
97
|
+
"optional": false,
|
|
98
|
+
"docs": {
|
|
99
|
+
"tags": [],
|
|
100
|
+
"text": ""
|
|
101
|
+
},
|
|
102
|
+
"getter": false,
|
|
103
|
+
"setter": false,
|
|
104
|
+
"reflect": false,
|
|
105
|
+
"attribute": "classname"
|
|
106
|
+
}
|
|
107
|
+
};
|
|
108
|
+
}
|
|
109
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,291 @@
|
|
|
1
|
+
import { cls, getNumber } from "../../utils";
|
|
2
|
+
import { h } from "@stencil/core";
|
|
3
|
+
/**
|
|
4
|
+
* @slot children - This is a default/unnamed slot
|
|
5
|
+
|
|
6
|
+
*/
|
|
7
|
+
export class DBTableDataCell {
|
|
8
|
+
/**
|
|
9
|
+
* Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.
|
|
10
|
+
* @param element the ref for the component
|
|
11
|
+
* @param customElementSelector the custom element like `my-component`
|
|
12
|
+
*/
|
|
13
|
+
enableAttributePassing(element, customElementSelector) {
|
|
14
|
+
const parent = element === null || element === void 0 ? void 0 : element.closest(customElementSelector);
|
|
15
|
+
if (element && parent) {
|
|
16
|
+
const attributes = parent.attributes;
|
|
17
|
+
for (let i = 0; i < attributes.length; i++) {
|
|
18
|
+
const attr = attributes.item(i);
|
|
19
|
+
if (attr && attr.name !== 'data-density' &&
|
|
20
|
+
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
21
|
+
element.setAttribute(attr.name, attr.value);
|
|
22
|
+
parent.removeAttribute(attr.name);
|
|
23
|
+
}
|
|
24
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
25
|
+
element.setAttribute(attr.name, attr.value);
|
|
26
|
+
parent.removeAttribute(attr.name);
|
|
27
|
+
}
|
|
28
|
+
else if (attr && attr.name === "class") {
|
|
29
|
+
const isWebComponent = attr.value.includes("hydrated");
|
|
30
|
+
const value = attr.value.replace("hydrated", "").trim();
|
|
31
|
+
const currentClass = element.getAttribute("class");
|
|
32
|
+
element.setAttribute(attr.name, `${currentClass ? `${currentClass} ` : ""}${value}`);
|
|
33
|
+
if (isWebComponent) {
|
|
34
|
+
// Stencil is using this class for lazy loading component
|
|
35
|
+
parent.setAttribute("class", "hydrated");
|
|
36
|
+
}
|
|
37
|
+
else {
|
|
38
|
+
parent.removeAttribute(attr.name);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
componentDidLoad() {
|
|
45
|
+
this.enableAttributePassing(this._ref, "db-table-data-cell");
|
|
46
|
+
}
|
|
47
|
+
render() {
|
|
48
|
+
return (h("td", { key: '8274250200fc80a6dd6df6d337b397930c665e18', class: cls("db-table-data-cell", this.className), ref: (el) => {
|
|
49
|
+
this._ref = el;
|
|
50
|
+
}, id: this.id, "data-horizontal-alignment": this.horizontalAlignment, "data-vertical-alignment": this.verticalAlignment, colSpan: getNumber(this.colSpan, this.colspan), rowSpan: getNumber(this.rowSpan, this.rowspan), headers: this.headers }, h("slot", { key: '15e1f9e5492c105d953fb8f4ec272f3c8853b318' })));
|
|
51
|
+
}
|
|
52
|
+
static get is() { return "db-table-data-cell"; }
|
|
53
|
+
static get properties() {
|
|
54
|
+
return {
|
|
55
|
+
"id": {
|
|
56
|
+
"type": "string",
|
|
57
|
+
"mutable": false,
|
|
58
|
+
"complexType": {
|
|
59
|
+
"original": "DBTableDataCellProps[\"id\"]",
|
|
60
|
+
"resolved": "string",
|
|
61
|
+
"references": {
|
|
62
|
+
"DBTableDataCellProps": {
|
|
63
|
+
"location": "import",
|
|
64
|
+
"path": "./model",
|
|
65
|
+
"id": "src/components/table-data-cell/model.ts::DBTableDataCellProps",
|
|
66
|
+
"referenceLocation": "DBTableDataCellProps"
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
},
|
|
70
|
+
"required": false,
|
|
71
|
+
"optional": false,
|
|
72
|
+
"docs": {
|
|
73
|
+
"tags": [],
|
|
74
|
+
"text": ""
|
|
75
|
+
},
|
|
76
|
+
"getter": false,
|
|
77
|
+
"setter": false,
|
|
78
|
+
"reflect": false,
|
|
79
|
+
"attribute": "id"
|
|
80
|
+
},
|
|
81
|
+
"className": {
|
|
82
|
+
"type": "string",
|
|
83
|
+
"mutable": false,
|
|
84
|
+
"complexType": {
|
|
85
|
+
"original": "DBTableDataCellProps[\"className\"]",
|
|
86
|
+
"resolved": "string",
|
|
87
|
+
"references": {
|
|
88
|
+
"DBTableDataCellProps": {
|
|
89
|
+
"location": "import",
|
|
90
|
+
"path": "./model",
|
|
91
|
+
"id": "src/components/table-data-cell/model.ts::DBTableDataCellProps",
|
|
92
|
+
"referenceLocation": "DBTableDataCellProps"
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
},
|
|
96
|
+
"required": false,
|
|
97
|
+
"optional": false,
|
|
98
|
+
"docs": {
|
|
99
|
+
"tags": [],
|
|
100
|
+
"text": ""
|
|
101
|
+
},
|
|
102
|
+
"getter": false,
|
|
103
|
+
"setter": false,
|
|
104
|
+
"reflect": false,
|
|
105
|
+
"attribute": "classname"
|
|
106
|
+
},
|
|
107
|
+
"horizontalAlignment": {
|
|
108
|
+
"type": "string",
|
|
109
|
+
"mutable": false,
|
|
110
|
+
"complexType": {
|
|
111
|
+
"original": "DBTableDataCellProps[\"horizontalAlignment\"]",
|
|
112
|
+
"resolved": "\"center\" | \"end\" | \"start\"",
|
|
113
|
+
"references": {
|
|
114
|
+
"DBTableDataCellProps": {
|
|
115
|
+
"location": "import",
|
|
116
|
+
"path": "./model",
|
|
117
|
+
"id": "src/components/table-data-cell/model.ts::DBTableDataCellProps",
|
|
118
|
+
"referenceLocation": "DBTableDataCellProps"
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
},
|
|
122
|
+
"required": false,
|
|
123
|
+
"optional": false,
|
|
124
|
+
"docs": {
|
|
125
|
+
"tags": [],
|
|
126
|
+
"text": ""
|
|
127
|
+
},
|
|
128
|
+
"getter": false,
|
|
129
|
+
"setter": false,
|
|
130
|
+
"reflect": false,
|
|
131
|
+
"attribute": "horizontal-alignment"
|
|
132
|
+
},
|
|
133
|
+
"verticalAlignment": {
|
|
134
|
+
"type": "string",
|
|
135
|
+
"mutable": false,
|
|
136
|
+
"complexType": {
|
|
137
|
+
"original": "DBTableDataCellProps[\"verticalAlignment\"]",
|
|
138
|
+
"resolved": "\"center\" | \"end\" | \"start\"",
|
|
139
|
+
"references": {
|
|
140
|
+
"DBTableDataCellProps": {
|
|
141
|
+
"location": "import",
|
|
142
|
+
"path": "./model",
|
|
143
|
+
"id": "src/components/table-data-cell/model.ts::DBTableDataCellProps",
|
|
144
|
+
"referenceLocation": "DBTableDataCellProps"
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
},
|
|
148
|
+
"required": false,
|
|
149
|
+
"optional": false,
|
|
150
|
+
"docs": {
|
|
151
|
+
"tags": [],
|
|
152
|
+
"text": ""
|
|
153
|
+
},
|
|
154
|
+
"getter": false,
|
|
155
|
+
"setter": false,
|
|
156
|
+
"reflect": false,
|
|
157
|
+
"attribute": "vertical-alignment"
|
|
158
|
+
},
|
|
159
|
+
"colSpan": {
|
|
160
|
+
"type": "any",
|
|
161
|
+
"mutable": false,
|
|
162
|
+
"complexType": {
|
|
163
|
+
"original": "DBTableDataCellProps[\"colSpan\"]",
|
|
164
|
+
"resolved": "number | string",
|
|
165
|
+
"references": {
|
|
166
|
+
"DBTableDataCellProps": {
|
|
167
|
+
"location": "import",
|
|
168
|
+
"path": "./model",
|
|
169
|
+
"id": "src/components/table-data-cell/model.ts::DBTableDataCellProps",
|
|
170
|
+
"referenceLocation": "DBTableDataCellProps"
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
},
|
|
174
|
+
"required": false,
|
|
175
|
+
"optional": false,
|
|
176
|
+
"docs": {
|
|
177
|
+
"tags": [],
|
|
178
|
+
"text": ""
|
|
179
|
+
},
|
|
180
|
+
"getter": false,
|
|
181
|
+
"setter": false,
|
|
182
|
+
"reflect": false,
|
|
183
|
+
"attribute": "col-span"
|
|
184
|
+
},
|
|
185
|
+
"colspan": {
|
|
186
|
+
"type": "any",
|
|
187
|
+
"mutable": false,
|
|
188
|
+
"complexType": {
|
|
189
|
+
"original": "DBTableDataCellProps[\"colspan\"]",
|
|
190
|
+
"resolved": "number | string",
|
|
191
|
+
"references": {
|
|
192
|
+
"DBTableDataCellProps": {
|
|
193
|
+
"location": "import",
|
|
194
|
+
"path": "./model",
|
|
195
|
+
"id": "src/components/table-data-cell/model.ts::DBTableDataCellProps",
|
|
196
|
+
"referenceLocation": "DBTableDataCellProps"
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
},
|
|
200
|
+
"required": false,
|
|
201
|
+
"optional": false,
|
|
202
|
+
"docs": {
|
|
203
|
+
"tags": [],
|
|
204
|
+
"text": ""
|
|
205
|
+
},
|
|
206
|
+
"getter": false,
|
|
207
|
+
"setter": false,
|
|
208
|
+
"reflect": false,
|
|
209
|
+
"attribute": "colspan"
|
|
210
|
+
},
|
|
211
|
+
"rowSpan": {
|
|
212
|
+
"type": "any",
|
|
213
|
+
"mutable": false,
|
|
214
|
+
"complexType": {
|
|
215
|
+
"original": "DBTableDataCellProps[\"rowSpan\"]",
|
|
216
|
+
"resolved": "number | string",
|
|
217
|
+
"references": {
|
|
218
|
+
"DBTableDataCellProps": {
|
|
219
|
+
"location": "import",
|
|
220
|
+
"path": "./model",
|
|
221
|
+
"id": "src/components/table-data-cell/model.ts::DBTableDataCellProps",
|
|
222
|
+
"referenceLocation": "DBTableDataCellProps"
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
},
|
|
226
|
+
"required": false,
|
|
227
|
+
"optional": false,
|
|
228
|
+
"docs": {
|
|
229
|
+
"tags": [],
|
|
230
|
+
"text": ""
|
|
231
|
+
},
|
|
232
|
+
"getter": false,
|
|
233
|
+
"setter": false,
|
|
234
|
+
"reflect": false,
|
|
235
|
+
"attribute": "row-span"
|
|
236
|
+
},
|
|
237
|
+
"rowspan": {
|
|
238
|
+
"type": "any",
|
|
239
|
+
"mutable": false,
|
|
240
|
+
"complexType": {
|
|
241
|
+
"original": "DBTableDataCellProps[\"rowspan\"]",
|
|
242
|
+
"resolved": "number | string",
|
|
243
|
+
"references": {
|
|
244
|
+
"DBTableDataCellProps": {
|
|
245
|
+
"location": "import",
|
|
246
|
+
"path": "./model",
|
|
247
|
+
"id": "src/components/table-data-cell/model.ts::DBTableDataCellProps",
|
|
248
|
+
"referenceLocation": "DBTableDataCellProps"
|
|
249
|
+
}
|
|
250
|
+
}
|
|
251
|
+
},
|
|
252
|
+
"required": false,
|
|
253
|
+
"optional": false,
|
|
254
|
+
"docs": {
|
|
255
|
+
"tags": [],
|
|
256
|
+
"text": ""
|
|
257
|
+
},
|
|
258
|
+
"getter": false,
|
|
259
|
+
"setter": false,
|
|
260
|
+
"reflect": false,
|
|
261
|
+
"attribute": "rowspan"
|
|
262
|
+
},
|
|
263
|
+
"headers": {
|
|
264
|
+
"type": "string",
|
|
265
|
+
"mutable": false,
|
|
266
|
+
"complexType": {
|
|
267
|
+
"original": "DBTableDataCellProps[\"headers\"]",
|
|
268
|
+
"resolved": "string",
|
|
269
|
+
"references": {
|
|
270
|
+
"DBTableDataCellProps": {
|
|
271
|
+
"location": "import",
|
|
272
|
+
"path": "./model",
|
|
273
|
+
"id": "src/components/table-data-cell/model.ts::DBTableDataCellProps",
|
|
274
|
+
"referenceLocation": "DBTableDataCellProps"
|
|
275
|
+
}
|
|
276
|
+
}
|
|
277
|
+
},
|
|
278
|
+
"required": false,
|
|
279
|
+
"optional": false,
|
|
280
|
+
"docs": {
|
|
281
|
+
"tags": [],
|
|
282
|
+
"text": ""
|
|
283
|
+
},
|
|
284
|
+
"getter": false,
|
|
285
|
+
"setter": false,
|
|
286
|
+
"reflect": false,
|
|
287
|
+
"attribute": "headers"
|
|
288
|
+
}
|
|
289
|
+
};
|
|
290
|
+
}
|
|
291
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
import { cls, uuid } from "../../utils";
|
|
2
|
+
import { h } from "@stencil/core";
|
|
3
|
+
/**
|
|
4
|
+
* @slot children - This is a default/unnamed slot
|
|
5
|
+
|
|
6
|
+
*/
|
|
7
|
+
export class DBTableFooter {
|
|
8
|
+
/**
|
|
9
|
+
* Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.
|
|
10
|
+
* @param element the ref for the component
|
|
11
|
+
* @param customElementSelector the custom element like `my-component`
|
|
12
|
+
*/
|
|
13
|
+
enableAttributePassing(element, customElementSelector) {
|
|
14
|
+
const parent = element === null || element === void 0 ? void 0 : element.closest(customElementSelector);
|
|
15
|
+
if (element && parent) {
|
|
16
|
+
const attributes = parent.attributes;
|
|
17
|
+
for (let i = 0; i < attributes.length; i++) {
|
|
18
|
+
const attr = attributes.item(i);
|
|
19
|
+
if (attr && attr.name !== 'data-density' &&
|
|
20
|
+
(attr.name.startsWith("data-") || attr.name.startsWith("aria-"))) {
|
|
21
|
+
element.setAttribute(attr.name, attr.value);
|
|
22
|
+
parent.removeAttribute(attr.name);
|
|
23
|
+
}
|
|
24
|
+
else if (attr && attr.name !== 'data-density' && attr.name !== "class" && attr.name === "style") {
|
|
25
|
+
element.setAttribute(attr.name, attr.value);
|
|
26
|
+
parent.removeAttribute(attr.name);
|
|
27
|
+
}
|
|
28
|
+
else if (attr && attr.name === "class") {
|
|
29
|
+
const isWebComponent = attr.value.includes("hydrated");
|
|
30
|
+
const value = attr.value.replace("hydrated", "").trim();
|
|
31
|
+
const currentClass = element.getAttribute("class");
|
|
32
|
+
element.setAttribute(attr.name, `${currentClass ? `${currentClass} ` : ""}${value}`);
|
|
33
|
+
if (isWebComponent) {
|
|
34
|
+
// Stencil is using this class for lazy loading component
|
|
35
|
+
parent.setAttribute("class", "hydrated");
|
|
36
|
+
}
|
|
37
|
+
else {
|
|
38
|
+
parent.removeAttribute(attr.name);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
componentDidLoad() {
|
|
45
|
+
this.enableAttributePassing(this._ref, "db-table-footer");
|
|
46
|
+
}
|
|
47
|
+
render() {
|
|
48
|
+
var _a;
|
|
49
|
+
return (h("tfoot", { key: '97d0abedb46046365f4d1a713133cd31a86c12c7', class: cls("db-table-footer", this.className), ref: (el) => {
|
|
50
|
+
this._ref = el;
|
|
51
|
+
}, id: this.id }, this.rows ? ((_a = this.rows) === null || _a === void 0 ? void 0 : _a.map((row, index) => {
|
|
52
|
+
var _a, _b;
|
|
53
|
+
return (h("db-table-row", { class: (_a = row.className) !== null && _a !== void 0 ? _a : row.class, key: `${(_b = this.id) !== null && _b !== void 0 ? _b : uuid()}-table-footer-row-${index}`, cells: row.cells, id: row.id }));
|
|
54
|
+
})) : (h("slot", null))));
|
|
55
|
+
}
|
|
56
|
+
static get is() { return "db-table-footer"; }
|
|
57
|
+
static get properties() {
|
|
58
|
+
return {
|
|
59
|
+
"id": {
|
|
60
|
+
"type": "string",
|
|
61
|
+
"mutable": false,
|
|
62
|
+
"complexType": {
|
|
63
|
+
"original": "DBTableFooterProps[\"id\"]",
|
|
64
|
+
"resolved": "string",
|
|
65
|
+
"references": {
|
|
66
|
+
"DBTableFooterProps": {
|
|
67
|
+
"location": "import",
|
|
68
|
+
"path": "./model",
|
|
69
|
+
"id": "src/components/table-footer/model.ts::DBTableFooterProps",
|
|
70
|
+
"referenceLocation": "DBTableFooterProps"
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
"required": false,
|
|
75
|
+
"optional": false,
|
|
76
|
+
"docs": {
|
|
77
|
+
"tags": [],
|
|
78
|
+
"text": ""
|
|
79
|
+
},
|
|
80
|
+
"getter": false,
|
|
81
|
+
"setter": false,
|
|
82
|
+
"reflect": false,
|
|
83
|
+
"attribute": "id"
|
|
84
|
+
},
|
|
85
|
+
"className": {
|
|
86
|
+
"type": "string",
|
|
87
|
+
"mutable": false,
|
|
88
|
+
"complexType": {
|
|
89
|
+
"original": "DBTableFooterProps[\"className\"]",
|
|
90
|
+
"resolved": "string",
|
|
91
|
+
"references": {
|
|
92
|
+
"DBTableFooterProps": {
|
|
93
|
+
"location": "import",
|
|
94
|
+
"path": "./model",
|
|
95
|
+
"id": "src/components/table-footer/model.ts::DBTableFooterProps",
|
|
96
|
+
"referenceLocation": "DBTableFooterProps"
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
"required": false,
|
|
101
|
+
"optional": false,
|
|
102
|
+
"docs": {
|
|
103
|
+
"tags": [],
|
|
104
|
+
"text": ""
|
|
105
|
+
},
|
|
106
|
+
"getter": false,
|
|
107
|
+
"setter": false,
|
|
108
|
+
"reflect": false,
|
|
109
|
+
"attribute": "classname"
|
|
110
|
+
},
|
|
111
|
+
"rows": {
|
|
112
|
+
"type": "unknown",
|
|
113
|
+
"mutable": false,
|
|
114
|
+
"complexType": {
|
|
115
|
+
"original": "DBTableFooterProps[\"rows\"]",
|
|
116
|
+
"resolved": "DBTableRowProps[]",
|
|
117
|
+
"references": {
|
|
118
|
+
"DBTableFooterProps": {
|
|
119
|
+
"location": "import",
|
|
120
|
+
"path": "./model",
|
|
121
|
+
"id": "src/components/table-footer/model.ts::DBTableFooterProps",
|
|
122
|
+
"referenceLocation": "DBTableFooterProps"
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
"required": false,
|
|
127
|
+
"optional": false,
|
|
128
|
+
"docs": {
|
|
129
|
+
"tags": [],
|
|
130
|
+
"text": ""
|
|
131
|
+
},
|
|
132
|
+
"getter": false,
|
|
133
|
+
"setter": false
|
|
134
|
+
}
|
|
135
|
+
};
|
|
136
|
+
}
|
|
137
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|