@dialpad/dialtone-vue 4.6.0 → 4.7.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/dist/{RichTextEditor-DaOHmXD_.js → RichTextEditor-D8DfONFm.js} +7 -7
- package/dist/{RichTextEditor-DaOHmXD_.js.map → RichTextEditor-D8DfONFm.js.map} +1 -1
- package/dist/{RichTextEditor-7eY8gy9u.cjs → RichTextEditor-DMUDJKVn.cjs} +2 -2
- package/dist/{RichTextEditor-7eY8gy9u.cjs.map → RichTextEditor-DMUDJKVn.cjs.map} +1 -1
- package/dist/common/mixins/keyboard-list-navigation.cjs +1 -1
- package/dist/common/mixins/keyboard-list-navigation.cjs.map +1 -1
- package/dist/common/mixins/keyboard-list-navigation.js +10 -7
- package/dist/common/mixins/keyboard-list-navigation.js.map +1 -1
- package/dist/common/mixins/keyboard_list_navigation.d.ts +1 -1
- package/dist/common/mixins/keyboard_list_navigation.d.ts.map +1 -1
- package/dist/common/sr_only_close_button.vue.d.ts +4 -1
- package/dist/component-documentation.json +1 -1
- package/dist/components/Avatar/Avatar.vue.d.ts +12 -8
- package/dist/components/Avatar/Avatar.vue.d.ts.map +1 -1
- package/dist/components/Badge/Badge.vue.d.ts +1 -2
- package/dist/components/Banner/Banner.vue.d.ts +8 -2
- package/dist/components/Banner/Banner.vue.d.ts.map +1 -1
- package/dist/components/Button/Button.vue.d.ts +4 -1
- package/dist/components/Button/Button.vue.d.ts.map +1 -1
- package/dist/components/Chip/Chip.vue.d.ts +4 -1
- package/dist/components/Chip/Chip.vue.d.ts.map +1 -1
- package/dist/components/Collapsible/Collapsible.vue.d.ts +4 -1
- package/dist/components/Collapsible/Collapsible.vue.d.ts.map +1 -1
- package/dist/components/Combobox/Combobox.vue.d.ts +5 -1
- package/dist/components/Combobox/Combobox.vue.d.ts.map +1 -1
- package/dist/components/Combobox/ComboboxEmptyList.vue.d.ts +2 -0
- package/dist/components/Combobox/ComboboxEmptyList.vue.d.ts.map +1 -1
- package/dist/components/Combobox/ComboboxLoadingList.vue.d.ts +2 -0
- package/dist/components/Combobox/ComboboxLoadingList.vue.d.ts.map +1 -1
- package/dist/components/ComboboxWithPopover/ComboboxWithPopover.vue.d.ts +51 -7
- package/dist/components/ComboboxWithPopover/ComboboxWithPopover.vue.d.ts.map +1 -1
- package/dist/components/Dropdown/Dropdown.vue.d.ts +74 -7
- package/dist/components/Dropdown/Dropdown.vue.d.ts.map +1 -1
- package/dist/components/FilterPill/FilterPill.vue.d.ts +530 -31
- package/dist/components/FilterPill/FilterPill.vue.d.ts.map +1 -1
- package/dist/components/FilterPill/FilterPillConstants.d.ts +2 -0
- package/dist/components/FilterPill/FilterPillConstants.d.ts.map +1 -0
- package/dist/components/FilterPill/FilterPillControlled.d.ts +92 -0
- package/dist/components/FilterPill/FilterPillControlled.d.ts.map +1 -0
- package/dist/components/FilterPill/FilterPillSelection.d.ts +13 -0
- package/dist/components/FilterPill/FilterPillSelection.d.ts.map +1 -0
- package/dist/components/Hovercard/Hovercard.vue.d.ts +102 -20
- package/dist/components/Hovercard/Hovercard.vue.d.ts.map +1 -1
- package/dist/components/ImageViewer/ImageViewer.vue.d.ts +8 -2
- package/dist/components/ImageViewer/ImageViewer.vue.d.ts.map +1 -1
- package/dist/components/ListItem/ListItem.vue.d.ts +2 -0
- package/dist/components/ListItem/ListItem.vue.d.ts.map +1 -1
- package/dist/components/ListItem/ListItemConstants.d.ts +2 -0
- package/dist/components/ListItem/ListItemConstants.d.ts.map +1 -1
- package/dist/components/ListItem/index.d.ts +1 -1
- package/dist/components/Loader/Loader.vue.d.ts +4 -1
- package/dist/components/Loader/Loader.vue.d.ts.map +1 -1
- package/dist/components/Modal/Modal.vue.d.ts +9 -3
- package/dist/components/Modal/Modal.vue.d.ts.map +1 -1
- package/dist/components/Notice/Notice.vue.d.ts +9 -3
- package/dist/components/Notice/Notice.vue.d.ts.map +1 -1
- package/dist/components/Notice/NoticeAction.vue.d.ts +8 -2
- package/dist/components/Notice/NoticeAction.vue.d.ts.map +1 -1
- package/dist/components/Pagination/Pagination.vue.d.ts +4 -1
- package/dist/components/Pagination/Pagination.vue.d.ts.map +1 -1
- package/dist/components/Popover/Popover.vue.d.ts +42 -6
- package/dist/components/Popover/Popover.vue.d.ts.map +1 -1
- package/dist/components/Popover/PopoverHeaderFooter.vue.d.ts +13 -1
- package/dist/components/Popover/PopoverHeaderFooter.vue.d.ts.map +1 -1
- package/dist/components/RichTextEditor/Extensions/Mentions/MentionSuggestion.vue.d.ts +12 -8
- package/dist/components/RichTextEditor/Extensions/Suggestion/SuggestionList.vue.d.ts +2 -0
- package/dist/components/RichTextEditor/Extensions/Suggestion/SuggestionList.vue.d.ts.map +1 -1
- package/dist/components/RichTextEditor/Extensions/Variable/VariableComponent.vue.d.ts +47 -9
- package/dist/components/RichTextEditor/Extensions/Variable/VariableComponent.vue.d.ts.map +1 -1
- package/dist/components/SegmentedControl/SegmentedControlItem.vue.d.ts.map +1 -1
- package/dist/components/SplitButton/SplitButton.vue.d.ts +82 -9
- package/dist/components/SplitButton/SplitButton.vue.d.ts.map +1 -1
- package/dist/components/SplitButton/SplitButtonEnd.vue.d.ts +4 -1
- package/dist/components/SplitButton/SplitButtonEnd.vue.d.ts.map +1 -1
- package/dist/components/SplitButton/SplitButtonStart.vue.d.ts +4 -1
- package/dist/components/Tab/Tab.vue.d.ts +4 -1
- package/dist/components/Toast/Layouts/ToastLayoutAlternate.vue.d.ts +9 -3
- package/dist/components/Toast/Layouts/ToastLayoutAlternate.vue.d.ts.map +1 -1
- package/dist/components/Toast/Layouts/ToastLayoutDefault.vue.d.ts +9 -3
- package/dist/components/Toast/Layouts/ToastLayoutDefault.vue.d.ts.map +1 -1
- package/dist/components/Toast/Toast.vue.d.ts +37 -13
- package/dist/components/Toast/Toast.vue.d.ts.map +1 -1
- package/dist/dialtone-vue.cjs +1 -1
- package/dist/dialtone-vue.js +96 -96
- package/dist/lib/avatar/avatar.cjs +1 -1
- package/dist/lib/avatar/avatar.cjs.map +1 -1
- package/dist/lib/avatar/avatar.js +50 -47
- package/dist/lib/avatar/avatar.js.map +1 -1
- package/dist/lib/badge/badge.cjs +1 -1
- package/dist/lib/badge/badge.cjs.map +1 -1
- package/dist/lib/badge/badge.js +12 -14
- package/dist/lib/badge/badge.js.map +1 -1
- package/dist/lib/button/button.cjs +1 -1
- package/dist/lib/button/button.js +21 -21
- package/dist/lib/dropdown/dropdown.cjs +1 -1
- package/dist/lib/dropdown/dropdown.cjs.map +1 -1
- package/dist/lib/dropdown/dropdown.js +73 -13
- package/dist/lib/dropdown/dropdown.js.map +1 -1
- package/dist/lib/filter-pill/filter-pill-constants.cjs +2 -0
- package/dist/lib/filter-pill/filter-pill-constants.cjs.map +1 -0
- package/dist/lib/filter-pill/filter-pill-constants.js +7 -0
- package/dist/lib/filter-pill/filter-pill-constants.js.map +1 -0
- package/dist/lib/filter-pill/filter-pill-controlled.cjs +2 -0
- package/dist/lib/filter-pill/filter-pill-controlled.cjs.map +1 -0
- package/dist/lib/filter-pill/filter-pill-controlled.js +308 -0
- package/dist/lib/filter-pill/filter-pill-controlled.js.map +1 -0
- package/dist/lib/filter-pill/filter-pill-selection.cjs +2 -0
- package/dist/lib/filter-pill/filter-pill-selection.cjs.map +1 -0
- package/dist/lib/filter-pill/filter-pill-selection.js +32 -0
- package/dist/lib/filter-pill/filter-pill-selection.js.map +1 -0
- package/dist/lib/filter-pill/filter-pill.cjs +1 -1
- package/dist/lib/filter-pill/filter-pill.cjs.map +1 -1
- package/dist/lib/filter-pill/filter-pill.js +360 -94
- package/dist/lib/filter-pill/filter-pill.js.map +1 -1
- package/dist/lib/list-item/index.cjs +1 -1
- package/dist/lib/list-item/index.js +3 -3
- package/dist/lib/list-item/list-item-constants.cjs +1 -1
- package/dist/lib/list-item/list-item-constants.cjs.map +1 -1
- package/dist/lib/list-item/list-item-constants.js +12 -6
- package/dist/lib/list-item/list-item-constants.js.map +1 -1
- package/dist/lib/list-item/list-item.cjs +1 -1
- package/dist/lib/list-item/list-item.cjs.map +1 -1
- package/dist/lib/list-item/list-item.js +36 -32
- package/dist/lib/list-item/list-item.js.map +1 -1
- package/dist/lib/loader/loader.cjs +3 -3
- package/dist/lib/loader/loader.cjs.map +1 -1
- package/dist/lib/loader/loader.js +28 -20
- package/dist/lib/loader/loader.js.map +1 -1
- package/dist/lib/modal/modal.cjs +1 -1
- package/dist/lib/modal/modal.cjs.map +1 -1
- package/dist/lib/modal/modal.js +6 -5
- package/dist/lib/modal/modal.js.map +1 -1
- package/dist/lib/popover/popover-header-footer.cjs +1 -1
- package/dist/lib/popover/popover-header-footer.cjs.map +1 -1
- package/dist/lib/popover/popover-header-footer.js +7 -1
- package/dist/lib/popover/popover-header-footer.js.map +1 -1
- package/dist/lib/popover/popover.cjs +1 -1
- package/dist/lib/popover/popover.cjs.map +1 -1
- package/dist/lib/popover/popover.js +57 -21
- package/dist/lib/popover/popover.js.map +1 -1
- package/dist/lib/rich-text-editor/index.cjs +1 -1
- package/dist/lib/rich-text-editor/index.js +1 -1
- package/dist/lib/rich-text-editor/rich-text-editor.cjs +1 -1
- package/dist/lib/rich-text-editor/rich-text-editor.js +1 -1
- package/dist/lib/segmented-control/segmented-control-item.cjs.map +1 -1
- package/dist/lib/segmented-control/segmented-control-item.js.map +1 -1
- package/dist/lib/text/text.cjs.map +1 -1
- package/dist/lib/text/text.js.map +1 -1
- package/dist/localization/en-US.cjs +9 -0
- package/dist/localization/en-US.cjs.map +1 -1
- package/dist/localization/en-US.js +1 -1
- package/dist/localization/en-US.js.map +1 -1
- package/dist/localization/index.cjs +1 -1
- package/dist/localization/index.cjs.map +1 -1
- package/dist/localization/index.js +50 -33
- package/dist/localization/index.js.map +1 -1
- package/package.json +3 -3
|
@@ -1,34 +1,81 @@
|
|
|
1
1
|
import { HTML_ELEMENT_TYPE as e } from "../../common/constants/index.js";
|
|
2
2
|
import { ordinalSizeValidator as t } from "../../common/validators/index.js";
|
|
3
|
-
import {
|
|
4
|
-
import { t as r } from "../../
|
|
5
|
-
import {
|
|
3
|
+
import { hasSlotContent as n } from "../../common/utils/index.js";
|
|
4
|
+
import { t as r } from "../../_plugin-vue_export-helper-BTgDAbhb.js";
|
|
5
|
+
import { t as i } from "../../mode_constants-tb7TL85q.js";
|
|
6
|
+
import a from "../text/text.js";
|
|
6
7
|
import { DialtoneLocalization as o } from "../../localization/index.js";
|
|
7
|
-
import s from "../button/button.js";
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import m from "../popover/popover.js";
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import {
|
|
8
|
+
import { BUTTON_ICON_SIZES as s, BUTTON_SIZE_MODIFIERS as c } from "../button/button-constants.js";
|
|
9
|
+
import l from "../button/button.js";
|
|
10
|
+
import u from "../checkbox/checkbox.js";
|
|
11
|
+
import d from "../checkbox-group/checkbox-group.js";
|
|
12
|
+
import f from "../list-item/list-item.js";
|
|
13
|
+
import p from "../stack/stack.js";
|
|
14
|
+
import { POPOVER_APPEND_TO_VALUES as m, POPOVER_HEADER_FOOTER_PADDING_CLASSES as h, POPOVER_PADDING_CLASSES as g } from "../popover/popover-constants.js";
|
|
15
|
+
import _ from "../popover/popover.js";
|
|
16
|
+
import v from "../dropdown/dropdown.js";
|
|
17
|
+
import { FILTER_PILL_OVERLAY_MIN_INLINE_SIZE_VALUES as y } from "./filter-pill-constants.js";
|
|
18
|
+
import b from "./filter-pill-controlled.js";
|
|
19
|
+
import { Fragment as x, createBlock as S, createCommentVNode as C, createElementBlock as w, createElementVNode as T, createSlots as E, createTextVNode as D, createVNode as O, guardReactiveProps as k, mergeProps as A, normalizeClass as j, normalizeProps as M, openBlock as N, renderList as P, renderSlot as F, resolveComponent as I, resolveDirective as L, resolveDynamicComponent as R, toDisplayString as z, withCtx as B, withDirectives as V, withKeys as H, withModifiers as U } from "vue";
|
|
20
|
+
import { DtIconCheck as W, DtIconChevronDown as G, DtIconClose as K } from "@dialpad/dialtone-icons/vue";
|
|
17
21
|
//#region components/FilterPill/FilterPill.vue
|
|
18
|
-
var
|
|
22
|
+
var q = {
|
|
19
23
|
name: "DtFilterPill",
|
|
20
24
|
components: {
|
|
21
|
-
DtCheckboxGroup:
|
|
22
|
-
DtCheckbox:
|
|
23
|
-
DtPopover:
|
|
24
|
-
DtButton:
|
|
25
|
-
DtIconClose:
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
25
|
+
DtCheckboxGroup: d,
|
|
26
|
+
DtCheckbox: u,
|
|
27
|
+
DtPopover: _,
|
|
28
|
+
DtButton: l,
|
|
29
|
+
DtIconClose: K,
|
|
30
|
+
DtIconCheck: W,
|
|
31
|
+
DtIconChevronDown: G,
|
|
32
|
+
DtDropdown: v,
|
|
33
|
+
DtListItem: f,
|
|
34
|
+
DtStack: p,
|
|
35
|
+
DtText: a
|
|
30
36
|
},
|
|
37
|
+
mixins: [b],
|
|
31
38
|
props: {
|
|
39
|
+
options: {
|
|
40
|
+
type: Array,
|
|
41
|
+
default: void 0
|
|
42
|
+
},
|
|
43
|
+
selected: {
|
|
44
|
+
type: [String, Array],
|
|
45
|
+
default: void 0
|
|
46
|
+
},
|
|
47
|
+
neutralValue: {
|
|
48
|
+
type: String,
|
|
49
|
+
default: void 0
|
|
50
|
+
},
|
|
51
|
+
open: {
|
|
52
|
+
type: [Boolean, null],
|
|
53
|
+
default: null
|
|
54
|
+
},
|
|
55
|
+
anchorEndClass: {
|
|
56
|
+
type: [
|
|
57
|
+
String,
|
|
58
|
+
Array,
|
|
59
|
+
Object
|
|
60
|
+
],
|
|
61
|
+
default: ""
|
|
62
|
+
},
|
|
63
|
+
optionEndClass: {
|
|
64
|
+
type: [
|
|
65
|
+
String,
|
|
66
|
+
Array,
|
|
67
|
+
Object
|
|
68
|
+
],
|
|
69
|
+
default: ""
|
|
70
|
+
},
|
|
71
|
+
headerContentClass: {
|
|
72
|
+
type: [
|
|
73
|
+
String,
|
|
74
|
+
Array,
|
|
75
|
+
Object
|
|
76
|
+
],
|
|
77
|
+
default: ""
|
|
78
|
+
},
|
|
32
79
|
useDropdown: {
|
|
33
80
|
type: Boolean,
|
|
34
81
|
default: !1
|
|
@@ -68,7 +115,7 @@ var z = {
|
|
|
68
115
|
popoverAppendTo: {
|
|
69
116
|
type: [e, String],
|
|
70
117
|
default: "body",
|
|
71
|
-
validator: (e) =>
|
|
118
|
+
validator: (e) => m.includes(e) || e instanceof HTMLElement
|
|
72
119
|
},
|
|
73
120
|
popoverFallbackPlacements: {
|
|
74
121
|
type: Array,
|
|
@@ -78,14 +125,19 @@ var z = {
|
|
|
78
125
|
type: String,
|
|
79
126
|
default: ""
|
|
80
127
|
},
|
|
128
|
+
overlayMinInlineSize: {
|
|
129
|
+
type: String,
|
|
130
|
+
default: "anchor",
|
|
131
|
+
validator: t(y)
|
|
132
|
+
},
|
|
81
133
|
popoverMaxWidth: {
|
|
82
134
|
type: String,
|
|
83
135
|
default: ""
|
|
84
136
|
},
|
|
85
137
|
popoverPadding: {
|
|
86
138
|
type: String,
|
|
87
|
-
default:
|
|
88
|
-
validator: (e) => Object.keys(
|
|
139
|
+
default: void 0,
|
|
140
|
+
validator: (e) => Object.keys(g).some((t) => t === e)
|
|
89
141
|
},
|
|
90
142
|
popoverPlacement: {
|
|
91
143
|
type: String,
|
|
@@ -139,14 +191,18 @@ var z = {
|
|
|
139
191
|
],
|
|
140
192
|
default: ""
|
|
141
193
|
},
|
|
142
|
-
contentMode:
|
|
194
|
+
contentMode: i,
|
|
143
195
|
size: {
|
|
144
196
|
type: [String, Number],
|
|
145
197
|
default: 200,
|
|
146
|
-
validator: t(
|
|
198
|
+
validator: t(c)
|
|
147
199
|
}
|
|
148
200
|
},
|
|
149
201
|
emits: [
|
|
202
|
+
"update:selected",
|
|
203
|
+
"selection-change",
|
|
204
|
+
"update:open",
|
|
205
|
+
"opened",
|
|
150
206
|
"clear",
|
|
151
207
|
"open",
|
|
152
208
|
"update:modelValue",
|
|
@@ -156,13 +212,17 @@ var z = {
|
|
|
156
212
|
return {
|
|
157
213
|
isOpen: !1,
|
|
158
214
|
i18n: new o(),
|
|
159
|
-
filters: this.modelValue,
|
|
160
|
-
pendingFilters: null
|
|
215
|
+
filters: Array.isArray(this.options) ? [] : this.modelValue,
|
|
216
|
+
pendingFilters: null,
|
|
217
|
+
overlayResizeObserver: null
|
|
161
218
|
};
|
|
162
219
|
},
|
|
163
220
|
computed: {
|
|
221
|
+
overlayUseDropdown() {
|
|
222
|
+
return this.controlledAtBirth ? this.controlledDropdown : this.useDropdown;
|
|
223
|
+
},
|
|
164
224
|
overlayComponent() {
|
|
165
|
-
return this.
|
|
225
|
+
return this.overlayUseDropdown ? "dt-dropdown" : "dt-popover";
|
|
166
226
|
},
|
|
167
227
|
overlayProps() {
|
|
168
228
|
let e = {
|
|
@@ -173,7 +233,12 @@ var z = {
|
|
|
173
233
|
modal: !0,
|
|
174
234
|
placement: this.popoverPlacement
|
|
175
235
|
};
|
|
176
|
-
|
|
236
|
+
if (this.controlledAtBirth && (e.visibilityChangeCallback = this.onControlledVisibility, e.forwardAnchorArrowKeys = !0), this.overlayUseDropdown) e["list-class"] = this.dropdownListClass;
|
|
237
|
+
else {
|
|
238
|
+
let t = this.popoverPadding === void 0;
|
|
239
|
+
e.padding = t ? "none" : this.popoverPadding, e["content-class"] = t ? ["d-filter-pill__popover-content", this.popoverContentClass] : this.popoverContentClass, e["header-wrapper-class"] = t ? [h.large, this.popoverHeaderClass] : this.popoverHeaderClass, e["header-class"] = this.headerContentClass, e["footer-wrapper-class"] = t ? [h.large, this.popoverFooterClass] : this.popoverFooterClass, e["dialog-class"] = this.popoverDialogClass;
|
|
240
|
+
}
|
|
241
|
+
return e;
|
|
177
242
|
},
|
|
178
243
|
buttonKind() {
|
|
179
244
|
return this.isActive && !this.disabled ? "default" : "muted";
|
|
@@ -190,17 +255,27 @@ var z = {
|
|
|
190
255
|
activeFilters() {
|
|
191
256
|
return this.filters.filter((e) => e.active).map((e) => e.name);
|
|
192
257
|
},
|
|
258
|
+
allFiltersActive() {
|
|
259
|
+
return this.filters.length > 1 && this.activeFilters.length === this.filters.length;
|
|
260
|
+
},
|
|
193
261
|
activeFilterList() {
|
|
194
|
-
return this.
|
|
262
|
+
return this.allFiltersActive ? "All" : this.activeFilters[0] ?? "";
|
|
263
|
+
},
|
|
264
|
+
activeFilterLabel() {
|
|
265
|
+
return this.allFiltersActive ? this.i18n.$t("DIALTONE_FILTER_PILL_ALL_LABEL") : this.activeFilterList;
|
|
266
|
+
},
|
|
267
|
+
activeFilterOverflowTitle() {
|
|
268
|
+
let e = this.controlledAtBirth ? this.controlledState.values.length - 1 : this.activeFilters.length - 1;
|
|
269
|
+
return this.i18n.$t("DIALTONE_FILTER_PILL_OVERFLOW_TITLE", { count: e });
|
|
195
270
|
},
|
|
196
271
|
activeFilterOverflow() {
|
|
197
|
-
return this.activeFilters.length <= 1 || this.
|
|
272
|
+
return this.activeFilters.length <= 1 || this.allFiltersActive ? "" : "+" + (this.activeFilters.length - 1);
|
|
198
273
|
},
|
|
199
274
|
isActive() {
|
|
200
|
-
return this.activeFilterList.length > 0;
|
|
275
|
+
return this.controlledAtBirth ? this.controlledState.valid && this.controlledState.isActive : this.activeFilterList.length > 0;
|
|
201
276
|
},
|
|
202
277
|
hasClear() {
|
|
203
|
-
return !this.readOnly && this.showClear && this.activeFilterList.length > 0;
|
|
278
|
+
return this.controlledAtBirth ? !this.readOnly && this.showClear && this.controlledContractValid && this.controlledState.valid && this.isActive : !this.readOnly && this.showClear && this.activeFilterList.length > 0;
|
|
204
279
|
},
|
|
205
280
|
displayFilters() {
|
|
206
281
|
return this.deferSelection && this.pendingFilters ? this.pendingFilters : this.filters;
|
|
@@ -215,28 +290,84 @@ var z = {
|
|
|
215
290
|
return this.i18n.$t("DIALTONE_FILTER_PILL_APPLY_BUTTON_LABEL");
|
|
216
291
|
},
|
|
217
292
|
clearIconSize() {
|
|
218
|
-
return String(this.size) === "100" ? "100" :
|
|
293
|
+
return String(this.size) === "100" ? "100" : s[String(this.size)];
|
|
219
294
|
}
|
|
220
295
|
},
|
|
221
296
|
watch: {
|
|
222
|
-
|
|
223
|
-
|
|
297
|
+
overlayMinInlineSize: {
|
|
298
|
+
handler: "observeOverlayAnchor",
|
|
299
|
+
flush: "post"
|
|
300
|
+
},
|
|
301
|
+
overlayUseDropdown: {
|
|
302
|
+
handler: "observeOverlayAnchor",
|
|
303
|
+
flush: "post"
|
|
224
304
|
},
|
|
305
|
+
hasClear: {
|
|
306
|
+
handler: "observeOverlayAnchor",
|
|
307
|
+
flush: "post"
|
|
308
|
+
},
|
|
309
|
+
popoverMaxWidth: {
|
|
310
|
+
handler: "syncOverlayMinInlineSize",
|
|
311
|
+
flush: "post"
|
|
312
|
+
},
|
|
313
|
+
isOpen: [{
|
|
314
|
+
handler: "syncOverlayMinInlineSize",
|
|
315
|
+
flush: "post"
|
|
316
|
+
}, function(e) {
|
|
317
|
+
this.controlledAtBirth || (this.$emit("open", e), this.deferSelection && (e ? this.pendingFilters = JSON.parse(JSON.stringify(this.filters)) : this.pendingFilters = null));
|
|
318
|
+
}],
|
|
225
319
|
filters: {
|
|
226
320
|
deep: !0,
|
|
227
321
|
handler(e) {
|
|
228
|
-
this.$emit("update:modelValue", e);
|
|
322
|
+
this.controlledAtBirth || this.$emit("update:modelValue", e);
|
|
229
323
|
}
|
|
230
324
|
}
|
|
231
325
|
},
|
|
232
326
|
mounted() {
|
|
233
|
-
this.modelValue?.length || this.$slots.content &&
|
|
327
|
+
this.observeOverlayAnchor(), !this.controlledAtBirth && !(this.modelValue?.length || this.$slots.content) && console.warn("Please provide content through the v-model or the \"content\" slot."), this.deferSelection && this.useDropdown && console.warn("deferSelection has no effect when useDropdown is true.");
|
|
328
|
+
},
|
|
329
|
+
beforeUnmount() {
|
|
330
|
+
this.overlayResizeObserver?.disconnect();
|
|
234
331
|
},
|
|
235
332
|
methods: {
|
|
333
|
+
hasSlotContent: n,
|
|
334
|
+
observeOverlayAnchor() {
|
|
335
|
+
this.overlayResizeObserver?.disconnect(), this.overlayResizeObserver = null, this.overlayMinInlineSize === "anchor" && typeof ResizeObserver < "u" && (this.overlayResizeObserver = new ResizeObserver(() => this.syncOverlayMinInlineSize()), [this.$el, ...this.getAnchorControls()].forEach((e) => this.overlayResizeObserver.observe(e))), this.syncOverlayMinInlineSize();
|
|
336
|
+
},
|
|
337
|
+
getAnchorControls() {
|
|
338
|
+
return [this.$el.querySelector("[data-qa=\"dt-filter-pill__button\"]"), this.$refs.clearButton?.$el].filter(Boolean);
|
|
339
|
+
},
|
|
340
|
+
measureAnchorInlineSize() {
|
|
341
|
+
let e = this.getAnchorControls();
|
|
342
|
+
if (!e.length) return 0;
|
|
343
|
+
let [t, n] = /^(vertical|sideways)/.test(getComputedStyle(this.$el).writingMode) ? ["top", "bottom"] : ["left", "right"], r = e.map((e) => e.getBoundingClientRect());
|
|
344
|
+
return Math.max(...r.map((e) => e[n])) - Math.min(...r.map((e) => e[t]));
|
|
345
|
+
},
|
|
346
|
+
resolveOverlayMinInlineSize() {
|
|
347
|
+
let e = String(this.overlayMinInlineSize ?? "0");
|
|
348
|
+
return e = e === "anchor" ? `${this.measureAnchorInlineSize()}px` : e === "0" ? "0px" : `var(--dt-layout-${e})`, e && this.popoverMaxWidth && this.popoverMaxWidth !== "none" ? `min(${e}, ${this.popoverMaxWidth})` : e;
|
|
349
|
+
},
|
|
350
|
+
syncOverlayMinInlineSize() {
|
|
351
|
+
let e = this.$refs.overlay;
|
|
352
|
+
if (!e) return;
|
|
353
|
+
let t = this.overlayUseDropdown ? e.$refs.popover : e, n = t?.popoverContentEl;
|
|
354
|
+
if (!n) return;
|
|
355
|
+
let r = this.resolveOverlayMinInlineSize();
|
|
356
|
+
n.style.minInlineSize !== r && (n.style.minInlineSize = r, t.tip?.popperInstance?.update());
|
|
357
|
+
},
|
|
236
358
|
clearFilter(e) {
|
|
359
|
+
if (this.controlledAtBirth) {
|
|
360
|
+
let t = this.controlledDropdown ? this.neutralValue ?? null : [];
|
|
361
|
+
this.controlledDraft = null, this.commitControlled(t, "clear", !0, e), this.reconcileCheckboxes();
|
|
362
|
+
return;
|
|
363
|
+
}
|
|
237
364
|
this.filters.forEach((e) => delete e.active), this.$emit("clear", e);
|
|
238
365
|
},
|
|
239
366
|
openPopover() {
|
|
367
|
+
if (this.controlledAtBirth) {
|
|
368
|
+
this.requestControlledOpen(!0);
|
|
369
|
+
return;
|
|
370
|
+
}
|
|
240
371
|
this.readOnly || (this.isOpen = !0);
|
|
241
372
|
},
|
|
242
373
|
selectFilter(e, t) {
|
|
@@ -245,25 +376,41 @@ var z = {
|
|
|
245
376
|
}), t();
|
|
246
377
|
},
|
|
247
378
|
applySelection() {
|
|
379
|
+
if (this.controlledAtBirth) return this.applyControlledSelection();
|
|
248
380
|
this.pendingFilters && (this.filters.forEach((e, t) => {
|
|
249
381
|
this.pendingFilters[t] ? e.active = this.pendingFilters[t].active : delete e.active;
|
|
250
382
|
}), this.$emit("apply"), this.isOpen = !1);
|
|
251
383
|
},
|
|
252
384
|
cancelSelection() {
|
|
385
|
+
if (this.controlledAtBirth) {
|
|
386
|
+
this.closeControlled();
|
|
387
|
+
return;
|
|
388
|
+
}
|
|
253
389
|
this.isOpen = !1;
|
|
254
390
|
}
|
|
255
391
|
}
|
|
256
|
-
},
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
392
|
+
}, J = {
|
|
393
|
+
class: "sr-only",
|
|
394
|
+
"data-qa": "dt-filter-pill__accessible-label"
|
|
395
|
+
}, Y = {
|
|
396
|
+
key: 0,
|
|
397
|
+
class: "d-filter-pill__label-start",
|
|
398
|
+
"data-qa": "dt-filter-pill__label-start",
|
|
399
|
+
"aria-hidden": "true"
|
|
400
|
+
}, X = ["title"], Z = ["title", "textContent"], Q = ["title", "textContent"], $ = ["title", "textContent"];
|
|
401
|
+
function ee(e, t, n, r, i, a) {
|
|
402
|
+
let o = I("dt-icon-chevron-down"), s = I("dt-button"), c = I("dt-checkbox"), l = I("dt-checkbox-group"), u = I("dt-stack"), d = I("dt-text"), f = I("dt-icon-check"), p = I("dt-list-item"), m = I("dt-icon-close"), h = L("dt-tooltip");
|
|
403
|
+
return N(), w("div", A({ class: ["d-filter-pill", { "d-filter-pill--read-only": n.readOnly }] }, e.legacyRootAttrs(), { "data-qa": "dt-filter-pill" }), [(N(), S(R(a.overlayComponent), A({
|
|
404
|
+
ref: "overlay",
|
|
405
|
+
open: i.isOpen
|
|
406
|
+
}, a.overlayProps, {
|
|
407
|
+
"aria-label": e.controlledAtBirth && !e.$slots.content ? n.label : void 0,
|
|
408
|
+
"content-mode": n.contentMode,
|
|
409
|
+
"onUpdate:open": e.onOverlayTerminalOpen,
|
|
410
|
+
onOpened: e.onOverlayOpened,
|
|
411
|
+
onKeydown: e.onOverlayKeydown
|
|
412
|
+
}), E({
|
|
413
|
+
anchor: B((t) => [V((N(), S(s, A({ ref: "primaryButton" }, e.anchorAttributes(t), {
|
|
267
414
|
active: a.isActive,
|
|
268
415
|
"aria-disabled": n.readOnly || void 0,
|
|
269
416
|
class: ["d-filter-pill__primary", { "d-filter-pill--selected": a.isActive }],
|
|
@@ -273,41 +420,65 @@ function U(e, t, n, r, i, a) {
|
|
|
273
420
|
"data-qa": "dt-filter-pill__button",
|
|
274
421
|
importance: "outlined",
|
|
275
422
|
onClick: a.openPopover,
|
|
276
|
-
onKeydown:
|
|
277
|
-
}),
|
|
278
|
-
default:
|
|
423
|
+
onKeydown: H(U(e.onAnchorArrow, ["prevent"]), ["up", "down"])
|
|
424
|
+
}), E({
|
|
425
|
+
default: B(() => [T("span", {
|
|
426
|
+
class: j(["d-filter-pill__label", n.labelClass]),
|
|
427
|
+
"data-qa": "dt-filter-pill__label"
|
|
428
|
+
}, [e.controlledAtBirth ? F(e.$slots, "default", M(A({ key: 0 }, e.controlledAnchorBindings)), () => [
|
|
429
|
+
T("span", J, z(e.controlledAccessibleLabel), 1),
|
|
430
|
+
e.controlledDropdown || !a.isActive || n.label ? (N(), w("span", Y, z(e.controlledDropdown || !a.isActive ? e.controlledDisplayLabel : n.label), 1)) : C("", !0),
|
|
431
|
+
!e.controlledDropdown && a.isActive ? (N(), w("span", {
|
|
432
|
+
key: 1,
|
|
433
|
+
class: j(["d-filter-pill__label-end", { "d-filter-pill__label-end--standalone": !n.label }]),
|
|
434
|
+
"data-qa": "dt-filter-pill__label-end",
|
|
435
|
+
"aria-hidden": "true"
|
|
436
|
+
}, z(e.controlledDisplayLabel), 3)) : C("", !0),
|
|
437
|
+
e.controlledOverflow ? (N(), w("span", {
|
|
438
|
+
key: 2,
|
|
439
|
+
class: "d-filter-pill__label-end-overflow",
|
|
440
|
+
"data-qa": "dt-filter-pill__overflow",
|
|
441
|
+
title: a.activeFilterOverflowTitle
|
|
442
|
+
}, z(e.controlledOverflow), 9, X)) : C("", !0),
|
|
443
|
+
a.hasSlotContent(e.$slots.anchorEnd, e.controlledAnchorBindings) ? (N(), w("span", {
|
|
444
|
+
key: 3,
|
|
445
|
+
class: j(["d-filter-pill__anchor-end", n.anchorEndClass]),
|
|
446
|
+
"data-qa": "dt-filter-pill__anchor-end"
|
|
447
|
+
}, [F(e.$slots, "anchorEnd", M(k(e.controlledAnchorBindings)))], 2)) : C("", !0)
|
|
448
|
+
]) : F(e.$slots, "default", {
|
|
449
|
+
key: 1,
|
|
279
450
|
label: n.label,
|
|
280
451
|
filters: i.filters,
|
|
281
452
|
activeFilters: a.activeFilters,
|
|
282
453
|
activeFilterList: a.activeFilterList,
|
|
283
454
|
activeFilterOverflow: a.activeFilterOverflow
|
|
284
455
|
}, () => [
|
|
285
|
-
|
|
456
|
+
T("span", {
|
|
286
457
|
class: "d-filter-pill__label-start",
|
|
287
458
|
title: n.label,
|
|
288
|
-
textContent:
|
|
289
|
-
}, null, 8,
|
|
290
|
-
a.activeFilterList ? (
|
|
459
|
+
textContent: z(n.label)
|
|
460
|
+
}, null, 8, Z),
|
|
461
|
+
a.activeFilterList ? (N(), w("span", {
|
|
291
462
|
key: 0,
|
|
292
463
|
class: "d-filter-pill__label-end",
|
|
293
|
-
title: a.
|
|
294
|
-
textContent:
|
|
295
|
-
}, null, 8,
|
|
296
|
-
a.activeFilterOverflow ? (
|
|
464
|
+
title: a.activeFilterLabel,
|
|
465
|
+
textContent: z(a.activeFilterLabel)
|
|
466
|
+
}, null, 8, Q)) : C("", !0),
|
|
467
|
+
a.activeFilterOverflow ? (N(), w("span", {
|
|
297
468
|
key: 1,
|
|
298
469
|
class: "d-filter-pill__label-end-overflow",
|
|
299
|
-
title:
|
|
300
|
-
textContent:
|
|
301
|
-
}, null, 8,
|
|
470
|
+
title: a.activeFilterOverflowTitle,
|
|
471
|
+
textContent: z(a.activeFilterOverflow)
|
|
472
|
+
}, null, 8, $)) : C("", !0)
|
|
302
473
|
])], 2)]),
|
|
303
474
|
_: 2
|
|
304
475
|
}, [e.$slots.startIcon ? {
|
|
305
476
|
name: "startIcon",
|
|
306
|
-
fn:
|
|
477
|
+
fn: B(({ iconSize: t }) => [F(e.$slots, "startIcon", { iconSize: t })]),
|
|
307
478
|
key: "0"
|
|
308
479
|
} : void 0, n.readOnly ? void 0 : {
|
|
309
480
|
name: "endIcon",
|
|
310
|
-
fn:
|
|
481
|
+
fn: B(({ iconSize: e }) => [O(o, {
|
|
311
482
|
size: e,
|
|
312
483
|
class: "d-filter-pill__icon",
|
|
313
484
|
"data-qa": "dt-filter-pill__icon"
|
|
@@ -322,23 +493,58 @@ function U(e, t, n, r, i, a) {
|
|
|
322
493
|
"size",
|
|
323
494
|
"onClick",
|
|
324
495
|
"onKeydown"
|
|
325
|
-
])), [[
|
|
496
|
+
])), [[h, a.resolvedStartTooltipText]])]),
|
|
326
497
|
_: 2
|
|
327
498
|
}, [
|
|
328
|
-
|
|
499
|
+
a.overlayUseDropdown ? void 0 : {
|
|
329
500
|
name: "content",
|
|
330
|
-
fn:
|
|
501
|
+
fn: B(({ close: t }) => [e.controlledAtBirth ? F(e.$slots, "content", M(A({ key: 0 }, e.controlledContentBindings)), () => [O(l, {
|
|
502
|
+
"model-value": e.checkboxRenderValues,
|
|
503
|
+
"aria-label": n.label,
|
|
504
|
+
name: n.label || "filter-pill",
|
|
505
|
+
disabled: !e.controlledCanSelect
|
|
506
|
+
}, {
|
|
507
|
+
default: B(() => [(N(!0), w(x, null, P(e.controlledState.options, (t) => (N(), S(c, {
|
|
508
|
+
id: e.controlledOptionId(t.value),
|
|
509
|
+
key: t.value,
|
|
510
|
+
label: t.label,
|
|
511
|
+
value: t.value,
|
|
512
|
+
"data-qa": "dt-filter-pill__checkbox",
|
|
513
|
+
"onUpdate:modelValue": (n) => e.toggleControlledOption(t.value, n)
|
|
514
|
+
}, {
|
|
515
|
+
default: B(() => [D(z(t.label) + " ", 1), e.$slots.optionEnd ? (N(), w("span", {
|
|
516
|
+
key: 0,
|
|
517
|
+
class: j(["d-filter-pill__option-end", n.optionEndClass])
|
|
518
|
+
}, [F(e.$slots, "optionEnd", {
|
|
519
|
+
option: t,
|
|
520
|
+
selected: e.controlledRowSelected(t.value)
|
|
521
|
+
})], 2)) : C("", !0)]),
|
|
522
|
+
_: 2
|
|
523
|
+
}, 1032, [
|
|
524
|
+
"id",
|
|
525
|
+
"label",
|
|
526
|
+
"value",
|
|
527
|
+
"onUpdate:modelValue"
|
|
528
|
+
]))), 128))]),
|
|
529
|
+
_: 3
|
|
530
|
+
}, 8, [
|
|
531
|
+
"model-value",
|
|
532
|
+
"aria-label",
|
|
533
|
+
"name",
|
|
534
|
+
"disabled"
|
|
535
|
+
])]) : F(e.$slots, "content", {
|
|
536
|
+
key: 1,
|
|
331
537
|
close: t,
|
|
332
538
|
apply: a.applySelection,
|
|
333
539
|
cancel: a.cancelSelection,
|
|
334
540
|
pendingFilters: i.pendingFilters
|
|
335
|
-
}, () => [n.modelValue?.length ? (
|
|
541
|
+
}, () => [n.modelValue?.length ? (N(), S(l, {
|
|
336
542
|
key: 0,
|
|
337
543
|
"model-value": n.deferSelection ? a.pendingActiveFilters : a.activeFilters,
|
|
338
544
|
"aria-label": n.label,
|
|
339
545
|
name: n.label || "filter-pill"
|
|
340
546
|
}, {
|
|
341
|
-
default:
|
|
547
|
+
default: B(() => [(N(!0), w(x, null, P(a.displayFilters, (e) => (N(), S(c, {
|
|
342
548
|
key: e.name,
|
|
343
549
|
label: e.name,
|
|
344
550
|
value: e.name,
|
|
@@ -353,68 +559,128 @@ function U(e, t, n, r, i, a) {
|
|
|
353
559
|
"model-value",
|
|
354
560
|
"aria-label",
|
|
355
561
|
"name"
|
|
356
|
-
])) :
|
|
562
|
+
])) : C("", !0)])]),
|
|
357
563
|
key: "0"
|
|
358
564
|
},
|
|
359
|
-
!
|
|
565
|
+
!a.overlayUseDropdown && e.$slots.headerContent ? {
|
|
360
566
|
name: "headerContent",
|
|
361
|
-
fn:
|
|
567
|
+
fn: B(({ close: t }) => [F(e.$slots, "headerContent", { close: e.controlledAtBirth ? e.closeControlled : t })]),
|
|
362
568
|
key: "1"
|
|
363
569
|
} : void 0,
|
|
364
|
-
!
|
|
570
|
+
!a.overlayUseDropdown && (n.deferSelection || e.$slots.footerContent) ? {
|
|
365
571
|
name: "footerContent",
|
|
366
|
-
fn:
|
|
367
|
-
close: t,
|
|
572
|
+
fn: B(({ close: t }) => [F(e.$slots, "footerContent", {
|
|
573
|
+
close: e.controlledAtBirth ? e.closeControlled : t,
|
|
368
574
|
apply: a.applySelection,
|
|
369
575
|
cancel: a.cancelSelection
|
|
370
|
-
}, () => [n.deferSelection ? (
|
|
576
|
+
}, () => [n.deferSelection ? (N(), S(u, {
|
|
371
577
|
key: 0,
|
|
372
578
|
direction: "row",
|
|
373
579
|
gap: "400",
|
|
374
580
|
justify: "end",
|
|
375
581
|
"data-qa": "dt-filter-pill__deferred-footer"
|
|
376
582
|
}, {
|
|
377
|
-
default:
|
|
583
|
+
default: B(() => [O(s, {
|
|
378
584
|
importance: "clear",
|
|
379
585
|
kind: "muted",
|
|
380
586
|
size: 200,
|
|
381
587
|
"data-qa": "dt-filter-pill__cancel-button",
|
|
382
588
|
onClick: a.cancelSelection
|
|
383
589
|
}, {
|
|
384
|
-
default:
|
|
590
|
+
default: B(() => [D(z(a.cancelButtonLabel), 1)]),
|
|
385
591
|
_: 1
|
|
386
|
-
}, 8, ["onClick"]),
|
|
592
|
+
}, 8, ["onClick"]), O(s, {
|
|
387
593
|
importance: "primary",
|
|
388
594
|
size: 200,
|
|
389
595
|
"data-qa": "dt-filter-pill__apply-button",
|
|
390
596
|
onClick: a.applySelection
|
|
391
597
|
}, {
|
|
392
|
-
default:
|
|
598
|
+
default: B(() => [D(z(a.applyButtonLabel), 1)]),
|
|
393
599
|
_: 1
|
|
394
600
|
}, 8, ["onClick"])]),
|
|
395
601
|
_: 1
|
|
396
|
-
})) :
|
|
602
|
+
})) : C("", !0)])]),
|
|
397
603
|
key: "2"
|
|
398
604
|
} : void 0,
|
|
399
|
-
|
|
605
|
+
a.overlayUseDropdown ? {
|
|
400
606
|
name: "list",
|
|
401
|
-
fn:
|
|
607
|
+
fn: B(({ close: t }) => [e.controlledAtBirth ? F(e.$slots, "content", M(A({ key: 0 }, e.controlledContentBindings)), () => [e.$slots.headerContent ? (N(), w("li", {
|
|
608
|
+
key: 0,
|
|
609
|
+
role: "presentation",
|
|
610
|
+
class: j(["d-filter-pill__menu-heading", n.headerContentClass])
|
|
611
|
+
}, [O(d, {
|
|
612
|
+
variant: "label-xs",
|
|
613
|
+
size: 100,
|
|
614
|
+
strength: "medium",
|
|
615
|
+
tone: "tertiary",
|
|
616
|
+
density: 500
|
|
617
|
+
}, {
|
|
618
|
+
default: B(() => [F(e.$slots, "headerContent")]),
|
|
619
|
+
_: 3
|
|
620
|
+
})], 2)) : C("", !0), (N(!0), w(x, null, P(e.controlledState.options, (t) => (N(), S(p, {
|
|
621
|
+
id: e.controlledOptionId(t.value),
|
|
622
|
+
key: t.value,
|
|
623
|
+
role: "menuitemradio",
|
|
624
|
+
"data-qa": "dt-filter-pill__option",
|
|
625
|
+
"navigation-type": "arrow-keys",
|
|
626
|
+
selected: e.controlledRowSelected(t.value),
|
|
627
|
+
"aria-disabled": !e.controlledCanSelect || void 0,
|
|
628
|
+
onClick: (n) => e.selectControlledOption(t.value)
|
|
629
|
+
}, E({
|
|
630
|
+
selected: B(() => [O(f, {
|
|
631
|
+
size: "200",
|
|
632
|
+
class: j({ "d-filter-pill__selection-indicator--hidden": !e.controlledRowSelected(t.value) }),
|
|
633
|
+
"aria-hidden": "true",
|
|
634
|
+
"data-qa": "dt-filter-pill__selection-indicator"
|
|
635
|
+
}, null, 8, ["class"])]),
|
|
636
|
+
default: B(() => [D(z(t.label) + " ", 1)]),
|
|
637
|
+
_: 2
|
|
638
|
+
}, [e.$slots.optionEnd ? {
|
|
639
|
+
name: "end",
|
|
640
|
+
fn: B(() => [T("span", { class: j(["d-filter-pill__option-end", n.optionEndClass]) }, [F(e.$slots, "optionEnd", {
|
|
641
|
+
option: t,
|
|
642
|
+
selected: e.controlledRowSelected(t.value)
|
|
643
|
+
})], 2)]),
|
|
644
|
+
key: "0"
|
|
645
|
+
} : void 0]), 1032, [
|
|
646
|
+
"id",
|
|
647
|
+
"selected",
|
|
648
|
+
"aria-disabled",
|
|
649
|
+
"onClick"
|
|
650
|
+
]))), 128))]) : F(e.$slots, "content", {
|
|
651
|
+
key: 1,
|
|
652
|
+
close: t
|
|
653
|
+
}, () => [(N(!0), w(x, null, P(i.filters, (e) => (N(), S(p, {
|
|
402
654
|
key: e.name,
|
|
403
655
|
role: "menuitem",
|
|
404
656
|
"navigation-type": "arrow-keys",
|
|
405
657
|
selected: e.active,
|
|
406
658
|
onClick: (n) => a.selectFilter(e, t)
|
|
407
659
|
}, {
|
|
408
|
-
|
|
660
|
+
selected: B(() => [O(f, {
|
|
661
|
+
size: "200",
|
|
662
|
+
class: j({ "d-filter-pill__selection-indicator--hidden": !e.active }),
|
|
663
|
+
"aria-hidden": "true",
|
|
664
|
+
"data-qa": "dt-filter-pill__selection-indicator"
|
|
665
|
+
}, null, 8, ["class"])]),
|
|
666
|
+
default: B(() => [D(z(e.name) + " ", 1)]),
|
|
409
667
|
_: 2
|
|
410
668
|
}, 1032, ["selected", "onClick"]))), 128))])]),
|
|
411
669
|
key: "3"
|
|
412
670
|
} : void 0
|
|
413
|
-
]), 1040, [
|
|
671
|
+
]), 1040, [
|
|
672
|
+
"open",
|
|
673
|
+
"aria-label",
|
|
674
|
+
"content-mode",
|
|
675
|
+
"onUpdate:open",
|
|
676
|
+
"onOpened",
|
|
677
|
+
"onKeydown"
|
|
678
|
+
])), a.hasClear ? V((N(), S(s, {
|
|
414
679
|
key: 0,
|
|
680
|
+
ref: "clearButton",
|
|
415
681
|
active: a.isActive,
|
|
416
682
|
"aria-label": a.clearButtonAriaLabel,
|
|
417
|
-
class:
|
|
683
|
+
class: j(["d-filter-pill__clear", { "d-filter-pill__clear--selected": a.isActive }]),
|
|
418
684
|
disabled: n.disabled,
|
|
419
685
|
kind: a.buttonKind,
|
|
420
686
|
size: n.size,
|
|
@@ -423,7 +689,7 @@ function U(e, t, n, r, i, a) {
|
|
|
423
689
|
importance: "outlined",
|
|
424
690
|
onClick: a.clearFilter
|
|
425
691
|
}, {
|
|
426
|
-
icon:
|
|
692
|
+
icon: B(() => [O(m, { size: a.clearIconSize }, null, 8, ["size"])]),
|
|
427
693
|
_: 1
|
|
428
694
|
}, 8, [
|
|
429
695
|
"active",
|
|
@@ -434,10 +700,10 @@ function U(e, t, n, r, i, a) {
|
|
|
434
700
|
"size",
|
|
435
701
|
"title",
|
|
436
702
|
"onClick"
|
|
437
|
-
])), [[
|
|
703
|
+
])), [[h, n.endTooltipText]]) : C("", !0)], 16);
|
|
438
704
|
}
|
|
439
|
-
var
|
|
705
|
+
var te = /* @__PURE__ */ r(q, [["render", ee]]);
|
|
440
706
|
//#endregion
|
|
441
|
-
export {
|
|
707
|
+
export { te as default };
|
|
442
708
|
|
|
443
709
|
//# sourceMappingURL=filter-pill.js.map
|