@vertexvis/ui 0.1.0-canary.11 → 0.1.0-canary.12
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/components.cjs.js +1 -1
- package/dist/cjs/dom-b6c5fbf4.js +13 -0
- package/dist/cjs/index.cjs.js +6 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/tab-4335cd8f.js +26 -0
- package/dist/cjs/tabs-ece62a01.js +111 -0
- package/dist/cjs/{tooltip-e9f63631.js → tooltip-9ac797a0.js} +2 -5
- package/dist/cjs/vertex-tab.cjs.entry.js +11 -0
- package/dist/cjs/vertex-tabs.cjs.entry.js +12 -0
- package/dist/cjs/vertex-tooltip.cjs.entry.js +2 -1
- package/dist/collection/collection-manifest.json +2 -0
- package/dist/collection/components/index.js +2 -0
- package/dist/collection/components/tab/tab.css +16 -0
- package/dist/collection/components/tab/tab.js +85 -0
- package/dist/collection/components/tab/util.js +3 -0
- package/dist/collection/components/tabs/tabs.css +67 -0
- package/dist/collection/components/tabs/tabs.js +159 -0
- package/dist/components/components.esm.js +1 -1
- package/dist/components/index.esm.js +1 -1
- package/dist/components/p-2ae8175d.entry.js +1 -0
- package/dist/components/p-3dd7a75f.entry.js +1 -0
- package/dist/components/p-69496858.js +1 -0
- package/dist/components/p-76b961b8.js +1 -0
- package/dist/components/p-96f55673.js +1 -0
- package/dist/components/p-d3fd9ca3.entry.js +1 -0
- package/dist/components/p-ff7c70b9.js +1 -0
- package/dist/esm/components.js +1 -1
- package/dist/esm/dom-613e2677.js +10 -0
- package/dist/esm/index.js +4 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/tab-c76332b0.js +24 -0
- package/dist/esm/tabs-8e5353ba.js +109 -0
- package/dist/esm/{tooltip-933da261.js → tooltip-29278ea4.js} +1 -4
- package/dist/esm/vertex-tab.entry.js +3 -0
- package/dist/esm/vertex-tabs.entry.js +4 -0
- package/dist/esm/vertex-tooltip.entry.js +2 -1
- package/dist/types/components/index.d.ts +2 -0
- package/dist/types/components/tab/tab.d.ts +11 -0
- package/dist/types/components/tab/util.d.ts +1 -0
- package/dist/types/components/tabs/tabs.d.ts +23 -0
- package/dist/types/components.d.ts +51 -0
- package/package.json +2 -2
- package/dist/components/p-0b1cdc8a.entry.js +0 -1
- package/dist/components/p-92930f2a.js +0 -1
|
@@ -88,7 +88,7 @@ const patchDynamicImport = (base, orgScriptElm) => {
|
|
|
88
88
|
};
|
|
89
89
|
|
|
90
90
|
patchBrowser().then(options => {
|
|
91
|
-
return index.bootstrapLazy([["vertex-click-to-edit-textfield.cjs",[[6,"vertex-click-to-edit-textfield",{"placeholder":[1],"fontSize":[1,"font-size"],"disabled":[516],"multiline":[4],"minRows":[2,"min-rows"],"maxRows":[2,"max-rows"],"value":[1032],"autoFocus":[4,"auto-focus"],"editing":[1540],"hasError":[4,"has-error"]}]]],["vertex-collapsible.cjs",[[1,"vertex-collapsible",{"label":[1],"open":[1540]}]]],["vertex-context-menu.cjs",[[1,"vertex-context-menu",{"targetSelector":[1,"target-selector"],"animated":[4],"position":[32],"open":[32]}]]],["vertex-dialog.cjs",[[1,"vertex-dialog",{"open":[1540],"fullscreen":[4],"resizable":[4],"width":[32],"height":[32],"minWidth":[32],"minHeight":[32],"maxWidth":[32],"maxHeight":[32],"isResizing":[32]},[[4,"keydown","keyDownListener"]]]]],["vertex-draggable-popover.cjs",[[1,"vertex-draggable-popover",{"position":[1],"boundarySelector":[1,"boundary-selector"],"boundaryPadding":[2,"boundary-padding"],"anchorPosition":[32],"lastPosition":[32],"dragging":[32]}]]],["vertex-dropdown-menu.cjs",[[1,"vertex-dropdown-menu",{"animated":[4],"placement":[1],"open":[32]}]]],["vertex-help-tooltip.cjs",[[1,"vertex-help-tooltip",{"animated":[4],"placement":[1],"open":[32]}]]],["vertex-search-bar.cjs",[[6,"vertex-search-bar",{"variant":[1],"disabled":[4],"triggerCharacter":[1,"trigger-character"],"breakCharacters":[16],"resultItems":[16],"placement":[1],"value":[1],"placeholder":[1],"replacements":[1040],"replacementUriType":[1,"replacement-uri-type"],"cursorPosition":[32],"displayedElements":[32],"hasTriggered":[32]}]]],["vertex-select.cjs",[[1,"vertex-select",{"value":[513],"placeholder":[513],"disabled":[516],"animated":[4],"hideSelected":[4,"hide-selected"],"resizeObserverFactory":[16],"open":[32],"position":[32],"displayValue":[32]}]]],["vertex-slider.cjs",[[1,"vertex-slider",{"min":[2],"max":[2],"valueLabelDisplay":[1,"value-label-display"],"step":[8],"size":[1],"value":[1026],"disabled":[4]}]]],["vertex-toast.cjs",[[1,"vertex-toast",{"content":[1],"placement":[1],"duration":[2],"animated":[4],"open":[4],"type":[1],"isOpen":[32]}]]],["vertex-color-circle-picker.cjs",[[1,"vertex-color-circle-picker",{"colors":[1],"supplementalColors":[1,"supplemental-colors"],"theme":[513],"lightenPercentage":[2,"lighten-percentage"],"darkenPercentage":[2,"darken-percentage"],"selected":[1537],"direction":[1]}]]],["vertex-color-picker.cjs",[[1,"vertex-color-picker",{"value":[1537],"disabled":[4]}]]],["vertex-toggle.cjs",[[1,"vertex-toggle",{"variant":[1],"disabled":[4],"checked":[1540]}]]],["vertex-avatar.cjs",[[1,"vertex-avatar",{"firstName":[1,"first-name"],"lastName":[1,"last-name"],"value":[1],"active":[4],"variant":[1]}]]],["vertex-avatar-group.cjs",[[1,"vertex-avatar-group"]]],["vertex-badge.cjs",[[1,"vertex-badge",{"badgeText":[1,"badge-text"],"badgeColor":[1,"badge-color"]}]]],["vertex-button.cjs",[[1,"vertex-button",{"type":[1],"color":[1],"variant":[1],"size":[1],"expand":[1],"href":[1],"target":[1],"disabled":[516]}]]],["vertex-card.cjs",[[1,"vertex-card",{"mode":[1]}]]],["vertex-card-group.cjs",[[1,"vertex-card-group",{"selected":[516],"hovered":[516],"expanded":[516]}]]],["vertex-chip.cjs",[[1,"vertex-chip",{"variant":[1],"color":[1]}]]],["vertex-logo-loading.cjs",[[1,"vertex-logo-loading"]]],["vertex-menu-divider.cjs",[[1,"vertex-menu-divider"]]],["vertex-menu-item.cjs",[[1,"vertex-menu-item",{"disabled":[516]}]]],["vertex-radio.cjs",[[2,"vertex-radio",{"disabled":[516],"value":[513],"label":[513],"name":[513],"checked":[516]}]]],["vertex-radio-group.cjs",[[1,"vertex-radio-group",{"name":[513],"value":[1537]}]]],["vertex-resizable.cjs",[[1,"vertex-resizable",{"horizontalDirection":[1,"horizontal-direction"],"verticalDirection":[1,"vertical-direction"],"initialHorizontalScale":[2,"initial-horizontal-scale"],"initialVerticalScale":[2,"initial-vertical-scale"],"initializeWithOffset":[4,"initialize-with-offset"],"parentSelector":[1,"parent-selector"],"verticalSiblingSelector":[1,"vertical-sibling-selector"],"horizontalSiblingSelector":[1,"horizontal-sibling-selector"],"contentSelector":[1,"content-selector"],"position":[1],"dimensionsComputed":[1540,"dimensions-computed"],"width":[32],"minWidth":[32],"maxWidth":[32],"height":[32],"minHeight":[32],"maxHeight":[32],"left":[32],"top":[32],"hoveredLocation":[32],"dragStartLocation":[32],"updateDimensions":[64]}]]],["vertex-spinner.cjs",[[1,"vertex-spinner",{"color":[1],"size":[1]}]]],["vertex-expandable.cjs",[[1,"vertex-expandable",{"expanded":[1540],"expanding":[1540],"collapsing":[1540],"controlled":[516],"expandType":[513,"expand-type"],"animated":[4],"contentScrollHeight":[32]}]]],["vertex-result-list.cjs",[[1,"vertex-result-list",{"items":[16],"itemsJson":[1,"items"],"viewportStartIndex":[1026,"viewport-start-index"],"viewportEndIndex":[1026,"viewport-end-index"],"resultHeight":[1026,"result-height"],"overScanCount":[2,"over-scan-count"],"placement":[1],"position":[1],"open":[4],"listHeight":[32],"parsedResults":[32],"scrollTop":[32],"lastStartIndex":[32],"lastFocusedIndex":[32],"stateMap":[32]}]]],["vertex-textfield.cjs",[[6,"vertex-textfield",{"type":[1],"name":[1],"variant":[1],"fontSize":[1,"font-size"],"multiline":[4],"minRows":[2,"min-rows"],"maxRows":[2,"max-rows"],"placeholder":[1],"autoFocus":[4,"auto-focus"],"autoComplete":[1,"auto-complete"],"autoCorrect":[1,"auto-correct"],"value":[1032],"disabled":[516],"hasError":[4,"has-error"],"updateInput":[64],"blurInput":[64],"getInputValue":[64],"selectAll":[64]}]]],["vertex-tooltip.cjs",[[1,"vertex-tooltip",{"content":[1],"disabled":[4],"placement":[1],"delay":[2],"animated":[4],"open":[32]}]]],["vertex-color-circle.cjs",[[1,"vertex-color-circle",{"color":[513],"supplementalColor":[513,"supplemental-color"],"theme":[513],"lightenPercentage":[2,"lighten-percentage"],"darkenPercentage":[2,"darken-percentage"],"lightened":[1537],"darkened":[1537]}]]],["vertex-auto-resize-textarea.cjs",[[1,"vertex-auto-resize-textarea",{"textareaSelector":[1,"textarea-selector"],"initialValue":[1,"initial-value"],"minRows":[514,"min-rows"],"maxRows":[514,"max-rows"],"textValue":[32]}]]],["vertex-menu.cjs",[[1,"vertex-menu",{"animated":[4],"open":[1540],"placement":[1],"fallbackPlacements":[16],"backdrop":[4],"position":[1040],"popoverProps":[16]}]]],["vertex-icon-button.cjs",[[1,"vertex-icon-button",{"iconName":[1,"icon-name"],"disabled":[516],"variant":[1],"iconColor":[1,"icon-color"],"iconSize":[1,"icon-size"]}]]],["vertex-icon.cjs",[[1,"vertex-icon",{"name":[1],"size":[1]}]]],["vertex-popover.cjs",[[1,"vertex-popover",{"open":[1540],"placement":[1],"position":[1025],"anchorBounds":[16],"backdrop":[4],"animated":[4],"anchorSelector":[1,"anchor-selector"],"boundarySelector":[1,"boundary-selector"],"resizeBehavior":[1,"resize-behavior"],"overflowBehavior":[16],"flipBehavior":[16],"offsetBehavior":[2,"offset-behavior"],"updateOnResize":[4,"update-on-resize"],"resizeObserverFactory":[16],"opened":[32],"computedPlacement":[32]}]]]], options);
|
|
91
|
+
return index.bootstrapLazy([["vertex-click-to-edit-textfield.cjs",[[6,"vertex-click-to-edit-textfield",{"placeholder":[1],"fontSize":[1,"font-size"],"disabled":[516],"multiline":[4],"minRows":[2,"min-rows"],"maxRows":[2,"max-rows"],"value":[1032],"autoFocus":[4,"auto-focus"],"editing":[1540],"hasError":[4,"has-error"]}]]],["vertex-collapsible.cjs",[[1,"vertex-collapsible",{"label":[1],"open":[1540]}]]],["vertex-context-menu.cjs",[[1,"vertex-context-menu",{"targetSelector":[1,"target-selector"],"animated":[4],"position":[32],"open":[32]}]]],["vertex-dialog.cjs",[[1,"vertex-dialog",{"open":[1540],"fullscreen":[4],"resizable":[4],"width":[32],"height":[32],"minWidth":[32],"minHeight":[32],"maxWidth":[32],"maxHeight":[32],"isResizing":[32]},[[4,"keydown","keyDownListener"]]]]],["vertex-draggable-popover.cjs",[[1,"vertex-draggable-popover",{"position":[1],"boundarySelector":[1,"boundary-selector"],"boundaryPadding":[2,"boundary-padding"],"anchorPosition":[32],"lastPosition":[32],"dragging":[32]}]]],["vertex-dropdown-menu.cjs",[[1,"vertex-dropdown-menu",{"animated":[4],"placement":[1],"open":[32]}]]],["vertex-help-tooltip.cjs",[[1,"vertex-help-tooltip",{"animated":[4],"placement":[1],"open":[32]}]]],["vertex-search-bar.cjs",[[6,"vertex-search-bar",{"variant":[1],"disabled":[4],"triggerCharacter":[1,"trigger-character"],"breakCharacters":[16],"resultItems":[16],"placement":[1],"value":[1],"placeholder":[1],"replacements":[1040],"replacementUriType":[1,"replacement-uri-type"],"cursorPosition":[32],"displayedElements":[32],"hasTriggered":[32]}]]],["vertex-select.cjs",[[1,"vertex-select",{"value":[513],"placeholder":[513],"disabled":[516],"animated":[4],"hideSelected":[4,"hide-selected"],"resizeObserverFactory":[16],"open":[32],"position":[32],"displayValue":[32]}]]],["vertex-slider.cjs",[[1,"vertex-slider",{"min":[2],"max":[2],"valueLabelDisplay":[1,"value-label-display"],"step":[8],"size":[1],"value":[1026],"disabled":[4]}]]],["vertex-toast.cjs",[[1,"vertex-toast",{"content":[1],"placement":[1],"duration":[2],"animated":[4],"open":[4],"type":[1],"isOpen":[32]}]]],["vertex-color-circle-picker.cjs",[[1,"vertex-color-circle-picker",{"colors":[1],"supplementalColors":[1,"supplemental-colors"],"theme":[513],"lightenPercentage":[2,"lighten-percentage"],"darkenPercentage":[2,"darken-percentage"],"selected":[1537],"direction":[1]}]]],["vertex-color-picker.cjs",[[1,"vertex-color-picker",{"value":[1537],"disabled":[4]}]]],["vertex-toggle.cjs",[[1,"vertex-toggle",{"variant":[1],"disabled":[4],"checked":[1540]}]]],["vertex-avatar.cjs",[[1,"vertex-avatar",{"firstName":[1,"first-name"],"lastName":[1,"last-name"],"value":[1],"active":[4],"variant":[1]}]]],["vertex-avatar-group.cjs",[[1,"vertex-avatar-group"]]],["vertex-badge.cjs",[[1,"vertex-badge",{"badgeText":[1,"badge-text"],"badgeColor":[1,"badge-color"]}]]],["vertex-button.cjs",[[1,"vertex-button",{"type":[1],"color":[1],"variant":[1],"size":[1],"expand":[1],"href":[1],"target":[1],"disabled":[516]}]]],["vertex-card.cjs",[[1,"vertex-card",{"mode":[1]}]]],["vertex-card-group.cjs",[[1,"vertex-card-group",{"selected":[516],"hovered":[516],"expanded":[516]}]]],["vertex-chip.cjs",[[1,"vertex-chip",{"variant":[1],"color":[1]}]]],["vertex-logo-loading.cjs",[[1,"vertex-logo-loading"]]],["vertex-menu-divider.cjs",[[1,"vertex-menu-divider"]]],["vertex-menu-item.cjs",[[1,"vertex-menu-item",{"disabled":[516]}]]],["vertex-radio.cjs",[[2,"vertex-radio",{"disabled":[516],"value":[513],"label":[513],"name":[513],"checked":[516]}]]],["vertex-radio-group.cjs",[[1,"vertex-radio-group",{"name":[513],"value":[1537]}]]],["vertex-resizable.cjs",[[1,"vertex-resizable",{"horizontalDirection":[1,"horizontal-direction"],"verticalDirection":[1,"vertical-direction"],"initialHorizontalScale":[2,"initial-horizontal-scale"],"initialVerticalScale":[2,"initial-vertical-scale"],"initializeWithOffset":[4,"initialize-with-offset"],"parentSelector":[1,"parent-selector"],"verticalSiblingSelector":[1,"vertical-sibling-selector"],"horizontalSiblingSelector":[1,"horizontal-sibling-selector"],"contentSelector":[1,"content-selector"],"position":[1],"dimensionsComputed":[1540,"dimensions-computed"],"width":[32],"minWidth":[32],"maxWidth":[32],"height":[32],"minHeight":[32],"maxHeight":[32],"left":[32],"top":[32],"hoveredLocation":[32],"dragStartLocation":[32],"updateDimensions":[64]}]]],["vertex-spinner.cjs",[[1,"vertex-spinner",{"color":[1],"size":[1]}]]],["vertex-tab.cjs",[[1,"vertex-tab",{"label":[1],"active":[4]}]]],["vertex-tabs.cjs",[[1,"vertex-tabs",{"active":[1025],"labels":[32],"activeBounds":[32],"activeButtonEl":[32]}]]],["vertex-expandable.cjs",[[1,"vertex-expandable",{"expanded":[1540],"expanding":[1540],"collapsing":[1540],"controlled":[516],"expandType":[513,"expand-type"],"animated":[4],"contentScrollHeight":[32]}]]],["vertex-result-list.cjs",[[1,"vertex-result-list",{"items":[16],"itemsJson":[1,"items"],"viewportStartIndex":[1026,"viewport-start-index"],"viewportEndIndex":[1026,"viewport-end-index"],"resultHeight":[1026,"result-height"],"overScanCount":[2,"over-scan-count"],"placement":[1],"position":[1],"open":[4],"listHeight":[32],"parsedResults":[32],"scrollTop":[32],"lastStartIndex":[32],"lastFocusedIndex":[32],"stateMap":[32]}]]],["vertex-textfield.cjs",[[6,"vertex-textfield",{"type":[1],"name":[1],"variant":[1],"fontSize":[1,"font-size"],"multiline":[4],"minRows":[2,"min-rows"],"maxRows":[2,"max-rows"],"placeholder":[1],"autoFocus":[4,"auto-focus"],"autoComplete":[1,"auto-complete"],"autoCorrect":[1,"auto-correct"],"value":[1032],"disabled":[516],"hasError":[4,"has-error"],"updateInput":[64],"blurInput":[64],"getInputValue":[64],"selectAll":[64]}]]],["vertex-tooltip.cjs",[[1,"vertex-tooltip",{"content":[1],"disabled":[4],"placement":[1],"delay":[2],"animated":[4],"open":[32]}]]],["vertex-color-circle.cjs",[[1,"vertex-color-circle",{"color":[513],"supplementalColor":[513,"supplemental-color"],"theme":[513],"lightenPercentage":[2,"lighten-percentage"],"darkenPercentage":[2,"darken-percentage"],"lightened":[1537],"darkened":[1537]}]]],["vertex-auto-resize-textarea.cjs",[[1,"vertex-auto-resize-textarea",{"textareaSelector":[1,"textarea-selector"],"initialValue":[1,"initial-value"],"minRows":[514,"min-rows"],"maxRows":[514,"max-rows"],"textValue":[32]}]]],["vertex-menu.cjs",[[1,"vertex-menu",{"animated":[4],"open":[1540],"placement":[1],"fallbackPlacements":[16],"backdrop":[4],"position":[1040],"popoverProps":[16]}]]],["vertex-icon-button.cjs",[[1,"vertex-icon-button",{"iconName":[1,"icon-name"],"disabled":[516],"variant":[1],"iconColor":[1,"icon-color"],"iconSize":[1,"icon-size"]}]]],["vertex-icon.cjs",[[1,"vertex-icon",{"name":[1],"size":[1]}]]],["vertex-popover.cjs",[[1,"vertex-popover",{"open":[1540],"placement":[1],"position":[1025],"anchorBounds":[16],"backdrop":[4],"animated":[4],"anchorSelector":[1,"anchor-selector"],"boundarySelector":[1,"boundary-selector"],"resizeBehavior":[1,"resize-behavior"],"overflowBehavior":[16],"flipBehavior":[16],"offsetBehavior":[2,"offset-behavior"],"updateOnResize":[4,"update-on-resize"],"resizeObserverFactory":[16],"opened":[32],"computedPlacement":[32]}]]]], options);
|
|
92
92
|
});
|
|
93
93
|
|
|
94
94
|
exports.setNonce = index.setNonce;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
const index = require('./index-6a92256c.js');
|
|
4
|
+
|
|
5
|
+
function readDOM(callback) {
|
|
6
|
+
index.readTask(callback);
|
|
7
|
+
}
|
|
8
|
+
function getBoundingClientRect(el) {
|
|
9
|
+
return el.getBoundingClientRect();
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
exports.getBoundingClientRect = getBoundingClientRect;
|
|
13
|
+
exports.readDOM = readDOM;
|
package/dist/cjs/index.cjs.js
CHANGED
|
@@ -36,16 +36,19 @@ const searchBar = require('./search-bar-91cbcd07.js');
|
|
|
36
36
|
const select = require('./select-5f8aecfe.js');
|
|
37
37
|
const slider = require('./slider-13594e49.js');
|
|
38
38
|
const spinner = require('./spinner-bb990a42.js');
|
|
39
|
+
const tab = require('./tab-4335cd8f.js');
|
|
40
|
+
const tabs = require('./tabs-ece62a01.js');
|
|
39
41
|
const textField = require('./text-field-bccbde1f.js');
|
|
40
42
|
const toast = require('./toast-bee7f47b.js');
|
|
41
43
|
const toggle = require('./toggle-a5dde469.js');
|
|
42
|
-
const tooltip = require('./tooltip-
|
|
44
|
+
const tooltip = require('./tooltip-9ac797a0.js');
|
|
43
45
|
require('./index-6a92256c.js');
|
|
44
46
|
require('./slots-fb5ac359.js');
|
|
45
47
|
require('./index-e1b40fa6.js');
|
|
46
48
|
require('./icon-helper-c24d6e6b.js');
|
|
47
49
|
require('./templates-e7b3ffbb.js');
|
|
48
50
|
require('./tslib.es6-838fd860.js');
|
|
51
|
+
require('./dom-b6c5fbf4.js');
|
|
49
52
|
|
|
50
53
|
|
|
51
54
|
|
|
@@ -83,6 +86,8 @@ exports.SearchBar = searchBar.SearchBar;
|
|
|
83
86
|
exports.Select = select.Select;
|
|
84
87
|
exports.Slider = slider.Slider;
|
|
85
88
|
exports.Spinner = spinner.Spinner;
|
|
89
|
+
exports.Tab = tab.Tab;
|
|
90
|
+
exports.Tabs = tabs.Tabs;
|
|
86
91
|
exports.TextField = textField.TextField;
|
|
87
92
|
exports.Toast = toast.Toast;
|
|
88
93
|
exports.Toggle = toggle.Toggle;
|
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([["vertex-click-to-edit-textfield.cjs",[[6,"vertex-click-to-edit-textfield",{"placeholder":[1],"fontSize":[1,"font-size"],"disabled":[516],"multiline":[4],"minRows":[2,"min-rows"],"maxRows":[2,"max-rows"],"value":[1032],"autoFocus":[4,"auto-focus"],"editing":[1540],"hasError":[4,"has-error"]}]]],["vertex-collapsible.cjs",[[1,"vertex-collapsible",{"label":[1],"open":[1540]}]]],["vertex-context-menu.cjs",[[1,"vertex-context-menu",{"targetSelector":[1,"target-selector"],"animated":[4],"position":[32],"open":[32]}]]],["vertex-dialog.cjs",[[1,"vertex-dialog",{"open":[1540],"fullscreen":[4],"resizable":[4],"width":[32],"height":[32],"minWidth":[32],"minHeight":[32],"maxWidth":[32],"maxHeight":[32],"isResizing":[32]},[[4,"keydown","keyDownListener"]]]]],["vertex-draggable-popover.cjs",[[1,"vertex-draggable-popover",{"position":[1],"boundarySelector":[1,"boundary-selector"],"boundaryPadding":[2,"boundary-padding"],"anchorPosition":[32],"lastPosition":[32],"dragging":[32]}]]],["vertex-dropdown-menu.cjs",[[1,"vertex-dropdown-menu",{"animated":[4],"placement":[1],"open":[32]}]]],["vertex-help-tooltip.cjs",[[1,"vertex-help-tooltip",{"animated":[4],"placement":[1],"open":[32]}]]],["vertex-search-bar.cjs",[[6,"vertex-search-bar",{"variant":[1],"disabled":[4],"triggerCharacter":[1,"trigger-character"],"breakCharacters":[16],"resultItems":[16],"placement":[1],"value":[1],"placeholder":[1],"replacements":[1040],"replacementUriType":[1,"replacement-uri-type"],"cursorPosition":[32],"displayedElements":[32],"hasTriggered":[32]}]]],["vertex-select.cjs",[[1,"vertex-select",{"value":[513],"placeholder":[513],"disabled":[516],"animated":[4],"hideSelected":[4,"hide-selected"],"resizeObserverFactory":[16],"open":[32],"position":[32],"displayValue":[32]}]]],["vertex-slider.cjs",[[1,"vertex-slider",{"min":[2],"max":[2],"valueLabelDisplay":[1,"value-label-display"],"step":[8],"size":[1],"value":[1026],"disabled":[4]}]]],["vertex-toast.cjs",[[1,"vertex-toast",{"content":[1],"placement":[1],"duration":[2],"animated":[4],"open":[4],"type":[1],"isOpen":[32]}]]],["vertex-color-circle-picker.cjs",[[1,"vertex-color-circle-picker",{"colors":[1],"supplementalColors":[1,"supplemental-colors"],"theme":[513],"lightenPercentage":[2,"lighten-percentage"],"darkenPercentage":[2,"darken-percentage"],"selected":[1537],"direction":[1]}]]],["vertex-color-picker.cjs",[[1,"vertex-color-picker",{"value":[1537],"disabled":[4]}]]],["vertex-toggle.cjs",[[1,"vertex-toggle",{"variant":[1],"disabled":[4],"checked":[1540]}]]],["vertex-avatar.cjs",[[1,"vertex-avatar",{"firstName":[1,"first-name"],"lastName":[1,"last-name"],"value":[1],"active":[4],"variant":[1]}]]],["vertex-avatar-group.cjs",[[1,"vertex-avatar-group"]]],["vertex-badge.cjs",[[1,"vertex-badge",{"badgeText":[1,"badge-text"],"badgeColor":[1,"badge-color"]}]]],["vertex-button.cjs",[[1,"vertex-button",{"type":[1],"color":[1],"variant":[1],"size":[1],"expand":[1],"href":[1],"target":[1],"disabled":[516]}]]],["vertex-card.cjs",[[1,"vertex-card",{"mode":[1]}]]],["vertex-card-group.cjs",[[1,"vertex-card-group",{"selected":[516],"hovered":[516],"expanded":[516]}]]],["vertex-chip.cjs",[[1,"vertex-chip",{"variant":[1],"color":[1]}]]],["vertex-logo-loading.cjs",[[1,"vertex-logo-loading"]]],["vertex-menu-divider.cjs",[[1,"vertex-menu-divider"]]],["vertex-menu-item.cjs",[[1,"vertex-menu-item",{"disabled":[516]}]]],["vertex-radio.cjs",[[2,"vertex-radio",{"disabled":[516],"value":[513],"label":[513],"name":[513],"checked":[516]}]]],["vertex-radio-group.cjs",[[1,"vertex-radio-group",{"name":[513],"value":[1537]}]]],["vertex-resizable.cjs",[[1,"vertex-resizable",{"horizontalDirection":[1,"horizontal-direction"],"verticalDirection":[1,"vertical-direction"],"initialHorizontalScale":[2,"initial-horizontal-scale"],"initialVerticalScale":[2,"initial-vertical-scale"],"initializeWithOffset":[4,"initialize-with-offset"],"parentSelector":[1,"parent-selector"],"verticalSiblingSelector":[1,"vertical-sibling-selector"],"horizontalSiblingSelector":[1,"horizontal-sibling-selector"],"contentSelector":[1,"content-selector"],"position":[1],"dimensionsComputed":[1540,"dimensions-computed"],"width":[32],"minWidth":[32],"maxWidth":[32],"height":[32],"minHeight":[32],"maxHeight":[32],"left":[32],"top":[32],"hoveredLocation":[32],"dragStartLocation":[32],"updateDimensions":[64]}]]],["vertex-spinner.cjs",[[1,"vertex-spinner",{"color":[1],"size":[1]}]]],["vertex-expandable.cjs",[[1,"vertex-expandable",{"expanded":[1540],"expanding":[1540],"collapsing":[1540],"controlled":[516],"expandType":[513,"expand-type"],"animated":[4],"contentScrollHeight":[32]}]]],["vertex-result-list.cjs",[[1,"vertex-result-list",{"items":[16],"itemsJson":[1,"items"],"viewportStartIndex":[1026,"viewport-start-index"],"viewportEndIndex":[1026,"viewport-end-index"],"resultHeight":[1026,"result-height"],"overScanCount":[2,"over-scan-count"],"placement":[1],"position":[1],"open":[4],"listHeight":[32],"parsedResults":[32],"scrollTop":[32],"lastStartIndex":[32],"lastFocusedIndex":[32],"stateMap":[32]}]]],["vertex-textfield.cjs",[[6,"vertex-textfield",{"type":[1],"name":[1],"variant":[1],"fontSize":[1,"font-size"],"multiline":[4],"minRows":[2,"min-rows"],"maxRows":[2,"max-rows"],"placeholder":[1],"autoFocus":[4,"auto-focus"],"autoComplete":[1,"auto-complete"],"autoCorrect":[1,"auto-correct"],"value":[1032],"disabled":[516],"hasError":[4,"has-error"],"updateInput":[64],"blurInput":[64],"getInputValue":[64],"selectAll":[64]}]]],["vertex-tooltip.cjs",[[1,"vertex-tooltip",{"content":[1],"disabled":[4],"placement":[1],"delay":[2],"animated":[4],"open":[32]}]]],["vertex-color-circle.cjs",[[1,"vertex-color-circle",{"color":[513],"supplementalColor":[513,"supplemental-color"],"theme":[513],"lightenPercentage":[2,"lighten-percentage"],"darkenPercentage":[2,"darken-percentage"],"lightened":[1537],"darkened":[1537]}]]],["vertex-auto-resize-textarea.cjs",[[1,"vertex-auto-resize-textarea",{"textareaSelector":[1,"textarea-selector"],"initialValue":[1,"initial-value"],"minRows":[514,"min-rows"],"maxRows":[514,"max-rows"],"textValue":[32]}]]],["vertex-menu.cjs",[[1,"vertex-menu",{"animated":[4],"open":[1540],"placement":[1],"fallbackPlacements":[16],"backdrop":[4],"position":[1040],"popoverProps":[16]}]]],["vertex-icon-button.cjs",[[1,"vertex-icon-button",{"iconName":[1,"icon-name"],"disabled":[516],"variant":[1],"iconColor":[1,"icon-color"],"iconSize":[1,"icon-size"]}]]],["vertex-icon.cjs",[[1,"vertex-icon",{"name":[1],"size":[1]}]]],["vertex-popover.cjs",[[1,"vertex-popover",{"open":[1540],"placement":[1],"position":[1025],"anchorBounds":[16],"backdrop":[4],"animated":[4],"anchorSelector":[1,"anchor-selector"],"boundarySelector":[1,"boundary-selector"],"resizeBehavior":[1,"resize-behavior"],"overflowBehavior":[16],"flipBehavior":[16],"offsetBehavior":[2,"offset-behavior"],"updateOnResize":[4,"update-on-resize"],"resizeObserverFactory":[16],"opened":[32],"computedPlacement":[32]}]]]], options);
|
|
17
|
+
return index.bootstrapLazy([["vertex-click-to-edit-textfield.cjs",[[6,"vertex-click-to-edit-textfield",{"placeholder":[1],"fontSize":[1,"font-size"],"disabled":[516],"multiline":[4],"minRows":[2,"min-rows"],"maxRows":[2,"max-rows"],"value":[1032],"autoFocus":[4,"auto-focus"],"editing":[1540],"hasError":[4,"has-error"]}]]],["vertex-collapsible.cjs",[[1,"vertex-collapsible",{"label":[1],"open":[1540]}]]],["vertex-context-menu.cjs",[[1,"vertex-context-menu",{"targetSelector":[1,"target-selector"],"animated":[4],"position":[32],"open":[32]}]]],["vertex-dialog.cjs",[[1,"vertex-dialog",{"open":[1540],"fullscreen":[4],"resizable":[4],"width":[32],"height":[32],"minWidth":[32],"minHeight":[32],"maxWidth":[32],"maxHeight":[32],"isResizing":[32]},[[4,"keydown","keyDownListener"]]]]],["vertex-draggable-popover.cjs",[[1,"vertex-draggable-popover",{"position":[1],"boundarySelector":[1,"boundary-selector"],"boundaryPadding":[2,"boundary-padding"],"anchorPosition":[32],"lastPosition":[32],"dragging":[32]}]]],["vertex-dropdown-menu.cjs",[[1,"vertex-dropdown-menu",{"animated":[4],"placement":[1],"open":[32]}]]],["vertex-help-tooltip.cjs",[[1,"vertex-help-tooltip",{"animated":[4],"placement":[1],"open":[32]}]]],["vertex-search-bar.cjs",[[6,"vertex-search-bar",{"variant":[1],"disabled":[4],"triggerCharacter":[1,"trigger-character"],"breakCharacters":[16],"resultItems":[16],"placement":[1],"value":[1],"placeholder":[1],"replacements":[1040],"replacementUriType":[1,"replacement-uri-type"],"cursorPosition":[32],"displayedElements":[32],"hasTriggered":[32]}]]],["vertex-select.cjs",[[1,"vertex-select",{"value":[513],"placeholder":[513],"disabled":[516],"animated":[4],"hideSelected":[4,"hide-selected"],"resizeObserverFactory":[16],"open":[32],"position":[32],"displayValue":[32]}]]],["vertex-slider.cjs",[[1,"vertex-slider",{"min":[2],"max":[2],"valueLabelDisplay":[1,"value-label-display"],"step":[8],"size":[1],"value":[1026],"disabled":[4]}]]],["vertex-toast.cjs",[[1,"vertex-toast",{"content":[1],"placement":[1],"duration":[2],"animated":[4],"open":[4],"type":[1],"isOpen":[32]}]]],["vertex-color-circle-picker.cjs",[[1,"vertex-color-circle-picker",{"colors":[1],"supplementalColors":[1,"supplemental-colors"],"theme":[513],"lightenPercentage":[2,"lighten-percentage"],"darkenPercentage":[2,"darken-percentage"],"selected":[1537],"direction":[1]}]]],["vertex-color-picker.cjs",[[1,"vertex-color-picker",{"value":[1537],"disabled":[4]}]]],["vertex-toggle.cjs",[[1,"vertex-toggle",{"variant":[1],"disabled":[4],"checked":[1540]}]]],["vertex-avatar.cjs",[[1,"vertex-avatar",{"firstName":[1,"first-name"],"lastName":[1,"last-name"],"value":[1],"active":[4],"variant":[1]}]]],["vertex-avatar-group.cjs",[[1,"vertex-avatar-group"]]],["vertex-badge.cjs",[[1,"vertex-badge",{"badgeText":[1,"badge-text"],"badgeColor":[1,"badge-color"]}]]],["vertex-button.cjs",[[1,"vertex-button",{"type":[1],"color":[1],"variant":[1],"size":[1],"expand":[1],"href":[1],"target":[1],"disabled":[516]}]]],["vertex-card.cjs",[[1,"vertex-card",{"mode":[1]}]]],["vertex-card-group.cjs",[[1,"vertex-card-group",{"selected":[516],"hovered":[516],"expanded":[516]}]]],["vertex-chip.cjs",[[1,"vertex-chip",{"variant":[1],"color":[1]}]]],["vertex-logo-loading.cjs",[[1,"vertex-logo-loading"]]],["vertex-menu-divider.cjs",[[1,"vertex-menu-divider"]]],["vertex-menu-item.cjs",[[1,"vertex-menu-item",{"disabled":[516]}]]],["vertex-radio.cjs",[[2,"vertex-radio",{"disabled":[516],"value":[513],"label":[513],"name":[513],"checked":[516]}]]],["vertex-radio-group.cjs",[[1,"vertex-radio-group",{"name":[513],"value":[1537]}]]],["vertex-resizable.cjs",[[1,"vertex-resizable",{"horizontalDirection":[1,"horizontal-direction"],"verticalDirection":[1,"vertical-direction"],"initialHorizontalScale":[2,"initial-horizontal-scale"],"initialVerticalScale":[2,"initial-vertical-scale"],"initializeWithOffset":[4,"initialize-with-offset"],"parentSelector":[1,"parent-selector"],"verticalSiblingSelector":[1,"vertical-sibling-selector"],"horizontalSiblingSelector":[1,"horizontal-sibling-selector"],"contentSelector":[1,"content-selector"],"position":[1],"dimensionsComputed":[1540,"dimensions-computed"],"width":[32],"minWidth":[32],"maxWidth":[32],"height":[32],"minHeight":[32],"maxHeight":[32],"left":[32],"top":[32],"hoveredLocation":[32],"dragStartLocation":[32],"updateDimensions":[64]}]]],["vertex-spinner.cjs",[[1,"vertex-spinner",{"color":[1],"size":[1]}]]],["vertex-tab.cjs",[[1,"vertex-tab",{"label":[1],"active":[4]}]]],["vertex-tabs.cjs",[[1,"vertex-tabs",{"active":[1025],"labels":[32],"activeBounds":[32],"activeButtonEl":[32]}]]],["vertex-expandable.cjs",[[1,"vertex-expandable",{"expanded":[1540],"expanding":[1540],"collapsing":[1540],"controlled":[516],"expandType":[513,"expand-type"],"animated":[4],"contentScrollHeight":[32]}]]],["vertex-result-list.cjs",[[1,"vertex-result-list",{"items":[16],"itemsJson":[1,"items"],"viewportStartIndex":[1026,"viewport-start-index"],"viewportEndIndex":[1026,"viewport-end-index"],"resultHeight":[1026,"result-height"],"overScanCount":[2,"over-scan-count"],"placement":[1],"position":[1],"open":[4],"listHeight":[32],"parsedResults":[32],"scrollTop":[32],"lastStartIndex":[32],"lastFocusedIndex":[32],"stateMap":[32]}]]],["vertex-textfield.cjs",[[6,"vertex-textfield",{"type":[1],"name":[1],"variant":[1],"fontSize":[1,"font-size"],"multiline":[4],"minRows":[2,"min-rows"],"maxRows":[2,"max-rows"],"placeholder":[1],"autoFocus":[4,"auto-focus"],"autoComplete":[1,"auto-complete"],"autoCorrect":[1,"auto-correct"],"value":[1032],"disabled":[516],"hasError":[4,"has-error"],"updateInput":[64],"blurInput":[64],"getInputValue":[64],"selectAll":[64]}]]],["vertex-tooltip.cjs",[[1,"vertex-tooltip",{"content":[1],"disabled":[4],"placement":[1],"delay":[2],"animated":[4],"open":[32]}]]],["vertex-color-circle.cjs",[[1,"vertex-color-circle",{"color":[513],"supplementalColor":[513,"supplemental-color"],"theme":[513],"lightenPercentage":[2,"lighten-percentage"],"darkenPercentage":[2,"darken-percentage"],"lightened":[1537],"darkened":[1537]}]]],["vertex-auto-resize-textarea.cjs",[[1,"vertex-auto-resize-textarea",{"textareaSelector":[1,"textarea-selector"],"initialValue":[1,"initial-value"],"minRows":[514,"min-rows"],"maxRows":[514,"max-rows"],"textValue":[32]}]]],["vertex-menu.cjs",[[1,"vertex-menu",{"animated":[4],"open":[1540],"placement":[1],"fallbackPlacements":[16],"backdrop":[4],"position":[1040],"popoverProps":[16]}]]],["vertex-icon-button.cjs",[[1,"vertex-icon-button",{"iconName":[1,"icon-name"],"disabled":[516],"variant":[1],"iconColor":[1,"icon-color"],"iconSize":[1,"icon-size"]}]]],["vertex-icon.cjs",[[1,"vertex-icon",{"name":[1],"size":[1]}]]],["vertex-popover.cjs",[[1,"vertex-popover",{"open":[1540],"placement":[1],"position":[1025],"anchorBounds":[16],"backdrop":[4],"animated":[4],"anchorSelector":[1,"anchor-selector"],"boundarySelector":[1,"boundary-selector"],"resizeBehavior":[1,"resize-behavior"],"overflowBehavior":[16],"flipBehavior":[16],"offsetBehavior":[2,"offset-behavior"],"updateOnResize":[4,"update-on-resize"],"resizeObserverFactory":[16],"opened":[32],"computedPlacement":[32]}]]]], options);
|
|
18
18
|
});
|
|
19
19
|
};
|
|
20
20
|
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
const index = require('./index-6a92256c.js');
|
|
4
|
+
const index$1 = require('./index-e1b40fa6.js');
|
|
5
|
+
|
|
6
|
+
const tabCss = ":host{position:relative;width:100%;height:100%}.content{display:none;height:0px}.content.active{display:flex;width:100%;height:100%}";
|
|
7
|
+
|
|
8
|
+
const Tab = class {
|
|
9
|
+
constructor(hostRef) {
|
|
10
|
+
index.registerInstance(this, hostRef);
|
|
11
|
+
this.tabClick = index.createEvent(this, "tabClick", 7);
|
|
12
|
+
this.handleClick = () => {
|
|
13
|
+
this.tabClick.emit(this.label);
|
|
14
|
+
};
|
|
15
|
+
this.label = undefined;
|
|
16
|
+
this.active = false;
|
|
17
|
+
}
|
|
18
|
+
render() {
|
|
19
|
+
return (index.h(index.Host, null, index.h("div", { class: index$1.classnames('content', {
|
|
20
|
+
active: this.active,
|
|
21
|
+
}) }, index.h("slot", null))));
|
|
22
|
+
}
|
|
23
|
+
};
|
|
24
|
+
Tab.style = tabCss;
|
|
25
|
+
|
|
26
|
+
exports.Tab = Tab;
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
const index = require('./index-6a92256c.js');
|
|
4
|
+
const index$1 = require('./index-e1b40fa6.js');
|
|
5
|
+
const dom = require('./dom-b6c5fbf4.js');
|
|
6
|
+
|
|
7
|
+
function isTabElement(element) {
|
|
8
|
+
return element.tagName === 'VERTEX-TAB';
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
const tabsCss = "button{border:none;background-color:transparent;font-family:var(--vertex-ui-font-family);font-size:0.875rem;padding:0}:host{display:flex;position:relative;width:100%;height:100%}.wrapper{display:flex;flex-direction:column;position:relative;height:100%;width:100%}.labels{display:flex;position:relative;border-bottom:solid 1px var(--vertex-ui-neutral-300)}.indicator{position:absolute;bottom:0;height:3px;background-color:var(--vertex-ui-blue-700);transition:left 0.2s ease-in-out}.label{position:relative;cursor:pointer;color:var(--vertex-ui-neutral-700);white-space:nowrap;font-family:var(--vertex-ui-font-family);font-size:var(--vertex-ui-text-md);padding:0.75rem 1.25rem}.label:not(.active):hover{color:var(--vertex-ui-neutral-800)}.label.active{color:var(--vertex-ui-blue-700);font-weight:var(--vertex-ui-font-weight-bold)}.hidden-label-text{font-weight:bold;visibility:hidden;height:0px}.tab-content{display:flex;height:5%;flex-grow:1}";
|
|
12
|
+
|
|
13
|
+
const Tabs = class {
|
|
14
|
+
constructor(hostRef) {
|
|
15
|
+
index.registerInstance(this, hostRef);
|
|
16
|
+
this.selectedTabChanged = index.createEvent(this, "selectedTabChanged", 7);
|
|
17
|
+
this.indicatorInitialized = false;
|
|
18
|
+
this.handleLabelClick = (label) => {
|
|
19
|
+
if (this.active != null) {
|
|
20
|
+
this.updateActiveOnTab(this.active, false);
|
|
21
|
+
}
|
|
22
|
+
this.active = label;
|
|
23
|
+
this.updateActiveOnTab(this.active, true);
|
|
24
|
+
this.selectedTabChanged.emit(label);
|
|
25
|
+
};
|
|
26
|
+
this.updateActiveOnTab = (label, active) => {
|
|
27
|
+
const activeTab = this.findTabByLabel(label);
|
|
28
|
+
if (activeTab != null) {
|
|
29
|
+
activeTab.active = active;
|
|
30
|
+
}
|
|
31
|
+
};
|
|
32
|
+
this.findTabByLabel = (label) => {
|
|
33
|
+
var _a;
|
|
34
|
+
const slotEl = ((_a = this.hostEl.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('slot:not([name])')) || undefined;
|
|
35
|
+
const slotAssignedElements = slotEl === null || slotEl === void 0 ? void 0 : slotEl.assignedElements();
|
|
36
|
+
const slotChildren = slotAssignedElements != null && slotAssignedElements.length > 0
|
|
37
|
+
? Array.from(slotAssignedElements[0].children)
|
|
38
|
+
: undefined;
|
|
39
|
+
return slotChildren != null
|
|
40
|
+
? slotChildren.filter(isTabElement).find((el) => el.label === label)
|
|
41
|
+
: undefined;
|
|
42
|
+
};
|
|
43
|
+
this.updateTabLabels = () => {
|
|
44
|
+
var _a;
|
|
45
|
+
const slotEl = ((_a = this.hostEl.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('slot:not([name])')) || undefined;
|
|
46
|
+
const slotAssignedElements = slotEl === null || slotEl === void 0 ? void 0 : slotEl.assignedElements();
|
|
47
|
+
const slotChildren = slotAssignedElements != null && slotAssignedElements.length > 0
|
|
48
|
+
? Array.from(slotAssignedElements[0].children)
|
|
49
|
+
: undefined;
|
|
50
|
+
this.labels =
|
|
51
|
+
slotChildren != null
|
|
52
|
+
? slotChildren.filter(isTabElement).map((t) => t.label)
|
|
53
|
+
: [];
|
|
54
|
+
};
|
|
55
|
+
this.active = undefined;
|
|
56
|
+
this.labels = [];
|
|
57
|
+
this.activeBounds = undefined;
|
|
58
|
+
this.activeButtonEl = undefined;
|
|
59
|
+
}
|
|
60
|
+
componentWillLoad() {
|
|
61
|
+
this.updateTabLabels();
|
|
62
|
+
}
|
|
63
|
+
componentDidLoad() {
|
|
64
|
+
if (this.active != null) {
|
|
65
|
+
this.updateActiveOnTab(this.active, true);
|
|
66
|
+
}
|
|
67
|
+
this.indicatorInitialized = false;
|
|
68
|
+
this.handleActiveButtonChange();
|
|
69
|
+
}
|
|
70
|
+
componentDidUpdate() {
|
|
71
|
+
// Place the indicator if it hasn't been initialized yet
|
|
72
|
+
if (!this.indicatorInitialized) {
|
|
73
|
+
this.handleActiveButtonChange();
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
handleActiveButtonChange() {
|
|
77
|
+
const button = this.activeButtonEl;
|
|
78
|
+
if (button != null) {
|
|
79
|
+
dom.readDOM(() => {
|
|
80
|
+
const hostElBounds = dom.getBoundingClientRect(this.hostEl);
|
|
81
|
+
const activeBounds = dom.getBoundingClientRect(button);
|
|
82
|
+
this.activeBounds = {
|
|
83
|
+
x: activeBounds.x - hostElBounds.x,
|
|
84
|
+
width: activeBounds.width,
|
|
85
|
+
};
|
|
86
|
+
if (this.activeBounds.width !== 0) {
|
|
87
|
+
this.indicatorInitialized = true;
|
|
88
|
+
}
|
|
89
|
+
});
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
render() {
|
|
93
|
+
return (index.h(index.Host, null, index.h("div", { class: "wrapper" }, index.h("div", { class: "labels" }, this.labels.map((label) => (index.h("button", { class: index$1.classnames('label', {
|
|
94
|
+
active: this.active === label,
|
|
95
|
+
}), "data-label": label, ref: (el) => {
|
|
96
|
+
if (this.active === label) {
|
|
97
|
+
this.activeButtonEl = el;
|
|
98
|
+
}
|
|
99
|
+
}, onClick: () => this.handleLabelClick(label) }, label, index.h("div", { class: "hidden-label-text" }, label)))), index.h("slot", { name: "label-header" }), this.activeBounds && (index.h("div", { class: "indicator", style: {
|
|
100
|
+
left: `${this.activeBounds.x}px`,
|
|
101
|
+
width: `${this.activeBounds.width}px`,
|
|
102
|
+
} }))), index.h("div", { class: "tab-content" }, index.h("slot", { onSlotchange: this.updateTabLabels })))));
|
|
103
|
+
}
|
|
104
|
+
get hostEl() { return index.getElement(this); }
|
|
105
|
+
static get watchers() { return {
|
|
106
|
+
"activeButtonEl": ["handleActiveButtonChange"]
|
|
107
|
+
}; }
|
|
108
|
+
};
|
|
109
|
+
Tabs.style = tabsCss;
|
|
110
|
+
|
|
111
|
+
exports.Tabs = Tabs;
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
const index = require('./index-6a92256c.js');
|
|
4
4
|
const tslib_es6 = require('./tslib.es6-838fd860.js');
|
|
5
5
|
const index$1 = require('./index-e1b40fa6.js');
|
|
6
|
+
const dom = require('./dom-b6c5fbf4.js');
|
|
6
7
|
const slots = require('./slots-fb5ac359.js');
|
|
7
8
|
|
|
8
9
|
/**
|
|
@@ -2052,10 +2053,6 @@ var uuid = /*#__PURE__*/Object.freeze({
|
|
|
2052
2053
|
toMsbLsb: toMsbLsb
|
|
2053
2054
|
});
|
|
2054
2055
|
|
|
2055
|
-
function getBoundingClientRect(el) {
|
|
2056
|
-
return el.getBoundingClientRect();
|
|
2057
|
-
}
|
|
2058
|
-
|
|
2059
2056
|
const tooltipCss = ":host{--tooltip-width:auto;--tooltip-white-space:normal;display:flex}.popover{width:100%;height:100%}.target{display:flex;width:100%;height:100%}.content-hidden{display:none}.tooltip{display:flex;justify-content:center;text-align:center;width:var(--tooltip-width);font-family:var(--vertex-ui-font-family);font-size:var(--vertex-ui-text-xxs);background-color:var(--vertex-ui-neutral-700);color:var(--vertex-ui-white);padding:0.25rem 0.5rem;border-radius:4px;pointer-events:none;white-space:var(--tooltip-white-space);user-select:none}.tooltip.hidden{display:none}";
|
|
2060
2057
|
|
|
2061
2058
|
const TOOLTIP_OPEN_DELAY = 500;
|
|
@@ -2125,7 +2122,7 @@ const Tooltip = class {
|
|
|
2125
2122
|
popover.backdrop = false;
|
|
2126
2123
|
popover.placement = this.placement;
|
|
2127
2124
|
popover.animated = this.animated;
|
|
2128
|
-
popover.anchorBounds = getBoundingClientRect(anchorElement);
|
|
2125
|
+
popover.anchorBounds = dom.getBoundingClientRect(anchorElement);
|
|
2129
2126
|
return popover;
|
|
2130
2127
|
}
|
|
2131
2128
|
createContentElement() {
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const tabs = require('./tabs-ece62a01.js');
|
|
6
|
+
require('./index-6a92256c.js');
|
|
7
|
+
require('./index-e1b40fa6.js');
|
|
8
|
+
require('./dom-b6c5fbf4.js');
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
exports.vertex_tabs = tabs.Tabs;
|
|
@@ -2,10 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const tooltip = require('./tooltip-
|
|
5
|
+
const tooltip = require('./tooltip-9ac797a0.js');
|
|
6
6
|
require('./index-6a92256c.js');
|
|
7
7
|
require('./tslib.es6-838fd860.js');
|
|
8
8
|
require('./index-e1b40fa6.js');
|
|
9
|
+
require('./dom-b6c5fbf4.js');
|
|
9
10
|
require('./slots-fb5ac359.js');
|
|
10
11
|
|
|
11
12
|
|
|
@@ -32,6 +32,8 @@ export * from './search-bar/search-bar';
|
|
|
32
32
|
export * from './select/select';
|
|
33
33
|
export * from './slider/slider';
|
|
34
34
|
export * from './spinner/spinner';
|
|
35
|
+
export * from './tab/tab';
|
|
36
|
+
export * from './tabs/tabs';
|
|
35
37
|
export * from './text-field/text-field';
|
|
36
38
|
export * from './toast/toast';
|
|
37
39
|
export * from './toggle/toggle';
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import { h, Host } from '@stencil/core';
|
|
2
|
+
import classNames from 'classnames';
|
|
3
|
+
export class Tab {
|
|
4
|
+
constructor() {
|
|
5
|
+
this.handleClick = () => {
|
|
6
|
+
this.tabClick.emit(this.label);
|
|
7
|
+
};
|
|
8
|
+
this.label = undefined;
|
|
9
|
+
this.active = false;
|
|
10
|
+
}
|
|
11
|
+
render() {
|
|
12
|
+
return (h(Host, null, h("div", { class: classNames('content', {
|
|
13
|
+
active: this.active,
|
|
14
|
+
}) }, h("slot", null))));
|
|
15
|
+
}
|
|
16
|
+
static get is() { return "vertex-tab"; }
|
|
17
|
+
static get encapsulation() { return "shadow"; }
|
|
18
|
+
static get originalStyleUrls() {
|
|
19
|
+
return {
|
|
20
|
+
"$": ["tab.css"]
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
static get styleUrls() {
|
|
24
|
+
return {
|
|
25
|
+
"$": ["tab.css"]
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
static get properties() {
|
|
29
|
+
return {
|
|
30
|
+
"label": {
|
|
31
|
+
"type": "string",
|
|
32
|
+
"mutable": false,
|
|
33
|
+
"complexType": {
|
|
34
|
+
"original": "string",
|
|
35
|
+
"resolved": "string",
|
|
36
|
+
"references": {}
|
|
37
|
+
},
|
|
38
|
+
"required": true,
|
|
39
|
+
"optional": false,
|
|
40
|
+
"docs": {
|
|
41
|
+
"tags": [],
|
|
42
|
+
"text": "The label to include in tab list."
|
|
43
|
+
},
|
|
44
|
+
"attribute": "label",
|
|
45
|
+
"reflect": false
|
|
46
|
+
},
|
|
47
|
+
"active": {
|
|
48
|
+
"type": "boolean",
|
|
49
|
+
"mutable": false,
|
|
50
|
+
"complexType": {
|
|
51
|
+
"original": "boolean",
|
|
52
|
+
"resolved": "boolean",
|
|
53
|
+
"references": {}
|
|
54
|
+
},
|
|
55
|
+
"required": false,
|
|
56
|
+
"optional": false,
|
|
57
|
+
"docs": {
|
|
58
|
+
"tags": [],
|
|
59
|
+
"text": ""
|
|
60
|
+
},
|
|
61
|
+
"attribute": "active",
|
|
62
|
+
"reflect": false,
|
|
63
|
+
"defaultValue": "false"
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
}
|
|
67
|
+
static get events() {
|
|
68
|
+
return [{
|
|
69
|
+
"method": "tabClick",
|
|
70
|
+
"name": "tabClick",
|
|
71
|
+
"bubbles": true,
|
|
72
|
+
"cancelable": true,
|
|
73
|
+
"composed": true,
|
|
74
|
+
"docs": {
|
|
75
|
+
"tags": [],
|
|
76
|
+
"text": ""
|
|
77
|
+
},
|
|
78
|
+
"complexType": {
|
|
79
|
+
"original": "string",
|
|
80
|
+
"resolved": "string",
|
|
81
|
+
"references": {}
|
|
82
|
+
}
|
|
83
|
+
}];
|
|
84
|
+
}
|
|
85
|
+
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
button {
|
|
2
|
+
border: none;
|
|
3
|
+
background-color: transparent;
|
|
4
|
+
font-family: var(--vertex-ui-font-family);
|
|
5
|
+
font-size: 0.875rem;
|
|
6
|
+
padding: 0;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
:host {
|
|
10
|
+
display: flex;
|
|
11
|
+
position: relative;
|
|
12
|
+
width: 100%;
|
|
13
|
+
height: 100%;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.wrapper {
|
|
17
|
+
display: flex;
|
|
18
|
+
flex-direction: column;
|
|
19
|
+
position: relative;
|
|
20
|
+
height: 100%;
|
|
21
|
+
width: 100%;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.labels {
|
|
25
|
+
display: flex;
|
|
26
|
+
position: relative;
|
|
27
|
+
border-bottom: solid 1px var(--vertex-ui-neutral-300);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.indicator {
|
|
31
|
+
position: absolute;
|
|
32
|
+
bottom: 0;
|
|
33
|
+
height: 3px;
|
|
34
|
+
background-color: var(--vertex-ui-blue-700);
|
|
35
|
+
transition: left 0.2s ease-in-out;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.label {
|
|
39
|
+
position: relative;
|
|
40
|
+
cursor: pointer;
|
|
41
|
+
color: var(--vertex-ui-neutral-700);
|
|
42
|
+
white-space: nowrap;
|
|
43
|
+
font-family: var(--vertex-ui-font-family);
|
|
44
|
+
font-size: var(--vertex-ui-text-md);
|
|
45
|
+
padding: 0.75rem 1.25rem;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.label:not(.active):hover {
|
|
49
|
+
color: var(--vertex-ui-neutral-800);
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.label.active {
|
|
53
|
+
color: var(--vertex-ui-blue-700);
|
|
54
|
+
font-weight: var(--vertex-ui-font-weight-bold);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.hidden-label-text {
|
|
58
|
+
font-weight: bold;
|
|
59
|
+
visibility: hidden;
|
|
60
|
+
height: 0px;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.tab-content {
|
|
64
|
+
display: flex;
|
|
65
|
+
height: 5%;
|
|
66
|
+
flex-grow: 1;
|
|
67
|
+
}
|