@uzum-tech/ui 2.4.2 → 2.4.3
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/index.js +162 -32
- package/dist/index.mjs +162 -32
- package/dist/index.prod.js +3 -3
- package/dist/index.prod.mjs +3 -3
- package/es/_internal/selection/src/Selection.d.ts +27 -0
- package/es/_internal/selection/src/Selection.mjs +54 -26
- package/es/_internal/selection/src/SelectionParts/CounterPlaceholder/CounterPlaceholder.d.ts +35 -0
- package/es/_internal/selection/src/SelectionParts/CounterPlaceholder/CounterPlaceholder.mjs +15 -0
- package/es/_internal/selection/src/SelectionParts/CounterPlaceholder/counter-placeholder.types.d.ts +17 -0
- package/es/_internal/selection/src/SelectionParts/CounterPlaceholder/counter-placeholder.types.mjs +16 -0
- package/es/_internal/selection/src/styles/index.cssr.mjs +45 -4
- package/es/_internal/selection/styles/light.d.ts +6 -0
- package/es/_internal/selection/styles/light.mjs +3 -0
- package/es/cascader/src/Cascader.d.ts +30 -0
- package/es/cascader/src/CascaderMenu.d.ts +6 -0
- package/es/cascader/src/CascaderOption.d.ts +6 -0
- package/es/cascader/src/CascaderSelectMenu.d.ts +6 -0
- package/es/cascader/src/CascaderSubmenu.d.ts +6 -0
- package/es/cascader/styles/light.d.ts +3 -0
- package/es/chat/src/Chat.d.ts +132 -0
- package/es/chat/src/ChatListItems.d.ts +45 -0
- package/es/chat/src/ChatMainArea.d.ts +45 -0
- package/es/chat/src/ChatMessages.d.ts +45 -0
- package/es/chat/src/ChatParts/ChatAttachmentButton/ChatAttachmentButton.d.ts +36 -0
- package/es/chat/src/ChatParts/ChatAttachmentButton/interface.d.ts +9 -0
- package/es/chat/src/ChatParts/ChatEditingBlock/ChatEditingBlock.d.ts +36 -0
- package/es/chat/src/ChatParts/ChatEditingBlock/interface.d.ts +9 -0
- package/es/chat/src/ChatParts/ChatHeader/ChatHeader.d.ts +36 -0
- package/es/chat/src/ChatParts/ChatHeader/interface.d.ts +9 -0
- package/es/chat/src/ChatParts/ChatLegacyInput/ChatLegacyInput.d.ts +36 -0
- package/es/chat/src/ChatParts/ChatLegacyInput/interface.d.ts +9 -0
- package/es/chat/src/ChatParts/Sidebar.d.ts +12 -0
- package/es/chat/src/interface.d.ts +9 -0
- package/es/chat/styles/dark.d.ts +3 -0
- package/es/chat/styles/light.d.ts +3 -0
- package/es/components.d.ts +453 -0
- package/es/data-table/src/DataTable.d.ts +24 -0
- package/es/data-table/src/HeaderButton/FilterButton.d.ts +12 -0
- package/es/data-table/src/HeaderButton/FilterMenu.d.ts +12 -0
- package/es/data-table/src/TableParts/Body.d.ts +12 -0
- package/es/data-table/src/TableParts/Header.d.ts +12 -0
- package/es/data-table/src/interface.d.ts +9 -0
- package/es/data-table/styles/light.d.ts +3 -0
- package/es/date-picker/src/DatePicker.d.ts +30 -0
- package/es/date-picker/src/panel/date.d.ts +6 -0
- package/es/date-picker/src/panel/daterange.d.ts +6 -0
- package/es/date-picker/src/panel/datetime.d.ts +6 -0
- package/es/date-picker/src/panel/datetimerange.d.ts +6 -0
- package/es/date-picker/src/panel/panelMonth.d.ts +24 -0
- package/es/date-picker/src/panel/panelMonthContent.d.ts +6 -0
- package/es/date-picker/src/panel/panelYear.d.ts +24 -0
- package/es/date-picker/src/panel/panelYearContent.d.ts +6 -0
- package/es/date-picker/src/panel/use-calendar.d.ts +6 -0
- package/es/date-picker/src/panel/use-dual-calendar.d.ts +6 -0
- package/es/date-picker/src/panel/use-panel-common.d.ts +6 -0
- package/es/date-picker/styles/light.d.ts +3 -0
- package/es/date-picker-v2/src/DatePickerV2.d.ts +30 -0
- package/es/date-picker-v2/styles/dark.d.ts +3 -0
- package/es/date-picker-v2/styles/light.d.ts +3 -0
- package/es/editor/src/Editor.d.ts +18 -0
- package/es/editor/src/EditorParts/EditorContent/EditorContent.d.ts +18 -0
- package/es/editor/src/EditorParts/EditorContent/interface.d.ts +9 -0
- package/es/editor/src/EditorParts/EditorToolbar/EditorToolbar.d.ts +21 -0
- package/es/editor/src/EditorParts/EditorToolbar/interface.d.ts +9 -0
- package/es/editor/src/interface.d.ts +9 -0
- package/es/editor/styles/dark.d.ts +3 -0
- package/es/editor/styles/light.d.ts +3 -0
- package/es/pagination/src/Pagination.d.ts +24 -0
- package/es/pagination/src/interface.d.ts +9 -0
- package/es/pagination/styles/light.d.ts +3 -0
- package/es/select/src/Select.d.ts +24 -0
- package/es/select/src/Select.mjs +2 -1
- package/es/select/src/interface.d.ts +10 -0
- package/es/select/src/interface.mjs +1 -0
- package/es/select/src/styles/index.cssr.mjs +4 -1
- package/es/select/styles/light.d.ts +3 -0
- package/es/tree-select/src/TreeSelect.d.ts +30 -0
- package/es/tree-select/styles/light.d.ts +3 -0
- package/es/version.d.ts +1 -1
- package/es/version.mjs +1 -1
- package/lib/_internal/selection/src/Selection.d.ts +27 -0
- package/lib/_internal/selection/src/Selection.js +43 -35
- package/lib/_internal/selection/src/SelectionParts/CounterPlaceholder/CounterPlaceholder.d.ts +35 -0
- package/lib/_internal/selection/src/SelectionParts/CounterPlaceholder/CounterPlaceholder.js +13 -0
- package/lib/_internal/selection/src/SelectionParts/CounterPlaceholder/counter-placeholder.types.d.ts +17 -0
- package/lib/_internal/selection/src/SelectionParts/CounterPlaceholder/counter-placeholder.types.js +19 -0
- package/lib/_internal/selection/src/styles/index.cssr.js +45 -4
- package/lib/_internal/selection/styles/light.d.ts +6 -0
- package/lib/_internal/selection/styles/light.js +3 -0
- package/lib/cascader/src/Cascader.d.ts +30 -0
- package/lib/cascader/src/CascaderMenu.d.ts +6 -0
- package/lib/cascader/src/CascaderOption.d.ts +6 -0
- package/lib/cascader/src/CascaderSelectMenu.d.ts +6 -0
- package/lib/cascader/src/CascaderSubmenu.d.ts +6 -0
- package/lib/cascader/styles/light.d.ts +3 -0
- package/lib/chat/src/Chat.d.ts +132 -0
- package/lib/chat/src/ChatListItems.d.ts +45 -0
- package/lib/chat/src/ChatMainArea.d.ts +45 -0
- package/lib/chat/src/ChatMessages.d.ts +45 -0
- package/lib/chat/src/ChatParts/ChatAttachmentButton/ChatAttachmentButton.d.ts +36 -0
- package/lib/chat/src/ChatParts/ChatAttachmentButton/interface.d.ts +9 -0
- package/lib/chat/src/ChatParts/ChatEditingBlock/ChatEditingBlock.d.ts +36 -0
- package/lib/chat/src/ChatParts/ChatEditingBlock/interface.d.ts +9 -0
- package/lib/chat/src/ChatParts/ChatHeader/ChatHeader.d.ts +36 -0
- package/lib/chat/src/ChatParts/ChatHeader/interface.d.ts +9 -0
- package/lib/chat/src/ChatParts/ChatLegacyInput/ChatLegacyInput.d.ts +36 -0
- package/lib/chat/src/ChatParts/ChatLegacyInput/interface.d.ts +9 -0
- package/lib/chat/src/ChatParts/Sidebar.d.ts +12 -0
- package/lib/chat/src/interface.d.ts +9 -0
- package/lib/chat/styles/dark.d.ts +3 -0
- package/lib/chat/styles/light.d.ts +3 -0
- package/lib/components.d.ts +453 -0
- package/lib/data-table/src/DataTable.d.ts +24 -0
- package/lib/data-table/src/HeaderButton/FilterButton.d.ts +12 -0
- package/lib/data-table/src/HeaderButton/FilterMenu.d.ts +12 -0
- package/lib/data-table/src/TableParts/Body.d.ts +12 -0
- package/lib/data-table/src/TableParts/Header.d.ts +12 -0
- package/lib/data-table/src/interface.d.ts +9 -0
- package/lib/data-table/styles/light.d.ts +3 -0
- package/lib/date-picker/src/DatePicker.d.ts +30 -0
- package/lib/date-picker/src/panel/date.d.ts +6 -0
- package/lib/date-picker/src/panel/daterange.d.ts +6 -0
- package/lib/date-picker/src/panel/datetime.d.ts +6 -0
- package/lib/date-picker/src/panel/datetimerange.d.ts +6 -0
- package/lib/date-picker/src/panel/panelMonth.d.ts +24 -0
- package/lib/date-picker/src/panel/panelMonthContent.d.ts +6 -0
- package/lib/date-picker/src/panel/panelYear.d.ts +24 -0
- package/lib/date-picker/src/panel/panelYearContent.d.ts +6 -0
- package/lib/date-picker/src/panel/use-calendar.d.ts +6 -0
- package/lib/date-picker/src/panel/use-dual-calendar.d.ts +6 -0
- package/lib/date-picker/src/panel/use-panel-common.d.ts +6 -0
- package/lib/date-picker/styles/light.d.ts +3 -0
- package/lib/date-picker-v2/src/DatePickerV2.d.ts +30 -0
- package/lib/date-picker-v2/styles/dark.d.ts +3 -0
- package/lib/date-picker-v2/styles/light.d.ts +3 -0
- package/lib/editor/src/Editor.d.ts +18 -0
- package/lib/editor/src/EditorParts/EditorContent/EditorContent.d.ts +18 -0
- package/lib/editor/src/EditorParts/EditorContent/interface.d.ts +9 -0
- package/lib/editor/src/EditorParts/EditorToolbar/EditorToolbar.d.ts +21 -0
- package/lib/editor/src/EditorParts/EditorToolbar/interface.d.ts +9 -0
- package/lib/editor/src/interface.d.ts +9 -0
- package/lib/editor/styles/dark.d.ts +3 -0
- package/lib/editor/styles/light.d.ts +3 -0
- package/lib/pagination/src/Pagination.d.ts +24 -0
- package/lib/pagination/src/interface.d.ts +9 -0
- package/lib/pagination/styles/light.d.ts +3 -0
- package/lib/select/src/Select.d.ts +24 -0
- package/lib/select/src/Select.js +5 -2
- package/lib/select/src/interface.d.ts +10 -0
- package/lib/select/src/interface.js +1 -1
- package/lib/select/src/styles/index.cssr.js +3 -0
- package/lib/select/styles/light.d.ts +3 -0
- package/lib/tree-select/src/TreeSelect.d.ts +30 -0
- package/lib/tree-select/styles/light.d.ts +3 -0
- package/lib/version.d.ts +1 -1
- package/lib/version.js +1 -1
- package/package.json +1 -1
- package/web-types.json +11 -1
package/dist/index.mjs
CHANGED
|
@@ -27921,8 +27921,11 @@ function self$1s(vars) {
|
|
|
27921
27921
|
caretColorSecondary: elementsPrimary,
|
|
27922
27922
|
filterCounterTextColor: textSecondary,
|
|
27923
27923
|
filterCounterTextColorDisabled: textSecondary,
|
|
27924
|
+
filterCounterGap: "8px",
|
|
27925
|
+
filterSuffixWrapperGap: "4px",
|
|
27924
27926
|
arrowColorSecondary: elementsSecondary,
|
|
27925
27927
|
clearColorSecondary: elementsSecondary,
|
|
27928
|
+
loadingColorSecondary: elementsSecondary,
|
|
27926
27929
|
colorSecondary: elementsPrimary,
|
|
27927
27930
|
textColorSecondary: textQuaternary,
|
|
27928
27931
|
borderSecondary: "none",
|
|
@@ -27975,6 +27978,44 @@ cB("base-selection", [cM("rtl", `
|
|
|
27975
27978
|
left: 10px;
|
|
27976
27979
|
`)])]);
|
|
27977
27980
|
|
|
27981
|
+
const counterPlaceholderProps = {
|
|
27982
|
+
clsPrefix: {
|
|
27983
|
+
type: String,
|
|
27984
|
+
required: true
|
|
27985
|
+
},
|
|
27986
|
+
placeholder: {
|
|
27987
|
+
type: String,
|
|
27988
|
+
default: ""
|
|
27989
|
+
},
|
|
27990
|
+
placeholderHidden: {
|
|
27991
|
+
type: Boolean
|
|
27992
|
+
},
|
|
27993
|
+
input: {
|
|
27994
|
+
type: Object
|
|
27995
|
+
}
|
|
27996
|
+
};
|
|
27997
|
+
|
|
27998
|
+
var CounterPlaceholder = defineComponent({
|
|
27999
|
+
name: "CounterPlaceholder",
|
|
28000
|
+
props: counterPlaceholderProps,
|
|
28001
|
+
render() {
|
|
28002
|
+
return /* @__PURE__ */ h$1(
|
|
28003
|
+
"div",
|
|
28004
|
+
{
|
|
28005
|
+
class: `${this.clsPrefix}-base-selection-placeholder ${this.clsPrefix}-base-selection__counter-placeholder`
|
|
28006
|
+
},
|
|
28007
|
+
/* @__PURE__ */ h$1(
|
|
28008
|
+
"span",
|
|
28009
|
+
{
|
|
28010
|
+
style: this.placeholderHidden ? { visibility: "hidden" } : void 0
|
|
28011
|
+
},
|
|
28012
|
+
this.placeholder
|
|
28013
|
+
),
|
|
28014
|
+
this.input
|
|
28015
|
+
);
|
|
28016
|
+
}
|
|
28017
|
+
});
|
|
28018
|
+
|
|
27978
28019
|
function generateSecondaryStates(state) {
|
|
27979
28020
|
return [cB("base-selection-input", `
|
|
27980
28021
|
color: var(--u-text-color${state}-secondary);
|
|
@@ -27988,6 +28029,8 @@ function generateSecondaryStates(state) {
|
|
|
27988
28029
|
`)]), cB("base-selection-tags", `
|
|
27989
28030
|
background-color: var(--u-color${state}-secondary);
|
|
27990
28031
|
color: var(--u-text-color${state}-secondary);
|
|
28032
|
+
`), cB("base-selection-placeholder", `
|
|
28033
|
+
color: var(--u-text-color${state}-secondary);
|
|
27991
28034
|
`), cE("border,state-border", `
|
|
27992
28035
|
border: var(--u-border${state}-secondary);
|
|
27993
28036
|
`), cB("base-clear", [cE("clear", `
|
|
@@ -28035,12 +28078,11 @@ var style$1H = c$1([cB("base-selection", `
|
|
|
28035
28078
|
top: 50%;
|
|
28036
28079
|
transform: translateY(-50%);
|
|
28037
28080
|
right: var(--u-padding-right);
|
|
28081
|
+
gap: var(--u-suffix-wrapper-gap);
|
|
28038
28082
|
`, [cB("base-clear", `
|
|
28039
28083
|
font-size: var(--u-clear-size);
|
|
28040
28084
|
`)]), cE("filter-counter", `
|
|
28041
|
-
width:
|
|
28042
|
-
margin-left: 6px;
|
|
28043
|
-
padding-left: 2px;
|
|
28085
|
+
width: 13px;
|
|
28044
28086
|
text-align: center;
|
|
28045
28087
|
color: var(--u-filter-counter-text-color);
|
|
28046
28088
|
`), cB("base-suffix", `
|
|
@@ -28130,6 +28172,8 @@ var style$1H = c$1([cB("base-selection", `
|
|
|
28130
28172
|
color: var(--u-text-color);
|
|
28131
28173
|
`)]), cNotM("disabled", [cM("secondary", [cB("base-selection-placeholder", `
|
|
28132
28174
|
color: var(--u-text-color);
|
|
28175
|
+
`)]), cM("secondary-selected", [cB("base-selection-placeholder", `
|
|
28176
|
+
color: var(--u-text-color-secondary);
|
|
28133
28177
|
`)]), c$1("&:hover", [cE("state-border", `
|
|
28134
28178
|
box-shadow: var(--u-box-shadow-hover);
|
|
28135
28179
|
border: var(--u-border-hover);
|
|
@@ -28219,6 +28263,8 @@ var style$1H = c$1([cB("base-selection", `
|
|
|
28219
28263
|
caret-color: var(--u-caret-color-secondary);
|
|
28220
28264
|
`), cB("base-selection-tags", `
|
|
28221
28265
|
padding-right: calc(var(--u-padding-right) + var(--u-arrow-size) + 37px + var(--u-clear-size));
|
|
28266
|
+
`), cB("base-loading", `
|
|
28267
|
+
color: var(--u-loading-color-secondary);
|
|
28222
28268
|
`), cNotM("disabled", [c$1("&:hover", [generateSecondaryStates("-hover"), cB("base-clear", "--u-clear-color-hover: var(--u-clear-color-hover-secondary)")]), cM("focus", [generateSecondaryStates("-focus")]), cM("active", [generateSecondaryStates("-active")])])]), ["warning", "error"].map(status => cM(`${status}-status`, [cE("state-border", `border: var(--u-border-${status});`), cNotM("secondary-selected", [cNotM("disabled", [cNotM("filled", [cM("active", [cB("base-selection-label", `background-color: var(--u-color-active-${status});`), cB("base-selection-tags", `background-color: var(--u-color-active-${status});`)])])])]), cNotM("disabled", [cM("active", [cE("state-border", `
|
|
28223
28269
|
box-shadow: var(--u-box-shadow-active-${status});
|
|
28224
28270
|
border: var(--u-border-active-${status});
|
|
@@ -28237,7 +28283,42 @@ var style$1H = c$1([cB("base-selection", `
|
|
|
28237
28283
|
zIndex: 2,
|
|
28238
28284
|
borderRadius: "var(--u-border-radius)",
|
|
28239
28285
|
cursor: "wait"
|
|
28240
|
-
})])
|
|
28286
|
+
})]), cM("auto-width", [cB("base-selection-label, base-selection-tags", `
|
|
28287
|
+
width: 0;
|
|
28288
|
+
min-width: 100%;
|
|
28289
|
+
`), cE("sizer", `
|
|
28290
|
+
position: static;
|
|
28291
|
+
display: block;
|
|
28292
|
+
height: 0;
|
|
28293
|
+
padding-top: 0;
|
|
28294
|
+
padding-bottom: 0;
|
|
28295
|
+
overflow: hidden;
|
|
28296
|
+
visibility: hidden;
|
|
28297
|
+
`, [cB("base-account-option", [cE("wrap", `
|
|
28298
|
+
width: auto;
|
|
28299
|
+
flex-grow: 0;
|
|
28300
|
+
`)])]), cNotM("secondary-selected", [cB("base-selection-placeholder", `
|
|
28301
|
+
padding-right: calc(var(--u-padding-right) + var(--u-arrow-size) + 8px);
|
|
28302
|
+
`)]), cM("counter-selected", [cB("base-selection-tags", "width: auto;")])]), cM("counter-selected", [cB("base-selection-tags", `
|
|
28303
|
+
flex-wrap: nowrap;
|
|
28304
|
+
gap: var(--u-filter-counter-gap);
|
|
28305
|
+
padding-right: var(--u-padding-right);
|
|
28306
|
+
`), cE("counter-placeholder", `
|
|
28307
|
+
position: relative;
|
|
28308
|
+
flex: 1 1 auto;
|
|
28309
|
+
min-width: 0;
|
|
28310
|
+
white-space: nowrap;
|
|
28311
|
+
overflow: hidden;
|
|
28312
|
+
text-overflow: ellipsis;
|
|
28313
|
+
`, [cB("base-selection-input-tag", `
|
|
28314
|
+
position: absolute;
|
|
28315
|
+
top: 0;
|
|
28316
|
+
left: 0;
|
|
28317
|
+
`)]), cE("suffix-wrapper", `
|
|
28318
|
+
position: static;
|
|
28319
|
+
transform: none;
|
|
28320
|
+
flex-shrink: 0;
|
|
28321
|
+
`)])]), cB("base-selection-popover", `
|
|
28241
28322
|
margin-bottom: -3px;
|
|
28242
28323
|
display: flex;
|
|
28243
28324
|
flex-wrap: wrap;
|
|
@@ -28328,6 +28409,7 @@ var UInternalSelection = defineComponent({
|
|
|
28328
28409
|
round: Boolean,
|
|
28329
28410
|
counter: Boolean,
|
|
28330
28411
|
secondary: Boolean,
|
|
28412
|
+
autoWidth: Boolean,
|
|
28331
28413
|
account: Boolean
|
|
28332
28414
|
},
|
|
28333
28415
|
setup(props) {
|
|
@@ -28674,6 +28756,7 @@ var UInternalSelection = defineComponent({
|
|
|
28674
28756
|
// secondary
|
|
28675
28757
|
arrowColorSecondary,
|
|
28676
28758
|
clearColorSecondary,
|
|
28759
|
+
loadingColorSecondary,
|
|
28677
28760
|
colorSecondary,
|
|
28678
28761
|
textColorSecondary,
|
|
28679
28762
|
borderSecondary,
|
|
@@ -28689,6 +28772,8 @@ var UInternalSelection = defineComponent({
|
|
|
28689
28772
|
borderHoverSecondary,
|
|
28690
28773
|
filterCounterTextColor,
|
|
28691
28774
|
filterCounterTextColorDisabled,
|
|
28775
|
+
filterCounterGap,
|
|
28776
|
+
filterSuffixWrapperGap,
|
|
28692
28777
|
caretColorSecondary,
|
|
28693
28778
|
arrowColorActiveSecondary,
|
|
28694
28779
|
clearColorActiveSecondary,
|
|
@@ -28783,8 +28868,11 @@ var UInternalSelection = defineComponent({
|
|
|
28783
28868
|
"--u-caret-color-secondary": caretColorSecondary,
|
|
28784
28869
|
"--u-filter-counter-text-color": filterCounterTextColor,
|
|
28785
28870
|
"--u-filter-counter-text-color-disabled": filterCounterTextColorDisabled,
|
|
28871
|
+
"--u-filter-counter-gap": filterCounterGap,
|
|
28872
|
+
"--u-suffix-wrapper-gap": filterSuffixWrapperGap,
|
|
28786
28873
|
"--u-arrow-color-secondary": arrowColorSecondary,
|
|
28787
28874
|
"--u-clear-color-secondary": clearColorSecondary,
|
|
28875
|
+
"--u-loading-color-secondary": loadingColorSecondary,
|
|
28788
28876
|
"--u-color-secondary": colorSecondary,
|
|
28789
28877
|
"--u-text-color-secondary": textColorSecondary,
|
|
28790
28878
|
"--u-border-secondary": borderSecondary,
|
|
@@ -28896,7 +28984,16 @@ var UInternalSelection = defineComponent({
|
|
|
28896
28984
|
const maxTagCountNumeric = typeof maxTagCount === "number";
|
|
28897
28985
|
const useMaxTagCount = maxTagCountResponsive || maxTagCountNumeric;
|
|
28898
28986
|
const filterCounterEl = this.filterCounterVisible && !this.disabled ? /* @__PURE__ */ h$1("div", { class: [`${clsPrefix}-base-selection__filter-counter`] }, this.filterCounterLength) : null;
|
|
28899
|
-
const clear = this.
|
|
28987
|
+
const clear = this.filterCounterVisible && this.loading ? /* @__PURE__ */ h$1(
|
|
28988
|
+
UBaseLoading,
|
|
28989
|
+
{
|
|
28990
|
+
clsPrefix,
|
|
28991
|
+
class: `${clsPrefix}-base-suffix`,
|
|
28992
|
+
strokeWidth: 24,
|
|
28993
|
+
scale: 0.85,
|
|
28994
|
+
show: true
|
|
28995
|
+
}
|
|
28996
|
+
) : this.filterCounterClearable ? /* @__PURE__ */ h$1(
|
|
28900
28997
|
UBaseClear,
|
|
28901
28998
|
{
|
|
28902
28999
|
clsPrefix,
|
|
@@ -28904,22 +29001,35 @@ var UInternalSelection = defineComponent({
|
|
|
28904
29001
|
onClear: this.handleClear
|
|
28905
29002
|
}
|
|
28906
29003
|
) : null;
|
|
29004
|
+
const suffixShowArrow = this.showArrow || this.counter && this.filterCounterLength === 0;
|
|
29005
|
+
const suffixLoading = this.loading && !this.filterCounterVisible;
|
|
28907
29006
|
const suffix = /* @__PURE__ */ h$1(Wrapper, null, {
|
|
28908
|
-
default: () => /* @__PURE__ */ h$1("div", { class: [`${clsPrefix}-base-selection__suffix-wrapper`] }, /* @__PURE__ */ h$1(
|
|
29007
|
+
default: () => /* @__PURE__ */ h$1("div", { class: [`${clsPrefix}-base-selection__suffix-wrapper`] }, suffixShowArrow ? /* @__PURE__ */ h$1(
|
|
28909
29008
|
Suffix,
|
|
28910
29009
|
{
|
|
28911
29010
|
clsPrefix,
|
|
28912
|
-
loading:
|
|
28913
|
-
showArrow:
|
|
29011
|
+
loading: suffixLoading,
|
|
29012
|
+
showArrow: suffixShowArrow,
|
|
28914
29013
|
showClear: this.showSuffixClear,
|
|
28915
29014
|
onClear: this.handleClear
|
|
28916
29015
|
},
|
|
28917
29016
|
{
|
|
28918
29017
|
default: () => [this.$slots.arrow?.()]
|
|
28919
29018
|
}
|
|
28920
|
-
), filterCounterEl, clear)
|
|
29019
|
+
) : null, filterCounterEl, clear)
|
|
28921
29020
|
});
|
|
28922
29021
|
let body;
|
|
29022
|
+
const renderVisibleLabel = () => {
|
|
29023
|
+
if (renderTag) {
|
|
29024
|
+
return renderTag({
|
|
29025
|
+
option: this.selectedOption,
|
|
29026
|
+
handleClose: () => {
|
|
29027
|
+
}
|
|
29028
|
+
});
|
|
29029
|
+
}
|
|
29030
|
+
const label = renderLabel ? renderLabel(this.selectedOption, true) : render$2(this.label, this.selectedOption, true);
|
|
29031
|
+
return account ? /* @__PURE__ */ h$1(UBaseAccountOption, { ...this.selectedOption, label }) : label;
|
|
29032
|
+
};
|
|
28923
29033
|
if (multiple) {
|
|
28924
29034
|
const { labelField } = this;
|
|
28925
29035
|
const createTag = (option) => {
|
|
@@ -29034,7 +29144,7 @@ var UInternalSelection = defineComponent({
|
|
|
29034
29144
|
);
|
|
29035
29145
|
}
|
|
29036
29146
|
}
|
|
29037
|
-
const tags = this.filterCounterVisible ?
|
|
29147
|
+
const tags = this.filterCounterVisible ? null : maxTagCountResponsive ? filterable ? /* @__PURE__ */ h$1(
|
|
29038
29148
|
VOverflow,
|
|
29039
29149
|
{
|
|
29040
29150
|
ref: "overflowRef",
|
|
@@ -29081,7 +29191,7 @@ var UInternalSelection = defineComponent({
|
|
|
29081
29191
|
themeOverrides: this.mergedTheme.peerOverrides.Popover,
|
|
29082
29192
|
...ellipsisTagPopoverProps
|
|
29083
29193
|
} : null;
|
|
29084
|
-
const showPlaceholder = this.selected ? false : this.active ? !this.pattern && !this.isComposing : true;
|
|
29194
|
+
const showPlaceholder = this.selected && !this.filterCounterVisible ? false : this.active ? !this.pattern && !this.isComposing : true;
|
|
29085
29195
|
const placeholder = showPlaceholder ? /* @__PURE__ */ h$1(
|
|
29086
29196
|
"div",
|
|
29087
29197
|
{
|
|
@@ -29089,14 +29199,24 @@ var UInternalSelection = defineComponent({
|
|
|
29089
29199
|
},
|
|
29090
29200
|
/* @__PURE__ */ h$1("div", { class: `${clsPrefix}-base-selection-placeholder__inner` }, this.placeholder)
|
|
29091
29201
|
) : null;
|
|
29202
|
+
const counterPlaceholderHidden = !!(this.pattern || this.isComposing);
|
|
29203
|
+
const counterPlaceholder = this.filterCounterVisible ? /* @__PURE__ */ h$1(
|
|
29204
|
+
CounterPlaceholder,
|
|
29205
|
+
{
|
|
29206
|
+
clsPrefix,
|
|
29207
|
+
placeholder: this.placeholder,
|
|
29208
|
+
"placeholder-hidden": counterPlaceholderHidden,
|
|
29209
|
+
input
|
|
29210
|
+
}
|
|
29211
|
+
) : null;
|
|
29092
29212
|
const popoverTrigger = filterable ? /* @__PURE__ */ h$1(
|
|
29093
29213
|
"div",
|
|
29094
29214
|
{
|
|
29095
29215
|
ref: "patternInputWrapperRef",
|
|
29096
29216
|
class: `${clsPrefix}-base-selection-tags`
|
|
29097
29217
|
},
|
|
29098
|
-
tags,
|
|
29099
|
-
maxTagCountResponsive ? null : input,
|
|
29218
|
+
counterPlaceholder ?? tags,
|
|
29219
|
+
counterPlaceholder || maxTagCountResponsive ? null : input,
|
|
29100
29220
|
suffix
|
|
29101
29221
|
) : /* @__PURE__ */ h$1(
|
|
29102
29222
|
"div",
|
|
@@ -29105,7 +29225,7 @@ var UInternalSelection = defineComponent({
|
|
|
29105
29225
|
class: `${clsPrefix}-base-selection-tags`,
|
|
29106
29226
|
tabindex: disabled ? void 0 : 0
|
|
29107
29227
|
},
|
|
29108
|
-
tags,
|
|
29228
|
+
counterPlaceholder ?? tags,
|
|
29109
29229
|
suffix
|
|
29110
29230
|
);
|
|
29111
29231
|
body = /* @__PURE__ */ h$1(Fragment$1, null, useMaxTagCount ? /* @__PURE__ */ h$1(
|
|
@@ -29119,13 +29239,8 @@ var UInternalSelection = defineComponent({
|
|
|
29119
29239
|
trigger: () => popoverTrigger,
|
|
29120
29240
|
default: renderPopover
|
|
29121
29241
|
}
|
|
29122
|
-
) : popoverTrigger, placeholder);
|
|
29242
|
+
) : popoverTrigger, counterPlaceholder ? null : placeholder);
|
|
29123
29243
|
} else {
|
|
29124
|
-
let children;
|
|
29125
|
-
if (this.label !== void 0) {
|
|
29126
|
-
const label = renderLabel ? renderLabel(this.selectedOption, true) : render$2(this.label, this.selectedOption, true);
|
|
29127
|
-
children = account && /* @__PURE__ */ h$1(UBaseAccountOption, { ...this.selectedOption, label }) || label;
|
|
29128
|
-
}
|
|
29129
29244
|
if (filterable) {
|
|
29130
29245
|
const hasInput = this.pattern || this.isComposing;
|
|
29131
29246
|
const isAccountFocused = this.patternInputFocused && this.account;
|
|
@@ -29162,11 +29277,7 @@ var UInternalSelection = defineComponent({
|
|
|
29162
29277
|
class: `${clsPrefix}-base-selection-label__render-label ${clsPrefix}-base-selection-overlay`,
|
|
29163
29278
|
key: "input"
|
|
29164
29279
|
},
|
|
29165
|
-
/* @__PURE__ */ h$1("div", { class: `${clsPrefix}-base-selection-overlay__wrapper` },
|
|
29166
|
-
option: this.selectedOption,
|
|
29167
|
-
handleClose: () => {
|
|
29168
|
-
}
|
|
29169
|
-
}) : children)
|
|
29280
|
+
/* @__PURE__ */ h$1("div", { class: `${clsPrefix}-base-selection-overlay__wrapper` }, renderVisibleLabel())
|
|
29170
29281
|
) : null,
|
|
29171
29282
|
showPlaceholder ? /* @__PURE__ */ h$1(
|
|
29172
29283
|
"div",
|
|
@@ -29193,11 +29304,7 @@ var UInternalSelection = defineComponent({
|
|
|
29193
29304
|
title: getTitleAttribute(this.label),
|
|
29194
29305
|
key: "input"
|
|
29195
29306
|
},
|
|
29196
|
-
/* @__PURE__ */ h$1("div", { class: `${clsPrefix}-base-selection-input__content` },
|
|
29197
|
-
option: this.selectedOption,
|
|
29198
|
-
handleClose: () => {
|
|
29199
|
-
}
|
|
29200
|
-
}) : children)
|
|
29307
|
+
/* @__PURE__ */ h$1("div", { class: `${clsPrefix}-base-selection-input__content` }, renderVisibleLabel())
|
|
29201
29308
|
) : /* @__PURE__ */ h$1(
|
|
29202
29309
|
"div",
|
|
29203
29310
|
{
|
|
@@ -29222,10 +29329,12 @@ var UInternalSelection = defineComponent({
|
|
|
29222
29329
|
[`${clsPrefix}-base-selection--active`]: this.active,
|
|
29223
29330
|
[`${clsPrefix}-base-selection--secondary`]: this.secondary,
|
|
29224
29331
|
[`${clsPrefix}-base-selection--secondary-selected`]: this.secondary && this.selected,
|
|
29332
|
+
[`${clsPrefix}-base-selection--counter-selected`]: this.filterCounterVisible,
|
|
29225
29333
|
[`${clsPrefix}-base-selection--selected`]: this.selected || this.active && this.pattern,
|
|
29226
29334
|
[`${clsPrefix}-base-selection--disabled`]: this.disabled,
|
|
29227
29335
|
[`${clsPrefix}-base-selection--multiple`]: this.multiple,
|
|
29228
29336
|
[`${clsPrefix}-base-selection--filled`]: this.filled,
|
|
29337
|
+
[`${clsPrefix}-base-selection--auto-width`]: this.autoWidth,
|
|
29229
29338
|
[`${clsPrefix}-base-selection--skeleton`]: this.loadingSkeleton,
|
|
29230
29339
|
// focus is not controlled by selection itself since it always need
|
|
29231
29340
|
// to be managed together with menu. provide :focus style will cause
|
|
@@ -29254,6 +29363,19 @@ var UInternalSelection = defineComponent({
|
|
|
29254
29363
|
}
|
|
29255
29364
|
) : [
|
|
29256
29365
|
body,
|
|
29366
|
+
this.autoWidth ? /* @__PURE__ */ h$1(
|
|
29367
|
+
"div",
|
|
29368
|
+
{
|
|
29369
|
+
"aria-hidden": "true",
|
|
29370
|
+
class: [
|
|
29371
|
+
`${clsPrefix}-base-selection-overlay`,
|
|
29372
|
+
`${clsPrefix}-base-selection-placeholder`,
|
|
29373
|
+
`${clsPrefix}-base-selection__sizer`
|
|
29374
|
+
]
|
|
29375
|
+
},
|
|
29376
|
+
/* @__PURE__ */ h$1("div", null, this.placeholder),
|
|
29377
|
+
!this.multiple && this.selectedOption ? /* @__PURE__ */ h$1("div", null, renderVisibleLabel()) : null
|
|
29378
|
+
) : null,
|
|
29257
29379
|
bordered ? /* @__PURE__ */ h$1("div", { class: `${clsPrefix}-base-selection__border` }) : null,
|
|
29258
29380
|
bordered ? /* @__PURE__ */ h$1("div", { class: `${clsPrefix}-base-selection__state-border` }) : null
|
|
29259
29381
|
]
|
|
@@ -83643,6 +83765,7 @@ const selectProps = {
|
|
|
83643
83765
|
round: Boolean,
|
|
83644
83766
|
counter: Boolean,
|
|
83645
83767
|
secondary: Boolean,
|
|
83768
|
+
autoWidth: Boolean,
|
|
83646
83769
|
/** deprecated */
|
|
83647
83770
|
onChange: [Function, Array],
|
|
83648
83771
|
items: Array,
|
|
@@ -83656,6 +83779,9 @@ var style$14 = c$1([cB("select", `
|
|
|
83656
83779
|
position: relative;
|
|
83657
83780
|
`, [cE("trigger-wrapper", `
|
|
83658
83781
|
width: 100%;
|
|
83782
|
+
`), cM("auto-width", `
|
|
83783
|
+
width: fit-content;
|
|
83784
|
+
max-width: 100%;
|
|
83659
83785
|
`)]), cB("select-menu", `
|
|
83660
83786
|
margin: 4px 0;
|
|
83661
83787
|
box-shadow: var(--u-menu-box-shadow);
|
|
@@ -84466,7 +84592,10 @@ var _USelect = defineComponent({
|
|
|
84466
84592
|
"div",
|
|
84467
84593
|
{
|
|
84468
84594
|
ref: "selfElRef",
|
|
84469
|
-
class:
|
|
84595
|
+
class: [
|
|
84596
|
+
`${this.mergedClsPrefix}-select`,
|
|
84597
|
+
this.autoWidth && `${this.mergedClsPrefix}-select--auto-width`
|
|
84598
|
+
],
|
|
84470
84599
|
onKeydown: this.$slots.trigger ? this.handleSelfKeydown : void 0
|
|
84471
84600
|
},
|
|
84472
84601
|
/* @__PURE__ */ h$1(Binder, null, {
|
|
@@ -84537,6 +84666,7 @@ var _USelect = defineComponent({
|
|
|
84537
84666
|
round: this.round,
|
|
84538
84667
|
counter: this.counter,
|
|
84539
84668
|
secondary: this.secondary,
|
|
84669
|
+
autoWidth: this.autoWidth,
|
|
84540
84670
|
account: this.account,
|
|
84541
84671
|
tagField: this.tagField,
|
|
84542
84672
|
renderTagLabel: this.renderTagLabel,
|
|
@@ -154773,7 +154903,7 @@ function useThemeVars() {
|
|
|
154773
154903
|
});
|
|
154774
154904
|
}
|
|
154775
154905
|
|
|
154776
|
-
var version = "2.4.
|
|
154906
|
+
var version = "2.4.3";
|
|
154777
154907
|
|
|
154778
154908
|
function create({
|
|
154779
154909
|
componentPrefix = "U",
|