@3t-transform/threeteeui 0.1.21 → 0.1.22
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-b8a62ede.js → index-dc6cc829.js} +2 -88
- package/dist/cjs/loader.cjs.js +3 -4
- package/dist/cjs/tttx-button.cjs.entry.js +24 -24
- package/dist/cjs/tttx-filter.cjs.entry.js +152 -152
- package/dist/cjs/tttx-form.cjs.entry.js +363 -363
- package/dist/cjs/tttx-icon.cjs.entry.js +11 -11
- package/dist/cjs/tttx-keyvalue-block.cjs.entry.js +59 -59
- package/dist/cjs/tttx-list.cjs.entry.js +43 -43
- package/dist/cjs/tttx-loading-spinner.cjs.entry.js +16 -16
- package/dist/cjs/tttx-sorter.cjs.entry.js +112 -0
- package/dist/cjs/tttx-standalone-input.cjs.entry.js +60 -60
- package/dist/cjs/tttx-toolbar.cjs.entry.js +10 -10
- package/dist/cjs/tttx.cjs.js +3 -7
- package/dist/collection/collection-manifest.json +3 -2
- package/dist/collection/components/atoms/tttx-button/tttx-button.js +110 -110
- package/dist/collection/components/atoms/tttx-button/tttx-button.stories.js +14 -14
- package/dist/collection/components/atoms/tttx-icon/tttx-icon.js +62 -62
- package/dist/collection/components/atoms/tttx-icon/tttx-icon.stories.js +22 -22
- package/dist/collection/components/atoms/tttx-keyvalue-block/tttx-keyvalue-block.js +109 -109
- package/dist/collection/components/atoms/tttx-keyvalue-block/tttx-keyvalue-block.stories.js +38 -38
- package/dist/collection/components/atoms/tttx-loading-spinner/tttx-loading-spinner.js +67 -67
- package/dist/collection/components/atoms/tttx-loading-spinner/tttx-loading-spinner.stories.js +17 -17
- package/dist/collection/components/molecules/tttx-filter/tttx-filter.js +325 -325
- package/dist/collection/components/molecules/tttx-filter/tttx-filter.stories.js +89 -89
- package/dist/collection/components/molecules/tttx-form/lib/setErrorState.js +35 -35
- package/dist/collection/components/molecules/tttx-form/lib/validityCheck.js +58 -58
- package/dist/collection/components/molecules/tttx-form/tttx-form.js +364 -364
- package/dist/collection/components/molecules/tttx-form/tttx-form.stories.js +127 -127
- package/dist/collection/components/molecules/tttx-list/tttx-list.js +105 -105
- package/dist/collection/components/molecules/tttx-list/tttx-list.stories.js +43 -43
- package/dist/collection/components/molecules/tttx-sorter/tttx-sorter.css +116 -0
- package/dist/collection/components/molecules/tttx-sorter/tttx-sorter.js +224 -0
- package/dist/collection/components/molecules/tttx-sorter/tttx-sorter.stories.js +47 -0
- package/dist/collection/components/molecules/tttx-standalone-input/tttx-standalone-input.js +627 -627
- package/dist/collection/components/molecules/tttx-standalone-input/tttx-standalone-input.stories.js +157 -157
- package/dist/collection/components/molecules/tttx-toolbar/tttx-toolbar.js +44 -44
- package/dist/collection/components/molecules/tttx-toolbar/tttx-toolbar.stories.js +14 -14
- package/dist/collection/components/palette.stories.js +7 -7
- package/dist/collection/docs/gettingstarted-developer.stories.js +5 -5
- package/dist/collection/icons.js +2838 -2838
- package/dist/collection/index.js +1 -1
- package/dist/collection/shared/domsanitiser.options.js +14 -14
- package/dist/components/index.d.ts +1 -9
- package/dist/components/index.js +2 -1
- package/dist/components/tttx-button.js +48 -48
- package/dist/components/tttx-filter.js +184 -184
- package/dist/components/tttx-form.js +380 -380
- package/dist/components/tttx-icon2.js +28 -28
- package/dist/components/tttx-keyvalue-block.js +76 -76
- package/dist/components/tttx-list.js +65 -65
- package/dist/components/tttx-loading-spinner.js +33 -33
- package/dist/components/tttx-sorter.d.ts +11 -0
- package/dist/components/tttx-sorter.js +141 -0
- package/dist/components/tttx-standalone-input.js +107 -107
- package/dist/components/tttx-toolbar.js +26 -26
- package/dist/esm/{index-e888a5f4.js → index-86faeaab.js} +3 -88
- package/dist/esm/loader.js +3 -4
- package/dist/esm/polyfills/core-js.js +0 -0
- package/dist/esm/polyfills/css-shim.js +1 -1
- package/dist/esm/polyfills/dom.js +0 -0
- package/dist/esm/polyfills/es5-html-element.js +0 -0
- package/dist/esm/polyfills/index.js +0 -0
- package/dist/esm/polyfills/system.js +0 -0
- package/dist/esm/tttx-button.entry.js +24 -24
- package/dist/esm/tttx-filter.entry.js +152 -152
- package/dist/esm/tttx-form.entry.js +363 -363
- package/dist/esm/tttx-icon.entry.js +11 -11
- package/dist/esm/tttx-keyvalue-block.entry.js +59 -59
- package/dist/esm/tttx-list.entry.js +43 -43
- package/dist/esm/tttx-loading-spinner.entry.js +16 -16
- package/dist/esm/tttx-sorter.entry.js +108 -0
- package/dist/esm/tttx-standalone-input.entry.js +60 -60
- package/dist/esm/tttx-toolbar.entry.js +10 -10
- package/dist/esm/tttx.js +3 -4
- package/dist/tttx/p-12fc0b16.entry.js +3 -0
- package/dist/tttx/p-52a47b7c.js +2 -0
- package/dist/tttx/p-5d9b6bc0.entry.js +1 -0
- package/dist/tttx/{p-41f5b296.entry.js → p-603f6ebe.entry.js} +1 -1
- package/dist/tttx/{p-e145951b.entry.js → p-72b4c98a.entry.js} +1 -1
- package/dist/tttx/{p-043f9b8a.entry.js → p-8f3badad.entry.js} +1 -1
- package/dist/tttx/{p-4cf3e1e0.entry.js → p-ae48fe5a.entry.js} +1 -1
- package/dist/tttx/{p-01f4628e.entry.js → p-bdb054b2.entry.js} +1 -1
- package/dist/tttx/{p-dc5c356b.entry.js → p-c72d1a03.entry.js} +1 -1
- package/dist/tttx/{p-96bbf1ed.entry.js → p-e25d5fe2.entry.js} +1 -1
- package/dist/tttx/{p-b3a03986.entry.js → p-f1d7eb35.entry.js} +1 -1
- package/dist/tttx/tttx.esm.js +1 -1
- package/dist/types/components/atoms/tttx-button/tttx-button.d.ts +10 -10
- package/dist/types/components/atoms/tttx-button/tttx-button.stories.d.ts +10 -10
- package/dist/types/components/atoms/tttx-icon/tttx-icon.d.ts +5 -5
- package/dist/types/components/atoms/tttx-icon/tttx-icon.stories.d.ts +20 -20
- package/dist/types/components/atoms/tttx-keyvalue-block/tttx-keyvalue-block.d.ts +7 -7
- package/dist/types/components/atoms/tttx-keyvalue-block/tttx-keyvalue-block.stories.d.ts +9 -9
- package/dist/types/components/atoms/tttx-loading-spinner/tttx-loading-spinner.d.ts +6 -6
- package/dist/types/components/atoms/tttx-loading-spinner/tttx-loading-spinner.stories.d.ts +17 -17
- package/dist/types/components/molecules/tttx-filter/tttx-filter.d.ts +37 -37
- package/dist/types/components/molecules/tttx-filter/tttx-filter.stories.d.ts +43 -43
- package/dist/types/components/molecules/tttx-form/lib/setErrorState.d.ts +13 -13
- package/dist/types/components/molecules/tttx-form/lib/validityCheck.d.ts +17 -17
- package/dist/types/components/molecules/tttx-form/tttx-form.d.ts +114 -114
- package/dist/types/components/molecules/tttx-form/tttx-form.stories.d.ts +13 -13
- package/dist/types/components/molecules/tttx-list/tttx-list.d.ts +11 -11
- package/dist/types/components/molecules/tttx-list/tttx-list.stories.d.ts +14 -14
- package/dist/types/components/molecules/tttx-sorter/interfaces.d.ts +9 -0
- package/dist/types/components/molecules/tttx-sorter/tttx-sorter.d.ts +19 -0
- package/dist/types/components/molecules/tttx-sorter/tttx-sorter.stories.d.ts +30 -0
- package/dist/types/components/molecules/tttx-standalone-input/tttx-standalone-input.d.ts +56 -56
- package/dist/types/components/molecules/tttx-standalone-input/tttx-standalone-input.stories.d.ts +123 -123
- package/dist/types/components/molecules/tttx-toolbar/tttx-toolbar.d.ts +4 -4
- package/dist/types/components/molecules/tttx-toolbar/tttx-toolbar.stories.d.ts +13 -13
- package/dist/types/components/palette.stories.d.ts +6 -6
- package/dist/types/components.d.ts +27 -0
- package/dist/types/docs/gettingstarted-developer.stories.d.ts +5 -5
- package/dist/types/icons.d.ts +2 -2
- package/dist/types/index.d.ts +1 -1
- package/dist/types/shared/domsanitiser.options.d.ts +10 -10
- package/dist/types/stencil-public-runtime.d.ts +3 -59
- package/loader/index.d.ts +0 -9
- package/package.json +1 -1
- package/dist/tttx/p-6dff6b5a.entry.js +0 -3
- package/dist/tttx/p-f764ffc4.js +0 -2
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { r as registerInstance, h, H as Host } from './index-
|
|
1
|
+
import { r as registerInstance, h, H as Host } from './index-86faeaab.js';
|
|
2
2
|
|
|
3
3
|
const tttxIconCss = ".material-symbols-rounded{font-variation-settings:\"FILL\" 1, \"wght\" 400, \"GRAD\" 0, \"opsz\" 24}.material-symbols-rounded{font-family:\"Material Symbols Rounded\", sans-serif;font-weight:400;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;color:#9e9e9e}:host{display:inline-block;cursor:default;user-select:none}.icon-size{width:24px;height:24px}.tooltip{background:#ffffff;color:#343434;font-weight:bold;padding:8px 16px;font-size:13px;border-radius:4px;box-shadow:0 0 5px 1px rgba(0, 0, 0, 0.3);display:none}.tooltip[data-show]{display:block}.arrow,.arrow::before{position:absolute;width:8px;height:8px;background:inherit}.arrow{visibility:hidden}.arrow::before{visibility:visible;content:\"\";transform:rotate(45deg)}.tooltip[data-popper-placement^=top]>.arrow{bottom:-4px}.tooltip[data-popper-placement^=bottom]>.arrow{top:-4px}.tooltip[data-popper-placement^=left]>.arrow{right:-4px}.tooltip[data-popper-placement^=right]>.arrow{left:-4px}.red{color:#dc0000}.darkred{color:#A20000}.orange{color:#f59500}.blue{color:#1479c6}.green{color:#a2bb31}.gray{color:#757575}.black{color:#212121}.white{color:white}";
|
|
4
4
|
|
|
5
|
-
const TttxIcon = class {
|
|
6
|
-
constructor(hostRef) {
|
|
7
|
-
registerInstance(this, hostRef);
|
|
8
|
-
this.icon = undefined;
|
|
9
|
-
this.color = 'grey';
|
|
10
|
-
}
|
|
11
|
-
render() {
|
|
12
|
-
return (h(Host, null, h("span", { class: `material-symbols-rounded ${this.color ? this.color : ''}` }, this.icon)));
|
|
13
|
-
}
|
|
14
|
-
};
|
|
5
|
+
const TttxIcon = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.icon = undefined;
|
|
9
|
+
this.color = 'grey';
|
|
10
|
+
}
|
|
11
|
+
render() {
|
|
12
|
+
return (h(Host, null, h("span", { class: `material-symbols-rounded ${this.color ? this.color : ''}` }, this.icon)));
|
|
13
|
+
}
|
|
14
|
+
};
|
|
15
15
|
TttxIcon.style = tttxIconCss;
|
|
16
16
|
|
|
17
17
|
export { TttxIcon as tttx_icon };
|
|
@@ -1,65 +1,65 @@
|
|
|
1
|
-
import { r as registerInstance, h, H as Host } from './index-
|
|
1
|
+
import { r as registerInstance, h, H as Host } from './index-86faeaab.js';
|
|
2
2
|
|
|
3
3
|
const tttxKeyvalueBlockCss = ":host{display:block}dl{margin:0;padding:0;font-family:\"Roboto\", sans-serif;cursor:default}dt{font-weight:400;line-height:21px;font-size:16px}dt,dt.subTitle{color:#757575}dt.mainTitle{color:#212121}dt,dd{overflow-wrap:anywhere}dd{margin:0;font-weight:400;font-size:16px;color:#212121;line-height:21px;margin-bottom:18px}dl.horizontal{display:flex;flex-direction:row;width:100%}dl.horizontal div{flex-grow:1}@media (max-width: 769px){dl.horizontal{flex-wrap:wrap}dl.horizontal div{width:50%;max-width:50% !important}}@media (max-width: 600px){dl.horizontal div{width:100%;max-width:100% !important}}";
|
|
4
4
|
|
|
5
|
-
const TttxKeyvalueBlock = class {
|
|
6
|
-
constructor(hostRef) {
|
|
7
|
-
registerInstance(this, hostRef);
|
|
8
|
-
this.keyvalues = undefined;
|
|
9
|
-
this.horizontal = undefined;
|
|
10
|
-
}
|
|
11
|
-
renderSingleElements(values) {
|
|
12
|
-
const keys = Object.keys(values);
|
|
13
|
-
const elements = [];
|
|
14
|
-
const divSize = (100 / keys.length).toString() + '%';
|
|
15
|
-
for (let i = 0; i < keys.length; i++) {
|
|
16
|
-
if (this.horizontal) {
|
|
17
|
-
elements.push(h("div", { style: { maxWidth: divSize } }, h("dt", null, keys[i]), h("dd", null, values[keys[i]])));
|
|
18
|
-
}
|
|
19
|
-
else {
|
|
20
|
-
elements.push(h("dt", null, keys[i]));
|
|
21
|
-
elements.push(h("dd", null, values[keys[i]]));
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
return elements;
|
|
25
|
-
}
|
|
26
|
-
renderArrayElements(values) {
|
|
27
|
-
const elements = [];
|
|
28
|
-
const divSize = (100 / values.length).toString() + '%';
|
|
29
|
-
for (let i = 0; i < values.length; i++) {
|
|
30
|
-
const value = values[i];
|
|
31
|
-
if (this.horizontal) {
|
|
32
|
-
elements.push(h("div", { style: { maxWidth: divSize } }, h("dt", { class: 'mainTitle' }, value.title), h("dt", { class: 'subTitle' }, value.subTitle), h("dd", null, value.data)));
|
|
33
|
-
}
|
|
34
|
-
else {
|
|
35
|
-
elements.push(h("dt", { class: 'mainTitle' }, value.title));
|
|
36
|
-
elements.push(h("dt", { class: 'subTitle' }, value.subTitle));
|
|
37
|
-
elements.push(h("dd", null, value.data));
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
return elements;
|
|
41
|
-
}
|
|
42
|
-
render() {
|
|
43
|
-
if (!this.keyvalues) {
|
|
44
|
-
return;
|
|
45
|
-
}
|
|
46
|
-
let values;
|
|
47
|
-
if (typeof this.keyvalues === 'string') {
|
|
48
|
-
values = JSON.parse(this.keyvalues);
|
|
49
|
-
}
|
|
50
|
-
else {
|
|
51
|
-
values = this.keyvalues;
|
|
52
|
-
}
|
|
53
|
-
let elements;
|
|
54
|
-
if (Array.isArray(values)) {
|
|
55
|
-
elements = this.renderArrayElements(values);
|
|
56
|
-
}
|
|
57
|
-
else {
|
|
58
|
-
elements = this.renderSingleElements(values);
|
|
59
|
-
}
|
|
60
|
-
return (h(Host, null, h("dl", { class: this.horizontal ? 'horizontal' : null }, elements)));
|
|
61
|
-
}
|
|
62
|
-
};
|
|
5
|
+
const TttxKeyvalueBlock = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.keyvalues = undefined;
|
|
9
|
+
this.horizontal = undefined;
|
|
10
|
+
}
|
|
11
|
+
renderSingleElements(values) {
|
|
12
|
+
const keys = Object.keys(values);
|
|
13
|
+
const elements = [];
|
|
14
|
+
const divSize = (100 / keys.length).toString() + '%';
|
|
15
|
+
for (let i = 0; i < keys.length; i++) {
|
|
16
|
+
if (this.horizontal) {
|
|
17
|
+
elements.push(h("div", { style: { maxWidth: divSize } }, h("dt", null, keys[i]), h("dd", null, values[keys[i]])));
|
|
18
|
+
}
|
|
19
|
+
else {
|
|
20
|
+
elements.push(h("dt", null, keys[i]));
|
|
21
|
+
elements.push(h("dd", null, values[keys[i]]));
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
return elements;
|
|
25
|
+
}
|
|
26
|
+
renderArrayElements(values) {
|
|
27
|
+
const elements = [];
|
|
28
|
+
const divSize = (100 / values.length).toString() + '%';
|
|
29
|
+
for (let i = 0; i < values.length; i++) {
|
|
30
|
+
const value = values[i];
|
|
31
|
+
if (this.horizontal) {
|
|
32
|
+
elements.push(h("div", { style: { maxWidth: divSize } }, h("dt", { class: 'mainTitle' }, value.title), h("dt", { class: 'subTitle' }, value.subTitle), h("dd", null, value.data)));
|
|
33
|
+
}
|
|
34
|
+
else {
|
|
35
|
+
elements.push(h("dt", { class: 'mainTitle' }, value.title));
|
|
36
|
+
elements.push(h("dt", { class: 'subTitle' }, value.subTitle));
|
|
37
|
+
elements.push(h("dd", null, value.data));
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
return elements;
|
|
41
|
+
}
|
|
42
|
+
render() {
|
|
43
|
+
if (!this.keyvalues) {
|
|
44
|
+
return;
|
|
45
|
+
}
|
|
46
|
+
let values;
|
|
47
|
+
if (typeof this.keyvalues === 'string') {
|
|
48
|
+
values = JSON.parse(this.keyvalues);
|
|
49
|
+
}
|
|
50
|
+
else {
|
|
51
|
+
values = this.keyvalues;
|
|
52
|
+
}
|
|
53
|
+
let elements;
|
|
54
|
+
if (Array.isArray(values)) {
|
|
55
|
+
elements = this.renderArrayElements(values);
|
|
56
|
+
}
|
|
57
|
+
else {
|
|
58
|
+
elements = this.renderSingleElements(values);
|
|
59
|
+
}
|
|
60
|
+
return (h(Host, null, h("dl", { class: this.horizontal ? 'horizontal' : null }, elements)));
|
|
61
|
+
}
|
|
62
|
+
};
|
|
63
63
|
TttxKeyvalueBlock.style = tttxKeyvalueBlockCss;
|
|
64
64
|
|
|
65
65
|
export { TttxKeyvalueBlock as tttx_keyvalue_block };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance, c as createEvent, h } from './index-
|
|
1
|
+
import { r as registerInstance, c as createEvent, h } from './index-86faeaab.js';
|
|
2
2
|
|
|
3
3
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
4
4
|
|
|
@@ -1649,52 +1649,52 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1649
1649
|
//# sourceMappingURL=purify.js.map
|
|
1650
1650
|
});
|
|
1651
1651
|
|
|
1652
|
-
function tagRegXp(tagName) {
|
|
1653
|
-
return RegExp(/^tttx-/).exec(tagName);
|
|
1654
|
-
}
|
|
1655
|
-
function attributeNameCheck() {
|
|
1656
|
-
return true;
|
|
1657
|
-
}
|
|
1658
|
-
const domSanitiserOptions = {
|
|
1659
|
-
CUSTOM_ELEMENT_HANDLING: {
|
|
1660
|
-
tagNameCheck: tagRegXp,
|
|
1661
|
-
attributeNameCheck: attributeNameCheck,
|
|
1662
|
-
allowCustomizedBuiltInElements: false, // customized built-ins are not allowed
|
|
1663
|
-
}
|
|
1652
|
+
function tagRegXp(tagName) {
|
|
1653
|
+
return RegExp(/^tttx-/).exec(tagName);
|
|
1654
|
+
}
|
|
1655
|
+
function attributeNameCheck() {
|
|
1656
|
+
return true;
|
|
1657
|
+
}
|
|
1658
|
+
const domSanitiserOptions = {
|
|
1659
|
+
CUSTOM_ELEMENT_HANDLING: {
|
|
1660
|
+
tagNameCheck: tagRegXp,
|
|
1661
|
+
attributeNameCheck: attributeNameCheck,
|
|
1662
|
+
allowCustomizedBuiltInElements: false, // customized built-ins are not allowed
|
|
1663
|
+
}
|
|
1664
1664
|
};
|
|
1665
1665
|
|
|
1666
1666
|
const tttxListCss = ".material-symbols-rounded{font-variation-settings:\"FILL\" 1, \"wght\" 400, \"GRAD\" 0, \"opsz\" 24}.material-symbols-rounded{font-family:\"Material Symbols Rounded\", sans-serif;font-weight:400;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;color:#9e9e9e}:host{display:flex;flex-direction:column}.list{margin:0;padding:0}.item{list-style:none;margin:0;padding:8px;border-bottom:1px solid #d5d5d5;min-height:36px;display:flex;align-items:center}.item:first-of-type{border-top:1px solid #d5d5d5}.item.clickable:hover{cursor:pointer}.item.clickable:active{background-color:#e6e6e6}.align-right{margin-left:auto}.item-content{display:flex;align-items:center}";
|
|
1667
1667
|
|
|
1668
|
-
const TttxList = class {
|
|
1669
|
-
constructor(hostRef) {
|
|
1670
|
-
registerInstance(this, hostRef);
|
|
1671
|
-
this.rowClick = createEvent(this, "listRowClick", 7);
|
|
1672
|
-
this.data = undefined;
|
|
1673
|
-
this.name = undefined;
|
|
1674
|
-
}
|
|
1675
|
-
onRowClickHandler(item) {
|
|
1676
|
-
if (!item.clickable || !item.rowData)
|
|
1677
|
-
return;
|
|
1678
|
-
this.rowClick.emit({ name: this.name, data: item.rowData });
|
|
1679
|
-
}
|
|
1680
|
-
renderListItem(item) {
|
|
1681
|
-
const cleanHTML = purify.sanitize(item.element, domSanitiserOptions);
|
|
1682
|
-
return (h("li", { class: `item ${item.clickable ? 'clickable' : ''}`, onClick: () => {
|
|
1683
|
-
this.onRowClickHandler(item);
|
|
1684
|
-
} }, item.element && h("span", { class: "item-content", innerHTML: cleanHTML }), item.icon && h("tttx-icon", { class: "align-right ", icon: item.icon })));
|
|
1685
|
-
}
|
|
1686
|
-
render() {
|
|
1687
|
-
if (!this.data)
|
|
1688
|
-
return;
|
|
1689
|
-
if (typeof this.data === 'string') {
|
|
1690
|
-
this._data = JSON.parse(this.data);
|
|
1691
|
-
}
|
|
1692
|
-
else {
|
|
1693
|
-
this._data = this.data;
|
|
1694
|
-
}
|
|
1695
|
-
return h("ul", { class: "list" }, this._data.map((item) => this.renderListItem(item)));
|
|
1696
|
-
}
|
|
1697
|
-
};
|
|
1668
|
+
const TttxList = class {
|
|
1669
|
+
constructor(hostRef) {
|
|
1670
|
+
registerInstance(this, hostRef);
|
|
1671
|
+
this.rowClick = createEvent(this, "listRowClick", 7);
|
|
1672
|
+
this.data = undefined;
|
|
1673
|
+
this.name = undefined;
|
|
1674
|
+
}
|
|
1675
|
+
onRowClickHandler(item) {
|
|
1676
|
+
if (!item.clickable || !item.rowData)
|
|
1677
|
+
return;
|
|
1678
|
+
this.rowClick.emit({ name: this.name, data: item.rowData });
|
|
1679
|
+
}
|
|
1680
|
+
renderListItem(item) {
|
|
1681
|
+
const cleanHTML = purify.sanitize(item.element, domSanitiserOptions);
|
|
1682
|
+
return (h("li", { class: `item ${item.clickable ? 'clickable' : ''}`, onClick: () => {
|
|
1683
|
+
this.onRowClickHandler(item);
|
|
1684
|
+
} }, item.element && h("span", { class: "item-content", innerHTML: cleanHTML }), item.icon && h("tttx-icon", { class: "align-right ", icon: item.icon })));
|
|
1685
|
+
}
|
|
1686
|
+
render() {
|
|
1687
|
+
if (!this.data)
|
|
1688
|
+
return;
|
|
1689
|
+
if (typeof this.data === 'string') {
|
|
1690
|
+
this._data = JSON.parse(this.data);
|
|
1691
|
+
}
|
|
1692
|
+
else {
|
|
1693
|
+
this._data = this.data;
|
|
1694
|
+
}
|
|
1695
|
+
return h("ul", { class: "list" }, this._data.map((item) => this.renderListItem(item)));
|
|
1696
|
+
}
|
|
1697
|
+
};
|
|
1698
1698
|
TttxList.style = tttxListCss;
|
|
1699
1699
|
|
|
1700
1700
|
export { TttxList as tttx_list };
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { r as registerInstance, h } from './index-
|
|
1
|
+
import { r as registerInstance, h } from './index-86faeaab.js';
|
|
2
2
|
|
|
3
3
|
const tttxLoadingSpinnerCss = ".material-symbols-rounded{font-variation-settings:\"FILL\" 1, \"wght\" 400, \"GRAD\" 0, \"opsz\" 24}.spinner-container{position:absolute}.loading-box{display:flex;align-items:center;justify-content:center}.loading-text{font-size:16px;font-weight:400;padding-top:10px;text-align:center}.spinner{border:solid #1479c6;border-bottom-color:#d5d5d5;border-radius:50%;position:relative;box-sizing:border-box;animation:rotation 1s linear infinite}.spinner.small{height:20px;width:20px;border-width:4px}.spinner.large{height:60px;width:60px;border-width:8px}@keyframes rotation{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}";
|
|
4
4
|
|
|
5
|
-
const TttxLoadingSpinner = class {
|
|
6
|
-
constructor(hostRef) {
|
|
7
|
-
registerInstance(this, hostRef);
|
|
8
|
-
this.loadingMessage = undefined;
|
|
9
|
-
this.size = 'large';
|
|
10
|
-
}
|
|
11
|
-
renderLoadingMessage() {
|
|
12
|
-
if (!this.loadingMessage)
|
|
13
|
-
return '';
|
|
14
|
-
return h("div", { class: "loading-text" }, "Loading, please wait...");
|
|
15
|
-
}
|
|
16
|
-
render() {
|
|
17
|
-
return (h("div", { class: "spinner-container" }, h("div", { class: "loading-box" }, h("span", { class: `spinner ${this.size}` })), this.renderLoadingMessage()));
|
|
18
|
-
}
|
|
19
|
-
};
|
|
5
|
+
const TttxLoadingSpinner = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.loadingMessage = undefined;
|
|
9
|
+
this.size = 'large';
|
|
10
|
+
}
|
|
11
|
+
renderLoadingMessage() {
|
|
12
|
+
if (!this.loadingMessage)
|
|
13
|
+
return '';
|
|
14
|
+
return h("div", { class: "loading-text" }, "Loading, please wait...");
|
|
15
|
+
}
|
|
16
|
+
render() {
|
|
17
|
+
return (h("div", { class: "spinner-container" }, h("div", { class: "loading-box" }, h("span", { class: `spinner ${this.size}` })), this.renderLoadingMessage()));
|
|
18
|
+
}
|
|
19
|
+
};
|
|
20
20
|
TttxLoadingSpinner.style = tttxLoadingSpinnerCss;
|
|
21
21
|
|
|
22
22
|
export { TttxLoadingSpinner as tttx_loading_spinner };
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-86faeaab.js';
|
|
2
|
+
|
|
3
|
+
const tttxSorterCss = ".material-symbols-rounded{font-variation-settings:\"FILL\" 1, \"wght\" 400, \"GRAD\" 0, \"opsz\" 24}.sorter-container{display:inline-flex;flex-direction:row;position:relative;height:36px;border:1px solid #d5d5d5;border-radius:4px;font-family:\"Roboto\", serif;font-weight:400}@media (max-width: 475px){.sorter-container{width:68px}}.sorter-container .arrow-toggle-button{display:inline-flex;justify-content:center;align-items:center;flex-direction:column;height:36px;background-color:white;font-size:16px;border:none;border-bottom-left-radius:4px;border-top-left-radius:4px}.sorter-container .arrow-toggle-button .hydrated{display:flex;justify-content:center;align-items:center}.sorter-container .arrow-toggle-button span{display:block;margin:auto;line-height:16px}.sorter-container .arrow-toggle-button .material-symbols-rounded{color:#212121}.sorter-container .dropdown-selector{display:inline-flex;position:relative;height:36px;flex-grow:1}.sorter-container .dropdown-selector .dropdown-selector-button{display:inline-flex;flex-direction:row;gap:4px;padding-right:4px;align-items:center;height:36px;font-size:16px;line-height:21px;color:#212121;box-sizing:border-box;width:100%}@media (max-width: 475px){.sorter-container .dropdown-selector .dropdown-selector-button .dropdown-selector-text{display:none}}.sorter-container .dropdown-selector .dropdown-selector-chevron{display:inline-flex;right:0;top:0;flex-direction:row;align-items:center;align-self:flex-end;height:36px}.sorter-container .dropdown-selector .dropdown-selector-chevron .hydrated{height:24px}.sorter-container .dropdown-options-list{position:absolute;top:36px;left:0;z-index:1;width:100%;line-height:21px;font-size:16px;border-radius:4px;padding-top:8px;padding-bottom:7px;box-shadow:0px 1px 5px #1111114D;box-sizing:border-box}@media (max-width: 475px){.sorter-container .dropdown-options-list{width:220px;padding-top:8px}}.sorter-container .dropdown-options-list .dropdown-option{padding:8px 16px;font-size:16px;line-height:21px}.sorter-container .dropdown-options-list .dropdown-option:hover,.sorter-container .dropdown-options-list .dropdown-option:focus{background-color:#e7f1f9}.sorter-container.--expanded{border-color:#1579c6}@media (max-width: 475px){.sorter-container.--expanded{border:none}}";
|
|
4
|
+
|
|
5
|
+
const TttxSorter = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.sorterChangeEvent = createEvent(this, "sorterChangeEvent", 7);
|
|
9
|
+
this.sorterKey = undefined;
|
|
10
|
+
this.defaultSortDirection = 'descending';
|
|
11
|
+
this.fieldOptionsData = null;
|
|
12
|
+
this.defaultOption = '';
|
|
13
|
+
this.selectedField = this.defaultOption;
|
|
14
|
+
this.sortDirection = this.defaultSortDirection;
|
|
15
|
+
this.dropdownExpand = false;
|
|
16
|
+
this.dropdownOptions = undefined;
|
|
17
|
+
}
|
|
18
|
+
emitSortEvent() {
|
|
19
|
+
this.sorterChangeEvent.emit({
|
|
20
|
+
sorterDirection: this.sortDirection,
|
|
21
|
+
sorterKey: this.sorterKey,
|
|
22
|
+
sortField: this.selectedField,
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
onSortToggleClick(event) {
|
|
26
|
+
event.preventDefault();
|
|
27
|
+
if (this.sortDirection == 'ascending') {
|
|
28
|
+
this.sortDirection = 'descending';
|
|
29
|
+
}
|
|
30
|
+
else {
|
|
31
|
+
this.sortDirection = 'ascending';
|
|
32
|
+
}
|
|
33
|
+
this.emitSortEvent();
|
|
34
|
+
}
|
|
35
|
+
onDropdownClicked() {
|
|
36
|
+
this.dropdownExpand = !this.dropdownExpand;
|
|
37
|
+
}
|
|
38
|
+
onDropdownSelected(event) {
|
|
39
|
+
this.dropdownExpand = false;
|
|
40
|
+
const target = event.target;
|
|
41
|
+
this.selectedField = target.innerHTML;
|
|
42
|
+
this.emitSortEvent();
|
|
43
|
+
}
|
|
44
|
+
// getOptionsList() {
|
|
45
|
+
// return this.el.shadowRoot.querySelectorAll('.dropdown-option');
|
|
46
|
+
// }
|
|
47
|
+
// /* istanbul ignore next */
|
|
48
|
+
// @Listen('keyup')
|
|
49
|
+
// handleKeyDown(ev: KeyboardEvent) {
|
|
50
|
+
// const keyboardEventValue = ev.key;
|
|
51
|
+
// if (document.activeElement.id != `sorter__${this.sorterKey}`) return;
|
|
52
|
+
// switch (keyboardEventValue) {
|
|
53
|
+
// case 'Enter':
|
|
54
|
+
// if (this._focussedElementIndex > -1) {
|
|
55
|
+
// const options = this.el.shadowRoot.querySelectorAll('.dropdown-option');
|
|
56
|
+
// this.selectedField = options[this._focussedElementIndex].innerHTML;
|
|
57
|
+
// this.emitSortEvent();
|
|
58
|
+
// }
|
|
59
|
+
// this.dropdownExpand = false;
|
|
60
|
+
// break;
|
|
61
|
+
// case 'Escape':
|
|
62
|
+
// this.dropdownExpand = false;
|
|
63
|
+
// break;
|
|
64
|
+
// case 'ArrowDown':
|
|
65
|
+
// this.dropdownExpand = true;
|
|
66
|
+
// if (this._focussedElementIndex > -1) {
|
|
67
|
+
// const options = this.getOptionsList();
|
|
68
|
+
// const currentOption = options[this._focussedElementIndex] as HTMLElement;
|
|
69
|
+
// currentOption.blur();
|
|
70
|
+
// options[this._focussedElementIndex].focus();
|
|
71
|
+
// this._focussedElementIndex + 1 < options.length ? this._focussedElementIndex++ : (this._focussedElementIndex = 0);
|
|
72
|
+
// } else {
|
|
73
|
+
// this._focussedElementIndex++;
|
|
74
|
+
// }
|
|
75
|
+
// break;
|
|
76
|
+
// case 'ArrowUp':
|
|
77
|
+
// this.dropdownExpand = true;
|
|
78
|
+
// if (this._focussedElementIndex == -1) {
|
|
79
|
+
// const options = this.getOptionsList();
|
|
80
|
+
// this._focussedElementIndex = options.length - 1;
|
|
81
|
+
// } else {
|
|
82
|
+
// const options = this.getOptionsList();
|
|
83
|
+
// const currentOption = options[this._focussedElementIndex] as HTMLElement;
|
|
84
|
+
// currentOption.blur();
|
|
85
|
+
// this._focussedElementIndex > 0 ? this._focussedElementIndex-- : (this._focussedElementIndex = options.length - 1);
|
|
86
|
+
// options[this._focussedElementIndex].focus();
|
|
87
|
+
// }
|
|
88
|
+
// break;
|
|
89
|
+
// }
|
|
90
|
+
// }
|
|
91
|
+
render() {
|
|
92
|
+
const parsedFieldOptionsData = typeof this.fieldOptionsData === 'string' ? JSON.parse(this.fieldOptionsData) : this.fieldOptionsData;
|
|
93
|
+
if (!this.fieldOptionsData)
|
|
94
|
+
return;
|
|
95
|
+
const arrowIcon = this.sortDirection == 'ascending' ? 'arrow_upward' : 'arrow_downward';
|
|
96
|
+
const chevronIcon = this.dropdownExpand ? 'expand_less' : 'expand_more';
|
|
97
|
+
const selectedOption = this.selectedField;
|
|
98
|
+
const dropdownSelectorClassNameModifier = this.dropdownExpand ? '--expanded' : '';
|
|
99
|
+
const sorterKey = `sorter__${this.sorterKey}`;
|
|
100
|
+
return (h(Host, { id: sorterKey }, h("div", { tabindex: 0, class: `sorter-container ${dropdownSelectorClassNameModifier}` }, h("button", { class: "arrow-toggle-button", type: "button", onClick: this.onSortToggleClick.bind(this) }, h("tttx-icon", { icon: arrowIcon, color: "black" })), h("div", { class: "dropdown-selector", onClick: this.onDropdownClicked.bind(this) }, h("div", { class: "dropdown-selector-button" }, h("div", { class: "dropdown-selector-text" }, selectedOption), h("div", { class: "dropdown-selector-chevron" }, h("tttx-icon", { icon: chevronIcon, color: "black" })))), this.dropdownExpand && (h("div", { class: "dropdown-options-list" }, parsedFieldOptionsData.sorterOptions.map(option => {
|
|
101
|
+
return (h("div", { class: "dropdown-option", tabIndex: -1, onClick: this.onDropdownSelected.bind(this), key: option.optionLabel }, option.optionLabel));
|
|
102
|
+
}))))));
|
|
103
|
+
}
|
|
104
|
+
get el() { return getElement(this); }
|
|
105
|
+
};
|
|
106
|
+
TttxSorter.style = tttxSorterCss;
|
|
107
|
+
|
|
108
|
+
export { TttxSorter as tttx_sorter };
|
|
@@ -1,66 +1,66 @@
|
|
|
1
|
-
import { r as registerInstance, c as createEvent, h, H as Host } from './index-
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host } from './index-86faeaab.js';
|
|
2
2
|
|
|
3
3
|
const tttxStandaloneInputCss = ".material-symbols-rounded.sc-tttx-standalone-input{font-variation-settings:\"FILL\" 1, \"wght\" 400, \"GRAD\" 0, \"opsz\" 24}.material-symbols-rounded.sc-tttx-standalone-input{font-family:\"Material Symbols Rounded\", sans-serif;font-weight:400;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;color:#9e9e9e}.icon-left.sc-tttx-standalone-input,.icon-right.sc-tttx-standalone-input{flex-basis:24px}.icon-left.sc-tttx-standalone-input span.sc-tttx-standalone-input,.icon-right.sc-tttx-standalone-input span.sc-tttx-standalone-input{font-size:24px;line-height:24px;text-align:center;display:block;width:24px;height:24px;margin-top:4px}.icon-left.sc-tttx-standalone-input span.sc-tttx-standalone-input{margin-left:4px}.icon-right.sc-tttx-standalone-input span.sc-tttx-standalone-input{margin-right:4px}.icon-right.sc-tttx-standalone-input{margin-top:5px}.icon-left.sc-tttx-standalone-input{margin-top:5px;margin-left:4px}.iconleft.sc-tttx-standalone-input .input.sc-tttx-standalone-input{padding-left:4px}.iconright.sc-tttx-standalone-input .input.sc-tttx-standalone-input{padding-right:4px}.input-icon.sc-tttx-standalone-input{position:absolute;margin-top:9px;margin-left:4px}.errormsg.sc-tttx-standalone-input{display:flex;justify-content:center;align-items:center;float:left;margin-bottom:16px;box-sizing:border-box;background-color:transparent;height:26px;font-size:14px;border-radius:none;z-index:2;color:#dc0000}.errormsg.sc-tttx-standalone-input .validationicon.sc-tttx-standalone-input{width:16px;height:16px;font-size:16px;margin-right:4px;vertical-align:middle;color:#dc0000}.danger.sc-tttx-standalone-input{color:#dc0000}.optional.sc-tttx-standalone-input{color:#757575;font-weight:normal}label.inputBlock.sc-tttx-standalone-input{display:block;position:relative;line-height:21px}label.inputInline.sc-tttx-standalone-input{display:flex;white-space:nowrap;align-items:center}label.inputInline.sc-tttx-standalone-input .input-container.sc-tttx-standalone-input{margin:0 4px;width:100%;display:flex;align-items:center;gap:4px;position:relative}label.sc-tttx-standalone-input{font-weight:500;font-size:16px}input.sc-tttx-standalone-input:not([type=submit]){font-family:\"Roboto\", serif;box-sizing:border-box;width:100%;height:36px;padding:0 16px;font-size:16px;border:1px solid #d5d5d5;border-radius:4px;margin-top:4px}input[type=date].sc-tttx-standalone-input{background:white;display:block;min-width:calc(100% - 18px);line-height:37px}@media (max-width: 600px){input[type=date].sc-tttx-standalone-input{padding-top:6px}}input.invalid.sc-tttx-standalone-input:invalid,input.standalone.invalid.sc-tttx-standalone-input{border:1px solid #dc0000}.input-icon.sc-tttx-standalone-input~input.sc-tttx-standalone-input{padding:0 32px}input.sc-tttx-standalone-input~.errorBubble.sc-tttx-standalone-input{min-height:27px;position:relative;font-size:14px;font-weight:normal;width:100%;font-family:\"Roboto\", sans-serif;color:#dc0000;display:flex;align-content:center;align-items:center;justify-items:center}input.sc-tttx-standalone-input~.errorBubble.sc-tttx-standalone-input:not(.visible){visibility:hidden}input.sc-tttx-standalone-input~.errorBubble.sc-tttx-standalone-input span.sc-tttx-standalone-input{color:#dc0000;font-size:16px;margin-right:4px;height:16px}input.invalid.sc-tttx-standalone-input:invalid~.errorBubble.sc-tttx-standalone-input{position:relative;font-size:14px;font-weight:normal;width:100%;font-family:\"Roboto\", sans-serif;color:#dc0000;visibility:visible}input.sc-tttx-standalone-input:focus{border-color:#1479c6}input.sc-tttx-standalone-input:focus-visible{outline:none}.sc-tttx-standalone-input-h{display:block}.input-container.sc-tttx-standalone-input{position:relative}#icon-left.sc-tttx-standalone-input{position:absolute;left:8px;top:10px}#icon-left.sc-tttx-standalone-input~input.sc-tttx-standalone-input{padding-left:36px}#icon-right.sc-tttx-standalone-input{position:absolute;right:8px;top:10px}#icon-right.sc-tttx-standalone-input~input.sc-tttx-standalone-input{padding-right:36px}";
|
|
4
4
|
|
|
5
|
-
const TttxInput = class {
|
|
6
|
-
constructor(hostRef) {
|
|
7
|
-
registerInstance(this, hostRef);
|
|
8
|
-
this.valueChanged = createEvent(this, "valueChanged", 7);
|
|
9
|
-
this.focusChanged = createEvent(this, "focusChanged", 7);
|
|
10
|
-
this.blurChanged = createEvent(this, "blurChanged", 7);
|
|
11
|
-
this.invalidChanged = createEvent(this, "invalidChanged", 7);
|
|
12
|
-
this.label = undefined;
|
|
13
|
-
this.showerrormsg = undefined;
|
|
14
|
-
this.showerrorbubble = true;
|
|
15
|
-
this.errormsg = undefined;
|
|
16
|
-
this.iconleft = undefined;
|
|
17
|
-
this.iconright = undefined;
|
|
18
|
-
this.inputicon = undefined;
|
|
19
|
-
this.inline = undefined;
|
|
20
|
-
this.inputAutocapitalize = undefined;
|
|
21
|
-
this.inputAutofocus = undefined;
|
|
22
|
-
this.inputKeyhint = undefined;
|
|
23
|
-
this.inputIndex = undefined;
|
|
24
|
-
this.inputTitle = undefined;
|
|
25
|
-
this.autocomplete = undefined;
|
|
26
|
-
this.checked = undefined;
|
|
27
|
-
this.disabled = undefined;
|
|
28
|
-
this.max = undefined;
|
|
29
|
-
this.maxlength = undefined;
|
|
30
|
-
this.min = undefined;
|
|
31
|
-
this.minlength = undefined;
|
|
32
|
-
this.name = undefined;
|
|
33
|
-
this.pattern = undefined;
|
|
34
|
-
this.placeholder = undefined;
|
|
35
|
-
this.readonly = undefined;
|
|
36
|
-
this.required = undefined;
|
|
37
|
-
this.step = undefined;
|
|
38
|
-
this.type = 'text';
|
|
39
|
-
this.value = undefined;
|
|
40
|
-
}
|
|
41
|
-
handleChange(event) {
|
|
42
|
-
const target = event.target;
|
|
43
|
-
this.value = target.value;
|
|
44
|
-
this.valueChanged.emit(target.value);
|
|
45
|
-
}
|
|
46
|
-
handleFocus(event) {
|
|
47
|
-
const target = event.target;
|
|
48
|
-
this.focusChanged.emit(target.value);
|
|
49
|
-
}
|
|
50
|
-
handleBlur(event) {
|
|
51
|
-
const target = event.target;
|
|
52
|
-
this.blurChanged.emit(target.value);
|
|
53
|
-
}
|
|
54
|
-
handleInvalid(event) {
|
|
55
|
-
event.preventDefault();
|
|
56
|
-
const target = event.target;
|
|
57
|
-
this.invalidChanged.emit(target.value);
|
|
58
|
-
}
|
|
59
|
-
render() {
|
|
60
|
-
const classNames = ['standalone', this.showerrormsg ? 'invalid' : ''].join(' ');
|
|
61
|
-
return (h(Host, null, h("label", { class: this.inline ? 'inputInline' : 'inputBlock' }, this.label, !this.required ? h("span", { class: "optional" }, "\u00A0(optional)") : '', h("div", { class: "input-container" }, this.inputicon && (h("tttx-icon", { class: "input-icon", icon: this.inputicon, color: "grey" })), this.iconleft && (h("tttx-icon", { id: "icon-left", icon: this.iconleft, color: "grey" })), this.iconright && (h("tttx-icon", { id: "icon-right", icon: this.iconright, color: "grey" })), h("input", { class: classNames, autocapitalize: this.inputAutocapitalize, autofocus: this.inputAutofocus, enterkeyhint: this.inputKeyhint, tabindex: this.inputIndex, title: this.inputTitle, autocomplete: this.autocomplete, checked: this.checked, disabled: this.disabled, max: this.max, maxlength: this.maxlength, min: this.min, minlength: this.minlength, name: this.name, pattern: this.pattern, placeholder: this.placeholder, readonly: this.readonly, required: this.required, step: this.step, type: this.type, value: this.value, onBlur: this.handleBlur.bind(this), onFocus: this.handleFocus.bind(this), onInput: this.handleChange.bind(this), onInvalid: this.handleInvalid.bind(this) }), this.showerrorbubble && (h("span", { class: ['errorBubble', this.showerrormsg && this.errormsg ? 'visible' : ''].join(' ') }, h("span", { class: "material-symbols-rounded validationicon" }, "warning"), " ", this.errormsg))))));
|
|
62
|
-
}
|
|
63
|
-
};
|
|
5
|
+
const TttxInput = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.valueChanged = createEvent(this, "valueChanged", 7);
|
|
9
|
+
this.focusChanged = createEvent(this, "focusChanged", 7);
|
|
10
|
+
this.blurChanged = createEvent(this, "blurChanged", 7);
|
|
11
|
+
this.invalidChanged = createEvent(this, "invalidChanged", 7);
|
|
12
|
+
this.label = undefined;
|
|
13
|
+
this.showerrormsg = undefined;
|
|
14
|
+
this.showerrorbubble = true;
|
|
15
|
+
this.errormsg = undefined;
|
|
16
|
+
this.iconleft = undefined;
|
|
17
|
+
this.iconright = undefined;
|
|
18
|
+
this.inputicon = undefined;
|
|
19
|
+
this.inline = undefined;
|
|
20
|
+
this.inputAutocapitalize = undefined;
|
|
21
|
+
this.inputAutofocus = undefined;
|
|
22
|
+
this.inputKeyhint = undefined;
|
|
23
|
+
this.inputIndex = undefined;
|
|
24
|
+
this.inputTitle = undefined;
|
|
25
|
+
this.autocomplete = undefined;
|
|
26
|
+
this.checked = undefined;
|
|
27
|
+
this.disabled = undefined;
|
|
28
|
+
this.max = undefined;
|
|
29
|
+
this.maxlength = undefined;
|
|
30
|
+
this.min = undefined;
|
|
31
|
+
this.minlength = undefined;
|
|
32
|
+
this.name = undefined;
|
|
33
|
+
this.pattern = undefined;
|
|
34
|
+
this.placeholder = undefined;
|
|
35
|
+
this.readonly = undefined;
|
|
36
|
+
this.required = undefined;
|
|
37
|
+
this.step = undefined;
|
|
38
|
+
this.type = 'text';
|
|
39
|
+
this.value = undefined;
|
|
40
|
+
}
|
|
41
|
+
handleChange(event) {
|
|
42
|
+
const target = event.target;
|
|
43
|
+
this.value = target.value;
|
|
44
|
+
this.valueChanged.emit(target.value);
|
|
45
|
+
}
|
|
46
|
+
handleFocus(event) {
|
|
47
|
+
const target = event.target;
|
|
48
|
+
this.focusChanged.emit(target.value);
|
|
49
|
+
}
|
|
50
|
+
handleBlur(event) {
|
|
51
|
+
const target = event.target;
|
|
52
|
+
this.blurChanged.emit(target.value);
|
|
53
|
+
}
|
|
54
|
+
handleInvalid(event) {
|
|
55
|
+
event.preventDefault();
|
|
56
|
+
const target = event.target;
|
|
57
|
+
this.invalidChanged.emit(target.value);
|
|
58
|
+
}
|
|
59
|
+
render() {
|
|
60
|
+
const classNames = ['standalone', this.showerrormsg ? 'invalid' : ''].join(' ');
|
|
61
|
+
return (h(Host, null, h("label", { class: this.inline ? 'inputInline' : 'inputBlock' }, this.label, !this.required ? h("span", { class: "optional" }, "\u00A0(optional)") : '', h("div", { class: "input-container" }, this.inputicon && (h("tttx-icon", { class: "input-icon", icon: this.inputicon, color: "grey" })), this.iconleft && (h("tttx-icon", { id: "icon-left", icon: this.iconleft, color: "grey" })), this.iconright && (h("tttx-icon", { id: "icon-right", icon: this.iconright, color: "grey" })), h("input", { class: classNames, autocapitalize: this.inputAutocapitalize, autofocus: this.inputAutofocus, enterkeyhint: this.inputKeyhint, tabindex: this.inputIndex, title: this.inputTitle, autocomplete: this.autocomplete, checked: this.checked, disabled: this.disabled, max: this.max, maxlength: this.maxlength, min: this.min, minlength: this.minlength, name: this.name, pattern: this.pattern, placeholder: this.placeholder, readonly: this.readonly, required: this.required, step: this.step, type: this.type, value: this.value, onBlur: this.handleBlur.bind(this), onFocus: this.handleFocus.bind(this), onInput: this.handleChange.bind(this), onInvalid: this.handleInvalid.bind(this) }), this.showerrorbubble && (h("span", { class: ['errorBubble', this.showerrormsg && this.errormsg ? 'visible' : ''].join(' ') }, h("span", { class: "material-symbols-rounded validationicon" }, "warning"), " ", this.errormsg))))));
|
|
62
|
+
}
|
|
63
|
+
};
|
|
64
64
|
TttxInput.style = tttxStandaloneInputCss;
|
|
65
65
|
|
|
66
66
|
export { TttxInput as tttx_standalone_input };
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { r as registerInstance, h, H as Host } from './index-
|
|
1
|
+
import { r as registerInstance, h, H as Host } from './index-86faeaab.js';
|
|
2
2
|
|
|
3
3
|
const tttxToolbarCss = ":host{height:36px;display:flex;padding:8px 0;gap:8px}:host(.bordered){border-bottom:1px solid #d5d5d5}slot[name=before]{display:flex;flex:1 1 0px;gap:8px}slot[name=center]{display:flex;justify-content:center;flex:1 1 0px;gap:8px}slot[name=after]{display:flex;justify-content:end;flex:1 1 0px;gap:8px}";
|
|
4
4
|
|
|
5
|
-
const TttxToolbar = class {
|
|
6
|
-
constructor(hostRef) {
|
|
7
|
-
registerInstance(this, hostRef);
|
|
8
|
-
this.border = true;
|
|
9
|
-
}
|
|
10
|
-
render() {
|
|
11
|
-
return (h(Host, { class: this.border ? 'bordered' : '' }, h("slot", { name: 'before' }), h("slot", { name: 'center' }), h("slot", { name: 'after' })));
|
|
12
|
-
}
|
|
13
|
-
};
|
|
5
|
+
const TttxToolbar = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.border = true;
|
|
9
|
+
}
|
|
10
|
+
render() {
|
|
11
|
+
return (h(Host, { class: this.border ? 'bordered' : '' }, h("slot", { name: 'before' }), h("slot", { name: 'center' }), h("slot", { name: 'after' })));
|
|
12
|
+
}
|
|
13
|
+
};
|
|
14
14
|
TttxToolbar.style = tttxToolbarCss;
|
|
15
15
|
|
|
16
16
|
export { TttxToolbar as tttx_toolbar };
|
package/dist/esm/tttx.js
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import { p as promiseResolve, b as bootstrapLazy } from './index-
|
|
2
|
-
export { s as setNonce } from './index-e888a5f4.js';
|
|
1
|
+
import { p as promiseResolve, b as bootstrapLazy } from './index-86faeaab.js';
|
|
3
2
|
|
|
4
3
|
/*
|
|
5
|
-
Stencil Client Patch Browser v2.
|
|
4
|
+
Stencil Client Patch Browser v2.20.0 | MIT Licensed | https://stenciljs.com
|
|
6
5
|
*/
|
|
7
6
|
const patchBrowser = () => {
|
|
8
7
|
const importMeta = import.meta.url;
|
|
@@ -14,5 +13,5 @@ const patchBrowser = () => {
|
|
|
14
13
|
};
|
|
15
14
|
|
|
16
15
|
patchBrowser().then(options => {
|
|
17
|
-
return bootstrapLazy([["tttx-button",[[1,"tttx-button",{"notext":[4],"icon":[1],"iconposition":[1],"design":[1]}]]],["tttx-filter",[[1,"tttx-filter",{"filterKey":[1,"filter-key"],"filterOptions":[16],"showSelectAll":[4,"show-select-all"],"showSearchField":[4,"show-search-field"],"showOptionIcons":[4,"show-option-icons"],"filterButtonStyle":[1,"filter-button-style"],"filterHeader":[1,"filter-header"],"showPopover":[32],"selectedFilters":[32],"filterSearchTerm":[32],"displayedFilterSettings":[32],"allSelected":[32]}]]],["tttx-list",[[1,"tttx-list",{"data":[1025],"name":[1]}]]],["tttx-standalone-input",[[2,"tttx-standalone-input",{"label":[1],"showerrormsg":[4],"showerrorbubble":[4],"errormsg":[1],"iconleft":[1],"iconright":[1],"inputicon":[1],"inline":[4],"inputAutocapitalize":[1,"input-autocapitalize"],"inputAutofocus":[4,"input-autofocus"],"inputKeyhint":[1,"input-keyhint"],"inputIndex":[8,"input-index"],"inputTitle":[1,"input-title"],"autocomplete":[1],"checked":[4],"disabled":[4],"max":[8],"maxlength":[8],"min":[8],"minlength":[8],"name":[1],"pattern":[1],"placeholder":[1],"readonly":[8],"required":[4],"step":[8],"type":[1],"value":[1032]}]]],["tttx-form",[[1,"tttx-form",{"formschema":[1032],"submitValue":[1032,"submit-value"]}]]],["tttx-keyvalue-block",[[1,"tttx-keyvalue-block",{"keyvalues":[8],"horizontal":[4]}]]],["tttx-loading-spinner",[[1,"tttx-loading-spinner",{"loadingMessage":[1028,"loading-message"],"size":[1025]}]]],["tttx-toolbar",[[1,"tttx-toolbar",{"border":[4]}]]]
|
|
16
|
+
return bootstrapLazy([["tttx-icon",[[1,"tttx-icon",{"icon":[1],"color":[1]}]]],["tttx-button",[[1,"tttx-button",{"notext":[4],"icon":[1],"iconposition":[1],"design":[1]}]]],["tttx-filter",[[1,"tttx-filter",{"filterKey":[1,"filter-key"],"filterOptions":[16],"showSelectAll":[4,"show-select-all"],"showSearchField":[4,"show-search-field"],"showOptionIcons":[4,"show-option-icons"],"filterButtonStyle":[1,"filter-button-style"],"filterHeader":[1,"filter-header"],"showPopover":[32],"selectedFilters":[32],"filterSearchTerm":[32],"displayedFilterSettings":[32],"allSelected":[32]}]]],["tttx-list",[[1,"tttx-list",{"data":[1025],"name":[1]}]]],["tttx-sorter",[[1,"tttx-sorter",{"sorterKey":[1,"sorter-key"],"defaultSortDirection":[1,"default-sort-direction"],"fieldOptionsData":[1,"field-options-data"],"defaultOption":[1,"default-option"],"selectedField":[32],"sortDirection":[32],"dropdownExpand":[32],"dropdownOptions":[32]}]]],["tttx-standalone-input",[[2,"tttx-standalone-input",{"label":[1],"showerrormsg":[4],"showerrorbubble":[4],"errormsg":[1],"iconleft":[1],"iconright":[1],"inputicon":[1],"inline":[4],"inputAutocapitalize":[1,"input-autocapitalize"],"inputAutofocus":[4,"input-autofocus"],"inputKeyhint":[1,"input-keyhint"],"inputIndex":[8,"input-index"],"inputTitle":[1,"input-title"],"autocomplete":[1],"checked":[4],"disabled":[4],"max":[8],"maxlength":[8],"min":[8],"minlength":[8],"name":[1],"pattern":[1],"placeholder":[1],"readonly":[8],"required":[4],"step":[8],"type":[1],"value":[1032]}]]],["tttx-form",[[1,"tttx-form",{"formschema":[1032],"submitValue":[1032,"submit-value"]}]]],["tttx-keyvalue-block",[[1,"tttx-keyvalue-block",{"keyvalues":[8],"horizontal":[4]}]]],["tttx-loading-spinner",[[1,"tttx-loading-spinner",{"loadingMessage":[1028,"loading-message"],"size":[1025]}]]],["tttx-toolbar",[[1,"tttx-toolbar",{"border":[4]}]]]], options);
|
|
18
17
|
});
|