@vonage/vivid 5.24.0 → 5.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/avatar/index.cjs +10 -10
- package/avatar/index.js +4 -3
- package/breadcrumb-item/index.cjs +9 -5
- package/breadcrumb-item/index.js +11 -6
- package/bundled/affix.cjs +1 -1
- package/bundled/affix.js +1 -1
- package/bundled/definition10.cjs +2 -1
- package/bundled/definition10.js +3 -2
- package/bundled/definition11.cjs +4 -4
- package/bundled/definition11.js +4 -3
- package/bundled/definition12.cjs +1 -1
- package/bundled/definition12.js +1 -0
- package/bundled/definition15.cjs +5 -5
- package/bundled/definition15.js +4 -3
- package/bundled/definition17.cjs +7 -7
- package/bundled/definition17.js +22 -109
- package/bundled/definition18.cjs +3 -3
- package/bundled/definition18.js +9 -31
- package/bundled/definition19.cjs +19 -19
- package/bundled/definition19.js +3 -2
- package/bundled/definition21.cjs +8 -8
- package/bundled/definition21.js +5 -4
- package/bundled/definition22.cjs +2 -2
- package/bundled/definition22.js +2 -2
- package/bundled/definition24.cjs +4 -4
- package/bundled/definition24.js +4 -3
- package/bundled/definition25.cjs +3 -3
- package/bundled/definition25.js +32 -28
- package/bundled/definition3.cjs +5 -5
- package/bundled/definition3.js +10 -40
- package/bundled/definition4.cjs +6 -6
- package/bundled/definition4.js +4 -3
- package/bundled/definition6.cjs +11 -11
- package/bundled/definition6.js +4 -3
- package/bundled/definition9.cjs +12 -6
- package/bundled/definition9.js +66 -43
- package/bundled/extractOptions.cjs +1 -1
- package/bundled/extractOptions.js +2 -2
- package/bundled/icon.cjs +1 -0
- package/bundled/icon.js +34 -0
- package/bundled/listbox.cjs +1 -1
- package/bundled/listbox.js +5 -2
- package/bundled/mixins.cjs +8 -8
- package/bundled/mixins.js +4 -3
- package/bundled/optgroup.cjs +1 -0
- package/bundled/optgroup.js +27 -0
- package/bundled/option.cjs +1 -0
- package/bundled/option.js +93 -0
- package/bundled/vivid-element.cjs +1 -1
- package/bundled/vivid-element.js +1 -1
- package/card/index.cjs +22 -22
- package/card/index.js +4 -3
- package/color-picker/index.cjs +18 -18
- package/color-picker/index.js +4 -3
- package/combobox/index.cjs +7 -7
- package/combobox/index.js +4 -2
- package/custom-elements.json +4159 -3847
- package/data-grid/index.cjs +24 -24
- package/data-grid/index.js +4 -3
- package/dial-pad/index.cjs +21 -21
- package/dial-pad/index.js +4 -3
- package/dialog/index.cjs +14 -14
- package/dialog/index.js +4 -3
- package/empty-state/index.cjs +3 -3
- package/empty-state/index.js +4 -3
- package/file-picker/index.cjs +7 -7
- package/file-picker/index.js +4 -3
- package/icon/definition.cjs +2 -1
- package/icon/definition.js +2 -1
- package/index.cjs +148 -141
- package/index.js +41 -37
- package/lib/accordion-item/accordion-item.d.ts +1 -0
- package/lib/combobox/combobox.d.ts +1 -1
- package/lib/components.d.ts +1 -0
- package/lib/dial-pad/dial-pad.d.ts +0 -1
- package/lib/listbox/definition.d.ts +3 -0
- package/lib/listbox/index.d.ts +1 -0
- package/lib/listbox/listbox.d.ts +1302 -0
- package/lib/listbox/listbox.template.d.ts +3 -0
- package/lib/listbox/variations.browser-spec.d.ts +1 -0
- package/lib/menu/menu.d.ts +0 -1
- package/lib/number-field/number-field.d.ts +0 -1
- package/lib/rich-text-editor/rte/features/base.d.ts +1 -0
- package/lib/rich-text-editor/rte/utils/default-textblock.d.ts +2 -2
- package/lib/tag-name-map.d.ts +2 -1
- package/lib/text-field/text-field.d.ts +1 -0
- package/lib/toggletip/toggletip.d.ts +1 -0
- package/lib/tooltip/tooltip.d.ts +1 -0
- package/listbox/definition.cjs +5 -0
- package/listbox/definition.js +2 -0
- package/listbox/index.cjs +11 -0
- package/listbox/index.js +540 -0
- package/nav/definition.cjs +1 -1
- package/nav/definition.js +1 -1
- package/nav-disclosure/definition.cjs +1 -1
- package/nav-disclosure/definition.js +1 -1
- package/nav-disclosure/index.cjs +4 -4
- package/nav-disclosure/index.js +4 -3
- package/nav-item/definition.cjs +1 -1
- package/nav-item/definition.js +1 -1
- package/note/definition.cjs +1 -1
- package/note/definition.js +1 -1
- package/number-field/definition.cjs +1 -1
- package/number-field/definition.js +1 -1
- package/optgroup/definition.cjs +2 -1
- package/optgroup/definition.js +2 -1
- package/option/definition.cjs +2 -1
- package/option/definition.js +2 -1
- package/package.json +8 -7
- package/pagination/definition.cjs +1 -1
- package/pagination/definition.js +1 -1
- package/platform-switch/definition.cjs +1 -1
- package/platform-switch/definition.js +1 -1
- package/popover/definition.cjs +1 -1
- package/popover/definition.js +1 -1
- package/popover/index.cjs +5 -5
- package/popover/index.js +4 -3
- package/progress/definition.cjs +1 -1
- package/progress/definition.js +1 -1
- package/radio/definition.cjs +1 -1
- package/radio/definition.js +1 -1
- package/radio-group/definition.cjs +1 -1
- package/radio-group/definition.js +1 -1
- package/range-slider/definition.cjs +1 -1
- package/range-slider/definition.js +1 -1
- package/rich-text-editor/definition.cjs +1 -1
- package/rich-text-editor/definition.js +1 -1
- package/rich-text-editor/index.cjs +13 -13
- package/rich-text-editor/index.js +22 -19
- package/rich-text-view/definition.cjs +1 -1
- package/rich-text-view/definition.js +1 -1
- package/searchable-select/definition.cjs +1 -1
- package/searchable-select/definition.js +1 -1
- package/searchable-select/index.cjs +23 -23
- package/searchable-select/index.js +10 -7
- package/select/definition.cjs +1 -1
- package/select/definition.js +1 -1
- package/selectable-box/definition.cjs +1 -1
- package/selectable-box/definition.js +1 -1
- package/shared/listbox/commands.d.ts +17 -0
- package/shared/listbox/move.d.ts +6 -0
- package/shared/listbox/options.d.ts +12 -0
- package/shared/listbox/selection.d.ts +28 -0
- package/shared/listbox/state.d.ts +26 -0
- package/shared/listbox/typeahead.d.ts +8 -0
- package/shared/listbox/with-options-filter.d.ts +440 -0
- package/shared/listbox/with-options.d.ts +862 -0
- package/side-drawer/definition.cjs +1 -1
- package/side-drawer/definition.js +1 -1
- package/simple-color-picker/definition.cjs +1 -1
- package/simple-color-picker/definition.js +1 -1
- package/simple-color-picker/index.cjs +6 -6
- package/simple-color-picker/index.js +4 -3
- package/split-button/definition.cjs +1 -1
- package/split-button/definition.js +1 -1
- package/status/definition.cjs +1 -1
- package/status/definition.js +1 -1
- package/switch/definition.cjs +1 -1
- package/switch/definition.js +1 -1
- package/tab/definition.cjs +1 -1
- package/tab/definition.js +1 -1
- package/tab-panel/definition.cjs +1 -1
- package/tab-panel/definition.js +1 -1
- package/table/definition.cjs +1 -1
- package/table/definition.js +1 -1
- package/table/index.cjs +13 -13
- package/table/index.js +4 -3
- package/tabs/definition.cjs +1 -1
- package/tabs/definition.js +1 -1
- package/tag/definition.cjs +1 -1
- package/tag/definition.js +1 -1
- package/tag/index.cjs +11 -11
- package/tag/index.js +4 -3
- package/tag-group/definition.cjs +1 -1
- package/tag-group/definition.js +1 -1
- package/text-area/definition.cjs +1 -1
- package/text-area/definition.js +1 -1
- package/time-picker/definition.cjs +1 -1
- package/time-picker/definition.js +1 -1
- package/tree-item/definition.cjs +1 -1
- package/tree-item/definition.js +1 -1
- package/tree-view/definition.cjs +1 -1
- package/tree-view/definition.js +1 -1
- package/unbundled/affix.cjs +2 -2
- package/unbundled/affix.js +1 -1
- package/unbundled/base-progress.cjs +1 -1
- package/unbundled/base-progress.js +1 -1
- package/unbundled/button.cjs +2 -2
- package/unbundled/button.js +2 -2
- package/unbundled/definition.cjs +2 -65
- package/unbundled/definition.js +4 -61
- package/unbundled/definition11.cjs +4 -3
- package/unbundled/definition11.js +3 -2
- package/unbundled/definition12.cjs +3 -2
- package/unbundled/definition12.js +3 -2
- package/unbundled/definition14.cjs +2 -1
- package/unbundled/definition14.js +2 -1
- package/unbundled/definition17.cjs +9 -4
- package/unbundled/definition17.js +9 -4
- package/unbundled/definition2.cjs +7 -2
- package/unbundled/definition2.js +8 -3
- package/unbundled/definition21.cjs +2 -1
- package/unbundled/definition21.js +2 -1
- package/unbundled/definition23.cjs +2 -1
- package/unbundled/definition23.js +2 -1
- package/unbundled/definition24.cjs +6 -4
- package/unbundled/definition24.js +6 -4
- package/unbundled/definition25.cjs +2 -1
- package/unbundled/definition25.js +2 -1
- package/unbundled/definition26.cjs +7 -4
- package/unbundled/definition26.js +7 -4
- package/unbundled/definition27.cjs +39 -5
- package/unbundled/definition27.js +40 -6
- package/unbundled/definition28.cjs +4 -3
- package/unbundled/definition28.js +4 -3
- package/unbundled/definition29.cjs +5 -168
- package/unbundled/definition29.js +11 -162
- package/unbundled/definition30.cjs +2 -63
- package/unbundled/definition30.js +5 -54
- package/unbundled/definition31.cjs +5 -3
- package/unbundled/definition31.js +5 -3
- package/unbundled/definition32.cjs +2 -1
- package/unbundled/definition32.js +2 -1
- package/unbundled/definition35.cjs +2 -1
- package/unbundled/definition35.js +2 -1
- package/unbundled/definition37.cjs +1 -1
- package/unbundled/definition37.js +1 -1
- package/unbundled/definition39.cjs +1 -1
- package/unbundled/definition39.js +1 -1
- package/unbundled/definition40.cjs +4 -2
- package/unbundled/definition40.js +4 -2
- package/unbundled/definition41.cjs +11 -6
- package/unbundled/definition41.js +11 -6
- package/unbundled/definition42.cjs +5 -4
- package/unbundled/definition42.js +5 -4
- package/unbundled/definition44.cjs +3 -2
- package/unbundled/definition44.js +3 -2
- package/unbundled/definition45.cjs +2 -2
- package/unbundled/definition45.js +2 -2
- package/unbundled/definition49.cjs +583 -79
- package/unbundled/definition49.js +579 -76
- package/unbundled/definition50.cjs +71 -33
- package/unbundled/definition50.js +67 -29
- package/unbundled/definition51.cjs +54 -23
- package/unbundled/definition51.js +52 -18
- package/unbundled/definition52.cjs +23 -39
- package/unbundled/definition52.js +17 -36
- package/unbundled/definition53.cjs +29 -314
- package/unbundled/definition53.js +27 -312
- package/unbundled/definition54.cjs +302 -195
- package/unbundled/definition54.js +298 -191
- package/unbundled/definition55.cjs +210 -40
- package/unbundled/definition55.js +206 -36
- package/unbundled/definition56.cjs +42 -266
- package/unbundled/definition56.js +38 -262
- package/unbundled/definition57.cjs +270 -50
- package/unbundled/definition57.js +267 -46
- package/unbundled/definition58.cjs +48 -146
- package/unbundled/definition58.js +47 -143
- package/unbundled/definition59.cjs +127 -225
- package/unbundled/definition59.js +122 -223
- package/unbundled/definition6.cjs +2 -1
- package/unbundled/definition6.js +2 -1
- package/unbundled/definition60.cjs +199 -418
- package/unbundled/definition60.js +196 -415
- package/unbundled/definition61.cjs +442 -3738
- package/unbundled/definition61.js +432 -3565
- package/unbundled/definition62.cjs +3717 -730
- package/unbundled/definition62.js +3544 -720
- package/unbundled/definition63.cjs +770 -97
- package/unbundled/definition63.js +767 -94
- package/unbundled/definition64.cjs +100 -999
- package/unbundled/definition64.js +98 -994
- package/unbundled/definition65.cjs +991 -93
- package/unbundled/definition65.js +985 -90
- package/unbundled/definition66.cjs +109 -73
- package/unbundled/definition66.js +105 -63
- package/unbundled/definition67.cjs +69 -155
- package/unbundled/definition67.js +60 -152
- package/unbundled/definition68.cjs +155 -119
- package/unbundled/definition68.js +151 -115
- package/unbundled/definition69.cjs +124 -49
- package/unbundled/definition69.js +120 -45
- package/unbundled/definition70.cjs +51 -85
- package/unbundled/definition70.js +50 -81
- package/unbundled/definition71.cjs +91 -19
- package/unbundled/definition71.js +86 -14
- package/unbundled/definition72.cjs +20 -87
- package/unbundled/definition72.js +14 -84
- package/unbundled/definition73.cjs +77 -294
- package/unbundled/definition73.js +72 -217
- package/unbundled/definition74.cjs +289 -311
- package/unbundled/definition74.js +219 -306
- package/unbundled/definition75.cjs +326 -26
- package/unbundled/definition75.js +317 -23
- package/unbundled/definition76.cjs +27 -122
- package/unbundled/definition76.js +22 -118
- package/unbundled/definition77.cjs +105 -232
- package/unbundled/definition77.js +101 -228
- package/unbundled/definition78.cjs +259 -26
- package/unbundled/definition78.js +249 -23
- package/unbundled/definition79.cjs +29 -148
- package/unbundled/definition79.js +27 -133
- package/unbundled/definition80.cjs +118 -173
- package/unbundled/definition80.js +109 -169
- package/unbundled/definition81.cjs +181 -477
- package/unbundled/definition81.js +176 -471
- package/unbundled/definition82.cjs +517 -0
- package/unbundled/definition82.js +497 -0
- package/unbundled/extractOptions.cjs +5 -5
- package/unbundled/extractOptions.js +2 -2
- package/unbundled/icon.cjs +67 -0
- package/unbundled/icon.js +61 -0
- package/unbundled/linkable.cjs +1 -1
- package/unbundled/linkable.js +1 -1
- package/unbundled/listbox.cjs +8 -3
- package/unbundled/listbox.js +7 -2
- package/unbundled/mixins.cjs +2 -1
- package/unbundled/mixins.js +2 -1
- package/unbundled/optgroup.cjs +66 -0
- package/unbundled/optgroup.js +54 -0
- package/unbundled/option.cjs +176 -0
- package/unbundled/option.js +164 -0
- package/unbundled/time-selection-picker.template.cjs +1 -1
- package/unbundled/time-selection-picker.template.js +1 -1
- package/unbundled/vivid-element.cjs +1 -1
- package/unbundled/vivid-element.js +1 -1
- package/video-player/definition.cjs +1 -1
- package/video-player/definition.js +1 -1
- package/vivid.api.json +336 -193
|
@@ -5,7 +5,7 @@ let _microsoft_fast_element = require("@microsoft/fast-element");
|
|
|
5
5
|
//#region src/shared/foundation/progress/base-progress.ts
|
|
6
6
|
/**
|
|
7
7
|
* An Progress HTML Element.
|
|
8
|
-
* Implements the
|
|
8
|
+
* Implements the [ARIA progressbar](https://www.w3.org/TR/wai-aria-1.1/#progressbar).
|
|
9
9
|
*/
|
|
10
10
|
var BaseProgress = class extends require_vivid_element.VividElement {
|
|
11
11
|
constructor(..._args) {
|
|
@@ -4,7 +4,7 @@ import { attr, nullableNumberConverter, observable } from "@microsoft/fast-eleme
|
|
|
4
4
|
//#region src/shared/foundation/progress/base-progress.ts
|
|
5
5
|
/**
|
|
6
6
|
* An Progress HTML Element.
|
|
7
|
-
* Implements the
|
|
7
|
+
* Implements the [ARIA progressbar](https://www.w3.org/TR/wai-aria-1.1/#progressbar).
|
|
8
8
|
*/
|
|
9
9
|
var BaseProgress = class extends VividElement {
|
|
10
10
|
constructor(..._args) {
|
package/unbundled/button.cjs
CHANGED
|
@@ -7,7 +7,7 @@ let _microsoft_fast_element = require("@microsoft/fast-element");
|
|
|
7
7
|
//#region src/shared/foundation/button/button.ts
|
|
8
8
|
/**
|
|
9
9
|
* A Button Custom HTML Element.
|
|
10
|
-
* Based largely on the
|
|
10
|
+
* Based largely on the [`<button>` element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button).
|
|
11
11
|
*
|
|
12
12
|
* @csspart control - The button element
|
|
13
13
|
* @csspart content - The element wrapping button content
|
|
@@ -69,7 +69,7 @@ var VividFoundationButton = class extends require_delegates_aria.DelegatesAria(r
|
|
|
69
69
|
if (next === "reset") this.addEventListener("click", this.handleFormReset);
|
|
70
70
|
if (previous === "reset") this.removeEventListener("click", this.handleFormReset);
|
|
71
71
|
}
|
|
72
|
-
/**
|
|
72
|
+
/** Validates the element against its constraints (e.g. `required`) and updates its validity state. */
|
|
73
73
|
validate() {
|
|
74
74
|
super.validate(this.control);
|
|
75
75
|
}
|
package/unbundled/button.js
CHANGED
|
@@ -6,7 +6,7 @@ import { Updates, attr } from "@microsoft/fast-element";
|
|
|
6
6
|
//#region src/shared/foundation/button/button.ts
|
|
7
7
|
/**
|
|
8
8
|
* A Button Custom HTML Element.
|
|
9
|
-
* Based largely on the
|
|
9
|
+
* Based largely on the [`<button>` element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button).
|
|
10
10
|
*
|
|
11
11
|
* @csspart control - The button element
|
|
12
12
|
* @csspart content - The element wrapping button content
|
|
@@ -68,7 +68,7 @@ var VividFoundationButton = class extends DelegatesAria(FormAssociated(VividElem
|
|
|
68
68
|
if (next === "reset") this.addEventListener("click", this.handleFormReset);
|
|
69
69
|
if (previous === "reset") this.removeEventListener("click", this.handleFormReset);
|
|
70
70
|
}
|
|
71
|
-
/**
|
|
71
|
+
/** Validates the element against its constraints (e.g. `required`) and updates its validity state. */
|
|
72
72
|
validate() {
|
|
73
73
|
super.validate(this.control);
|
|
74
74
|
}
|
package/unbundled/definition.cjs
CHANGED
|
@@ -1,68 +1,11 @@
|
|
|
1
1
|
require("./chunk.cjs");
|
|
2
2
|
const require_vivid_element = require("./vivid-element.cjs");
|
|
3
|
-
const
|
|
4
|
-
const require_decorate = require("./decorate.cjs");
|
|
3
|
+
const require_icon = require("./icon.cjs");
|
|
5
4
|
let _microsoft_fast_element = require("@microsoft/fast-element");
|
|
6
5
|
let _microsoft_fast_web_utilities = require("@microsoft/fast-web-utilities");
|
|
7
6
|
//#region src/lib/icon/icon.scss?inline
|
|
8
7
|
var icon_default = ":host{vertical-align:sub;display:inline-block}.control.connotation-accent{--_connotation-color-primary:var(--vvd-icon-accent-primary,var(--vvd-color-canvas-text))}.control.connotation-announcement{--_connotation-color-primary:var(--vvd-icon-announcement-primary,var(--vvd-color-announcement-500))}.control.connotation-cta{--_connotation-color-primary:var(--vvd-icon-cta-primary,var(--vvd-color-cta-500))}.control.connotation-success{--_connotation-color-primary:var(--vvd-icon-success-primary,var(--vvd-color-success-500))}.control.connotation-warning{--_connotation-color-primary:var(--vvd-icon-warning-primary,var(--vvd-color-warning-300))}.control.connotation-alert{--_connotation-color-primary:var(--vvd-icon-alert-primary,var(--vvd-color-alert-500))}.control.connotation-information{--_connotation-color-primary:var(--vvd-icon-information-primary,var(--vvd-color-information-500))}.control.size--6{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2)) - 1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) - 16))}.control.size--5{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) - 20))}.control.size--4{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) - 16))}.control.size--3{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) - 12))}.control.size--2{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) - 8))}.control.size--1{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) - 4))}.control.size-0{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2)))}.control.size-1{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) + 4))}.control.size-2{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) + 8))}.control.size-3{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) + 12))}.control.size-4{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) + 16))}.control.size-5{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) + 20))}.control:not(.size--6,.size--5,.size--4,.size--3,.size--2,.size--1,.size-0,.size-1,.size-2,.size-3,.size-4,.size-5){--_icon-block-size:1em}.control{margin:unset;block-size:var(--_icon-block-size);color:currentColor;contain:strict;inline-size:var(--_icon-block-size);display:flex}.control[class*=connotation]{color:var(--_connotation-color-primary)}slot,svg,::slotted(:where(svg,img)){block-size:inherit;inline-size:inherit;margin:auto}";
|
|
9
8
|
//#endregion
|
|
10
|
-
//#region src/lib/icon/icon.ts
|
|
11
|
-
var PLACEHOLDER_DELAY = 500;
|
|
12
|
-
var PLACEHOLDER_TIMEOUT = 2e3;
|
|
13
|
-
/**
|
|
14
|
-
* @public
|
|
15
|
-
* @component icon
|
|
16
|
-
* @slot - Default slot.
|
|
17
|
-
* @testQuery name name
|
|
18
|
-
*/
|
|
19
|
-
var Icon = class extends require_vivid_element.VividElement {
|
|
20
|
-
constructor(..._args) {
|
|
21
|
-
super(..._args);
|
|
22
|
-
this.iconLoaded = false;
|
|
23
|
-
this.#currentRequestId = 0;
|
|
24
|
-
this.#abortController = null;
|
|
25
|
-
}
|
|
26
|
-
#currentRequestId;
|
|
27
|
-
#abortController;
|
|
28
|
-
/** @internal */
|
|
29
|
-
async nameChanged() {
|
|
30
|
-
const requestId = ++this.#currentRequestId;
|
|
31
|
-
if (this.#abortController) this.#abortController.abort();
|
|
32
|
-
this.#abortController = new AbortController();
|
|
33
|
-
this._svg = void 0;
|
|
34
|
-
this.iconLoaded = false;
|
|
35
|
-
let timeout = setTimeout(() => {
|
|
36
|
-
/* v8 ignore else -- @preserve */
|
|
37
|
-
if (this.#currentRequestId === requestId) {
|
|
38
|
-
this._svg = require_numberConverter.PLACEHOLDER_ICON;
|
|
39
|
-
timeout = setTimeout(() => {
|
|
40
|
-
/* v8 ignore else -- @preserve */
|
|
41
|
-
if (this.#currentRequestId === requestId && this._svg === require_numberConverter.PLACEHOLDER_ICON) this._svg = void 0;
|
|
42
|
-
}, PLACEHOLDER_TIMEOUT);
|
|
43
|
-
}
|
|
44
|
-
}, PLACEHOLDER_DELAY);
|
|
45
|
-
try {
|
|
46
|
-
const svg = await require_numberConverter.resolveIcon(this.name, this.#abortController.signal);
|
|
47
|
-
/* v8 ignore else -- @preserve */
|
|
48
|
-
if (this.#currentRequestId === requestId) this._svg = svg;
|
|
49
|
-
} catch {
|
|
50
|
-
if (this.#currentRequestId === requestId) this._svg = void 0;
|
|
51
|
-
} finally {
|
|
52
|
-
if (this.#currentRequestId === requestId) {
|
|
53
|
-
clearTimeout(timeout);
|
|
54
|
-
this.iconLoaded = true;
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
};
|
|
59
|
-
require_decorate.__decorate([_microsoft_fast_element.attr], Icon.prototype, "connotation", void 0);
|
|
60
|
-
require_decorate.__decorate([(0, _microsoft_fast_element.attr)({ converter: require_numberConverter.numberConverter })], Icon.prototype, "size", void 0);
|
|
61
|
-
require_decorate.__decorate([_microsoft_fast_element.observable], Icon.prototype, "_svg", void 0);
|
|
62
|
-
require_decorate.__decorate([_microsoft_fast_element.observable], Icon.prototype, "iconLoaded", void 0);
|
|
63
|
-
require_decorate.__decorate([_microsoft_fast_element.attr], Icon.prototype, "label", void 0);
|
|
64
|
-
require_decorate.__decorate([_microsoft_fast_element.attr], Icon.prototype, "name", void 0);
|
|
65
|
-
//#endregion
|
|
66
9
|
//#region src/lib/icon/icon.template.ts
|
|
67
10
|
var iconTemplate = () => {
|
|
68
11
|
const isDecorative = (x) => !x.label || x.label.trim().length === 0;
|
|
@@ -83,7 +26,7 @@ var iconTemplate = () => {
|
|
|
83
26
|
//#endregion
|
|
84
27
|
//#region src/lib/icon/definition.ts
|
|
85
28
|
/** @internal */
|
|
86
|
-
var iconDefinition = require_vivid_element.defineVividComponent("icon", Icon, iconTemplate, [], { styles: icon_default });
|
|
29
|
+
var iconDefinition = require_vivid_element.defineVividComponent("icon", require_icon.Icon, iconTemplate, [], { styles: icon_default });
|
|
87
30
|
/**
|
|
88
31
|
* Registers the icon component & its prerequisite components with the design system.
|
|
89
32
|
*
|
|
@@ -91,12 +34,6 @@ var iconDefinition = require_vivid_element.defineVividComponent("icon", Icon, ic
|
|
|
91
34
|
*/
|
|
92
35
|
var registerIcon = require_vivid_element.createRegisterFunction(iconDefinition);
|
|
93
36
|
//#endregion
|
|
94
|
-
Object.defineProperty(exports, "Icon", {
|
|
95
|
-
enumerable: true,
|
|
96
|
-
get: function() {
|
|
97
|
-
return Icon;
|
|
98
|
-
}
|
|
99
|
-
});
|
|
100
37
|
Object.defineProperty(exports, "iconDefinition", {
|
|
101
38
|
enumerable: true,
|
|
102
39
|
get: function() {
|
package/unbundled/definition.js
CHANGED
|
@@ -1,67 +1,10 @@
|
|
|
1
|
-
import { d as createRegisterFunction,
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { attr, html, observable, when } from "@microsoft/fast-element";
|
|
1
|
+
import { d as createRegisterFunction, u as defineVividComponent } from "./vivid-element.js";
|
|
2
|
+
import { t as Icon } from "./icon.js";
|
|
3
|
+
import { html, when } from "@microsoft/fast-element";
|
|
5
4
|
import { classNames } from "@microsoft/fast-web-utilities";
|
|
6
5
|
//#region src/lib/icon/icon.scss?inline
|
|
7
6
|
var icon_default = ":host{vertical-align:sub;display:inline-block}.control.connotation-accent{--_connotation-color-primary:var(--vvd-icon-accent-primary,var(--vvd-color-canvas-text))}.control.connotation-announcement{--_connotation-color-primary:var(--vvd-icon-announcement-primary,var(--vvd-color-announcement-500))}.control.connotation-cta{--_connotation-color-primary:var(--vvd-icon-cta-primary,var(--vvd-color-cta-500))}.control.connotation-success{--_connotation-color-primary:var(--vvd-icon-success-primary,var(--vvd-color-success-500))}.control.connotation-warning{--_connotation-color-primary:var(--vvd-icon-warning-primary,var(--vvd-color-warning-300))}.control.connotation-alert{--_connotation-color-primary:var(--vvd-icon-alert-primary,var(--vvd-color-alert-500))}.control.connotation-information{--_connotation-color-primary:var(--vvd-icon-information-primary,var(--vvd-color-information-500))}.control.size--6{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2)) - 1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) - 16))}.control.size--5{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) - 20))}.control.size--4{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) - 16))}.control.size--3{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) - 12))}.control.size--2{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) - 8))}.control.size--1{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) - 4))}.control.size-0{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2)))}.control.size-1{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) + 4))}.control.size-2{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) + 8))}.control.size-3{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) + 12))}.control.size-4{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) + 16))}.control.size-5{--_icon-block-size:calc(1px * (40 + 4 * clamp(-1, var(--vvd-size-density,0), 2) + 20))}.control:not(.size--6,.size--5,.size--4,.size--3,.size--2,.size--1,.size-0,.size-1,.size-2,.size-3,.size-4,.size-5){--_icon-block-size:1em}.control{margin:unset;block-size:var(--_icon-block-size);color:currentColor;contain:strict;inline-size:var(--_icon-block-size);display:flex}.control[class*=connotation]{color:var(--_connotation-color-primary)}slot,svg,::slotted(:where(svg,img)){block-size:inherit;inline-size:inherit;margin:auto}";
|
|
8
7
|
//#endregion
|
|
9
|
-
//#region src/lib/icon/icon.ts
|
|
10
|
-
var PLACEHOLDER_DELAY = 500;
|
|
11
|
-
var PLACEHOLDER_TIMEOUT = 2e3;
|
|
12
|
-
/**
|
|
13
|
-
* @public
|
|
14
|
-
* @component icon
|
|
15
|
-
* @slot - Default slot.
|
|
16
|
-
* @testQuery name name
|
|
17
|
-
*/
|
|
18
|
-
var Icon = class extends VividElement {
|
|
19
|
-
constructor(..._args) {
|
|
20
|
-
super(..._args);
|
|
21
|
-
this.iconLoaded = false;
|
|
22
|
-
this.#currentRequestId = 0;
|
|
23
|
-
this.#abortController = null;
|
|
24
|
-
}
|
|
25
|
-
#currentRequestId;
|
|
26
|
-
#abortController;
|
|
27
|
-
/** @internal */
|
|
28
|
-
async nameChanged() {
|
|
29
|
-
const requestId = ++this.#currentRequestId;
|
|
30
|
-
if (this.#abortController) this.#abortController.abort();
|
|
31
|
-
this.#abortController = new AbortController();
|
|
32
|
-
this._svg = void 0;
|
|
33
|
-
this.iconLoaded = false;
|
|
34
|
-
let timeout = setTimeout(() => {
|
|
35
|
-
/* v8 ignore else -- @preserve */
|
|
36
|
-
if (this.#currentRequestId === requestId) {
|
|
37
|
-
this._svg = PLACEHOLDER_ICON;
|
|
38
|
-
timeout = setTimeout(() => {
|
|
39
|
-
/* v8 ignore else -- @preserve */
|
|
40
|
-
if (this.#currentRequestId === requestId && this._svg === PLACEHOLDER_ICON) this._svg = void 0;
|
|
41
|
-
}, PLACEHOLDER_TIMEOUT);
|
|
42
|
-
}
|
|
43
|
-
}, PLACEHOLDER_DELAY);
|
|
44
|
-
try {
|
|
45
|
-
const svg = await resolveIcon(this.name, this.#abortController.signal);
|
|
46
|
-
/* v8 ignore else -- @preserve */
|
|
47
|
-
if (this.#currentRequestId === requestId) this._svg = svg;
|
|
48
|
-
} catch {
|
|
49
|
-
if (this.#currentRequestId === requestId) this._svg = void 0;
|
|
50
|
-
} finally {
|
|
51
|
-
if (this.#currentRequestId === requestId) {
|
|
52
|
-
clearTimeout(timeout);
|
|
53
|
-
this.iconLoaded = true;
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
};
|
|
58
|
-
__decorate([attr], Icon.prototype, "connotation", void 0);
|
|
59
|
-
__decorate([attr({ converter: numberConverter })], Icon.prototype, "size", void 0);
|
|
60
|
-
__decorate([observable], Icon.prototype, "_svg", void 0);
|
|
61
|
-
__decorate([observable], Icon.prototype, "iconLoaded", void 0);
|
|
62
|
-
__decorate([attr], Icon.prototype, "label", void 0);
|
|
63
|
-
__decorate([attr], Icon.prototype, "name", void 0);
|
|
64
|
-
//#endregion
|
|
65
8
|
//#region src/lib/icon/icon.template.ts
|
|
66
9
|
var iconTemplate = () => {
|
|
67
10
|
const isDecorative = (x) => !x.label || x.label.trim().length === 0;
|
|
@@ -90,4 +33,4 @@ var iconDefinition = defineVividComponent("icon", Icon, iconTemplate, [], { styl
|
|
|
90
33
|
*/
|
|
91
34
|
var registerIcon = createRegisterFunction(iconDefinition);
|
|
92
35
|
//#endregion
|
|
93
|
-
export { registerIcon as n,
|
|
36
|
+
export { registerIcon as n, iconDefinition as t };
|
|
@@ -2,6 +2,7 @@ require("./chunk.cjs");
|
|
|
2
2
|
const require_vivid_element = require("./vivid-element.cjs");
|
|
3
3
|
const require_definition = require("./definition.cjs");
|
|
4
4
|
const require_decorate = require("./decorate.cjs");
|
|
5
|
+
const require_icon = require("./icon.cjs");
|
|
5
6
|
const require_affix = require("./affix.cjs");
|
|
6
7
|
const require_key_codes = require("./key-codes.cjs");
|
|
7
8
|
const require_kbd_shortcut = require("./kbd-shortcut.cjs");
|
|
@@ -24,7 +25,7 @@ var MenuItemRole = {
|
|
|
24
25
|
* @public
|
|
25
26
|
* @component menu-item
|
|
26
27
|
* @slot meta - Assign nodes to the `meta` slot to set a badge or an additional icon.
|
|
27
|
-
* @slot trailing-meta - Assign nodes to the `meta` slot to set a badge or an additional icon.
|
|
28
|
+
* @slot trailing-meta - Assign nodes to the `trailing-meta` slot to set a badge or an additional icon at the end of the Menu Item.
|
|
28
29
|
* @slot submenu - Assign a Menu to the `submenu` slot to add a submenu.
|
|
29
30
|
* @event {CustomEvent<HTMLElement>} expanded-change - Fired when the expanded state changes.
|
|
30
31
|
* @event {CustomEvent<undefined>} change - Fired when the item is triggered. Does not fire when a submenu is collapsed or expanded.
|
|
@@ -212,7 +213,7 @@ var getIndicatorIcon = (x) => {
|
|
|
212
213
|
return `${x.controlType === "checkbox" ? "checkbox" : "radio"}-${x.checked ? "checked" : "unchecked"}-2-line`;
|
|
213
214
|
};
|
|
214
215
|
function checkIndicator(context) {
|
|
215
|
-
const iconTag = context.tagFor(
|
|
216
|
+
const iconTag = context.tagFor(require_icon.Icon);
|
|
216
217
|
return _microsoft_fast_element.html`${(0, _microsoft_fast_element.when)((x) => Boolean(x.controlType), _microsoft_fast_element.html`<span class="action"><${iconTag} class="icon" name="${(x) => getIndicatorIcon(x)}"></${iconTag}></span>`)}`;
|
|
217
218
|
}
|
|
218
219
|
function text() {
|
|
@@ -223,7 +224,7 @@ function text() {
|
|
|
223
224
|
}
|
|
224
225
|
var MenuItemTemplate = (context) => {
|
|
225
226
|
const affixIconTemplate = require_affix.affixIconTemplateFactory(context);
|
|
226
|
-
const iconTag = context.tagFor(
|
|
227
|
+
const iconTag = context.tagFor(require_icon.Icon);
|
|
227
228
|
return _microsoft_fast_element.html`
|
|
228
229
|
<template
|
|
229
230
|
${require_host_semantics.applyHostSemantics({
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { d as createRegisterFunction, n as replaces, t as VividElement, u as defineVividComponent } from "./vivid-element.js";
|
|
2
|
-
import {
|
|
2
|
+
import { t as iconDefinition } from "./definition.js";
|
|
3
3
|
import { t as __decorate } from "./decorate.js";
|
|
4
|
+
import { t as Icon } from "./icon.js";
|
|
4
5
|
import { a as affixIconTemplateFactory, t as AffixIcon } from "./affix.js";
|
|
5
6
|
import { n as keyArrowRight$1, t as keyArrowLeft$1 } from "./key-codes.js";
|
|
6
7
|
import { t as WithKbdShortcut } from "./kbd-shortcut.js";
|
|
@@ -23,7 +24,7 @@ var MenuItemRole = {
|
|
|
23
24
|
* @public
|
|
24
25
|
* @component menu-item
|
|
25
26
|
* @slot meta - Assign nodes to the `meta` slot to set a badge or an additional icon.
|
|
26
|
-
* @slot trailing-meta - Assign nodes to the `meta` slot to set a badge or an additional icon.
|
|
27
|
+
* @slot trailing-meta - Assign nodes to the `trailing-meta` slot to set a badge or an additional icon at the end of the Menu Item.
|
|
27
28
|
* @slot submenu - Assign a Menu to the `submenu` slot to add a submenu.
|
|
28
29
|
* @event {CustomEvent<HTMLElement>} expanded-change - Fired when the expanded state changes.
|
|
29
30
|
* @event {CustomEvent<undefined>} change - Fired when the item is triggered. Does not fire when a submenu is collapsed or expanded.
|
|
@@ -161,6 +161,7 @@ var Menu = class extends require_anchored.Anchored(require_delegates_aria.Delega
|
|
|
161
161
|
get #triggerBehaviour() {
|
|
162
162
|
return this.trigger ?? "auto";
|
|
163
163
|
}
|
|
164
|
+
/** @internal */
|
|
164
165
|
openChanged(_, newValue) {
|
|
165
166
|
if (newValue) this._popupEl?.show().then(() => this.focus());
|
|
166
167
|
this.$emit(newValue ? "open" : "close", void 0, { bubbles: false });
|
|
@@ -251,7 +252,7 @@ var MenuTemplate = (context) => {
|
|
|
251
252
|
@keydown="${(x, c) => handleEscapeKey(x, c.event)}"
|
|
252
253
|
>
|
|
253
254
|
<div class="${(x) => (0, _microsoft_fast_web_utilities.classNames)("base", ["hide-header", !x.headerSlottedContent?.length], ["hide-actions", !x.actionItemsSlottedContent?.length], ["hide-body", x.items && !x.items.length])}">
|
|
254
|
-
<div class="header">
|
|
255
|
+
<div class="header" part="header">
|
|
255
256
|
<slot name="header" ${(0, _microsoft_fast_element.slotted)("headerSlottedContent")}></slot>
|
|
256
257
|
</div>
|
|
257
258
|
<div
|
|
@@ -263,7 +264,7 @@ var MenuTemplate = (context) => {
|
|
|
263
264
|
>
|
|
264
265
|
<slot ${(0, _microsoft_fast_element.slotted)("items")}></slot>
|
|
265
266
|
</div>
|
|
266
|
-
<footer class="action-items"><slot name="action-items" ${(0, _microsoft_fast_element.slotted)("actionItemsSlottedContent")}></slot></footer>
|
|
267
|
+
<footer class="action-items" part="action-items"><slot name="action-items" ${(0, _microsoft_fast_element.slotted)("actionItemsSlottedContent")}></slot></footer>
|
|
267
268
|
</div>
|
|
268
269
|
</${popupTag}>
|
|
269
270
|
</template>`;
|
|
@@ -160,6 +160,7 @@ var Menu = class extends Anchored(DelegatesAria(VividElement)) {
|
|
|
160
160
|
get #triggerBehaviour() {
|
|
161
161
|
return this.trigger ?? "auto";
|
|
162
162
|
}
|
|
163
|
+
/** @internal */
|
|
163
164
|
openChanged(_, newValue) {
|
|
164
165
|
if (newValue) this._popupEl?.show().then(() => this.focus());
|
|
165
166
|
this.$emit(newValue ? "open" : "close", void 0, { bubbles: false });
|
|
@@ -250,7 +251,7 @@ var MenuTemplate = (context) => {
|
|
|
250
251
|
@keydown="${(x, c) => handleEscapeKey(x, c.event)}"
|
|
251
252
|
>
|
|
252
253
|
<div class="${(x) => classNames("base", ["hide-header", !x.headerSlottedContent?.length], ["hide-actions", !x.actionItemsSlottedContent?.length], ["hide-body", x.items && !x.items.length])}">
|
|
253
|
-
<div class="header">
|
|
254
|
+
<div class="header" part="header">
|
|
254
255
|
<slot name="header" ${slotted("headerSlottedContent")}></slot>
|
|
255
256
|
</div>
|
|
256
257
|
<div
|
|
@@ -262,7 +263,7 @@ var MenuTemplate = (context) => {
|
|
|
262
263
|
>
|
|
263
264
|
<slot ${slotted("items")}></slot>
|
|
264
265
|
</div>
|
|
265
|
-
<footer class="action-items"><slot name="action-items" ${slotted("actionItemsSlottedContent")}></slot></footer>
|
|
266
|
+
<footer class="action-items" part="action-items"><slot name="action-items" ${slotted("actionItemsSlottedContent")}></slot></footer>
|
|
266
267
|
</div>
|
|
267
268
|
</${popupTag}>
|
|
268
269
|
</template>`;
|
|
@@ -2,6 +2,7 @@ require("./chunk.cjs");
|
|
|
2
2
|
const require_vivid_element = require("./vivid-element.cjs");
|
|
3
3
|
const require_definition = require("./definition.cjs");
|
|
4
4
|
const require_decorate = require("./decorate.cjs");
|
|
5
|
+
const require_icon = require("./icon.cjs");
|
|
5
6
|
const require_delegates_aria = require("./delegates-aria.cjs");
|
|
6
7
|
const require_linkable = require("./linkable.cjs");
|
|
7
8
|
let _microsoft_fast_element = require("@microsoft/fast-element");
|
|
@@ -62,7 +63,7 @@ function renderAvatarBaseElement(x, content) {
|
|
|
62
63
|
else return _microsoft_fast_element.html`<span class="${getClasses}">${content}</span>`;
|
|
63
64
|
}
|
|
64
65
|
var AvatarTemplate = (context) => {
|
|
65
|
-
const iconTag = context.tagFor(
|
|
66
|
+
const iconTag = context.tagFor(require_icon.Icon);
|
|
66
67
|
return _microsoft_fast_element.html`
|
|
67
68
|
${(x) => renderAvatarBaseElement(x, _microsoft_fast_element.html`<slot name="graphic">
|
|
68
69
|
${(0, _microsoft_fast_element.when)((x) => x.initials, renderInitials())}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { d as createRegisterFunction, t as VividElement, u as defineVividComponent } from "./vivid-element.js";
|
|
2
|
-
import {
|
|
2
|
+
import { t as iconDefinition } from "./definition.js";
|
|
3
3
|
import { t as __decorate } from "./decorate.js";
|
|
4
|
+
import { t as Icon } from "./icon.js";
|
|
4
5
|
import { n as delegateAria } from "./delegates-aria.js";
|
|
5
6
|
import { t as Linkable } from "./linkable.js";
|
|
6
7
|
import { attr, html, when } from "@microsoft/fast-element";
|
|
@@ -1,19 +1,24 @@
|
|
|
1
1
|
require("./chunk.cjs");
|
|
2
2
|
const require_vivid_element = require("./vivid-element.cjs");
|
|
3
3
|
const require_definition = require("./definition.cjs");
|
|
4
|
+
const require_icon = require("./icon.cjs");
|
|
4
5
|
const require_breadcrumb_item = require("./breadcrumb-item.cjs");
|
|
5
6
|
let _microsoft_fast_element = require("@microsoft/fast-element");
|
|
6
7
|
let _microsoft_fast_web_utilities = require("@microsoft/fast-web-utilities");
|
|
7
8
|
//#region src/lib/breadcrumb-item/breadcrumb-item.scss?inline
|
|
8
|
-
var breadcrumb_item_default = ".base{color:var(--vvd-color-canvas-text);font:var(--vvd-typography-base);align-items:center;display:flex}.base .separator{color:var(--vvd-color-neutral-600);margin:0 16px;font-size:12px}.control{font:inherit}.control:focus-visible{outline:none;position:relative}.control:focus-visible:after{box-shadow:0 0 0 4px color-mix(in sRGB, var(--focus-stroke-color,var(--vvd-color-cta-500)), transparent 85%), inset 0 0 0 3px var(--focus-stroke-gap-color,currentColor);outline:1px solid var(--focus-stroke-color,var(--vvd-color-cta-500));outline-offset:calc(-1px - var(--focus-inset,0px));border-radius:var(--focus-border-radius,inherit);block-size:calc(100% + var(--focus-block-size-addition,4px));content:\"\";inline-size:calc(100% + var(--focus-block-size-addition,4px));--focus-stroke-gap-color:transparent;--focus-block-size-addition:8px;--focus-border-radius:4px;display:block;position:absolute;inset-block-start:50%;inset-inline-start:50%;transform:translate(-50%,-50%)}.control:any-link{color:var(--vvd-color-cta-600);text-decoration:none}@media (hover:hover){.control:any-link:hover{text-decoration:underline}}";
|
|
9
|
+
var breadcrumb_item_default = ":host{flex:0 auto;min-inline-size:0}.base{color:var(--vvd-color-canvas-text);font:var(--vvd-typography-base);align-items:center;min-inline-size:0;display:flex}.base .separator{color:var(--vvd-color-neutral-600);margin:0 16px;font-size:12px}.text{text-overflow:ellipsis;white-space:nowrap;max-inline-size:100%;display:block;overflow:hidden}.control{font:inherit;min-inline-size:0;display:block}.control:focus-visible{outline:none;position:relative}.control:focus-visible:after{box-shadow:0 0 0 4px color-mix(in sRGB, var(--focus-stroke-color,var(--vvd-color-cta-500)), transparent 85%), inset 0 0 0 3px var(--focus-stroke-gap-color,currentColor);outline:1px solid var(--focus-stroke-color,var(--vvd-color-cta-500));outline-offset:calc(-1px - var(--focus-inset,0px));border-radius:var(--focus-border-radius,inherit);block-size:calc(100% + var(--focus-block-size-addition,4px));content:\"\";inline-size:calc(100% + var(--focus-block-size-addition,4px));--focus-stroke-gap-color:transparent;--focus-block-size-addition:8px;--focus-border-radius:4px;display:block;position:absolute;inset-block-start:50%;inset-inline-start:50%;transform:translate(-50%,-50%)}.control:any-link{color:var(--vvd-color-cta-600);text-decoration:none}@media (hover:hover){.control:any-link:hover{text-decoration:underline}}";
|
|
9
10
|
//#endregion
|
|
10
11
|
//#region src/lib/breadcrumb-item/breadcrumb-item.template.ts
|
|
11
12
|
var getClasses = (_) => (0, _microsoft_fast_web_utilities.classNames)("base");
|
|
12
13
|
var BreadcrumbItemTemplate = (context) => {
|
|
13
|
-
const iconTag = context.tagFor(
|
|
14
|
+
const iconTag = context.tagFor(require_icon.Icon);
|
|
14
15
|
return _microsoft_fast_element.html` <div role="listitem" class="${getClasses}">
|
|
15
|
-
${(0, _microsoft_fast_element.when)((x) => x.text && !x.href, _microsoft_fast_element.html
|
|
16
|
-
|
|
16
|
+
${(0, _microsoft_fast_element.when)((x) => x.text && !x.href, _microsoft_fast_element.html`<span class="text" title="${(x) => x.text}"
|
|
17
|
+
>${(x) => x.text}</span
|
|
18
|
+
>`)}
|
|
19
|
+
${(0, _microsoft_fast_element.when)((x) => x.text && x.href && x.href.length > 0, _microsoft_fast_element.html`${(x) => x._renderLinkElement(_microsoft_fast_element.html`<span class="text" title="${(x) => x.text}"
|
|
20
|
+
>${(x) => x.text}</span
|
|
21
|
+
>`, "control")}`)}
|
|
17
22
|
${(0, _microsoft_fast_element.when)((x) => x.separator, _microsoft_fast_element.html`<${iconTag} class="separator" name="chevron-right-solid"></${iconTag}>`)}
|
|
18
23
|
</div>`;
|
|
19
24
|
};
|
|
@@ -1,18 +1,23 @@
|
|
|
1
1
|
import { d as createRegisterFunction, u as defineVividComponent } from "./vivid-element.js";
|
|
2
|
-
import {
|
|
2
|
+
import { t as iconDefinition } from "./definition.js";
|
|
3
|
+
import { t as Icon } from "./icon.js";
|
|
3
4
|
import { t as BreadcrumbItem } from "./breadcrumb-item.js";
|
|
4
5
|
import { html, when } from "@microsoft/fast-element";
|
|
5
6
|
import { classNames } from "@microsoft/fast-web-utilities";
|
|
6
7
|
//#region src/lib/breadcrumb-item/breadcrumb-item.scss?inline
|
|
7
|
-
var breadcrumb_item_default = ".base{color:var(--vvd-color-canvas-text);font:var(--vvd-typography-base);align-items:center;display:flex}.base .separator{color:var(--vvd-color-neutral-600);margin:0 16px;font-size:12px}.control{font:inherit}.control:focus-visible{outline:none;position:relative}.control:focus-visible:after{box-shadow:0 0 0 4px color-mix(in sRGB, var(--focus-stroke-color,var(--vvd-color-cta-500)), transparent 85%), inset 0 0 0 3px var(--focus-stroke-gap-color,currentColor);outline:1px solid var(--focus-stroke-color,var(--vvd-color-cta-500));outline-offset:calc(-1px - var(--focus-inset,0px));border-radius:var(--focus-border-radius,inherit);block-size:calc(100% + var(--focus-block-size-addition,4px));content:\"\";inline-size:calc(100% + var(--focus-block-size-addition,4px));--focus-stroke-gap-color:transparent;--focus-block-size-addition:8px;--focus-border-radius:4px;display:block;position:absolute;inset-block-start:50%;inset-inline-start:50%;transform:translate(-50%,-50%)}.control:any-link{color:var(--vvd-color-cta-600);text-decoration:none}@media (hover:hover){.control:any-link:hover{text-decoration:underline}}";
|
|
8
|
+
var breadcrumb_item_default = ":host{flex:0 auto;min-inline-size:0}.base{color:var(--vvd-color-canvas-text);font:var(--vvd-typography-base);align-items:center;min-inline-size:0;display:flex}.base .separator{color:var(--vvd-color-neutral-600);margin:0 16px;font-size:12px}.text{text-overflow:ellipsis;white-space:nowrap;max-inline-size:100%;display:block;overflow:hidden}.control{font:inherit;min-inline-size:0;display:block}.control:focus-visible{outline:none;position:relative}.control:focus-visible:after{box-shadow:0 0 0 4px color-mix(in sRGB, var(--focus-stroke-color,var(--vvd-color-cta-500)), transparent 85%), inset 0 0 0 3px var(--focus-stroke-gap-color,currentColor);outline:1px solid var(--focus-stroke-color,var(--vvd-color-cta-500));outline-offset:calc(-1px - var(--focus-inset,0px));border-radius:var(--focus-border-radius,inherit);block-size:calc(100% + var(--focus-block-size-addition,4px));content:\"\";inline-size:calc(100% + var(--focus-block-size-addition,4px));--focus-stroke-gap-color:transparent;--focus-block-size-addition:8px;--focus-border-radius:4px;display:block;position:absolute;inset-block-start:50%;inset-inline-start:50%;transform:translate(-50%,-50%)}.control:any-link{color:var(--vvd-color-cta-600);text-decoration:none}@media (hover:hover){.control:any-link:hover{text-decoration:underline}}";
|
|
8
9
|
//#endregion
|
|
9
10
|
//#region src/lib/breadcrumb-item/breadcrumb-item.template.ts
|
|
10
11
|
var getClasses = (_) => classNames("base");
|
|
11
12
|
var BreadcrumbItemTemplate = (context) => {
|
|
12
13
|
const iconTag = context.tagFor(Icon);
|
|
13
14
|
return html` <div role="listitem" class="${getClasses}">
|
|
14
|
-
${when((x) => x.text && !x.href, html
|
|
15
|
-
|
|
15
|
+
${when((x) => x.text && !x.href, html`<span class="text" title="${(x) => x.text}"
|
|
16
|
+
>${(x) => x.text}</span
|
|
17
|
+
>`)}
|
|
18
|
+
${when((x) => x.text && x.href && x.href.length > 0, html`${(x) => x._renderLinkElement(html`<span class="text" title="${(x) => x.text}"
|
|
19
|
+
>${(x) => x.text}</span
|
|
20
|
+
>`, "control")}`)}
|
|
16
21
|
${when((x) => x.separator, html`<${iconTag} class="separator" name="chevron-right-solid"></${iconTag}>`)}
|
|
17
22
|
</div>`;
|
|
18
23
|
};
|
|
@@ -49,6 +49,11 @@ require_decorate.__decorate([(0, _microsoft_fast_element.attr)({ mode: "boolean"
|
|
|
49
49
|
require_decorate.__decorate([_microsoft_fast_element.attr], AccordionItem.prototype, "id", void 0);
|
|
50
50
|
require_decorate.__decorate([_microsoft_fast_element.attr], AccordionItem.prototype, "heading", void 0);
|
|
51
51
|
require_decorate.__decorate([(0, _microsoft_fast_element.attr)({ attribute: "secondary-text" })], AccordionItem.prototype, "secondaryText", void 0);
|
|
52
|
+
require_decorate.__decorate([require_vivid_element.replaces({
|
|
53
|
+
deprecatedPropertyName: "secondaryText",
|
|
54
|
+
fromDeprecated: (v) => v,
|
|
55
|
+
toDeprecated: (v) => v
|
|
56
|
+
}), (0, _microsoft_fast_element.attr)({ attribute: "text-secondary" })], AccordionItem.prototype, "textSecondary", void 0);
|
|
52
57
|
require_decorate.__decorate([_microsoft_fast_element.observable], AccordionItem.prototype, "_headingSlottedContent", void 0);
|
|
53
58
|
require_decorate.__decorate([(0, _microsoft_fast_element.attr)({
|
|
54
59
|
mode: "boolean",
|
|
@@ -80,8 +85,8 @@ var header = (context, hTagName) => {
|
|
|
80
85
|
<slot name="heading" ${(0, _microsoft_fast_element.slotted)("_headingSlottedContent")}></slot>
|
|
81
86
|
${(0, _microsoft_fast_element.when)((x) => x.heading && !x._headingSlottedContent?.length, _microsoft_fast_element.html`${(x) => x.heading}`)}
|
|
82
87
|
</span>
|
|
83
|
-
${(0, _microsoft_fast_element.when)((x) => Boolean(x.
|
|
84
|
-
>${(x) => x.
|
|
88
|
+
${(0, _microsoft_fast_element.when)((x) => Boolean(x.textSecondary), _microsoft_fast_element.html`<span class="heading-secondary"
|
|
89
|
+
>${(x) => x.textSecondary}</span
|
|
85
90
|
>`)}
|
|
86
91
|
</span>
|
|
87
92
|
|
package/unbundled/definition2.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { d as createRegisterFunction, t as VividElement, u as defineVividComponent } from "./vivid-element.js";
|
|
1
|
+
import { d as createRegisterFunction, n as replaces, t as VividElement, u as defineVividComponent } from "./vivid-element.js";
|
|
2
2
|
import { t as iconDefinition } from "./definition.js";
|
|
3
3
|
import { t as __decorate } from "./decorate.js";
|
|
4
4
|
import { a as affixIconTemplateFactory, i as IconWrapper, n as AffixIconWithTrailing } from "./affix.js";
|
|
@@ -48,6 +48,11 @@ __decorate([attr({ mode: "boolean" })], AccordionItem.prototype, "expanded", voi
|
|
|
48
48
|
__decorate([attr], AccordionItem.prototype, "id", void 0);
|
|
49
49
|
__decorate([attr], AccordionItem.prototype, "heading", void 0);
|
|
50
50
|
__decorate([attr({ attribute: "secondary-text" })], AccordionItem.prototype, "secondaryText", void 0);
|
|
51
|
+
__decorate([replaces({
|
|
52
|
+
deprecatedPropertyName: "secondaryText",
|
|
53
|
+
fromDeprecated: (v) => v,
|
|
54
|
+
toDeprecated: (v) => v
|
|
55
|
+
}), attr({ attribute: "text-secondary" })], AccordionItem.prototype, "textSecondary", void 0);
|
|
51
56
|
__decorate([observable], AccordionItem.prototype, "_headingSlottedContent", void 0);
|
|
52
57
|
__decorate([attr({
|
|
53
58
|
mode: "boolean",
|
|
@@ -79,8 +84,8 @@ var header = (context, hTagName) => {
|
|
|
79
84
|
<slot name="heading" ${slotted("_headingSlottedContent")}></slot>
|
|
80
85
|
${when((x) => x.heading && !x._headingSlottedContent?.length, html`${(x) => x.heading}`)}
|
|
81
86
|
</span>
|
|
82
|
-
${when((x) => Boolean(x.
|
|
83
|
-
>${(x) => x.
|
|
87
|
+
${when((x) => Boolean(x.textSecondary), html`<span class="heading-secondary"
|
|
88
|
+
>${(x) => x.textSecondary}</span
|
|
84
89
|
>`)}
|
|
85
90
|
</span>
|
|
86
91
|
|
|
@@ -2,6 +2,7 @@ require("./chunk.cjs");
|
|
|
2
2
|
const require_vivid_element = require("./vivid-element.cjs");
|
|
3
3
|
const require_definition = require("./definition.cjs");
|
|
4
4
|
const require_decorate = require("./decorate.cjs");
|
|
5
|
+
const require_icon = require("./icon.cjs");
|
|
5
6
|
const require_delegates_aria = require("./delegates-aria.cjs");
|
|
6
7
|
const require_linkable = require("./linkable.cjs");
|
|
7
8
|
const require_enums = require("./enums.cjs");
|
|
@@ -106,7 +107,7 @@ function renderCardBaseElement(x, content) {
|
|
|
106
107
|
</div>`;
|
|
107
108
|
}
|
|
108
109
|
function renderCardContent(context) {
|
|
109
|
-
const iconTag = context.tagFor(
|
|
110
|
+
const iconTag = context.tagFor(require_icon.Icon);
|
|
110
111
|
return _microsoft_fast_element.html`
|
|
111
112
|
${(x) => renderCardBaseElement(x, _microsoft_fast_element.html`<div class="wrapper">
|
|
112
113
|
<div class="vwc-card-media">
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { d as createRegisterFunction, t as VividElement, u as defineVividComponent } from "./vivid-element.js";
|
|
2
|
-
import {
|
|
2
|
+
import { t as iconDefinition } from "./definition.js";
|
|
3
3
|
import { t as __decorate } from "./decorate.js";
|
|
4
|
+
import { t as Icon } from "./icon.js";
|
|
4
5
|
import { n as delegateAria } from "./delegates-aria.js";
|
|
5
6
|
import { t as Linkable } from "./linkable.js";
|
|
6
7
|
import { t as Appearance } from "./enums.js";
|
|
@@ -2,6 +2,7 @@ require("./chunk.cjs");
|
|
|
2
2
|
const require_vivid_element = require("./vivid-element.cjs");
|
|
3
3
|
const require_definition = require("./definition.cjs");
|
|
4
4
|
const require_decorate = require("./decorate.cjs");
|
|
5
|
+
const require_icon = require("./icon.cjs");
|
|
5
6
|
const require_delegates_aria = require("./delegates-aria.cjs");
|
|
6
7
|
const require_form_associated = require("./form-associated.cjs");
|
|
7
8
|
const require_mixins = require("./mixins.cjs");
|
|
@@ -91,7 +92,7 @@ require_decorate.__decorate([_microsoft_fast_element.observable], Checkbox.proto
|
|
|
91
92
|
//#endregion
|
|
92
93
|
//#region src/lib/checkbox/checkbox.template.ts
|
|
93
94
|
var CheckboxTemplate = (context) => {
|
|
94
|
-
const iconTag = context.tagFor(
|
|
95
|
+
const iconTag = context.tagFor(require_icon.Icon);
|
|
95
96
|
return _microsoft_fast_element.html`<template>
|
|
96
97
|
<div
|
|
97
98
|
${(0, _microsoft_fast_element.ref)("control")}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { d as createRegisterFunction, t as VividElement, u as defineVividComponent } from "./vivid-element.js";
|
|
2
|
-
import {
|
|
2
|
+
import { t as iconDefinition } from "./definition.js";
|
|
3
3
|
import { t as __decorate } from "./decorate.js";
|
|
4
|
+
import { t as Icon } from "./icon.js";
|
|
4
5
|
import { n as delegateAria, t as DelegatesAria } from "./delegates-aria.js";
|
|
5
6
|
import { t as CheckableFormAssociated } from "./form-associated.js";
|
|
6
7
|
import { r as feedbackMessageDefinition, t as WithFeedback } from "./mixins.js";
|
|
@@ -8,15 +8,15 @@ const require_anchored = require("./anchored.cjs");
|
|
|
8
8
|
let _microsoft_fast_element = require("@microsoft/fast-element");
|
|
9
9
|
let _microsoft_fast_web_utilities = require("@microsoft/fast-web-utilities");
|
|
10
10
|
//#region src/lib/toggletip/toggletip.scss?inline
|
|
11
|
-
var toggletip_default = ":host :host{display:var(--_popup-display,inline)}:host :host([slotted-anchor]){--_popup-display:contents}.content-wrapper{width:var(--toggletip-inline-size,auto);max-inline-size:var(--toggletip-max-inline-size,30ch);padding:16px}.headline{font:var(--vvd-typography-base-bold);margin:0}.action-items{justify-content:flex-end;gap:10px;display:flex}::slotted([slot=action-items]){margin-block-start:16px}";
|
|
11
|
+
var toggletip_default = ":host :host{display:var(--_popup-display,inline)}:host :host([slotted-anchor]){--_popup-display:contents}.content-wrapper{width:var(--toggletip-inline-size,auto);max-inline-size:var(--toggletip-max-inline-size,30ch);padding:16px}.headline{font:var(--vvd-typography-base-bold);margin:0}.text-secondary{color:var(--vvd-color-neutral-600);font:var(--vvd-typography-base);margin:4px 0 0}.text-secondary:first-child{margin-block-start:0}.action-items{justify-content:flex-end;gap:10px;display:flex}::slotted([slot=action-items]){margin-block-start:16px}";
|
|
12
12
|
//#endregion
|
|
13
13
|
//#region src/lib/toggletip/toggletip.ts
|
|
14
14
|
/**
|
|
15
15
|
* @public
|
|
16
16
|
* @component toggletip
|
|
17
|
-
* @slot - The content to display in the
|
|
18
|
-
* @slot anchor - Used to set the anchor element for the
|
|
19
|
-
* @slot action-items - The content to display in the
|
|
17
|
+
* @slot - The content to display in the Toggletip.
|
|
18
|
+
* @slot anchor - Used to set the anchor element for the Toggletip.
|
|
19
|
+
* @slot action-items - The content to display in the Toggletip action items.
|
|
20
20
|
* @testSelector byHeadline byHeadline
|
|
21
21
|
* @testQuery open open true
|
|
22
22
|
* @testQuery closed open false
|
|
@@ -93,6 +93,7 @@ var Toggletip = class extends require_localized.Localized(require_anchored.Ancho
|
|
|
93
93
|
#closeOnEscape;
|
|
94
94
|
};
|
|
95
95
|
require_decorate.__decorate([_microsoft_fast_element.attr], Toggletip.prototype, "headline", void 0);
|
|
96
|
+
require_decorate.__decorate([(0, _microsoft_fast_element.attr)({ attribute: "text-secondary" })], Toggletip.prototype, "textSecondary", void 0);
|
|
96
97
|
require_decorate.__decorate([(0, _microsoft_fast_element.attr)({ mode: "boolean" })], Toggletip.prototype, "alternate", void 0);
|
|
97
98
|
require_decorate.__decorate([(0, _microsoft_fast_element.attr)({ mode: "fromView" })], Toggletip.prototype, "placement", void 0);
|
|
98
99
|
require_decorate.__decorate([(0, _microsoft_fast_element.attr)({ mode: "boolean" })], Toggletip.prototype, "open", void 0);
|
|
@@ -118,6 +119,7 @@ var ToggletipTemplate = (context) => {
|
|
|
118
119
|
>
|
|
119
120
|
<div class="content-wrapper">
|
|
120
121
|
${(0, _microsoft_fast_element.when)((x) => x.headline, _microsoft_fast_element.html`<h2 class="headline">${(x) => x.headline}</h2>`)}
|
|
122
|
+
${(0, _microsoft_fast_element.when)((x) => x.textSecondary, _microsoft_fast_element.html`<p class="text-secondary">${(x) => x.textSecondary}</p>`)}
|
|
121
123
|
<slot></slot>
|
|
122
124
|
<div class="action-items"><slot name="action-items"></slot></div>
|
|
123
125
|
</div>
|
|
@@ -7,15 +7,15 @@ import { n as anchorSlotTemplateFactory, t as Anchored } from "./anchored.js";
|
|
|
7
7
|
import { Updates, attr, html, when } from "@microsoft/fast-element";
|
|
8
8
|
import { classNames } from "@microsoft/fast-web-utilities";
|
|
9
9
|
//#region src/lib/toggletip/toggletip.scss?inline
|
|
10
|
-
var toggletip_default = ":host :host{display:var(--_popup-display,inline)}:host :host([slotted-anchor]){--_popup-display:contents}.content-wrapper{width:var(--toggletip-inline-size,auto);max-inline-size:var(--toggletip-max-inline-size,30ch);padding:16px}.headline{font:var(--vvd-typography-base-bold);margin:0}.action-items{justify-content:flex-end;gap:10px;display:flex}::slotted([slot=action-items]){margin-block-start:16px}";
|
|
10
|
+
var toggletip_default = ":host :host{display:var(--_popup-display,inline)}:host :host([slotted-anchor]){--_popup-display:contents}.content-wrapper{width:var(--toggletip-inline-size,auto);max-inline-size:var(--toggletip-max-inline-size,30ch);padding:16px}.headline{font:var(--vvd-typography-base-bold);margin:0}.text-secondary{color:var(--vvd-color-neutral-600);font:var(--vvd-typography-base);margin:4px 0 0}.text-secondary:first-child{margin-block-start:0}.action-items{justify-content:flex-end;gap:10px;display:flex}::slotted([slot=action-items]){margin-block-start:16px}";
|
|
11
11
|
//#endregion
|
|
12
12
|
//#region src/lib/toggletip/toggletip.ts
|
|
13
13
|
/**
|
|
14
14
|
* @public
|
|
15
15
|
* @component toggletip
|
|
16
|
-
* @slot - The content to display in the
|
|
17
|
-
* @slot anchor - Used to set the anchor element for the
|
|
18
|
-
* @slot action-items - The content to display in the
|
|
16
|
+
* @slot - The content to display in the Toggletip.
|
|
17
|
+
* @slot anchor - Used to set the anchor element for the Toggletip.
|
|
18
|
+
* @slot action-items - The content to display in the Toggletip action items.
|
|
19
19
|
* @testSelector byHeadline byHeadline
|
|
20
20
|
* @testQuery open open true
|
|
21
21
|
* @testQuery closed open false
|
|
@@ -92,6 +92,7 @@ var Toggletip = class extends Localized(Anchored(VividElement)) {
|
|
|
92
92
|
#closeOnEscape;
|
|
93
93
|
};
|
|
94
94
|
__decorate([attr], Toggletip.prototype, "headline", void 0);
|
|
95
|
+
__decorate([attr({ attribute: "text-secondary" })], Toggletip.prototype, "textSecondary", void 0);
|
|
95
96
|
__decorate([attr({ mode: "boolean" })], Toggletip.prototype, "alternate", void 0);
|
|
96
97
|
__decorate([attr({ mode: "fromView" })], Toggletip.prototype, "placement", void 0);
|
|
97
98
|
__decorate([attr({ mode: "boolean" })], Toggletip.prototype, "open", void 0);
|
|
@@ -117,6 +118,7 @@ var ToggletipTemplate = (context) => {
|
|
|
117
118
|
>
|
|
118
119
|
<div class="content-wrapper">
|
|
119
120
|
${when((x) => x.headline, html`<h2 class="headline">${(x) => x.headline}</h2>`)}
|
|
121
|
+
${when((x) => x.textSecondary, html`<p class="text-secondary">${(x) => x.textSecondary}</p>`)}
|
|
120
122
|
<slot></slot>
|
|
121
123
|
<div class="action-items"><slot name="action-items"></slot></div>
|
|
122
124
|
</div>
|