@3t-transform/threeteeui 0.1.66 → 0.1.68
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/loader.cjs.js +1 -1
- package/dist/cjs/tttx-tag.cjs.entry.js +21 -0
- package/dist/cjs/tttx-toolbar.cjs.entry.js +17 -2
- package/dist/cjs/tttx.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/atoms/tttx-tag/tttx-tag.css +180 -0
- package/dist/collection/components/atoms/tttx-tag/tttx-tag.js +62 -0
- package/dist/collection/components/atoms/tttx-tag/tttx-tag.stories.js +39 -0
- package/dist/collection/components/molecules/tttx-list/tttx-list.stories.js +4 -4
- package/dist/collection/components/molecules/tttx-toolbar/tttx-toolbar.css +21 -11
- package/dist/collection/components/molecules/tttx-toolbar/tttx-toolbar.js +30 -1
- package/dist/collection/components/molecules/tttx-toolbar/tttx-toolbar.stories.js +107 -5
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +1 -0
- package/dist/components/tttx-tag.d.ts +11 -0
- package/dist/components/tttx-tag.js +38 -0
- package/dist/components/tttx-toolbar.js +20 -4
- package/dist/esm/loader.js +1 -1
- package/dist/esm/tttx-tag.entry.js +17 -0
- package/dist/esm/tttx-toolbar.entry.js +17 -2
- package/dist/esm/tttx.js +1 -1
- package/dist/tttx/p-68680d65.entry.js +1 -0
- package/dist/tttx/p-6a40d3cc.entry.js +1 -0
- package/dist/tttx/tttx.esm.js +1 -1
- package/dist/types/components/atoms/tttx-tag/tttx-tag.d.ts +5 -0
- package/dist/types/components/atoms/tttx-tag/tttx-tag.stories.d.ts +21 -0
- package/dist/types/components/molecules/tttx-toolbar/tttx-toolbar.d.ts +4 -0
- package/dist/types/components/molecules/tttx-toolbar/tttx-toolbar.stories.d.ts +7 -1
- package/dist/types/components.d.ts +17 -0
- package/package.json +1 -1
- package/dist/tttx/p-4879a614.entry.js +0 -1
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -14,7 +14,7 @@ const patchEsm = () => {
|
|
|
14
14
|
const defineCustomElements = (win, options) => {
|
|
15
15
|
if (typeof window === 'undefined') return Promise.resolve();
|
|
16
16
|
return patchEsm().then(() => {
|
|
17
|
-
return index.bootstrapLazy([["tttx-dialog-box.cjs",[[1,"tttx-dialog-box",{"data":[1025],"size":[1],"open":[1028],"elementSize":[32]},[[9,"resize","handleResize"]]]]],["tttx-select-box.cjs",[[1,"tttx-select-box",{"optionsData":[1,"options-data"],"label":[1],"inline":[4],"placeholder":[1],"searchEnabled":[4,"search-enabled"],"open":[32],"selectedItem":[32],"searchTerm":[32]},[[0,"closeSelectBox","handleCloseSelectBox"],[0,"blur","handleBlur"]]]]],["tttx-tree-view.cjs",[[1,"tttx-tree-view",{"data":[1040],"treeData":[32]}]]],["tttx-filter.cjs",[[1,"tttx-filter",{"filterKey":[1,"filter-key"],"filterOptions":[1,"filter-options"],"showSelectAll":[4,"show-select-all"],"showSearchField":[4,"show-search-field"],"showOptionIcons":[4,"show-option-icons"],"filterButtonStyle":[1,"filter-button-style"],"filterHeader":[1,"filter-header"],"defaultFilterOptions":[1,"default-filter-options"],"popoverWidth":[1,"popover-width"],"showPopover":[32],"displayedFilterSettings":[32],"selectedFilters":[32],"filterSearchTerm":[32],"allSelected":[32]},[[0,"closeFilter","handleCloseFilter"]]]]],["tttx-list.cjs",[[1,"tttx-list",{"data":[1025],"name":[1],"_data":[32],"setAllCheckboxes":[64]}]]],["tttx-sorter.cjs",[[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]},[[0,"closeSorter","handleCloseSorter"]]]]],["tttx-form.cjs",[[1,"tttx-form",{"formschema":[1032],"data":[1032],"submit":[64]}]]],["tttx-keyvalue-block.cjs",[[1,"tttx-keyvalue-block",{"keyvalues":[8],"horizontal":[4]}]]],["tttx-loading-spinner.cjs",[[1,"tttx-loading-spinner",{"loadingMessage":[1028,"loading-message"],"size":[1025]}]]],["tttx-qrcode.cjs",[[1,"tttx-qrcode",{"link":[1025],"size":[1026]}]]],["tttx-toolbar.cjs",[[1,"tttx-toolbar",{"border":[4]}]]],["tttx-icon.cjs",[[1,"tttx-icon",{"icon":[1],"color":[1]}]]],["tttx-standalone-input.cjs",[[2,"tttx-standalone-input",{"label":[1],"secondarylabel":[1],"showerrormsg":[4],"showerrorbubble":[4],"errormsg":[1],"iconleft":[1],"iconleftcolor":[1],"iconright":[1],"iconrightcolor":[1],"inputicon":[1],"inputiconcolor":[1],"inline":[4],"inputautocapitalize":[1],"inputautofocus":[4],"inputkeyhint":[1],"inputindex":[8],"inputtitle":[1],"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-button.cjs",[[1,"tttx-button",{"notext":[4],"icon":[1],"iconposition":[1],"iconcolor":[1025],"design":[1]}]]]], options);
|
|
17
|
+
return index.bootstrapLazy([["tttx-dialog-box.cjs",[[1,"tttx-dialog-box",{"data":[1025],"size":[1],"open":[1028],"elementSize":[32]},[[9,"resize","handleResize"]]]]],["tttx-select-box.cjs",[[1,"tttx-select-box",{"optionsData":[1,"options-data"],"label":[1],"inline":[4],"placeholder":[1],"searchEnabled":[4,"search-enabled"],"open":[32],"selectedItem":[32],"searchTerm":[32]},[[0,"closeSelectBox","handleCloseSelectBox"],[0,"blur","handleBlur"]]]]],["tttx-tree-view.cjs",[[1,"tttx-tree-view",{"data":[1040],"treeData":[32]}]]],["tttx-filter.cjs",[[1,"tttx-filter",{"filterKey":[1,"filter-key"],"filterOptions":[1,"filter-options"],"showSelectAll":[4,"show-select-all"],"showSearchField":[4,"show-search-field"],"showOptionIcons":[4,"show-option-icons"],"filterButtonStyle":[1,"filter-button-style"],"filterHeader":[1,"filter-header"],"defaultFilterOptions":[1,"default-filter-options"],"popoverWidth":[1,"popover-width"],"showPopover":[32],"displayedFilterSettings":[32],"selectedFilters":[32],"filterSearchTerm":[32],"allSelected":[32]},[[0,"closeFilter","handleCloseFilter"]]]]],["tttx-list.cjs",[[1,"tttx-list",{"data":[1025],"name":[1],"_data":[32],"setAllCheckboxes":[64]}]]],["tttx-sorter.cjs",[[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]},[[0,"closeSorter","handleCloseSorter"]]]]],["tttx-form.cjs",[[1,"tttx-form",{"formschema":[1032],"data":[1032],"submit":[64]}]]],["tttx-keyvalue-block.cjs",[[1,"tttx-keyvalue-block",{"keyvalues":[8],"horizontal":[4]}]]],["tttx-loading-spinner.cjs",[[1,"tttx-loading-spinner",{"loadingMessage":[1028,"loading-message"],"size":[1025]}]]],["tttx-qrcode.cjs",[[1,"tttx-qrcode",{"link":[1025],"size":[1026]}]]],["tttx-tag.cjs",[[1,"tttx-tag",{"text":[1],"color":[1]}]]],["tttx-toolbar.cjs",[[1,"tttx-toolbar",{"border":[4],"viewSize":[32]},[[9,"resize","handleResize"]]]]],["tttx-icon.cjs",[[1,"tttx-icon",{"icon":[1],"color":[1]}]]],["tttx-standalone-input.cjs",[[2,"tttx-standalone-input",{"label":[1],"secondarylabel":[1],"showerrormsg":[4],"showerrorbubble":[4],"errormsg":[1],"iconleft":[1],"iconleftcolor":[1],"iconright":[1],"iconrightcolor":[1],"inputicon":[1],"inputiconcolor":[1],"inline":[4],"inputautocapitalize":[1],"inputautofocus":[4],"inputkeyhint":[1],"inputindex":[8],"inputtitle":[1],"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-button.cjs",[[1,"tttx-button",{"notext":[4],"icon":[1],"iconposition":[1],"iconcolor":[1025],"design":[1]}]]]], options);
|
|
18
18
|
});
|
|
19
19
|
};
|
|
20
20
|
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-43af0e62.js');
|
|
6
|
+
|
|
7
|
+
const tttxTagCss = ".material-symbols-rounded{font-variation-settings:\"FILL\" 1, \"wght\" 400, \"GRAD\" 0, \"opsz\" 24}button{cursor:pointer}.button{font-family:Roboto, serif;box-sizing:border-box;height:36px;min-width:36px;padding:0;margin:0;background:transparent;color:#212121;border:1px solid #c8c8c8;border-radius:4px;text-transform:uppercase;display:flex;justify-content:left;align-items:center;font-size:14px;font-weight:400}.button-content{display:block;padding:0 16px}.icon-left,.icon-right{margin-top:4px}.iconleft{padding-left:8px}.iconleft .button-content{padding-left:4px}.iconright{padding-right:8px}.iconright .button-content{padding-right:4px}.notext{padding:0 6px}.button:active{background:rgba(17, 17, 17, 0.2);border:1px solid #d5d5d5}.primary{background:#1479c6;border:1px solid #1479c6;color:white}.primary:active{background:#1464a2;border:1px solid #1464a2}.borderless{background:transparent;border:none;color:#212121}.borderless:active{background:rgba(17, 17, 17, 0.2);border:none}.borderless-circle{background:transparent;border:none;color:#212121;border-radius:50%}.borderless-circle:active{border:none}.borderless-circle:focus{border-color:transparent}.danger{background:#dc0000;border:1px solid #dc0000;color:white}.danger:active{background:#b00000;border:1px solid #b00000}.disabled{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}.disabled:active{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}@media (hover: hover){.button:hover{background:rgba(17, 17, 17, 0.1);border:1px solid #d5d5d5}.primary:hover{background:#146eb3;border:1px solid #146eb3}.borderless:hover{background:rgba(17, 17, 17, 0.1);border:none}.borderless-circle:hover{background:rgba(17, 17, 17, 0.1);border:none}.danger:hover{background:#c60000;border:1px solid #c60000}.disabled:hover{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}}:host{display:inline-block}.tag{border-radius:20px;padding:4px;font-family:\"Roboto\", sans-serif;font-size:14px;font-weight:400}.tag span{margin-left:4px;margin-right:4px;color:#212121}.icon{height:18px;width:18px;font-weight:400}";
|
|
8
|
+
|
|
9
|
+
const TttxTag = class {
|
|
10
|
+
constructor(hostRef) {
|
|
11
|
+
index.registerInstance(this, hostRef);
|
|
12
|
+
this.text = undefined;
|
|
13
|
+
this.color = '#d5d5d5';
|
|
14
|
+
}
|
|
15
|
+
render() {
|
|
16
|
+
return (index.h(index.Host, null, index.h("div", { class: "tag", style: { 'background-color': this.color } }, index.h("span", null, this.text))));
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
TttxTag.style = tttxTagCss;
|
|
20
|
+
|
|
21
|
+
exports.tttx_tag = TttxTag;
|
|
@@ -4,15 +4,30 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-43af0e62.js');
|
|
6
6
|
|
|
7
|
-
const tttxToolbarCss = "
|
|
7
|
+
const tttxToolbarCss = ".container{display:flex;align-items:flex-end;row-gap:8px;padding:8px 0;flex-wrap:wrap}.container.bordered{border-bottom:1px solid #d5d5d5}.desktop ::slotted([slot=before]){flex:1 1 0px}.desktop ::slotted([slot=center]){flex:0 1 fit-content}.desktop ::slotted([slot=after]){flex:1 1 0px}::slotted([slot=before]){display:flex;align-items:flex-end;flex-wrap:wrap;gap:8px}::slotted([slot=center]){display:flex;justify-content:center;align-items:flex-end;flex-wrap:wrap;gap:8px}::slotted([slot=after]){display:flex;justify-content:end;align-items:flex-end;flex-wrap:wrap;gap:8px}";
|
|
8
8
|
|
|
9
9
|
const TttxToolbar = class {
|
|
10
10
|
constructor(hostRef) {
|
|
11
11
|
index.registerInstance(this, hostRef);
|
|
12
12
|
this.border = true;
|
|
13
|
+
this.viewSize = undefined;
|
|
14
|
+
}
|
|
15
|
+
handleResize() {
|
|
16
|
+
this.setViewSize();
|
|
17
|
+
}
|
|
18
|
+
async componentWillLoad() {
|
|
19
|
+
this.setViewSize();
|
|
20
|
+
}
|
|
21
|
+
setViewSize() {
|
|
22
|
+
if (window.innerWidth < 698) {
|
|
23
|
+
this.viewSize = 'mobile';
|
|
24
|
+
}
|
|
25
|
+
else {
|
|
26
|
+
this.viewSize = 'desktop';
|
|
27
|
+
}
|
|
13
28
|
}
|
|
14
29
|
render() {
|
|
15
|
-
return (index.h(index.Host, { class: this.border ? 'bordered' : '' }, index.h("slot", { name: 'before' }), index.h("slot", { name: 'center' }), index.h("slot", { name: 'after' })));
|
|
30
|
+
return (index.h(index.Host, null, index.h("div", { class: `container ${this.border ? 'bordered' : ''} ${this.viewSize}` }, index.h("slot", { name: 'before' }), index.h("slot", { name: 'center' }), index.h("slot", { name: 'after' }))));
|
|
16
31
|
}
|
|
17
32
|
};
|
|
18
33
|
TttxToolbar.style = tttxToolbarCss;
|
package/dist/cjs/tttx.cjs.js
CHANGED
|
@@ -17,7 +17,7 @@ const patchBrowser = () => {
|
|
|
17
17
|
};
|
|
18
18
|
|
|
19
19
|
patchBrowser().then(options => {
|
|
20
|
-
return index.bootstrapLazy([["tttx-dialog-box.cjs",[[1,"tttx-dialog-box",{"data":[1025],"size":[1],"open":[1028],"elementSize":[32]},[[9,"resize","handleResize"]]]]],["tttx-select-box.cjs",[[1,"tttx-select-box",{"optionsData":[1,"options-data"],"label":[1],"inline":[4],"placeholder":[1],"searchEnabled":[4,"search-enabled"],"open":[32],"selectedItem":[32],"searchTerm":[32]},[[0,"closeSelectBox","handleCloseSelectBox"],[0,"blur","handleBlur"]]]]],["tttx-tree-view.cjs",[[1,"tttx-tree-view",{"data":[1040],"treeData":[32]}]]],["tttx-filter.cjs",[[1,"tttx-filter",{"filterKey":[1,"filter-key"],"filterOptions":[1,"filter-options"],"showSelectAll":[4,"show-select-all"],"showSearchField":[4,"show-search-field"],"showOptionIcons":[4,"show-option-icons"],"filterButtonStyle":[1,"filter-button-style"],"filterHeader":[1,"filter-header"],"defaultFilterOptions":[1,"default-filter-options"],"popoverWidth":[1,"popover-width"],"showPopover":[32],"displayedFilterSettings":[32],"selectedFilters":[32],"filterSearchTerm":[32],"allSelected":[32]},[[0,"closeFilter","handleCloseFilter"]]]]],["tttx-list.cjs",[[1,"tttx-list",{"data":[1025],"name":[1],"_data":[32],"setAllCheckboxes":[64]}]]],["tttx-sorter.cjs",[[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]},[[0,"closeSorter","handleCloseSorter"]]]]],["tttx-form.cjs",[[1,"tttx-form",{"formschema":[1032],"data":[1032],"submit":[64]}]]],["tttx-keyvalue-block.cjs",[[1,"tttx-keyvalue-block",{"keyvalues":[8],"horizontal":[4]}]]],["tttx-loading-spinner.cjs",[[1,"tttx-loading-spinner",{"loadingMessage":[1028,"loading-message"],"size":[1025]}]]],["tttx-qrcode.cjs",[[1,"tttx-qrcode",{"link":[1025],"size":[1026]}]]],["tttx-toolbar.cjs",[[1,"tttx-toolbar",{"border":[4]}]]],["tttx-icon.cjs",[[1,"tttx-icon",{"icon":[1],"color":[1]}]]],["tttx-standalone-input.cjs",[[2,"tttx-standalone-input",{"label":[1],"secondarylabel":[1],"showerrormsg":[4],"showerrorbubble":[4],"errormsg":[1],"iconleft":[1],"iconleftcolor":[1],"iconright":[1],"iconrightcolor":[1],"inputicon":[1],"inputiconcolor":[1],"inline":[4],"inputautocapitalize":[1],"inputautofocus":[4],"inputkeyhint":[1],"inputindex":[8],"inputtitle":[1],"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-button.cjs",[[1,"tttx-button",{"notext":[4],"icon":[1],"iconposition":[1],"iconcolor":[1025],"design":[1]}]]]], options);
|
|
20
|
+
return index.bootstrapLazy([["tttx-dialog-box.cjs",[[1,"tttx-dialog-box",{"data":[1025],"size":[1],"open":[1028],"elementSize":[32]},[[9,"resize","handleResize"]]]]],["tttx-select-box.cjs",[[1,"tttx-select-box",{"optionsData":[1,"options-data"],"label":[1],"inline":[4],"placeholder":[1],"searchEnabled":[4,"search-enabled"],"open":[32],"selectedItem":[32],"searchTerm":[32]},[[0,"closeSelectBox","handleCloseSelectBox"],[0,"blur","handleBlur"]]]]],["tttx-tree-view.cjs",[[1,"tttx-tree-view",{"data":[1040],"treeData":[32]}]]],["tttx-filter.cjs",[[1,"tttx-filter",{"filterKey":[1,"filter-key"],"filterOptions":[1,"filter-options"],"showSelectAll":[4,"show-select-all"],"showSearchField":[4,"show-search-field"],"showOptionIcons":[4,"show-option-icons"],"filterButtonStyle":[1,"filter-button-style"],"filterHeader":[1,"filter-header"],"defaultFilterOptions":[1,"default-filter-options"],"popoverWidth":[1,"popover-width"],"showPopover":[32],"displayedFilterSettings":[32],"selectedFilters":[32],"filterSearchTerm":[32],"allSelected":[32]},[[0,"closeFilter","handleCloseFilter"]]]]],["tttx-list.cjs",[[1,"tttx-list",{"data":[1025],"name":[1],"_data":[32],"setAllCheckboxes":[64]}]]],["tttx-sorter.cjs",[[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]},[[0,"closeSorter","handleCloseSorter"]]]]],["tttx-form.cjs",[[1,"tttx-form",{"formschema":[1032],"data":[1032],"submit":[64]}]]],["tttx-keyvalue-block.cjs",[[1,"tttx-keyvalue-block",{"keyvalues":[8],"horizontal":[4]}]]],["tttx-loading-spinner.cjs",[[1,"tttx-loading-spinner",{"loadingMessage":[1028,"loading-message"],"size":[1025]}]]],["tttx-qrcode.cjs",[[1,"tttx-qrcode",{"link":[1025],"size":[1026]}]]],["tttx-tag.cjs",[[1,"tttx-tag",{"text":[1],"color":[1]}]]],["tttx-toolbar.cjs",[[1,"tttx-toolbar",{"border":[4],"viewSize":[32]},[[9,"resize","handleResize"]]]]],["tttx-icon.cjs",[[1,"tttx-icon",{"icon":[1],"color":[1]}]]],["tttx-standalone-input.cjs",[[2,"tttx-standalone-input",{"label":[1],"secondarylabel":[1],"showerrormsg":[4],"showerrorbubble":[4],"errormsg":[1],"iconleft":[1],"iconleftcolor":[1],"iconright":[1],"iconrightcolor":[1],"inputicon":[1],"inputiconcolor":[1],"inline":[4],"inputautocapitalize":[1],"inputautofocus":[4],"inputkeyhint":[1],"inputindex":[8],"inputtitle":[1],"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-button.cjs",[[1,"tttx-button",{"notext":[4],"icon":[1],"iconposition":[1],"iconcolor":[1025],"design":[1]}]]]], options);
|
|
21
21
|
});
|
|
22
22
|
|
|
23
23
|
exports.setNonce = index.setNonce;
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
"./components/atoms/tttx-keyvalue-block/tttx-keyvalue-block.js",
|
|
8
8
|
"./components/atoms/tttx-loading-spinner/tttx-loading-spinner.js",
|
|
9
9
|
"./components/atoms/tttx-qrcode/tttx-qrcode.js",
|
|
10
|
+
"./components/atoms/tttx-tag/tttx-tag.js",
|
|
10
11
|
"./components/molecules/tttx-dialog-box/tttx-dialog-box.js",
|
|
11
12
|
"./components/molecules/tttx-form/tttx-form.js",
|
|
12
13
|
"./components/molecules/tttx-list/tttx-list.js",
|
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
.material-symbols-rounded {
|
|
2
|
+
font-variation-settings: "FILL" 1, "wght" 400, "GRAD" 0, "opsz" 24;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
button {
|
|
6
|
+
cursor: pointer;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.button {
|
|
10
|
+
font-family: Roboto, serif;
|
|
11
|
+
box-sizing: border-box;
|
|
12
|
+
height: 36px;
|
|
13
|
+
min-width: 36px;
|
|
14
|
+
padding: 0;
|
|
15
|
+
margin: 0;
|
|
16
|
+
background: transparent;
|
|
17
|
+
color: #212121;
|
|
18
|
+
border: 1px solid #c8c8c8;
|
|
19
|
+
border-radius: 4px;
|
|
20
|
+
text-transform: uppercase;
|
|
21
|
+
display: flex;
|
|
22
|
+
justify-content: left;
|
|
23
|
+
align-items: center;
|
|
24
|
+
font-size: 14px;
|
|
25
|
+
font-weight: 400;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.button-content {
|
|
29
|
+
display: block;
|
|
30
|
+
padding: 0 16px;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.icon-left,
|
|
34
|
+
.icon-right {
|
|
35
|
+
margin-top: 4px;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.iconleft {
|
|
39
|
+
padding-left: 8px;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.iconleft .button-content {
|
|
43
|
+
padding-left: 4px;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.iconright {
|
|
47
|
+
padding-right: 8px;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.iconright .button-content {
|
|
51
|
+
padding-right: 4px;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.notext {
|
|
55
|
+
padding: 0 6px;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.button:active {
|
|
59
|
+
background: rgba(17, 17, 17, 0.2);
|
|
60
|
+
border: 1px solid #d5d5d5;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.primary {
|
|
64
|
+
background: #1479c6;
|
|
65
|
+
border: 1px solid #1479c6;
|
|
66
|
+
color: white;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.primary:active {
|
|
70
|
+
background: #1464a2;
|
|
71
|
+
border: 1px solid #1464a2;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.borderless {
|
|
75
|
+
background: transparent;
|
|
76
|
+
border: none;
|
|
77
|
+
color: #212121;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
.borderless:active {
|
|
81
|
+
background: rgba(17, 17, 17, 0.2);
|
|
82
|
+
border: none;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.borderless-circle {
|
|
86
|
+
background: transparent;
|
|
87
|
+
border: none;
|
|
88
|
+
color: #212121;
|
|
89
|
+
border-radius: 50%;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.borderless-circle:active {
|
|
93
|
+
border: none;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.borderless-circle:focus {
|
|
97
|
+
border-color: transparent;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.danger {
|
|
101
|
+
background: #dc0000;
|
|
102
|
+
border: 1px solid #dc0000;
|
|
103
|
+
color: white;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
.danger:active {
|
|
107
|
+
background: #b00000;
|
|
108
|
+
border: 1px solid #b00000;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.disabled {
|
|
112
|
+
background: #aeaeae;
|
|
113
|
+
border: none;
|
|
114
|
+
color: #4c4c4c;
|
|
115
|
+
cursor: not-allowed;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.disabled:active {
|
|
119
|
+
background: #aeaeae;
|
|
120
|
+
border: none;
|
|
121
|
+
color: #4c4c4c;
|
|
122
|
+
cursor: not-allowed;
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
@media (hover: hover) {
|
|
126
|
+
.button:hover {
|
|
127
|
+
background: rgba(17, 17, 17, 0.1);
|
|
128
|
+
border: 1px solid #d5d5d5;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
.primary:hover {
|
|
132
|
+
background: #146eb3;
|
|
133
|
+
border: 1px solid #146eb3;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
.borderless:hover {
|
|
137
|
+
background: rgba(17, 17, 17, 0.1);
|
|
138
|
+
border: none;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
.borderless-circle:hover {
|
|
142
|
+
background: rgba(17, 17, 17, 0.1);
|
|
143
|
+
border: none;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
.danger:hover {
|
|
147
|
+
background: #c60000;
|
|
148
|
+
border: 1px solid #c60000;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.disabled:hover {
|
|
152
|
+
background: #aeaeae;
|
|
153
|
+
border: none;
|
|
154
|
+
color: #4c4c4c;
|
|
155
|
+
cursor: not-allowed;
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
:host {
|
|
159
|
+
display: inline-block;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
.tag {
|
|
163
|
+
border-radius: 20px;
|
|
164
|
+
padding: 4px;
|
|
165
|
+
font-family: "Roboto", sans-serif;
|
|
166
|
+
font-size: 14px;
|
|
167
|
+
font-weight: 400;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.tag span {
|
|
171
|
+
margin-left: 4px;
|
|
172
|
+
margin-right: 4px;
|
|
173
|
+
color: #212121;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.icon {
|
|
177
|
+
height: 18px;
|
|
178
|
+
width: 18px;
|
|
179
|
+
font-weight: 400;
|
|
180
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
2
|
+
import { Host, h } from '@stencil/core';
|
|
3
|
+
export class TttxTag {
|
|
4
|
+
constructor() {
|
|
5
|
+
this.text = undefined;
|
|
6
|
+
this.color = '#d5d5d5';
|
|
7
|
+
}
|
|
8
|
+
render() {
|
|
9
|
+
return (h(Host, null, h("div", { class: "tag", style: { 'background-color': this.color } }, h("span", null, this.text))));
|
|
10
|
+
}
|
|
11
|
+
static get is() { return "tttx-tag"; }
|
|
12
|
+
static get encapsulation() { return "shadow"; }
|
|
13
|
+
static get originalStyleUrls() {
|
|
14
|
+
return {
|
|
15
|
+
"$": ["tttx-tag.scss"]
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
static get styleUrls() {
|
|
19
|
+
return {
|
|
20
|
+
"$": ["tttx-tag.css"]
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
static get properties() {
|
|
24
|
+
return {
|
|
25
|
+
"text": {
|
|
26
|
+
"type": "string",
|
|
27
|
+
"mutable": false,
|
|
28
|
+
"complexType": {
|
|
29
|
+
"original": "string",
|
|
30
|
+
"resolved": "string",
|
|
31
|
+
"references": {}
|
|
32
|
+
},
|
|
33
|
+
"required": false,
|
|
34
|
+
"optional": false,
|
|
35
|
+
"docs": {
|
|
36
|
+
"tags": [],
|
|
37
|
+
"text": ""
|
|
38
|
+
},
|
|
39
|
+
"attribute": "text",
|
|
40
|
+
"reflect": false
|
|
41
|
+
},
|
|
42
|
+
"color": {
|
|
43
|
+
"type": "string",
|
|
44
|
+
"mutable": false,
|
|
45
|
+
"complexType": {
|
|
46
|
+
"original": "string",
|
|
47
|
+
"resolved": "string",
|
|
48
|
+
"references": {}
|
|
49
|
+
},
|
|
50
|
+
"required": false,
|
|
51
|
+
"optional": false,
|
|
52
|
+
"docs": {
|
|
53
|
+
"tags": [],
|
|
54
|
+
"text": ""
|
|
55
|
+
},
|
|
56
|
+
"attribute": "color",
|
|
57
|
+
"reflect": false,
|
|
58
|
+
"defaultValue": "'#d5d5d5'"
|
|
59
|
+
}
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
title: 'Atoms/Tag',
|
|
3
|
+
component: 'tttx-tag',
|
|
4
|
+
argTypes: {
|
|
5
|
+
text: {
|
|
6
|
+
control: { type: 'text' },
|
|
7
|
+
default: 'tag',
|
|
8
|
+
},
|
|
9
|
+
color: {
|
|
10
|
+
control: { type: 'text' },
|
|
11
|
+
default: '#d5d5d5',
|
|
12
|
+
}
|
|
13
|
+
},
|
|
14
|
+
};
|
|
15
|
+
const Template = ({ text, color }) => {
|
|
16
|
+
return `<tttx-tag text="${text}" color="${color}" ></tttx-tag>`;
|
|
17
|
+
};
|
|
18
|
+
export const tag = Template.bind({});
|
|
19
|
+
tag.args = {
|
|
20
|
+
text: 'tag',
|
|
21
|
+
color: '#d5d5d5',
|
|
22
|
+
};
|
|
23
|
+
const tagTemplates = () => `
|
|
24
|
+
<h2>Default</h2>
|
|
25
|
+
<tttx-tag text="Default" color="#d5d5d5"></tttx-tag>
|
|
26
|
+
<hr />
|
|
27
|
+
<h2>Critical</h2>
|
|
28
|
+
<tttx-tag text="Critical" color="#f2bebe"></tttx-tag>
|
|
29
|
+
<hr />
|
|
30
|
+
<h2>Warning</h2>
|
|
31
|
+
<tttx-tag text="Warning" color="#f9e1be"></tttx-tag>
|
|
32
|
+
<hr />
|
|
33
|
+
<h2>Success</h2>
|
|
34
|
+
<tttx-tag text="Success" color="#e4ebc9"></tttx-tag>
|
|
35
|
+
<hr />
|
|
36
|
+
<h2>Info</h2>
|
|
37
|
+
<tttx-tag text="Info" color="#c2daee"></tttx-tag>
|
|
38
|
+
`;
|
|
39
|
+
export const tags = tagTemplates.bind({});
|
|
@@ -108,9 +108,9 @@ WorkerList.args = {
|
|
|
108
108
|
</li>
|
|
109
109
|
<li>
|
|
110
110
|
<span style="padding: 8px; display: inline-flex; align-items: center; gap: 8px;">
|
|
111
|
-
<
|
|
112
|
-
<
|
|
113
|
-
<
|
|
111
|
+
<tttx-tag text="Driller" color="#EABFFF"></tttx-tag>
|
|
112
|
+
<tttx-tag text="Offshore" color="#9BE8D5"></tttx-tag>
|
|
113
|
+
<tttx-tag text="3t Transform" color="#B9CCF5"></tttx-tag>
|
|
114
114
|
</span>
|
|
115
115
|
</li>
|
|
116
116
|
<li>
|
|
@@ -135,7 +135,7 @@ WorkerList.args = {
|
|
|
135
135
|
<div style="display: flex; flex-direction: row; align-items: center; gap: 8px;">
|
|
136
136
|
<span><tttx-icon icon="check_circle" color="green" /></span>
|
|
137
137
|
Qualification row
|
|
138
|
-
<
|
|
138
|
+
<tttx-tag text="Vantage" color="#D5D5D5"></tttx-tag>
|
|
139
139
|
<span style="color: #757575;">Awarded:</span> <span style="color: #212121;">10 Jan 2022</span>
|
|
140
140
|
<span style="color: #757575;">Expiry:</span> <span style="color: #212121;">10 Jan 2023</span>
|
|
141
141
|
</div>
|
|
@@ -1,33 +1,43 @@
|
|
|
1
|
-
|
|
2
|
-
height: 36px;
|
|
1
|
+
.container {
|
|
3
2
|
display: flex;
|
|
3
|
+
align-items: flex-end;
|
|
4
|
+
row-gap: 8px;
|
|
4
5
|
padding: 8px 0;
|
|
5
|
-
|
|
6
|
+
flex-wrap: wrap;
|
|
6
7
|
}
|
|
7
|
-
|
|
8
|
-
:host(.bordered) {
|
|
8
|
+
.container.bordered {
|
|
9
9
|
border-bottom: 1px solid #d5d5d5;
|
|
10
10
|
}
|
|
11
11
|
|
|
12
|
+
.desktop ::slotted([slot=before]) {
|
|
13
|
+
flex: 1 1 0px;
|
|
14
|
+
}
|
|
15
|
+
.desktop ::slotted([slot=center]) {
|
|
16
|
+
flex: 0 1 fit-content;
|
|
17
|
+
}
|
|
18
|
+
.desktop ::slotted([slot=after]) {
|
|
19
|
+
flex: 1 1 0px;
|
|
20
|
+
}
|
|
21
|
+
|
|
12
22
|
::slotted([slot=before]) {
|
|
13
23
|
display: flex;
|
|
14
|
-
align-items:
|
|
15
|
-
flex:
|
|
24
|
+
align-items: flex-end;
|
|
25
|
+
flex-wrap: wrap;
|
|
16
26
|
gap: 8px;
|
|
17
27
|
}
|
|
18
28
|
|
|
19
29
|
::slotted([slot=center]) {
|
|
20
30
|
display: flex;
|
|
21
31
|
justify-content: center;
|
|
22
|
-
align-items:
|
|
23
|
-
flex:
|
|
32
|
+
align-items: flex-end;
|
|
33
|
+
flex-wrap: wrap;
|
|
24
34
|
gap: 8px;
|
|
25
35
|
}
|
|
26
36
|
|
|
27
37
|
::slotted([slot=after]) {
|
|
28
38
|
display: flex;
|
|
29
39
|
justify-content: end;
|
|
30
|
-
align-items:
|
|
31
|
-
flex:
|
|
40
|
+
align-items: flex-end;
|
|
41
|
+
flex-wrap: wrap;
|
|
32
42
|
gap: 8px;
|
|
33
43
|
}
|
|
@@ -3,9 +3,24 @@ import { h, Host } from '@stencil/core';
|
|
|
3
3
|
export class TttxToolbar {
|
|
4
4
|
constructor() {
|
|
5
5
|
this.border = true;
|
|
6
|
+
this.viewSize = undefined;
|
|
7
|
+
}
|
|
8
|
+
handleResize() {
|
|
9
|
+
this.setViewSize();
|
|
10
|
+
}
|
|
11
|
+
async componentWillLoad() {
|
|
12
|
+
this.setViewSize();
|
|
13
|
+
}
|
|
14
|
+
setViewSize() {
|
|
15
|
+
if (window.innerWidth < 698) {
|
|
16
|
+
this.viewSize = 'mobile';
|
|
17
|
+
}
|
|
18
|
+
else {
|
|
19
|
+
this.viewSize = 'desktop';
|
|
20
|
+
}
|
|
6
21
|
}
|
|
7
22
|
render() {
|
|
8
|
-
return (h(Host, { class: this.border ? 'bordered' : '' }, h("slot", { name: 'before' }), h("slot", { name: 'center' }), h("slot", { name: 'after' })));
|
|
23
|
+
return (h(Host, null, h("div", { class: `container ${this.border ? 'bordered' : ''} ${this.viewSize}` }, h("slot", { name: 'before' }), h("slot", { name: 'center' }), h("slot", { name: 'after' }))));
|
|
9
24
|
}
|
|
10
25
|
static get is() { return "tttx-toolbar"; }
|
|
11
26
|
static get encapsulation() { return "shadow"; }
|
|
@@ -41,4 +56,18 @@ export class TttxToolbar {
|
|
|
41
56
|
}
|
|
42
57
|
};
|
|
43
58
|
}
|
|
59
|
+
static get states() {
|
|
60
|
+
return {
|
|
61
|
+
"viewSize": {}
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
static get listeners() {
|
|
65
|
+
return [{
|
|
66
|
+
"name": "resize",
|
|
67
|
+
"method": "handleResize",
|
|
68
|
+
"target": "window",
|
|
69
|
+
"capture": false,
|
|
70
|
+
"passive": true
|
|
71
|
+
}];
|
|
72
|
+
}
|
|
44
73
|
}
|
|
@@ -9,12 +9,114 @@ export default {
|
|
|
9
9
|
};
|
|
10
10
|
const Default = ({ border }) => `
|
|
11
11
|
<tttx-toolbar border="${border ? 'true' : 'false'}">
|
|
12
|
-
<span slot="before"><tttx-button design="primary">Before</tttx-button></span>
|
|
13
|
-
<span slot="center"><
|
|
14
|
-
<span slot="after"><tttx-
|
|
12
|
+
<span slot="before"><tttx-button design="primary">Before</tttx-button><tttx-button design="primary">Button Two</tttx-button></span>
|
|
13
|
+
<span slot="center"><tttx-button design="primary">Center</tttx-button></span>
|
|
14
|
+
<span slot="after"><tttx-button design="primary">After</tttx-button></span>
|
|
15
15
|
</tttx-toolbar>
|
|
16
16
|
`;
|
|
17
|
-
export const
|
|
18
|
-
|
|
17
|
+
export const DefaultToolbar = Default.bind({});
|
|
18
|
+
DefaultToolbar.args = {
|
|
19
|
+
border: true
|
|
20
|
+
};
|
|
21
|
+
const TallElements = ({ border }) => `
|
|
22
|
+
<tttx-toolbar border="${border ? 'true' : 'false'}">
|
|
23
|
+
<span slot="before"><tttx-button design="primary">Before</tttx-button><div style="position: relative; top: 18px;"><tttx-standalone-input placeholder="before" label="search" required showerrorbubble="false" inputicon="search" /></div></span>
|
|
24
|
+
<span slot="center"><div style="position: relative; top: 17px;"><tttx-standalone-input placeholder="center" inline required showerrorbubble="false" inputicon="search" /></div></span>
|
|
25
|
+
<span slot="after"><div style="position: relative; top: 22px;"><tttx-keyvalue-block horizontal keyvalues='{"Position":"after"}' /></div></span>
|
|
26
|
+
</tttx-toolbar>
|
|
27
|
+
`;
|
|
28
|
+
export const TallElementsToolbar = TallElements.bind({});
|
|
29
|
+
TallElementsToolbar.args = {
|
|
30
|
+
border: true
|
|
31
|
+
};
|
|
32
|
+
const WrapElements = ({ border }) => `
|
|
33
|
+
<tttx-toolbar border="${border ? 'true' : 'false'}">
|
|
34
|
+
<span slot="before"><div style="width: 125px;display: flex;gap: 8px;flex-wrap: wrap;"><tttx-button design="primary">Button One</tttx-button><tttx-button design="primary">Button Two</tttx-button><tttx-button design="primary">Button Three</tttx-button></div></span>
|
|
35
|
+
<span slot="center"><div style="width: 125px;display: flex;gap: 8px;flex-wrap: wrap;"><tttx-button design="primary">Button One</tttx-button><tttx-button design="primary">Button Two</tttx-button><tttx-button design="primary">Button Three</tttx-button></div></span>
|
|
36
|
+
<span slot="after"><div style="width: 125px;display: flex;gap: 8px;flex-wrap: wrap;"><tttx-button design="primary">Button One</tttx-button><tttx-button design="primary">Button Two</tttx-button><tttx-button design="primary">Button Three</tttx-button></div></span>
|
|
37
|
+
</tttx-toolbar>
|
|
38
|
+
`;
|
|
39
|
+
export const WrapElementsToolbar = WrapElements.bind({});
|
|
40
|
+
WrapElementsToolbar.args = {
|
|
41
|
+
border: true
|
|
42
|
+
};
|
|
43
|
+
const LeftToolbar = ({ border }) => `
|
|
44
|
+
<tttx-toolbar border="${border ? 'true' : 'false'}">
|
|
45
|
+
<span slot="before"><tttx-button design="primary">Before</tttx-button><tttx-button design="primary">Button Two</tttx-button></span>
|
|
46
|
+
</tttx-toolbar>
|
|
47
|
+
`;
|
|
48
|
+
export const LeftToolbarOnly = LeftToolbar.bind({});
|
|
49
|
+
LeftToolbarOnly.args = {
|
|
50
|
+
border: true
|
|
51
|
+
};
|
|
52
|
+
const CenterToolbar = ({ border }) => `
|
|
53
|
+
<tttx-toolbar border="${border ? 'true' : 'false'}">
|
|
54
|
+
<span slot='before'></span>
|
|
55
|
+
<span slot="center"><tttx-button design="primary">Before</tttx-button><tttx-button design="primary">Button Two</tttx-button></span>
|
|
56
|
+
<span slot='after'></span>
|
|
57
|
+
</tttx-toolbar>
|
|
58
|
+
`;
|
|
59
|
+
export const CenterToolbarOnly = CenterToolbar.bind({});
|
|
60
|
+
CenterToolbarOnly.args = {
|
|
61
|
+
border: true
|
|
62
|
+
};
|
|
63
|
+
const TwoColumn = ({ border }) => `
|
|
64
|
+
<tttx-toolbar border="${border ? 'true' : 'false'}">
|
|
65
|
+
<span slot="before"><tttx-button design="primary">Before</tttx-button><tttx-button design="primary">Button Two</tttx-button></span>
|
|
66
|
+
<span slot='after'><tttx-button design="primary">After</tttx-button><tttx-button design="primary">Button Two</tttx-button></span>
|
|
67
|
+
</tttx-toolbar>
|
|
68
|
+
`;
|
|
69
|
+
export const TwoColumnToolbar = TwoColumn.bind({});
|
|
70
|
+
TwoColumnToolbar.args = {
|
|
71
|
+
border: true
|
|
72
|
+
};
|
|
73
|
+
const selectOptions = JSON.stringify([
|
|
74
|
+
{ value: 'Bonnie', label: 'Steuber' },
|
|
75
|
+
{ value: 'Priscilla', label: 'Lowe' },
|
|
76
|
+
{ value: 'Terence', label: 'Hyatt' },
|
|
77
|
+
{ value: 'Ruben', label: 'Toy' },
|
|
78
|
+
{ value: 'Rhiannon', label: 'Hills' },
|
|
79
|
+
{ value: 'Trent', label: 'Mueller' },
|
|
80
|
+
{ value: 'Penelope', label: 'Mann' },
|
|
81
|
+
{ value: 'Oswaldo', label: 'Klocko' },
|
|
82
|
+
{ value: 'Jorge', label: 'Lockman' },
|
|
83
|
+
{ value: 'Conner', label: 'Feeney' },
|
|
84
|
+
{ value: 'Dorian', label: 'Fay' },
|
|
85
|
+
{ value: 'Estrella', label: 'Predovic' },
|
|
86
|
+
{ value: 'Heidi', label: 'McClure' },
|
|
87
|
+
{ value: 'Ronaldo', label: 'Mann' },
|
|
88
|
+
]);
|
|
89
|
+
const LongItems = ({ border }) => `
|
|
90
|
+
<tttx-toolbar border="${border ? 'true' : 'false'}">
|
|
91
|
+
<span slot="before">
|
|
92
|
+
<div style="width: 350px">
|
|
93
|
+
<tttx-select-box
|
|
94
|
+
id="htmlSelectBox"
|
|
95
|
+
options-data='${selectOptions}'
|
|
96
|
+
placeholder='Select a name'
|
|
97
|
+
label=''
|
|
98
|
+
inline='true'
|
|
99
|
+
></tttx-select-box>
|
|
100
|
+
</div>
|
|
101
|
+
<tttx-button>
|
|
102
|
+
This is a very long button
|
|
103
|
+
</tttx-button>
|
|
104
|
+
<tttx-button>
|
|
105
|
+
This is a very long button
|
|
106
|
+
</tttx-button>
|
|
107
|
+
<tttx-button>
|
|
108
|
+
This is a very long button
|
|
109
|
+
</tttx-button>
|
|
110
|
+
</span>
|
|
111
|
+
<span slot="center">
|
|
112
|
+
<tttx-button>
|
|
113
|
+
This is a very long button in the middle
|
|
114
|
+
</tttx-button>
|
|
115
|
+
</span>
|
|
116
|
+
<span slot="after"></span>
|
|
117
|
+
</tttx-toolbar>
|
|
118
|
+
`;
|
|
119
|
+
export const LongItemsToolbar = LongItems.bind({});
|
|
120
|
+
LongItemsToolbar.args = {
|
|
19
121
|
border: true
|
|
20
122
|
};
|
|
@@ -11,6 +11,7 @@ export { TttxQrCode as TttxQrcode } from '../types/components/atoms/tttx-qrcode/
|
|
|
11
11
|
export { TttxSelectBox as TttxSelectBox } from '../types/components/molecules/tttx-select-box/tttx-select-box';
|
|
12
12
|
export { TttxSorter as TttxSorter } from '../types/components/molecules/tttx-sorter/tttx-sorter';
|
|
13
13
|
export { TttxInput as TttxStandaloneInput } from '../types/components/molecules/tttx-standalone-input/tttx-standalone-input';
|
|
14
|
+
export { TttxTag as TttxTag } from '../types/components/atoms/tttx-tag/tttx-tag';
|
|
14
15
|
export { TttxToolbar as TttxToolbar } from '../types/components/molecules/tttx-toolbar/tttx-toolbar';
|
|
15
16
|
export { TttxTreeView as TttxTreeView } from '../types/components/molecules/tttx-tree-view/tttx-tree-view';
|
|
16
17
|
|
package/dist/components/index.js
CHANGED
|
@@ -11,5 +11,6 @@ export { TttxQrcode, defineCustomElement as defineCustomElementTttxQrcode } from
|
|
|
11
11
|
export { TttxSelectBox, defineCustomElement as defineCustomElementTttxSelectBox } from './tttx-select-box.js';
|
|
12
12
|
export { TttxSorter, defineCustomElement as defineCustomElementTttxSorter } from './tttx-sorter.js';
|
|
13
13
|
export { TttxStandaloneInput, defineCustomElement as defineCustomElementTttxStandaloneInput } from './tttx-standalone-input.js';
|
|
14
|
+
export { TttxTag, defineCustomElement as defineCustomElementTttxTag } from './tttx-tag.js';
|
|
14
15
|
export { TttxToolbar, defineCustomElement as defineCustomElementTttxToolbar } from './tttx-toolbar.js';
|
|
15
16
|
export { TttxTreeView, defineCustomElement as defineCustomElementTttxTreeView } from './tttx-tree-view.js';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { Components, JSX } from "../types/components";
|
|
2
|
+
|
|
3
|
+
interface TttxTag extends Components.TttxTag, HTMLElement {}
|
|
4
|
+
export const TttxTag: {
|
|
5
|
+
prototype: TttxTag;
|
|
6
|
+
new (): TttxTag;
|
|
7
|
+
};
|
|
8
|
+
/**
|
|
9
|
+
* Used to define this component and all nested components recursively.
|
|
10
|
+
*/
|
|
11
|
+
export const defineCustomElement: () => void;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
2
|
+
|
|
3
|
+
const tttxTagCss = ".material-symbols-rounded{font-variation-settings:\"FILL\" 1, \"wght\" 400, \"GRAD\" 0, \"opsz\" 24}button{cursor:pointer}.button{font-family:Roboto, serif;box-sizing:border-box;height:36px;min-width:36px;padding:0;margin:0;background:transparent;color:#212121;border:1px solid #c8c8c8;border-radius:4px;text-transform:uppercase;display:flex;justify-content:left;align-items:center;font-size:14px;font-weight:400}.button-content{display:block;padding:0 16px}.icon-left,.icon-right{margin-top:4px}.iconleft{padding-left:8px}.iconleft .button-content{padding-left:4px}.iconright{padding-right:8px}.iconright .button-content{padding-right:4px}.notext{padding:0 6px}.button:active{background:rgba(17, 17, 17, 0.2);border:1px solid #d5d5d5}.primary{background:#1479c6;border:1px solid #1479c6;color:white}.primary:active{background:#1464a2;border:1px solid #1464a2}.borderless{background:transparent;border:none;color:#212121}.borderless:active{background:rgba(17, 17, 17, 0.2);border:none}.borderless-circle{background:transparent;border:none;color:#212121;border-radius:50%}.borderless-circle:active{border:none}.borderless-circle:focus{border-color:transparent}.danger{background:#dc0000;border:1px solid #dc0000;color:white}.danger:active{background:#b00000;border:1px solid #b00000}.disabled{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}.disabled:active{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}@media (hover: hover){.button:hover{background:rgba(17, 17, 17, 0.1);border:1px solid #d5d5d5}.primary:hover{background:#146eb3;border:1px solid #146eb3}.borderless:hover{background:rgba(17, 17, 17, 0.1);border:none}.borderless-circle:hover{background:rgba(17, 17, 17, 0.1);border:none}.danger:hover{background:#c60000;border:1px solid #c60000}.disabled:hover{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}}:host{display:inline-block}.tag{border-radius:20px;padding:4px;font-family:\"Roboto\", sans-serif;font-size:14px;font-weight:400}.tag span{margin-left:4px;margin-right:4px;color:#212121}.icon{height:18px;width:18px;font-weight:400}";
|
|
4
|
+
|
|
5
|
+
const TttxTag$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
6
|
+
constructor() {
|
|
7
|
+
super();
|
|
8
|
+
this.__registerHost();
|
|
9
|
+
this.__attachShadow();
|
|
10
|
+
this.text = undefined;
|
|
11
|
+
this.color = '#d5d5d5';
|
|
12
|
+
}
|
|
13
|
+
render() {
|
|
14
|
+
return (h(Host, null, h("div", { class: "tag", style: { 'background-color': this.color } }, h("span", null, this.text))));
|
|
15
|
+
}
|
|
16
|
+
static get style() { return tttxTagCss; }
|
|
17
|
+
}, [1, "tttx-tag", {
|
|
18
|
+
"text": [1],
|
|
19
|
+
"color": [1]
|
|
20
|
+
}]);
|
|
21
|
+
function defineCustomElement$1() {
|
|
22
|
+
if (typeof customElements === "undefined") {
|
|
23
|
+
return;
|
|
24
|
+
}
|
|
25
|
+
const components = ["tttx-tag"];
|
|
26
|
+
components.forEach(tagName => { switch (tagName) {
|
|
27
|
+
case "tttx-tag":
|
|
28
|
+
if (!customElements.get(tagName)) {
|
|
29
|
+
customElements.define(tagName, TttxTag$1);
|
|
30
|
+
}
|
|
31
|
+
break;
|
|
32
|
+
} });
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
const TttxTag = TttxTag$1;
|
|
36
|
+
const defineCustomElement = defineCustomElement$1;
|
|
37
|
+
|
|
38
|
+
export { TttxTag, defineCustomElement };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
2
2
|
|
|
3
|
-
const tttxToolbarCss = "
|
|
3
|
+
const tttxToolbarCss = ".container{display:flex;align-items:flex-end;row-gap:8px;padding:8px 0;flex-wrap:wrap}.container.bordered{border-bottom:1px solid #d5d5d5}.desktop ::slotted([slot=before]){flex:1 1 0px}.desktop ::slotted([slot=center]){flex:0 1 fit-content}.desktop ::slotted([slot=after]){flex:1 1 0px}::slotted([slot=before]){display:flex;align-items:flex-end;flex-wrap:wrap;gap:8px}::slotted([slot=center]){display:flex;justify-content:center;align-items:flex-end;flex-wrap:wrap;gap:8px}::slotted([slot=after]){display:flex;justify-content:end;align-items:flex-end;flex-wrap:wrap;gap:8px}";
|
|
4
4
|
|
|
5
5
|
const TttxToolbar$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
6
6
|
constructor() {
|
|
@@ -8,14 +8,30 @@ const TttxToolbar$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement
|
|
|
8
8
|
this.__registerHost();
|
|
9
9
|
this.__attachShadow();
|
|
10
10
|
this.border = true;
|
|
11
|
+
this.viewSize = undefined;
|
|
12
|
+
}
|
|
13
|
+
handleResize() {
|
|
14
|
+
this.setViewSize();
|
|
15
|
+
}
|
|
16
|
+
async componentWillLoad() {
|
|
17
|
+
this.setViewSize();
|
|
18
|
+
}
|
|
19
|
+
setViewSize() {
|
|
20
|
+
if (window.innerWidth < 698) {
|
|
21
|
+
this.viewSize = 'mobile';
|
|
22
|
+
}
|
|
23
|
+
else {
|
|
24
|
+
this.viewSize = 'desktop';
|
|
25
|
+
}
|
|
11
26
|
}
|
|
12
27
|
render() {
|
|
13
|
-
return (h(Host, { class: this.border ? 'bordered' : '' }, h("slot", { name: 'before' }), h("slot", { name: 'center' }), h("slot", { name: 'after' })));
|
|
28
|
+
return (h(Host, null, h("div", { class: `container ${this.border ? 'bordered' : ''} ${this.viewSize}` }, h("slot", { name: 'before' }), h("slot", { name: 'center' }), h("slot", { name: 'after' }))));
|
|
14
29
|
}
|
|
15
30
|
static get style() { return tttxToolbarCss; }
|
|
16
31
|
}, [1, "tttx-toolbar", {
|
|
17
|
-
"border": [4]
|
|
18
|
-
|
|
32
|
+
"border": [4],
|
|
33
|
+
"viewSize": [32]
|
|
34
|
+
}, [[9, "resize", "handleResize"]]]);
|
|
19
35
|
function defineCustomElement$1() {
|
|
20
36
|
if (typeof customElements === "undefined") {
|
|
21
37
|
return;
|
package/dist/esm/loader.js
CHANGED
|
@@ -11,7 +11,7 @@ const patchEsm = () => {
|
|
|
11
11
|
const defineCustomElements = (win, options) => {
|
|
12
12
|
if (typeof window === 'undefined') return Promise.resolve();
|
|
13
13
|
return patchEsm().then(() => {
|
|
14
|
-
return bootstrapLazy([["tttx-dialog-box",[[1,"tttx-dialog-box",{"data":[1025],"size":[1],"open":[1028],"elementSize":[32]},[[9,"resize","handleResize"]]]]],["tttx-select-box",[[1,"tttx-select-box",{"optionsData":[1,"options-data"],"label":[1],"inline":[4],"placeholder":[1],"searchEnabled":[4,"search-enabled"],"open":[32],"selectedItem":[32],"searchTerm":[32]},[[0,"closeSelectBox","handleCloseSelectBox"],[0,"blur","handleBlur"]]]]],["tttx-tree-view",[[1,"tttx-tree-view",{"data":[1040],"treeData":[32]}]]],["tttx-filter",[[1,"tttx-filter",{"filterKey":[1,"filter-key"],"filterOptions":[1,"filter-options"],"showSelectAll":[4,"show-select-all"],"showSearchField":[4,"show-search-field"],"showOptionIcons":[4,"show-option-icons"],"filterButtonStyle":[1,"filter-button-style"],"filterHeader":[1,"filter-header"],"defaultFilterOptions":[1,"default-filter-options"],"popoverWidth":[1,"popover-width"],"showPopover":[32],"displayedFilterSettings":[32],"selectedFilters":[32],"filterSearchTerm":[32],"allSelected":[32]},[[0,"closeFilter","handleCloseFilter"]]]]],["tttx-list",[[1,"tttx-list",{"data":[1025],"name":[1],"_data":[32],"setAllCheckboxes":[64]}]]],["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]},[[0,"closeSorter","handleCloseSorter"]]]]],["tttx-form",[[1,"tttx-form",{"formschema":[1032],"data":[1032],"submit":[64]}]]],["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-qrcode",[[1,"tttx-qrcode",{"link":[1025],"size":[1026]}]]],["tttx-toolbar",[[1,"tttx-toolbar",{"border":[4]}]]],["tttx-icon",[[1,"tttx-icon",{"icon":[1],"color":[1]}]]],["tttx-standalone-input",[[2,"tttx-standalone-input",{"label":[1],"secondarylabel":[1],"showerrormsg":[4],"showerrorbubble":[4],"errormsg":[1],"iconleft":[1],"iconleftcolor":[1],"iconright":[1],"iconrightcolor":[1],"inputicon":[1],"inputiconcolor":[1],"inline":[4],"inputautocapitalize":[1],"inputautofocus":[4],"inputkeyhint":[1],"inputindex":[8],"inputtitle":[1],"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-button",[[1,"tttx-button",{"notext":[4],"icon":[1],"iconposition":[1],"iconcolor":[1025],"design":[1]}]]]], options);
|
|
14
|
+
return bootstrapLazy([["tttx-dialog-box",[[1,"tttx-dialog-box",{"data":[1025],"size":[1],"open":[1028],"elementSize":[32]},[[9,"resize","handleResize"]]]]],["tttx-select-box",[[1,"tttx-select-box",{"optionsData":[1,"options-data"],"label":[1],"inline":[4],"placeholder":[1],"searchEnabled":[4,"search-enabled"],"open":[32],"selectedItem":[32],"searchTerm":[32]},[[0,"closeSelectBox","handleCloseSelectBox"],[0,"blur","handleBlur"]]]]],["tttx-tree-view",[[1,"tttx-tree-view",{"data":[1040],"treeData":[32]}]]],["tttx-filter",[[1,"tttx-filter",{"filterKey":[1,"filter-key"],"filterOptions":[1,"filter-options"],"showSelectAll":[4,"show-select-all"],"showSearchField":[4,"show-search-field"],"showOptionIcons":[4,"show-option-icons"],"filterButtonStyle":[1,"filter-button-style"],"filterHeader":[1,"filter-header"],"defaultFilterOptions":[1,"default-filter-options"],"popoverWidth":[1,"popover-width"],"showPopover":[32],"displayedFilterSettings":[32],"selectedFilters":[32],"filterSearchTerm":[32],"allSelected":[32]},[[0,"closeFilter","handleCloseFilter"]]]]],["tttx-list",[[1,"tttx-list",{"data":[1025],"name":[1],"_data":[32],"setAllCheckboxes":[64]}]]],["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]},[[0,"closeSorter","handleCloseSorter"]]]]],["tttx-form",[[1,"tttx-form",{"formschema":[1032],"data":[1032],"submit":[64]}]]],["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-qrcode",[[1,"tttx-qrcode",{"link":[1025],"size":[1026]}]]],["tttx-tag",[[1,"tttx-tag",{"text":[1],"color":[1]}]]],["tttx-toolbar",[[1,"tttx-toolbar",{"border":[4],"viewSize":[32]},[[9,"resize","handleResize"]]]]],["tttx-icon",[[1,"tttx-icon",{"icon":[1],"color":[1]}]]],["tttx-standalone-input",[[2,"tttx-standalone-input",{"label":[1],"secondarylabel":[1],"showerrormsg":[4],"showerrorbubble":[4],"errormsg":[1],"iconleft":[1],"iconleftcolor":[1],"iconright":[1],"iconrightcolor":[1],"inputicon":[1],"inputiconcolor":[1],"inline":[4],"inputautocapitalize":[1],"inputautofocus":[4],"inputkeyhint":[1],"inputindex":[8],"inputtitle":[1],"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-button",[[1,"tttx-button",{"notext":[4],"icon":[1],"iconposition":[1],"iconcolor":[1025],"design":[1]}]]]], options);
|
|
15
15
|
});
|
|
16
16
|
};
|
|
17
17
|
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { r as registerInstance, h, H as Host } from './index-1c711ead.js';
|
|
2
|
+
|
|
3
|
+
const tttxTagCss = ".material-symbols-rounded{font-variation-settings:\"FILL\" 1, \"wght\" 400, \"GRAD\" 0, \"opsz\" 24}button{cursor:pointer}.button{font-family:Roboto, serif;box-sizing:border-box;height:36px;min-width:36px;padding:0;margin:0;background:transparent;color:#212121;border:1px solid #c8c8c8;border-radius:4px;text-transform:uppercase;display:flex;justify-content:left;align-items:center;font-size:14px;font-weight:400}.button-content{display:block;padding:0 16px}.icon-left,.icon-right{margin-top:4px}.iconleft{padding-left:8px}.iconleft .button-content{padding-left:4px}.iconright{padding-right:8px}.iconright .button-content{padding-right:4px}.notext{padding:0 6px}.button:active{background:rgba(17, 17, 17, 0.2);border:1px solid #d5d5d5}.primary{background:#1479c6;border:1px solid #1479c6;color:white}.primary:active{background:#1464a2;border:1px solid #1464a2}.borderless{background:transparent;border:none;color:#212121}.borderless:active{background:rgba(17, 17, 17, 0.2);border:none}.borderless-circle{background:transparent;border:none;color:#212121;border-radius:50%}.borderless-circle:active{border:none}.borderless-circle:focus{border-color:transparent}.danger{background:#dc0000;border:1px solid #dc0000;color:white}.danger:active{background:#b00000;border:1px solid #b00000}.disabled{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}.disabled:active{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}@media (hover: hover){.button:hover{background:rgba(17, 17, 17, 0.1);border:1px solid #d5d5d5}.primary:hover{background:#146eb3;border:1px solid #146eb3}.borderless:hover{background:rgba(17, 17, 17, 0.1);border:none}.borderless-circle:hover{background:rgba(17, 17, 17, 0.1);border:none}.danger:hover{background:#c60000;border:1px solid #c60000}.disabled:hover{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}}:host{display:inline-block}.tag{border-radius:20px;padding:4px;font-family:\"Roboto\", sans-serif;font-size:14px;font-weight:400}.tag span{margin-left:4px;margin-right:4px;color:#212121}.icon{height:18px;width:18px;font-weight:400}";
|
|
4
|
+
|
|
5
|
+
const TttxTag = class {
|
|
6
|
+
constructor(hostRef) {
|
|
7
|
+
registerInstance(this, hostRef);
|
|
8
|
+
this.text = undefined;
|
|
9
|
+
this.color = '#d5d5d5';
|
|
10
|
+
}
|
|
11
|
+
render() {
|
|
12
|
+
return (h(Host, null, h("div", { class: "tag", style: { 'background-color': this.color } }, h("span", null, this.text))));
|
|
13
|
+
}
|
|
14
|
+
};
|
|
15
|
+
TttxTag.style = tttxTagCss;
|
|
16
|
+
|
|
17
|
+
export { TttxTag as tttx_tag };
|
|
@@ -1,14 +1,29 @@
|
|
|
1
1
|
import { r as registerInstance, h, H as Host } from './index-1c711ead.js';
|
|
2
2
|
|
|
3
|
-
const tttxToolbarCss = "
|
|
3
|
+
const tttxToolbarCss = ".container{display:flex;align-items:flex-end;row-gap:8px;padding:8px 0;flex-wrap:wrap}.container.bordered{border-bottom:1px solid #d5d5d5}.desktop ::slotted([slot=before]){flex:1 1 0px}.desktop ::slotted([slot=center]){flex:0 1 fit-content}.desktop ::slotted([slot=after]){flex:1 1 0px}::slotted([slot=before]){display:flex;align-items:flex-end;flex-wrap:wrap;gap:8px}::slotted([slot=center]){display:flex;justify-content:center;align-items:flex-end;flex-wrap:wrap;gap:8px}::slotted([slot=after]){display:flex;justify-content:end;align-items:flex-end;flex-wrap:wrap;gap:8px}";
|
|
4
4
|
|
|
5
5
|
const TttxToolbar = class {
|
|
6
6
|
constructor(hostRef) {
|
|
7
7
|
registerInstance(this, hostRef);
|
|
8
8
|
this.border = true;
|
|
9
|
+
this.viewSize = undefined;
|
|
10
|
+
}
|
|
11
|
+
handleResize() {
|
|
12
|
+
this.setViewSize();
|
|
13
|
+
}
|
|
14
|
+
async componentWillLoad() {
|
|
15
|
+
this.setViewSize();
|
|
16
|
+
}
|
|
17
|
+
setViewSize() {
|
|
18
|
+
if (window.innerWidth < 698) {
|
|
19
|
+
this.viewSize = 'mobile';
|
|
20
|
+
}
|
|
21
|
+
else {
|
|
22
|
+
this.viewSize = 'desktop';
|
|
23
|
+
}
|
|
9
24
|
}
|
|
10
25
|
render() {
|
|
11
|
-
return (h(Host, { class: this.border ? 'bordered' : '' }, h("slot", { name: 'before' }), h("slot", { name: 'center' }), h("slot", { name: 'after' })));
|
|
26
|
+
return (h(Host, null, h("div", { class: `container ${this.border ? 'bordered' : ''} ${this.viewSize}` }, h("slot", { name: 'before' }), h("slot", { name: 'center' }), h("slot", { name: 'after' }))));
|
|
12
27
|
}
|
|
13
28
|
};
|
|
14
29
|
TttxToolbar.style = tttxToolbarCss;
|
package/dist/esm/tttx.js
CHANGED
|
@@ -14,5 +14,5 @@ const patchBrowser = () => {
|
|
|
14
14
|
};
|
|
15
15
|
|
|
16
16
|
patchBrowser().then(options => {
|
|
17
|
-
return bootstrapLazy([["tttx-dialog-box",[[1,"tttx-dialog-box",{"data":[1025],"size":[1],"open":[1028],"elementSize":[32]},[[9,"resize","handleResize"]]]]],["tttx-select-box",[[1,"tttx-select-box",{"optionsData":[1,"options-data"],"label":[1],"inline":[4],"placeholder":[1],"searchEnabled":[4,"search-enabled"],"open":[32],"selectedItem":[32],"searchTerm":[32]},[[0,"closeSelectBox","handleCloseSelectBox"],[0,"blur","handleBlur"]]]]],["tttx-tree-view",[[1,"tttx-tree-view",{"data":[1040],"treeData":[32]}]]],["tttx-filter",[[1,"tttx-filter",{"filterKey":[1,"filter-key"],"filterOptions":[1,"filter-options"],"showSelectAll":[4,"show-select-all"],"showSearchField":[4,"show-search-field"],"showOptionIcons":[4,"show-option-icons"],"filterButtonStyle":[1,"filter-button-style"],"filterHeader":[1,"filter-header"],"defaultFilterOptions":[1,"default-filter-options"],"popoverWidth":[1,"popover-width"],"showPopover":[32],"displayedFilterSettings":[32],"selectedFilters":[32],"filterSearchTerm":[32],"allSelected":[32]},[[0,"closeFilter","handleCloseFilter"]]]]],["tttx-list",[[1,"tttx-list",{"data":[1025],"name":[1],"_data":[32],"setAllCheckboxes":[64]}]]],["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]},[[0,"closeSorter","handleCloseSorter"]]]]],["tttx-form",[[1,"tttx-form",{"formschema":[1032],"data":[1032],"submit":[64]}]]],["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-qrcode",[[1,"tttx-qrcode",{"link":[1025],"size":[1026]}]]],["tttx-toolbar",[[1,"tttx-toolbar",{"border":[4]}]]],["tttx-icon",[[1,"tttx-icon",{"icon":[1],"color":[1]}]]],["tttx-standalone-input",[[2,"tttx-standalone-input",{"label":[1],"secondarylabel":[1],"showerrormsg":[4],"showerrorbubble":[4],"errormsg":[1],"iconleft":[1],"iconleftcolor":[1],"iconright":[1],"iconrightcolor":[1],"inputicon":[1],"inputiconcolor":[1],"inline":[4],"inputautocapitalize":[1],"inputautofocus":[4],"inputkeyhint":[1],"inputindex":[8],"inputtitle":[1],"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-button",[[1,"tttx-button",{"notext":[4],"icon":[1],"iconposition":[1],"iconcolor":[1025],"design":[1]}]]]], options);
|
|
17
|
+
return bootstrapLazy([["tttx-dialog-box",[[1,"tttx-dialog-box",{"data":[1025],"size":[1],"open":[1028],"elementSize":[32]},[[9,"resize","handleResize"]]]]],["tttx-select-box",[[1,"tttx-select-box",{"optionsData":[1,"options-data"],"label":[1],"inline":[4],"placeholder":[1],"searchEnabled":[4,"search-enabled"],"open":[32],"selectedItem":[32],"searchTerm":[32]},[[0,"closeSelectBox","handleCloseSelectBox"],[0,"blur","handleBlur"]]]]],["tttx-tree-view",[[1,"tttx-tree-view",{"data":[1040],"treeData":[32]}]]],["tttx-filter",[[1,"tttx-filter",{"filterKey":[1,"filter-key"],"filterOptions":[1,"filter-options"],"showSelectAll":[4,"show-select-all"],"showSearchField":[4,"show-search-field"],"showOptionIcons":[4,"show-option-icons"],"filterButtonStyle":[1,"filter-button-style"],"filterHeader":[1,"filter-header"],"defaultFilterOptions":[1,"default-filter-options"],"popoverWidth":[1,"popover-width"],"showPopover":[32],"displayedFilterSettings":[32],"selectedFilters":[32],"filterSearchTerm":[32],"allSelected":[32]},[[0,"closeFilter","handleCloseFilter"]]]]],["tttx-list",[[1,"tttx-list",{"data":[1025],"name":[1],"_data":[32],"setAllCheckboxes":[64]}]]],["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]},[[0,"closeSorter","handleCloseSorter"]]]]],["tttx-form",[[1,"tttx-form",{"formschema":[1032],"data":[1032],"submit":[64]}]]],["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-qrcode",[[1,"tttx-qrcode",{"link":[1025],"size":[1026]}]]],["tttx-tag",[[1,"tttx-tag",{"text":[1],"color":[1]}]]],["tttx-toolbar",[[1,"tttx-toolbar",{"border":[4],"viewSize":[32]},[[9,"resize","handleResize"]]]]],["tttx-icon",[[1,"tttx-icon",{"icon":[1],"color":[1]}]]],["tttx-standalone-input",[[2,"tttx-standalone-input",{"label":[1],"secondarylabel":[1],"showerrormsg":[4],"showerrorbubble":[4],"errormsg":[1],"iconleft":[1],"iconleftcolor":[1],"iconright":[1],"iconrightcolor":[1],"inputicon":[1],"inputiconcolor":[1],"inline":[4],"inputautocapitalize":[1],"inputautofocus":[4],"inputkeyhint":[1],"inputindex":[8],"inputtitle":[1],"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-button",[[1,"tttx-button",{"notext":[4],"icon":[1],"iconposition":[1],"iconcolor":[1025],"design":[1]}]]]], options);
|
|
18
18
|
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r,h as o,H as e}from"./p-c544551b.js";const n=class{constructor(o){r(this,o),this.text=void 0,this.color="#d5d5d5"}render(){return o(e,null,o("div",{class:"tag",style:{"background-color":this.color}},o("span",null,this.text)))}};n.style='.material-symbols-rounded{font-variation-settings:"FILL" 1, "wght" 400, "GRAD" 0, "opsz" 24}button{cursor:pointer}.button{font-family:Roboto, serif;box-sizing:border-box;height:36px;min-width:36px;padding:0;margin:0;background:transparent;color:#212121;border:1px solid #c8c8c8;border-radius:4px;text-transform:uppercase;display:flex;justify-content:left;align-items:center;font-size:14px;font-weight:400}.button-content{display:block;padding:0 16px}.icon-left,.icon-right{margin-top:4px}.iconleft{padding-left:8px}.iconleft .button-content{padding-left:4px}.iconright{padding-right:8px}.iconright .button-content{padding-right:4px}.notext{padding:0 6px}.button:active{background:rgba(17, 17, 17, 0.2);border:1px solid #d5d5d5}.primary{background:#1479c6;border:1px solid #1479c6;color:white}.primary:active{background:#1464a2;border:1px solid #1464a2}.borderless{background:transparent;border:none;color:#212121}.borderless:active{background:rgba(17, 17, 17, 0.2);border:none}.borderless-circle{background:transparent;border:none;color:#212121;border-radius:50%}.borderless-circle:active{border:none}.borderless-circle:focus{border-color:transparent}.danger{background:#dc0000;border:1px solid #dc0000;color:white}.danger:active{background:#b00000;border:1px solid #b00000}.disabled{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}.disabled:active{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}@media (hover: hover){.button:hover{background:rgba(17, 17, 17, 0.1);border:1px solid #d5d5d5}.primary:hover{background:#146eb3;border:1px solid #146eb3}.borderless:hover{background:rgba(17, 17, 17, 0.1);border:none}.borderless-circle:hover{background:rgba(17, 17, 17, 0.1);border:none}.danger:hover{background:#c60000;border:1px solid #c60000}.disabled:hover{background:#aeaeae;border:none;color:#4c4c4c;cursor:not-allowed}}:host{display:inline-block}.tag{border-radius:20px;padding:4px;font-family:"Roboto", sans-serif;font-size:14px;font-weight:400}.tag span{margin-left:4px;margin-right:4px;color:#212121}.icon{height:18px;width:18px;font-weight:400}';export{n as tttx_tag}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as e,h as t,H as s}from"./p-c544551b.js";const o=class{constructor(t){e(this,t),this.border=!0,this.viewSize=void 0}handleResize(){this.setViewSize()}async componentWillLoad(){this.setViewSize()}setViewSize(){this.viewSize=window.innerWidth<698?"mobile":"desktop"}render(){return t(s,null,t("div",{class:`container ${this.border?"bordered":""} ${this.viewSize}`},t("slot",{name:"before"}),t("slot",{name:"center"}),t("slot",{name:"after"})))}};o.style=".container{display:flex;align-items:flex-end;row-gap:8px;padding:8px 0;flex-wrap:wrap}.container.bordered{border-bottom:1px solid #d5d5d5}.desktop ::slotted([slot=before]){flex:1 1 0px}.desktop ::slotted([slot=center]){flex:0 1 fit-content}.desktop ::slotted([slot=after]){flex:1 1 0px}::slotted([slot=before]){display:flex;align-items:flex-end;flex-wrap:wrap;gap:8px}::slotted([slot=center]){display:flex;justify-content:center;align-items:flex-end;flex-wrap:wrap;gap:8px}::slotted([slot=after]){display:flex;justify-content:end;align-items:flex-end;flex-wrap:wrap;gap:8px}";export{o as tttx_toolbar}
|
package/dist/tttx/tttx.esm.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{p as e,b as t}from"./p-c544551b.js";export{s as setNonce}from"./p-c544551b.js";(()=>{const t=import.meta.url,o={};return""!==t&&(o.resourcesUrl=new URL(".",t).href),e(o)})().then((e=>t([["p-64479f02",[[1,"tttx-dialog-box",{data:[1025],size:[1],open:[1028],elementSize:[32]},[[9,"resize","handleResize"]]]]],["p-ff38d9f3",[[1,"tttx-select-box",{optionsData:[1,"options-data"],label:[1],inline:[4],placeholder:[1],searchEnabled:[4,"search-enabled"],open:[32],selectedItem:[32],searchTerm:[32]},[[0,"closeSelectBox","handleCloseSelectBox"],[0,"blur","handleBlur"]]]]],["p-2f066b53",[[1,"tttx-tree-view",{data:[1040],treeData:[32]}]]],["p-a658e1ac",[[1,"tttx-filter",{filterKey:[1,"filter-key"],filterOptions:[1,"filter-options"],showSelectAll:[4,"show-select-all"],showSearchField:[4,"show-search-field"],showOptionIcons:[4,"show-option-icons"],filterButtonStyle:[1,"filter-button-style"],filterHeader:[1,"filter-header"],defaultFilterOptions:[1,"default-filter-options"],popoverWidth:[1,"popover-width"],showPopover:[32],displayedFilterSettings:[32],selectedFilters:[32],filterSearchTerm:[32],allSelected:[32]},[[0,"closeFilter","handleCloseFilter"]]]]],["p-40c66a2e",[[1,"tttx-list",{data:[1025],name:[1],_data:[32],setAllCheckboxes:[64]}]]],["p-225e6fa6",[[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]},[[0,"closeSorter","handleCloseSorter"]]]]],["p-57621fdb",[[1,"tttx-form",{formschema:[1032],data:[1032],submit:[64]}]]],["p-f80ab1d8",[[1,"tttx-keyvalue-block",{keyvalues:[8],horizontal:[4]}]]],["p-3467c62e",[[1,"tttx-loading-spinner",{loadingMessage:[1028,"loading-message"],size:[1025]}]]],["p-cff962bf",[[1,"tttx-qrcode",{link:[1025],size:[1026]}]]],["p-
|
|
1
|
+
import{p as e,b as t}from"./p-c544551b.js";export{s as setNonce}from"./p-c544551b.js";(()=>{const t=import.meta.url,o={};return""!==t&&(o.resourcesUrl=new URL(".",t).href),e(o)})().then((e=>t([["p-64479f02",[[1,"tttx-dialog-box",{data:[1025],size:[1],open:[1028],elementSize:[32]},[[9,"resize","handleResize"]]]]],["p-ff38d9f3",[[1,"tttx-select-box",{optionsData:[1,"options-data"],label:[1],inline:[4],placeholder:[1],searchEnabled:[4,"search-enabled"],open:[32],selectedItem:[32],searchTerm:[32]},[[0,"closeSelectBox","handleCloseSelectBox"],[0,"blur","handleBlur"]]]]],["p-2f066b53",[[1,"tttx-tree-view",{data:[1040],treeData:[32]}]]],["p-a658e1ac",[[1,"tttx-filter",{filterKey:[1,"filter-key"],filterOptions:[1,"filter-options"],showSelectAll:[4,"show-select-all"],showSearchField:[4,"show-search-field"],showOptionIcons:[4,"show-option-icons"],filterButtonStyle:[1,"filter-button-style"],filterHeader:[1,"filter-header"],defaultFilterOptions:[1,"default-filter-options"],popoverWidth:[1,"popover-width"],showPopover:[32],displayedFilterSettings:[32],selectedFilters:[32],filterSearchTerm:[32],allSelected:[32]},[[0,"closeFilter","handleCloseFilter"]]]]],["p-40c66a2e",[[1,"tttx-list",{data:[1025],name:[1],_data:[32],setAllCheckboxes:[64]}]]],["p-225e6fa6",[[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]},[[0,"closeSorter","handleCloseSorter"]]]]],["p-57621fdb",[[1,"tttx-form",{formschema:[1032],data:[1032],submit:[64]}]]],["p-f80ab1d8",[[1,"tttx-keyvalue-block",{keyvalues:[8],horizontal:[4]}]]],["p-3467c62e",[[1,"tttx-loading-spinner",{loadingMessage:[1028,"loading-message"],size:[1025]}]]],["p-cff962bf",[[1,"tttx-qrcode",{link:[1025],size:[1026]}]]],["p-68680d65",[[1,"tttx-tag",{text:[1],color:[1]}]]],["p-6a40d3cc",[[1,"tttx-toolbar",{border:[4],viewSize:[32]},[[9,"resize","handleResize"]]]]],["p-53fa8b4d",[[1,"tttx-icon",{icon:[1],color:[1]}]]],["p-e6bbdae3",[[2,"tttx-standalone-input",{label:[1],secondarylabel:[1],showerrormsg:[4],showerrorbubble:[4],errormsg:[1],iconleft:[1],iconleftcolor:[1],iconright:[1],iconrightcolor:[1],inputicon:[1],inputiconcolor:[1],inline:[4],inputautocapitalize:[1],inputautofocus:[4],inputkeyhint:[1],inputindex:[8],inputtitle:[1],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]}]]],["p-3c7e11d9",[[1,"tttx-button",{notext:[4],icon:[1],iconposition:[1],iconcolor:[1025],design:[1]}]]]],e)));
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
title: string;
|
|
3
|
+
component: string;
|
|
4
|
+
argTypes: {
|
|
5
|
+
text: {
|
|
6
|
+
control: {
|
|
7
|
+
type: string;
|
|
8
|
+
};
|
|
9
|
+
default: string;
|
|
10
|
+
};
|
|
11
|
+
color: {
|
|
12
|
+
control: {
|
|
13
|
+
type: string;
|
|
14
|
+
};
|
|
15
|
+
default: string;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
};
|
|
19
|
+
export default _default;
|
|
20
|
+
export declare const tag: any;
|
|
21
|
+
export declare const tags: any;
|
|
@@ -10,4 +10,10 @@ declare const _default: {
|
|
|
10
10
|
};
|
|
11
11
|
};
|
|
12
12
|
export default _default;
|
|
13
|
-
export declare const
|
|
13
|
+
export declare const DefaultToolbar: any;
|
|
14
|
+
export declare const TallElementsToolbar: any;
|
|
15
|
+
export declare const WrapElementsToolbar: any;
|
|
16
|
+
export declare const LeftToolbarOnly: any;
|
|
17
|
+
export declare const CenterToolbarOnly: any;
|
|
18
|
+
export declare const TwoColumnToolbar: any;
|
|
19
|
+
export declare const LongItemsToolbar: any;
|
|
@@ -120,6 +120,10 @@ export namespace Components {
|
|
|
120
120
|
"type": string;
|
|
121
121
|
"value": string | number;
|
|
122
122
|
}
|
|
123
|
+
interface TttxTag {
|
|
124
|
+
"color": string;
|
|
125
|
+
"text": string;
|
|
126
|
+
}
|
|
123
127
|
interface TttxToolbar {
|
|
124
128
|
"border": boolean;
|
|
125
129
|
}
|
|
@@ -232,6 +236,12 @@ declare global {
|
|
|
232
236
|
prototype: HTMLTttxStandaloneInputElement;
|
|
233
237
|
new (): HTMLTttxStandaloneInputElement;
|
|
234
238
|
};
|
|
239
|
+
interface HTMLTttxTagElement extends Components.TttxTag, HTMLStencilElement {
|
|
240
|
+
}
|
|
241
|
+
var HTMLTttxTagElement: {
|
|
242
|
+
prototype: HTMLTttxTagElement;
|
|
243
|
+
new (): HTMLTttxTagElement;
|
|
244
|
+
};
|
|
235
245
|
interface HTMLTttxToolbarElement extends Components.TttxToolbar, HTMLStencilElement {
|
|
236
246
|
}
|
|
237
247
|
var HTMLTttxToolbarElement: {
|
|
@@ -257,6 +267,7 @@ declare global {
|
|
|
257
267
|
"tttx-select-box": HTMLTttxSelectBoxElement;
|
|
258
268
|
"tttx-sorter": HTMLTttxSorterElement;
|
|
259
269
|
"tttx-standalone-input": HTMLTttxStandaloneInputElement;
|
|
270
|
+
"tttx-tag": HTMLTttxTagElement;
|
|
260
271
|
"tttx-toolbar": HTMLTttxToolbarElement;
|
|
261
272
|
"tttx-tree-view": HTMLTttxTreeViewElement;
|
|
262
273
|
}
|
|
@@ -386,6 +397,10 @@ declare namespace LocalJSX {
|
|
|
386
397
|
"type"?: string;
|
|
387
398
|
"value"?: string | number;
|
|
388
399
|
}
|
|
400
|
+
interface TttxTag {
|
|
401
|
+
"color"?: string;
|
|
402
|
+
"text"?: string;
|
|
403
|
+
}
|
|
389
404
|
interface TttxToolbar {
|
|
390
405
|
"border"?: boolean;
|
|
391
406
|
}
|
|
@@ -406,6 +421,7 @@ declare namespace LocalJSX {
|
|
|
406
421
|
"tttx-select-box": TttxSelectBox;
|
|
407
422
|
"tttx-sorter": TttxSorter;
|
|
408
423
|
"tttx-standalone-input": TttxStandaloneInput;
|
|
424
|
+
"tttx-tag": TttxTag;
|
|
409
425
|
"tttx-toolbar": TttxToolbar;
|
|
410
426
|
"tttx-tree-view": TttxTreeView;
|
|
411
427
|
}
|
|
@@ -426,6 +442,7 @@ declare module "@stencil/core" {
|
|
|
426
442
|
"tttx-select-box": LocalJSX.TttxSelectBox & JSXBase.HTMLAttributes<HTMLTttxSelectBoxElement>;
|
|
427
443
|
"tttx-sorter": LocalJSX.TttxSorter & JSXBase.HTMLAttributes<HTMLTttxSorterElement>;
|
|
428
444
|
"tttx-standalone-input": LocalJSX.TttxStandaloneInput & JSXBase.HTMLAttributes<HTMLTttxStandaloneInputElement>;
|
|
445
|
+
"tttx-tag": LocalJSX.TttxTag & JSXBase.HTMLAttributes<HTMLTttxTagElement>;
|
|
429
446
|
"tttx-toolbar": LocalJSX.TttxToolbar & JSXBase.HTMLAttributes<HTMLTttxToolbarElement>;
|
|
430
447
|
"tttx-tree-view": LocalJSX.TttxTreeView & JSXBase.HTMLAttributes<HTMLTttxTreeViewElement>;
|
|
431
448
|
}
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as e,h as t,H as s}from"./p-c544551b.js";const o=class{constructor(t){e(this,t),this.border=!0}render(){return t(s,{class:this.border?"bordered":""},t("slot",{name:"before"}),t("slot",{name:"center"}),t("slot",{name:"after"}))}};o.style=":host{height:36px;display:flex;padding:8px 0;gap:8px}:host(.bordered){border-bottom:1px solid #d5d5d5}::slotted([slot=before]){display:flex;align-items:center;flex:1 1 0px;gap:8px}::slotted([slot=center]){display:flex;justify-content:center;align-items:center;flex:1 1 0px;gap:8px}::slotted([slot=after]){display:flex;justify-content:end;align-items:center;flex:1 1 0px;gap:8px}";export{o as tttx_toolbar}
|