@watermarkinsights/ripple 5.19.1 → 5.20.0-alpha.1
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/{app-globals-11721855.js → app-globals-e741af80.js} +1 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/ripple.cjs.js +2 -2
- package/dist/cjs/wm-tab-item_3.cjs.entry.js +188 -61
- package/dist/cjs/wm-tag-input.cjs.entry.js +2 -2
- package/dist/cjs/wm-textarea.cjs.entry.js +1 -1
- package/dist/cjs/wm-timepicker.cjs.entry.js +2 -2
- package/dist/cjs/wm-toggletip.cjs.entry.js +4 -4
- package/dist/cjs/wm-uploader.cjs.entry.js +2 -2
- package/dist/collection/components/wm-tabs/wm-tab-item/wm-tab-item.css +27 -19
- package/dist/collection/components/wm-tabs/wm-tab-item/wm-tab-item.js +24 -22
- package/dist/collection/components/wm-tabs/wm-tab-list/wm-tab-list.css +43 -9
- package/dist/collection/components/wm-tabs/wm-tab-list/wm-tab-list.js +187 -72
- package/dist/collection/components/wm-tabs/wm-tab-panel/wm-tab-panel.js +1 -1
- package/dist/collection/components/wm-tag-input/wm-tag-input.js +2 -2
- package/dist/collection/components/wm-textarea/wm-textarea.js +1 -1
- package/dist/collection/components/wm-timepicker/wm-timepicker.js +2 -2
- package/dist/collection/components/wm-toggletip/wm-toggletip.js +4 -4
- package/dist/collection/components/wm-uploader/wm-uploader.js +2 -2
- package/dist/esm/{app-globals-6634ff38.js → app-globals-8edefb94.js} +1 -1
- package/dist/esm/loader.js +2 -2
- package/dist/esm/ripple.js +2 -2
- package/dist/esm/wm-tab-item_3.entry.js +190 -63
- package/dist/esm/wm-tag-input.entry.js +2 -2
- package/dist/esm/wm-textarea.entry.js +1 -1
- package/dist/esm/wm-timepicker.entry.js +2 -2
- package/dist/esm/wm-toggletip.entry.js +4 -4
- package/dist/esm/wm-uploader.entry.js +2 -2
- package/dist/esm-es5/app-globals-8edefb94.js +1 -0
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/ripple.js +1 -1
- package/dist/esm-es5/wm-tab-item_3.entry.js +1 -1
- package/dist/esm-es5/wm-tag-input.entry.js +1 -1
- package/dist/esm-es5/wm-textarea.entry.js +1 -1
- package/dist/esm-es5/wm-timepicker.entry.js +1 -1
- package/dist/esm-es5/wm-toggletip.entry.js +1 -1
- package/dist/esm-es5/wm-uploader.entry.js +1 -1
- package/dist/ripple/{p-dfdcdae0.system.entry.js → p-23c44c11.system.entry.js} +1 -1
- package/dist/ripple/{p-c1d6740e.entry.js → p-24e17026.entry.js} +1 -1
- package/dist/ripple/{p-0c20a096.system.entry.js → p-335a45e6.system.entry.js} +1 -1
- package/dist/ripple/{p-96a7c1b9.system.entry.js → p-4d5de385.system.entry.js} +1 -1
- package/dist/ripple/p-74786c48.system.entry.js +1 -0
- package/dist/ripple/p-7b185f34.system.js +1 -0
- package/dist/ripple/{p-8c73dadf.system.entry.js → p-8f4b4e29.system.entry.js} +1 -1
- package/dist/ripple/{p-7d708fab.entry.js → p-9499fa62.entry.js} +1 -1
- package/dist/ripple/p-b6eef7d1.entry.js +1 -0
- package/dist/ripple/p-b9db60d3.js +1 -0
- package/dist/ripple/{p-4b0b66e0.system.entry.js → p-ba6d438c.system.entry.js} +1 -1
- package/dist/ripple/{p-d784f4b4.entry.js → p-c34346d5.entry.js} +1 -1
- package/dist/ripple/p-c650cd07.system.js +1 -0
- package/dist/ripple/p-ca11a1be.entry.js +1 -0
- package/dist/ripple/{p-328b9560.entry.js → p-e2239af2.entry.js} +1 -1
- package/dist/ripple/ripple.esm.js +1 -1
- package/dist/ripple/ripple.js +1 -1
- package/dist/types/components/wm-tabs/wm-tab-item/wm-tab-item.d.ts +3 -1
- package/dist/types/components/wm-tabs/wm-tab-list/wm-tab-list.d.ts +14 -19
- package/dist/types/components.d.ts +2 -21
- package/package.json +2 -2
- package/dist/esm-es5/app-globals-6634ff38.js +0 -1
- package/dist/ripple/p-01aec0e1.system.js +0 -1
- package/dist/ripple/p-1eb2ec31.system.entry.js +0 -1
- package/dist/ripple/p-42949f98.system.js +0 -1
- package/dist/ripple/p-4886fc88.entry.js +0 -1
- package/dist/ripple/p-ab6b6158.js +0 -1
- package/dist/ripple/p-ec9f782e.entry.js +0 -1
|
@@ -937,10 +937,10 @@ const TagInput = class {
|
|
|
937
937
|
}
|
|
938
938
|
}
|
|
939
939
|
render() {
|
|
940
|
-
return (index.h("div", { key: '
|
|
940
|
+
return (index.h("div", { key: 'f619bb843bdd10d0b951e9da5da4de945d3fe396', class: `wrapper label-${this.labelPosition} ${this.errorMessage ? "invalid" : ""}` }, index.h("div", { key: 'eecfce0ecabff49e128c044e323f8250e48c7946', class: "label-wrapper" }, index.h("label", { key: '080f21a334fb82a6488fb7ba799aa97d0cbe7c55', class: "label", htmlFor: "input", onMouseEnter: (ev) => this.handleLabelMouseEnter(ev), onMouseLeave: () => functions.hideTooltip() }, this.label), this.requiredField && (index.h("div", { key: 'd1ee9ee1ce70d2a4bfdd23b6ae509b03acd992aa', class: "required", "aria-hidden": "true" }, "*"))), index.h("div", { key: '0e432095a2f0a434460026b83a21cc23bdb7b9a5', class: `field-wrapper ${this.el.shadowRoot.activeElement === this.inputEl ? "focused" : ""} ${this.errorMessage ? "invalid" : ""}`, ref: (el) => (this.fieldWrapperEl = el) }, index.h("div", { key: '28607d2bb8883ff21375f6b576bfc2565a5f4a6e', class: "upper-row" }, index.h("div", { key: '1280356e15ebc52c968ad2e1729e9ab1cff6d728', class: "svg-icon svg-search" }), index.h("div", { key: 'c803a0d4aa130018d92edb9fc0fdebeef14c7b12', class: `tags-and-input-wrapper` }, index.h("ul", { key: 'bf23f84d10a03c5ba5db56b609d8d0aacd698a0a', ref: (el) => (this.tagAreaEl = el), class: `tag-area ${this.taggedOptions.length === 0 && "empty"} ${this.isKeying ? "user-is-keying" : ""}`, role: "listbox", "aria-activedescendant": this.focusedTag ? this.focusedTag.id : null, "aria-orientation": "horizontal", "aria-label": `${this.label} ${this.tagAreaInstructions}`, tabindex: this._tagEls.length > 0 ? 0 : -1, "aria-describedby": `info max-tags`, onFocus: (ev) => this.handleTagAreaFocus(ev), onBlur: (ev) => {
|
|
941
941
|
this.focusedTagIndex = undefined;
|
|
942
942
|
this.handleBlur(ev);
|
|
943
|
-
}, onKeyDown: (ev) => this.handleTagAreaKeyDown(ev) }, this.renderTags()), this.isDropdown && this.renderDropdownInput(), this.isTable && this.renderTableInput()), this.isDropdown && (index.h("div", { key: '
|
|
943
|
+
}, onKeyDown: (ev) => this.handleTagAreaKeyDown(ev) }, this.renderTags()), this.isDropdown && this.renderDropdownInput(), this.isTable && this.renderTableInput()), this.isDropdown && (index.h("div", { key: '9b96f3d46ad73a96abaa0b0cd66d10e38a3dd173', class: "character-count" }, this.charCount, "/", this.characterLimit))), this.renderTagCounter(), this.isDropdown && this.renderDropdown()), this.info && (index.h("div", { key: '0db7af5bd7706d639ac6699a115b5ba45c3a744e', id: "info", class: "info-text" }, this.info)), index.h("div", { key: 'ca7e60ed4237a43016507d753042a98d8eb0b56f', id: "error" }, this.errorMessage), index.h("div", { key: 'bd892fb1aab39e18f31d9dc5fcf7296bac8866ef', class: "sr-only", "aria-live": "polite", ref: (el) => (this.liveRegionEl = el), "aria-atomic": "true" }, this.liveRegionMessage), this.isTable && this.renderTable()));
|
|
944
944
|
}
|
|
945
945
|
static get delegatesFocus() { return true; }
|
|
946
946
|
get el() { return index.getElement(this); }
|
|
@@ -81,7 +81,7 @@ const Textarea = class {
|
|
|
81
81
|
this.announcement = message;
|
|
82
82
|
}
|
|
83
83
|
render() {
|
|
84
|
-
return (index.h("div", { key: '
|
|
84
|
+
return (index.h("div", { key: '53bf016c0ab72f8726008c4233527f364c635f41', class: `wrapper label-${this.labelPosition} ${this.errorMessage ? "invalid" : ""}` }, index.h("div", { key: '691995e62aae4051a54125247947358f2677a5e2', class: "label-wrapper" }, index.h("label", { key: 'fab8e9b942bd1affaeea4f180c3b4c9e27b1ddd9', htmlFor: "inputfield", class: "label", onMouseEnter: (ev) => this.handleLabelMouseEnter(ev), onMouseLeave: () => functions.hideTooltip() }, this.label, this.characterLimit && (index.h("span", { key: '0d35cd920126b13a614faffd20276c9a4bc59acd', class: "sr-only" }, " ", intl.globalMessages.getCharacterLimit(this.characterLimit)))), this.requiredField && (index.h("span", { key: '0e33d69604dc3db5993cbcf2e2ec6f2800067cfb', class: "required", "aria-hidden": "true" }, "*"))), index.h("div", { key: 'a18c90a4c7f9712b9cf6b6405ad111fa3611b660', class: "inner-wrapper" }, index.h("div", { key: '20cf3663c3f6493942d0200affc106ca07f28bd8', class: `inputfield-wrapper ${this.errorMessage ? "invalid" : ""}`, style: this.inputWidth ? { width: this.inputWidth } : {} }, index.h("textarea", { key: '43275a292a56669c4e92d323489f90b8daa13f8d', id: "inputfield", disabled: this.isDisabled, "aria-describedby": "info error", onInput: (ev) => this.handleInput(ev), onBlur: () => this.handleBlur(), placeholder: this.placeholder, autocomplete: "off", "aria-required": this.requiredField ? "true" : null, value: this.value, rows: 3, style: { height: this.inputHeight } }), this.characterLimit && typeof this.characterLimit === "number" ? (index.h("div", { class: `character-count ${this.value.length > this.characterLimit ? "exceeded" : ""}` }, this.charCount, "/", this.characterLimit)) : ("")), this.info && (index.h("div", { key: '2f5e7884dc10b4d324beac35e3f94809aafc1b14', id: "info", class: "info" }, this.info)), index.h("div", { key: '5e21a007c7b9c6603b92b35931518f45f6838666', id: "error", class: "error-message" }, this.errorMessage), index.h("div", { key: '8977e8b27c76b086aeac3ad8b325d65e3a0c61fd', id: "live-polite", class: "sr-only", "aria-live": "polite", "aria-atomic": "true", ref: (el) => (this.liveRegionEl = el) }, this.announcement))));
|
|
85
85
|
}
|
|
86
86
|
get el() { return index.getElement(this); }
|
|
87
87
|
static get watchers() { return {
|
|
@@ -292,13 +292,13 @@ const Timepicker = class {
|
|
|
292
292
|
return this.times.map((time, index$1) => (index.h("li", { id: `option${index$1 + 1}`, "data-time": time, role: "option", onClick: () => this.handleOptionClick(time) }, this.reformatTimeInternal("12", time))));
|
|
293
293
|
}
|
|
294
294
|
render() {
|
|
295
|
-
return (index.h(index.Host, { key: '
|
|
295
|
+
return (index.h(index.Host, { key: '1bc0e3c55453f573f958f434f08d6c0928ca315c', onBlur: () => this.close(false) }, index.h("div", { key: '56b51917022bb7ca450007c624d93bd6de4dd16c', class: `wrapper label-${this.labelPosition} ${!!this.errorMessage ? "invalid" : ""}`, ref: (t) => (this.tpWrapper = t) }, index.h("div", { key: 'fac1dae254a4a9a3c03a2edb6dbbccc810cf77d3', class: "label-wrapper" }, this.labelPosition !== "none" && (index.h("label", { key: '48519de32da0a22f89e1c260061c21dddd4152b7', id: "label", class: "label", htmlFor: "time-input", onMouseEnter: (ev) => this.handleLabelMouseEnter(ev), onMouseLeave: () => functions.hideTooltip() }, this.label)), this.labelPosition !== "none" && this.requiredField && (index.h("div", { key: '0233b207923d7197b278a57aacfbe8791d1af0ea', "aria-hidden": "true", class: "required" }, "*"))), index.h("div", { key: 'dd4d6ad315f27742ce8993c9f5345be4f9744bfa' }, index.h("div", { key: '75b5a580fc22d5665321c9b7452d1e5c4423fe59', class: "inner-wrapper" }, index.h("input", { key: '3779ff4140aa2814becebd5ca7592517ac4bd52e', id: "time-input", "aria-label": this.label, "aria-describedby": "error", ref: (el) => (this.inputEl = el), onBlur: () => this.handleInputBlur(), onInput: () => (this.value = this.inputEl.value), disabled: this.isDisabled, "aria-required": this.requiredField ? "true" : null, placeholder: this.timeFormat, autocomplete: "off", value: this.value, onFocus: () => this.tpWrapper.classList.add("focus") }), index.h("button", { key: '160a3d7a30e79788320035d2bb0c7c49500ee3af', id: "btn", ref: (el) => (this.buttonEl = el), disabled: this.isDisabled, "aria-controls": "list", "aria-expanded": this.isExpanded ? "true" : "false", "aria-label": this.buttonAriaLabel, "aria-describedby": "time-input", onClick: () => (this.isExpanded ? this.close() : this.open()),
|
|
296
296
|
// This addresses an issue in Safari, where clicking buttons does not focus them
|
|
297
297
|
// if the button does not receive focus when clicked, Timepicker incorrectly emits a blur event
|
|
298
298
|
onMouseDown: (ev) => {
|
|
299
299
|
ev.preventDefault();
|
|
300
300
|
this.buttonEl.focus();
|
|
301
|
-
} }, index.h("span", { key: '
|
|
301
|
+
} }, index.h("span", { key: '15601dcb4eaf6a2481983c9bea235f322c1ceaa2', class: "svg-icon svg-time" })), index.h("ul", { key: '92cee000b94cd36a160ca75afc9cdb6ec4ecf7ea', class: `options ${this.isExpanded ? "open" : ""} ${this.openUp ? "upwards" : ""}`, id: "list", role: "listbox", "aria-labelledby": "label", "aria-describedby": this.isExpanded ? "collapsed" : null, tabindex: -1, ref: (el) => (this.optionsEl = el) }, this.renderOptions())), index.h("div", { key: '74d38c280568661ed4caaee63a804d9c535f7ce4', id: "error", class: "error" }, this.errorMessage)), index.h("div", { key: '65b86599f1b7afb766bb8f3367b8f5039202220d', id: "live-polite", class: "sr-only", "aria-live": "polite", "aria-atomic": "true", ref: (el) => (this.liveRegionEl = el) }))));
|
|
302
302
|
}
|
|
303
303
|
static get delegatesFocus() { return true; }
|
|
304
304
|
get el() { return index.getElement(this); }
|
|
@@ -37,7 +37,7 @@ const Toggletip = class {
|
|
|
37
37
|
this.isHidden = true;
|
|
38
38
|
}
|
|
39
39
|
get isOpen() {
|
|
40
|
-
return this.toggletipEl.matches(":popover-open");
|
|
40
|
+
return this.toggletipEl && this.toggletipEl.matches(":popover-open");
|
|
41
41
|
}
|
|
42
42
|
get tooltipMessage() {
|
|
43
43
|
switch (this.toggletipType) {
|
|
@@ -238,11 +238,11 @@ const Toggletip = class {
|
|
|
238
238
|
}
|
|
239
239
|
}
|
|
240
240
|
render() {
|
|
241
|
-
return (index.h(index.Host, { key: '
|
|
241
|
+
return (index.h(index.Host, { key: 'e67e9c6a38b5e0514a5e23e67e52462e0a418f5f', class: `size-${this.targetSize}` }, index.h("button", { key: '38c604092c47bb70b8cd751c81a19550bf971c38', ref: (el) => (this.buttonEl = el), class: "button", type: "button", "aria-label": this.label, popoverTarget: "toggletip", popoverTargetAction: "toggle", onClick: () => this.open(),
|
|
242
242
|
// In order to position the tooltip identically to the toggletip, its presence is determined by these four events
|
|
243
|
-
onMouseEnter: () => !this.isOpen && functions.showTooltip(this.toggletipPosition, this.el, this.tooltipMessage), onMouseLeave: () => functions.hideTooltip(), onFocus: () => !this.isOpen && functions.showTooltip(this.toggletipPosition, this.el, this.tooltipMessage), onBlur: () => this.handleBlur() }, this.renderIcon()), index.h("div", { key: '
|
|
243
|
+
onMouseEnter: () => !this.isOpen && functions.showTooltip(this.toggletipPosition, this.el, this.tooltipMessage), onMouseLeave: () => functions.hideTooltip(), onFocus: () => !this.isOpen && functions.showTooltip(this.toggletipPosition, this.el, this.tooltipMessage), onBlur: () => this.handleBlur() }, this.renderIcon()), index.h("div", { key: '9e0e76a3309eacad13cf2ed9374f9e51edf0d7ac', popover: "", ref: (el) => (this.toggletipEl = el), class: `toggletip ${this.targetSize} ${this.isHidden ? "hidden" : ""}`, id: "toggletip",
|
|
244
244
|
// @ts-ignore - despite what Typescript says, this is a valid event for popover elements
|
|
245
|
-
onToggle: (ev) => this.handlePopoverToggle(ev) }, this.tooltip), index.h("div", { key: '
|
|
245
|
+
onToggle: (ev) => this.handlePopoverToggle(ev) }, this.tooltip), index.h("div", { key: '11e378047dcef3677934b6303997fabb97d6177b', ref: (el) => (this.liveRegionEl = el), class: "live-region sr-only", role: "status", "aria-live": "polite", "aria-atomic": "true" })));
|
|
246
246
|
}
|
|
247
247
|
static get delegatesFocus() { return true; }
|
|
248
248
|
get el() { return index.getElement(this); }
|
|
@@ -323,9 +323,9 @@ const Uploader = class {
|
|
|
323
323
|
return (index.h("div", { class: `drop-area -${this.dropArea}`, ref: (el) => (this.dropAreaEl = el), onDragEnter: (ev) => this.handleDragEnter(ev), onDragOver: (ev) => this.handleDragOver(ev), onDragLeave: (ev) => this.handleDragLeave(ev), onDrop: (ev) => this.handleDrop(ev) }, this.dropArea == "page" && (index.h("div", { ref: (el) => (this.dropOverlayEl = el), class: "drop-overlay", popover: "manual" }, index.h("span", { class: "upload-arrow" }), index.h("span", null, "Drop to Upload")))));
|
|
324
324
|
}
|
|
325
325
|
render() {
|
|
326
|
-
return (index.h(index.Host, { key: '
|
|
326
|
+
return (index.h(index.Host, { key: 'a738eaf93c6eec61166b6fc124bd140d0ac3d1de', class: `-${this.dropArea}` }, this.uploaderType == "drop" && this.renderDropArea(), this.label && this.renderLabel(), this.renderHeader(), this.renderListContainer(), index.h("div", { key: '4fc10439e41bcdce383905fb180b719fd8a48344', ref: (el) => (this.assertiveLiveRegionEl = el), class: "live-region sr-only", "aria-live": "assertive" // since it's directly linked to the action the user took, it should be read in priority. With polite, some messages get dismissed in favor of the page title
|
|
327
327
|
,
|
|
328
|
-
"aria-atomic": "true" }), index.h("div", { key: '
|
|
328
|
+
"aria-atomic": "true" }), index.h("div", { key: '2d1de4f0798576c5955f1c182b741215428ada2c', ref: (el) => (this.politeLiveRegionEl = el), class: "live-region sr-only", "aria-live": "polite", "aria-atomic": "true" })));
|
|
329
329
|
}
|
|
330
330
|
static get delegatesFocus() { return true; }
|
|
331
331
|
get el() { return index.getElement(this); }
|
|
@@ -868,15 +868,23 @@
|
|
|
868
868
|
display: flex;
|
|
869
869
|
font-family: inherit;
|
|
870
870
|
align-self: stretch;
|
|
871
|
-
|
|
872
|
-
:
|
|
873
|
-
display: none;
|
|
871
|
+
max-width: 80%;
|
|
872
|
+
flex: 0 0 auto;
|
|
874
873
|
}
|
|
875
874
|
|
|
876
875
|
.tab-item {
|
|
876
|
+
padding-block: 0.75rem;
|
|
877
877
|
display: flex;
|
|
878
878
|
align-self: stretch;
|
|
879
879
|
list-style-type: none;
|
|
880
|
+
width: 100%;
|
|
881
|
+
}
|
|
882
|
+
.tab-item:hover {
|
|
883
|
+
background-color: var(--wmcolor-interactive-background-hover);
|
|
884
|
+
color: var(--wmcolor-interactive-hover);
|
|
885
|
+
}
|
|
886
|
+
.tab-item:hover.dark {
|
|
887
|
+
background-color: var(--wmcolor-interactive-background-hover-ondark);
|
|
880
888
|
}
|
|
881
889
|
.tab-item .tab {
|
|
882
890
|
-webkit-border-radius: 0;
|
|
@@ -885,37 +893,37 @@
|
|
|
885
893
|
border-radius: 0;
|
|
886
894
|
color: var(--wmcolor-tab-text);
|
|
887
895
|
text-decoration: none;
|
|
888
|
-
letter-spacing: 0.7px;
|
|
889
896
|
font-size: 0.875rem;
|
|
890
|
-
font-weight:
|
|
897
|
+
font-weight: 600;
|
|
891
898
|
opacity: 1;
|
|
892
899
|
position: relative;
|
|
893
|
-
text-transform: uppercase;
|
|
894
900
|
display: flex;
|
|
895
901
|
align-items: center;
|
|
896
902
|
padding-inline: 1.5rem;
|
|
903
|
+
white-space: normal;
|
|
904
|
+
word-break: break-word;
|
|
905
|
+
width: 100%;
|
|
897
906
|
}
|
|
898
907
|
.tab-item .tab[aria-selected=true] {
|
|
899
908
|
font-weight: 700;
|
|
900
|
-
opacity: 1;
|
|
901
|
-
text-decoration: underline;
|
|
902
|
-
text-decoration-thickness: 3px;
|
|
903
|
-
text-underline-offset: 16px;
|
|
904
|
-
}
|
|
905
|
-
.tab-item .tab[aria-selected=true].dark {
|
|
906
|
-
color: var(--wmcolor-tab-text-ondark);
|
|
907
909
|
}
|
|
908
|
-
.tab-item .tab, .tab-item .tab:
|
|
910
|
+
.tab-item .tab:hover, .tab-item .tab:active, .tab-item .tab:focus {
|
|
909
911
|
outline: none;
|
|
910
912
|
}
|
|
911
|
-
.tab-item .tab
|
|
912
|
-
outline: none;
|
|
913
|
-
}
|
|
914
|
-
.tab-item .tab.dark:not([aria-selected=true]) {
|
|
913
|
+
.tab-item.dark .tab {
|
|
915
914
|
opacity: 0.8;
|
|
916
915
|
color: var(--wmcolor-tab-text-ondark);
|
|
917
916
|
}
|
|
918
|
-
.tab-item .tab
|
|
917
|
+
.tab-item.dark .tab[aria-selected=true] {
|
|
918
|
+
opacity: 1;
|
|
919
|
+
}
|
|
920
|
+
.tab-item:has(.tab[aria-selected=true]) {
|
|
921
|
+
box-shadow: inset 0 -4px 0 0 var(--wmcolor-interactive);
|
|
922
|
+
}
|
|
923
|
+
.tab-item:has(.tab[aria-selected=true]).dark {
|
|
924
|
+
box-shadow: inset 0 -4px 0 0 var(--wmcolor-interactive-ondark);
|
|
925
|
+
}
|
|
926
|
+
.tab-item:has(:focus-visible) {
|
|
919
927
|
outline: 3px solid var(--wmcolor-interactive-focus);
|
|
920
928
|
outline-offset: -3px;
|
|
921
929
|
}
|
|
@@ -17,7 +17,6 @@ export class TabItem {
|
|
|
17
17
|
}
|
|
18
18
|
};
|
|
19
19
|
this.selected = false;
|
|
20
|
-
this.show = true;
|
|
21
20
|
this.tabId = "";
|
|
22
21
|
}
|
|
23
22
|
get parentTabList() {
|
|
@@ -27,8 +26,7 @@ export class TabItem {
|
|
|
27
26
|
this.tabItemLoaded.emit();
|
|
28
27
|
}
|
|
29
28
|
render() {
|
|
30
|
-
|
|
31
|
-
classes += this.parentTabList && this.parentTabList.customBackground == "dark" ? "dark" : "";
|
|
29
|
+
const isDark = this.parentTabList && this.parentTabList.customBackground == "dark";
|
|
32
30
|
let styles = {};
|
|
33
31
|
const padding = this.parentTabList && this.parentTabList.customPadding;
|
|
34
32
|
if (padding) {
|
|
@@ -40,7 +38,9 @@ export class TabItem {
|
|
|
40
38
|
"background-size": `calc(100% - ${bkgSize}${units}) 3px`,
|
|
41
39
|
};
|
|
42
40
|
}
|
|
43
|
-
return (h(Host, { key: '
|
|
41
|
+
return (h(Host, { key: 'c4233132fdeffae370245ddb4d62e05fc59ac68d', role: "presentation" }, h("li", { key: '43d23f45217e39a9c6e8d6d0f3f5401c1fa7f252', class: `tab-item ${isDark ? "dark" : ""}`, role: "presentation" }, h("a", { key: '4606d7b99a4ebe3e92bc71089458ce4356ef318a', class: `tab`, style: styles, role: "tab", ref: (el) => (this.linkEl = el), onClick: this.tabClicked, id: `tab-link-${this.tabId}`, onKeyDown: (ev) => this.tabPressed(ev), "aria-selected": this.selected ? "true" : "false", tabindex: this.selected ? 0 : -1, onFocus: () => {
|
|
42
|
+
this.wmIntTabFocused.emit({ tabItem: this.el });
|
|
43
|
+
} }, h("slot", { key: '0ec5fa05c84e7b1e6eb51a3f6e6da39568c44a5c' })))));
|
|
44
44
|
}
|
|
45
45
|
static get is() { return "wm-tab-item"; }
|
|
46
46
|
static get encapsulation() { return "shadow"; }
|
|
@@ -75,24 +75,6 @@ export class TabItem {
|
|
|
75
75
|
"reflect": false,
|
|
76
76
|
"defaultValue": "false"
|
|
77
77
|
},
|
|
78
|
-
"show": {
|
|
79
|
-
"type": "boolean",
|
|
80
|
-
"mutable": false,
|
|
81
|
-
"complexType": {
|
|
82
|
-
"original": "boolean",
|
|
83
|
-
"resolved": "boolean",
|
|
84
|
-
"references": {}
|
|
85
|
-
},
|
|
86
|
-
"required": false,
|
|
87
|
-
"optional": false,
|
|
88
|
-
"docs": {
|
|
89
|
-
"tags": [],
|
|
90
|
-
"text": ""
|
|
91
|
-
},
|
|
92
|
-
"attribute": "show",
|
|
93
|
-
"reflect": false,
|
|
94
|
-
"defaultValue": "true"
|
|
95
|
-
},
|
|
96
78
|
"tabId": {
|
|
97
79
|
"type": "string",
|
|
98
80
|
"mutable": false,
|
|
@@ -129,6 +111,26 @@ export class TabItem {
|
|
|
129
111
|
"resolved": "{ tabId: string; }",
|
|
130
112
|
"references": {}
|
|
131
113
|
}
|
|
114
|
+
}, {
|
|
115
|
+
"method": "wmIntTabFocused",
|
|
116
|
+
"name": "wmIntTabFocused",
|
|
117
|
+
"bubbles": true,
|
|
118
|
+
"cancelable": true,
|
|
119
|
+
"composed": true,
|
|
120
|
+
"docs": {
|
|
121
|
+
"tags": [],
|
|
122
|
+
"text": ""
|
|
123
|
+
},
|
|
124
|
+
"complexType": {
|
|
125
|
+
"original": "{ tabItem: HTMLWmTabItemElement }",
|
|
126
|
+
"resolved": "{ tabItem: HTMLWmTabItemElement; }",
|
|
127
|
+
"references": {
|
|
128
|
+
"HTMLWmTabItemElement": {
|
|
129
|
+
"location": "global",
|
|
130
|
+
"id": "global::HTMLWmTabItemElement"
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
}
|
|
132
134
|
}, {
|
|
133
135
|
"method": "keydownOnTabItem",
|
|
134
136
|
"name": "keydownOnTabItem",
|
|
@@ -869,25 +869,59 @@
|
|
|
869
869
|
--wmcolor-tab-background-dark: var(--wmcolor-background-dark);
|
|
870
870
|
--wmcolor-tab-text-ondark: var(--wmcolor-interactive-ondark);
|
|
871
871
|
--wmcolor-tab-text: var(--wmcolor-interactive);
|
|
872
|
-
|
|
873
|
-
white-space: nowrap;
|
|
874
|
-
height: fit-content;
|
|
872
|
+
background: var(--wmcolor-tab-background);
|
|
875
873
|
display: block;
|
|
874
|
+
position: relative;
|
|
875
|
+
width: fit-content;
|
|
876
|
+
max-width: 100%;
|
|
877
|
+
}
|
|
878
|
+
:host .component-wrapper {
|
|
879
|
+
display: flex;
|
|
880
|
+
align-items: center;
|
|
881
|
+
width: 100%;
|
|
882
|
+
border-block-end: 1px solid var(--wmcolor-border);
|
|
883
|
+
}
|
|
884
|
+
:host .component-wrapper:has(.dark) {
|
|
885
|
+
background: var(--wmcolor-tab-background-dark);
|
|
886
|
+
border-block-end: 2px solid var(--wmcolor-tab-background-dark);
|
|
876
887
|
}
|
|
877
888
|
:host .tabcontainer {
|
|
878
|
-
background: var(--wmcolor-tab-background);
|
|
879
889
|
margin: 0;
|
|
880
|
-
width:
|
|
881
|
-
|
|
890
|
+
width: fit-content;
|
|
891
|
+
max-width: 100%;
|
|
892
|
+
min-height: 2.75rem;
|
|
882
893
|
display: flex;
|
|
883
894
|
flex-direction: row;
|
|
884
895
|
align-items: center;
|
|
885
896
|
padding: 0;
|
|
897
|
+
overflow-x: hidden;
|
|
898
|
+
--fade-distance: 0.875rem;
|
|
886
899
|
}
|
|
887
900
|
:host .tabcontainer.dark {
|
|
888
|
-
background: var(--wmcolor-tab-background-dark);
|
|
889
901
|
margin: 0;
|
|
902
|
+
padding-inline-start: 0.125rem;
|
|
903
|
+
}
|
|
904
|
+
:host .tabcontainer.fade-left.fade-right {
|
|
905
|
+
mask-image: linear-gradient(90deg, transparent 0, black var(--fade-distance), black calc(100% - var(--fade-distance)), transparent 100%);
|
|
906
|
+
}
|
|
907
|
+
:host .tabcontainer.fade-left:not(.fade-right) {
|
|
908
|
+
mask-image: linear-gradient(90deg, transparent 0, black var(--fade-distance), black 100%);
|
|
909
|
+
}
|
|
910
|
+
:host .tabcontainer.fade-right:not(.fade-left) {
|
|
911
|
+
mask-image: linear-gradient(90deg, black 0, black calc(100% - var(--fade-distance)), transparent 100%);
|
|
912
|
+
}
|
|
913
|
+
:host wm-button.left-arrow,
|
|
914
|
+
:host wm-button.right-arrow {
|
|
915
|
+
display: none;
|
|
916
|
+
flex-shrink: 0;
|
|
917
|
+
}
|
|
918
|
+
:host wm-button.left-arrow.visible,
|
|
919
|
+
:host wm-button.right-arrow.visible {
|
|
920
|
+
display: block;
|
|
921
|
+
}
|
|
922
|
+
:host wm-button.left-arrow {
|
|
923
|
+
margin-inline-start: 0.5rem;
|
|
890
924
|
}
|
|
891
|
-
:host wm-
|
|
892
|
-
|
|
925
|
+
:host wm-button.right-arrow {
|
|
926
|
+
margin-inline-end: 0.5rem;
|
|
893
927
|
}
|