@shtabapp/ui-kit 1.74.0 → 1.76.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/CHANGELOG.md +26 -0
- package/dist/{SButton-CLTNdnCK.cjs → SButton-BCgdXE_B.cjs} +1 -1
- package/dist/{SButton-LAOBxpd4.js → SButton-DIWMMCSc.js} +1 -0
- package/dist/{SButtonGroup-DPq5g7bZ.js → SButtonGroup-BqW5Rz1p.js} +0 -2
- package/dist/{SButtonGroup-Co1AUbsm.cjs → SButtonGroup-DSi8mQSz.cjs} +1 -1
- package/dist/{SCard-DKZYyR5b.cjs → SCard-B210wsTH.cjs} +1 -1
- package/dist/{SCard-DgGxjBUV.js → SCard-DJuyINB7.js} +1 -1
- package/dist/SChartBar-BvytQ-2z.js +293 -0
- package/dist/SChartBar-BzCeNCsi.cjs +1 -0
- package/dist/SChartBurnup-BeQWgnGT.js +261 -0
- package/dist/SChartBurnup-joKIDLFb.cjs +1 -0
- package/dist/SChartHorizontalBar-C40Yroue.js +176 -0
- package/dist/SChartHorizontalBar-Dwln3uuE.cjs +1 -0
- package/dist/SChartLegend-D1gPKGm0.cjs +1 -0
- package/dist/SChartLegend-dDqLhvIj.js +88 -0
- package/dist/{SChartLine-v0tkmnN6.js → SChartLine-BV8Ytso5.js} +36 -36
- package/dist/{SChartLine-3l507dBg.cjs → SChartLine-DeJjaBmo.cjs} +1 -1
- package/dist/SChartMultiLine-7_HcvVEQ.js +279 -0
- package/dist/SChartMultiLine-Cl9Pf3Wp.cjs +1 -0
- package/dist/SChartPie-BiLoxutQ.js +267 -0
- package/dist/SChartPie-DccW5J0b.cjs +1 -0
- package/dist/{SChartProgress-9Zzy7E8K.cjs → SChartProgress-Cpdkad6Q.cjs} +1 -1
- package/dist/{SChartProgress-DUgSOdv7.js → SChartProgress-DSxJqRA0.js} +27 -27
- package/dist/{SChartStackedArea-Blpqa23h.js → SChartStackedArea-B28offwE.js} +44 -44
- package/dist/{SChartStackedArea-C3MezV9k.cjs → SChartStackedArea-Ce7xyhp1.cjs} +1 -1
- package/dist/{SChartStackedBar-CCxEXw1H.js → SChartStackedBar-C77FlKGS.js} +55 -55
- package/dist/{SChartStackedBar-CJ-UdOfv.cjs → SChartStackedBar-CqUDrFJ3.cjs} +1 -1
- package/dist/SCheckbox-Dkbk21Id.cjs +1 -0
- package/dist/SCheckbox-Dulusx5v.js +105 -0
- package/dist/{SChip-Dcvk3JI8.cjs → SChip-BCB1bvua.cjs} +1 -1
- package/dist/{SChip-NDTK29yq.js → SChip-C6d9oIYL.js} +1 -1
- package/dist/{SColorPicker-Ct8FVU0D.cjs → SColorPicker-CcPnyXE0.cjs} +1 -1
- package/dist/{SColorPicker-BjtlrGHZ.js → SColorPicker-XXyDOuDg.js} +2 -2
- package/dist/{SInput-D8NftspL.js → SInput-CGlUBCkW.js} +57 -54
- package/dist/SInput-fT-S-Tko.cjs +1 -0
- package/dist/SList-BuuCfuHg.js +471 -0
- package/dist/SList-Vg9nx1oe.cjs +1 -0
- package/dist/SListItem-CDlsjhA3.js +227 -0
- package/dist/SListItem-DMjtJXxV.cjs +1 -0
- package/dist/{SPhotoEdit-CShhPLJt.cjs → SPhotoEdit-B4ujF5Dh.cjs} +1 -1
- package/dist/{SPhotoEdit-r63G2NZI.js → SPhotoEdit-BxxycqvA.js} +1 -1
- package/dist/SRadio-B9qQ-PEk.cjs +1 -0
- package/dist/SRadio-BhoLtFUS.js +60 -0
- package/dist/SSelect-Bn4kifqp.js +666 -0
- package/dist/SSelect-DyngcoP9.cjs +1 -0
- package/dist/STab-BkQzKaLY.cjs +1 -0
- package/dist/STab-D7SATMfv.js +242 -0
- package/dist/{STable-CToIFCiU.js → STable-BVGHC_FJ.js} +193 -169
- package/dist/STable-QYXxMVAw.cjs +1 -0
- package/dist/STabs-BYbsRtvi.js +151 -0
- package/dist/STabs-DDP-2p6T.cjs +1 -0
- package/dist/{STag-C5KhPWjQ.js → STag-DWjv_Za8.js} +1 -1
- package/dist/{STag-ZPrc5q4N.cjs → STag-nqzlv8OZ.cjs} +1 -1
- package/dist/{STagGroup-ccEvIkK7.cjs → STagGroup-CYEI9OXO.cjs} +1 -1
- package/dist/{STagGroup-BGwvunuu.js → STagGroup-DEPpEU5C.js} +1 -1
- package/dist/SToggle-BNgLiIrQ.cjs +1 -0
- package/dist/SToggle-MSdprnRP.js +62 -0
- package/dist/applyChartHighlightedYTick-BHVwiljn.cjs +1 -0
- package/dist/applyChartHighlightedYTick-DmsstRVM.js +17 -0
- package/dist/buildMultiLineChartScales-Di-yTvEB.js +41 -0
- package/dist/buildMultiLineChartScales-lVP6h9H4.cjs +1 -0
- package/dist/components/SButton/SButton.vue.d.ts.map +1 -1
- package/dist/components/SButtonGroup/SButtonGroup.vue.d.ts.map +1 -1
- package/dist/components/SChartBar/SChartBar.types.d.ts +33 -4
- package/dist/components/SChartBar/SChartBar.types.d.ts.map +1 -1
- package/dist/components/SChartBar/SChartBar.vue.d.ts.map +1 -1
- package/dist/components/SChartBar/index.d.ts +1 -1
- package/dist/components/SChartBar/index.d.ts.map +1 -1
- package/dist/components/SChartBar/utils/buildBarChartConfig.d.ts +8 -2
- package/dist/components/SChartBar/utils/buildBarChartConfig.d.ts.map +1 -1
- package/dist/components/SChartBar/utils/createBarTargetLinePlugin.d.ts.map +1 -1
- package/dist/components/SChartBar/utils/createBarValueLabelPlugin.d.ts +7 -0
- package/dist/components/SChartBar/utils/createBarValueLabelPlugin.d.ts.map +1 -0
- package/dist/components/SChartBar/utils/demoBarSeries.d.ts +7 -1
- package/dist/components/SChartBar/utils/demoBarSeries.d.ts.map +1 -1
- package/dist/components/SChartBurnup/SChartBurnup.types.d.ts +8 -1
- package/dist/components/SChartBurnup/SChartBurnup.types.d.ts.map +1 -1
- package/dist/components/SChartBurnup/utils/buildBurnupChartConfig.d.ts.map +1 -1
- package/dist/components/SChartBurnup/utils/demoBurnupPoints.d.ts +1 -0
- package/dist/components/SChartBurnup/utils/demoBurnupPoints.d.ts.map +1 -1
- package/dist/components/SChartLegend/SChartLegend.types.d.ts +17 -0
- package/dist/components/SChartLegend/SChartLegend.types.d.ts.map +1 -1
- package/dist/components/SChartLegend/SChartLegend.vue.d.ts +3 -1
- package/dist/components/SChartLegend/SChartLegend.vue.d.ts.map +1 -1
- package/dist/components/SChartLegend/index.d.ts +1 -0
- package/dist/components/SChartLegend/index.d.ts.map +1 -1
- package/dist/components/SChartMultiLine/SChartMultiLine.types.d.ts +14 -2
- package/dist/components/SChartMultiLine/SChartMultiLine.types.d.ts.map +1 -1
- package/dist/components/SChartMultiLine/SChartMultiLine.vue.d.ts +3 -1
- package/dist/components/SChartMultiLine/SChartMultiLine.vue.d.ts.map +1 -1
- package/dist/components/SChartMultiLine/index.d.ts +1 -1
- package/dist/components/SChartMultiLine/index.d.ts.map +1 -1
- package/dist/components/SChartMultiLine/utils/buildMultiLineChartConfig.d.ts +9 -2
- package/dist/components/SChartMultiLine/utils/buildMultiLineChartConfig.d.ts.map +1 -1
- package/dist/components/SChartMultiLine/utils/demoMultiLineSeries.d.ts +4 -1
- package/dist/components/SChartMultiLine/utils/demoMultiLineSeries.d.ts.map +1 -1
- package/dist/components/SChartPie/SChartPie.types.d.ts +27 -1
- package/dist/components/SChartPie/SChartPie.types.d.ts.map +1 -1
- package/dist/components/SChartPie/SChartPie.vue.d.ts +16 -2
- package/dist/components/SChartPie/SChartPie.vue.d.ts.map +1 -1
- package/dist/components/SChartPie/index.d.ts +2 -1
- package/dist/components/SChartPie/index.d.ts.map +1 -1
- package/dist/components/SChartPie/utils/buildPieChartConfig.d.ts +3 -1
- package/dist/components/SChartPie/utils/buildPieChartConfig.d.ts.map +1 -1
- package/dist/components/SChartPie/utils/demoPieSlices.d.ts +1 -0
- package/dist/components/SChartPie/utils/demoPieSlices.d.ts.map +1 -1
- package/dist/components/SChartSegmentedBar/SChartSegmentedBar.types.d.ts +9 -0
- package/dist/components/SChartSegmentedBar/SChartSegmentedBar.types.d.ts.map +1 -1
- package/dist/components/SChartSegmentedBar/SChartSegmentedBar.vue.d.ts +14 -2
- package/dist/components/SChartSegmentedBar/SChartSegmentedBar.vue.d.ts.map +1 -1
- package/dist/components/SChartSegmentedBar/utils/buildSegmentedBarChartConfig.d.ts +4 -1
- package/dist/components/SChartSegmentedBar/utils/buildSegmentedBarChartConfig.d.ts.map +1 -1
- package/dist/components/SChartSegmentedBar/utils/createSegmentedBarBadgePlugin.d.ts.map +1 -1
- package/dist/components/SCheckbox/SCheckbox.vue.d.ts.map +1 -1
- package/dist/components/SInput/SInput.vue.d.ts.map +1 -1
- package/dist/components/SInput/utils/fieldLabelId.d.ts +6 -0
- package/dist/components/SInput/utils/fieldLabelId.d.ts.map +1 -0
- package/dist/components/SList/SList.vue.d.ts.map +1 -1
- package/dist/components/SList/utils/context.d.ts +3 -0
- package/dist/components/SList/utils/context.d.ts.map +1 -1
- package/dist/components/SList/utils/resolveListItemFields.d.ts +1 -1
- package/dist/components/SList/utils/resolveListItemFields.d.ts.map +1 -1
- package/dist/components/SListItem/SListItem.types.d.ts +22 -0
- package/dist/components/SListItem/SListItem.types.d.ts.map +1 -1
- package/dist/components/SListItem/SListItem.vue.d.ts.map +1 -1
- package/dist/components/SListItem/index.d.ts +2 -2
- package/dist/components/SListItem/index.d.ts.map +1 -1
- package/dist/components/SListItem/utils/listItemAria.d.ts +31 -0
- package/dist/components/SListItem/utils/listItemAria.d.ts.map +1 -0
- package/dist/components/SRadio/SRadio.vue.d.ts.map +1 -1
- package/dist/components/SRoadmap/SRoadmap.types.d.ts +47 -0
- package/dist/components/SRoadmap/SRoadmap.types.d.ts.map +1 -0
- package/dist/components/SRoadmap/SRoadmap.vue.d.ts +21 -0
- package/dist/components/SRoadmap/SRoadmap.vue.d.ts.map +1 -0
- package/dist/components/SRoadmap/index.d.ts +4 -0
- package/dist/components/SRoadmap/index.d.ts.map +1 -0
- package/dist/components/SRoadmap/utils/buildRoadmapRows.d.ts +19 -0
- package/dist/components/SRoadmap/utils/buildRoadmapRows.d.ts.map +1 -0
- package/dist/components/SRoadmap/utils/demoRoadmapItems.d.ts +5 -0
- package/dist/components/SRoadmap/utils/demoRoadmapItems.d.ts.map +1 -0
- package/dist/components/SRoadmap/utils/roadmapDate.d.ts +16 -0
- package/dist/components/SRoadmap/utils/roadmapDate.d.ts.map +1 -0
- package/dist/components/SSelect/SSelect.vue.d.ts.map +1 -1
- package/dist/components/STab/STab.types.d.ts +5 -0
- package/dist/components/STab/STab.types.d.ts.map +1 -1
- package/dist/components/STab/STab.vue.d.ts +2 -0
- package/dist/components/STab/STab.vue.d.ts.map +1 -1
- package/dist/components/STable/STable.vue.d.ts.map +1 -1
- package/dist/components/STable/parts/STableGroupRow.vue.d.ts +2 -0
- package/dist/components/STable/parts/STableGroupRow.vue.d.ts.map +1 -1
- package/dist/components/STable/parts/STableRow.vue.d.ts +2 -0
- package/dist/components/STable/parts/STableRow.vue.d.ts.map +1 -1
- package/dist/components/STable/utils/useTableRowHydration.d.ts +3 -1
- package/dist/components/STable/utils/useTableRowHydration.d.ts.map +1 -1
- package/dist/components/STabs/STabs.vue.d.ts.map +1 -1
- package/dist/components/SToggle/SToggle.vue.d.ts.map +1 -1
- package/dist/composables/useAriaAttrs.d.ts +21 -0
- package/dist/composables/useAriaAttrs.d.ts.map +1 -0
- package/dist/composables/useChartInteractivity.d.ts +2 -1
- package/dist/composables/useChartInteractivity.d.ts.map +1 -1
- package/dist/{createChartCrosshairPlugin-B4e8d8OF.cjs → createChartCrosshairPlugin-BTPv09h4.cjs} +1 -1
- package/dist/{createChartCrosshairPlugin-C2NUAO5s.js → createChartCrosshairPlugin-EqMlaexu.js} +2 -2
- package/dist/createChartMarkersPlugin-BKxLg4pL.cjs +1 -0
- package/dist/{createChartMarkersPlugin-DkXituwE.js → createChartMarkersPlugin-DPvfZp_e.js} +11 -11
- package/dist/entries/button-group.cjs +1 -1
- package/dist/entries/button-group.js +1 -1
- package/dist/entries/button.cjs +1 -1
- package/dist/entries/button.js +1 -1
- package/dist/entries/card.cjs +1 -1
- package/dist/entries/card.js +1 -1
- package/dist/entries/chart-bar.cjs +1 -1
- package/dist/entries/chart-bar.js +1 -1
- package/dist/entries/chart-burnup.cjs +1 -1
- package/dist/entries/chart-burnup.js +1 -1
- package/dist/entries/chart-horizontal-bar.cjs +1 -1
- package/dist/entries/chart-horizontal-bar.js +1 -1
- package/dist/entries/chart-line.cjs +1 -1
- package/dist/entries/chart-line.js +1 -1
- package/dist/entries/chart-multi-line.cjs +1 -1
- package/dist/entries/chart-multi-line.js +1 -1
- package/dist/entries/chart-pie.cjs +1 -1
- package/dist/entries/chart-pie.d.ts +2 -2
- package/dist/entries/chart-pie.d.ts.map +1 -1
- package/dist/entries/chart-pie.js +2 -2
- package/dist/entries/chart-progress.cjs +1 -1
- package/dist/entries/chart-progress.js +1 -1
- package/dist/entries/chart-stacked-area.cjs +1 -1
- package/dist/entries/chart-stacked-area.js +1 -1
- package/dist/entries/chart-stacked-bar.cjs +1 -1
- package/dist/entries/chart-stacked-bar.js +1 -1
- package/dist/entries/checkbox.cjs +1 -1
- package/dist/entries/checkbox.js +1 -1
- package/dist/entries/chip.cjs +1 -1
- package/dist/entries/chip.js +1 -1
- package/dist/entries/color-picker.cjs +1 -1
- package/dist/entries/color-picker.js +1 -1
- package/dist/entries/input.cjs +1 -1
- package/dist/entries/input.js +1 -1
- package/dist/entries/list-item.cjs +1 -1
- package/dist/entries/list-item.d.ts +2 -2
- package/dist/entries/list-item.d.ts.map +1 -1
- package/dist/entries/list-item.js +2 -2
- package/dist/entries/list.cjs +1 -1
- package/dist/entries/list.js +1 -1
- package/dist/entries/photo-edit.cjs +1 -1
- package/dist/entries/photo-edit.js +1 -1
- package/dist/entries/radio.cjs +1 -1
- package/dist/entries/radio.js +1 -1
- package/dist/entries/select.cjs +1 -1
- package/dist/entries/select.js +1 -1
- package/dist/entries/tab.cjs +1 -1
- package/dist/entries/tab.js +1 -1
- package/dist/entries/table.cjs +1 -1
- package/dist/entries/table.js +1 -1
- package/dist/entries/tabs.cjs +1 -1
- package/dist/entries/tabs.js +2 -2
- package/dist/entries/tag-group.cjs +1 -1
- package/dist/entries/tag-group.js +2 -2
- package/dist/entries/tag.cjs +1 -1
- package/dist/entries/tag.js +1 -1
- package/dist/entries/toggle.cjs +1 -1
- package/dist/entries/toggle.js +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +9 -7
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +568 -302
- package/dist/resolveBarStackedSeriesColor-CjwUxrUx.js +11 -0
- package/dist/resolveBarStackedSeriesColor-Czkj5bJY.cjs +1 -0
- package/dist/resolveCssColorValue-BFMo08-w.cjs +1 -0
- package/dist/resolveCssColorValue-DH_SEZj4.js +8 -0
- package/dist/resolveSeriesPaletteColor-BepW1gdW.cjs +1 -0
- package/dist/{resolveSeriesPaletteColor-B7wHDj1L.js → resolveSeriesPaletteColor-DoPeNP_F.js} +3 -2
- package/dist/{resolveStackedChartContext-DxJNWqwE.js → resolveStackedChartContext-BbCzct6O.js} +5 -5
- package/dist/{resolveStackedChartContext-Br3N7ISo.cjs → resolveStackedChartContext-D4tuSA6Z.cjs} +1 -1
- package/dist/splitChartAxisLabel-D-IFyucJ.js +4 -0
- package/dist/splitChartAxisLabel-DAmQOJn6.cjs +2 -0
- package/dist/uikit-components.css +1 -1
- package/dist/useAriaAttrs-CxGRTeye.js +15 -0
- package/dist/useAriaAttrs-D748yeJ_.cjs +1 -0
- package/dist/useChartInteractivity-CaZ37kX-.cjs +1 -0
- package/dist/{useChartInteractivity-Cl06JL4l.js → useChartInteractivity-DygkiRA1.js} +178 -144
- package/dist/utils/chart/burnup/createBurnupTooltipCallbacks.d.ts +3 -1
- package/dist/utils/chart/burnup/createBurnupTooltipCallbacks.d.ts.map +1 -1
- package/dist/utils/chart/chart.types.d.ts +10 -0
- package/dist/utils/chart/chart.types.d.ts.map +1 -1
- package/dist/utils/chart/core/applyChartHighlightedYTick.d.ts +19 -0
- package/dist/utils/chart/core/applyChartHighlightedYTick.d.ts.map +1 -0
- package/dist/utils/chart/core/chartCssVariables.d.ts +3 -0
- package/dist/utils/chart/core/chartCssVariables.d.ts.map +1 -1
- package/dist/utils/chart/core/chartInteractivity.d.ts +9 -2
- package/dist/utils/chart/core/chartInteractivity.d.ts.map +1 -1
- package/dist/utils/chart/core/createChartMarkersPlugin.d.ts.map +1 -1
- package/dist/utils/chart/core/resolveSeriesPaletteColor.d.ts.map +1 -1
- package/dist/utils/chart/core/splitChartAxisLabel.d.ts +2 -0
- package/dist/utils/chart/core/splitChartAxisLabel.d.ts.map +1 -0
- package/dist/utils/chart/css/resolveCssColorValue.d.ts +2 -0
- package/dist/utils/chart/css/resolveCssColorValue.d.ts.map +1 -0
- package/dist/utils/chart/horizontalBar/resolveHorizontalBarColor.d.ts.map +1 -1
- package/dist/utils/chart/index.d.ts +4 -1
- package/dist/utils/chart/index.d.ts.map +1 -1
- package/dist/utils/chart/multiLine/buildMultiLineChartScales.d.ts +119 -14
- package/dist/utils/chart/multiLine/buildMultiLineChartScales.d.ts.map +1 -1
- package/dist/utils/chart/multiLine/createMultiLineTooltipCallbacks.d.ts +7 -2
- package/dist/utils/chart/multiLine/createMultiLineTooltipCallbacks.d.ts.map +1 -1
- package/package.json +3 -3
- package/dist/SChartBar-CUAibXox.js +0 -215
- package/dist/SChartBar-xzw8oxXl.cjs +0 -1
- package/dist/SChartBurnup-C5Z7UDi-.js +0 -250
- package/dist/SChartBurnup-CWSJUoA_.cjs +0 -1
- package/dist/SChartHorizontalBar-0RpJa5EJ.cjs +0 -1
- package/dist/SChartHorizontalBar-B9SWFvdN.js +0 -175
- package/dist/SChartLegend-DGtjd6zV.cjs +0 -1
- package/dist/SChartLegend-oZoF8XK7.js +0 -42
- package/dist/SChartMultiLine-CG6dKmWm.js +0 -244
- package/dist/SChartMultiLine-vz7JdyA3.cjs +0 -1
- package/dist/SChartPie-0ugeo2fO.js +0 -182
- package/dist/SChartPie-QpnxLQYv.cjs +0 -1
- package/dist/SCheckbox-BMkOc5cn.js +0 -102
- package/dist/SCheckbox-DnnC5mOH.cjs +0 -1
- package/dist/SInput-B4So5LGW.cjs +0 -1
- package/dist/SList-BuXrkB03.js +0 -465
- package/dist/SList-CvP0U6U1.cjs +0 -1
- package/dist/SListItem-BOSQGRWA.js +0 -209
- package/dist/SListItem-BeaflFVf.cjs +0 -1
- package/dist/SRadio-D6_Pd6XX.js +0 -57
- package/dist/SRadio-DRo_GU5A.cjs +0 -1
- package/dist/SSelect-mnobObXO.cjs +0 -1
- package/dist/SSelect-rpJCD5PL.js +0 -652
- package/dist/STab-C06drUMG.cjs +0 -1
- package/dist/STab-ltjZBvbK.js +0 -218
- package/dist/STable-Ci_3UqBz.cjs +0 -1
- package/dist/STabs-BARXqgoB.js +0 -149
- package/dist/STabs-n5hMERTK.cjs +0 -1
- package/dist/SToggle-CGd0Mh0R.cjs +0 -1
- package/dist/SToggle-sGw-LSNd.js +0 -59
- package/dist/buildMultiLineChartScales-7mcIfRVG.cjs +0 -1
- package/dist/buildMultiLineChartScales-CFZ8YVeJ.js +0 -19
- package/dist/createChartMarkersPlugin-Cg1yGzxW.cjs +0 -1
- package/dist/resolveBarStackedSeriesColor-DM7Ax0-s.js +0 -11
- package/dist/resolveBarStackedSeriesColor-z3NP5vAS.cjs +0 -1
- package/dist/resolveSeriesPaletteColor-D0XlU5vT.cjs +0 -1
- package/dist/useChartInteractivity-LbJiqlvI.cjs +0 -1
|
@@ -0,0 +1,666 @@
|
|
|
1
|
+
import { i as e, n as t, r as n, t as r } from "./SButton-DIWMMCSc.js";
|
|
2
|
+
import { n as i } from "./useSelectionGroup-BCAmPf3R.js";
|
|
3
|
+
import { t as a } from "./useAriaAttrs-CxGRTeye.js";
|
|
4
|
+
import { t as o } from "./SDropdown-cNmJ5Lrz.js";
|
|
5
|
+
import { t as s } from "./SDropdownMenu-2koPU6IG.js";
|
|
6
|
+
import { n as c, r as l, t as u } from "./SInput-CGlUBCkW.js";
|
|
7
|
+
import { t as d } from "./SListItem-CDlsjhA3.js";
|
|
8
|
+
import { i as f, n as p, r as m, t as ee } from "./SList-BuuCfuHg.js";
|
|
9
|
+
import { computed as h, createBlock as g, createCommentVNode as _, createElementBlock as v, createElementVNode as y, createSlots as b, createTextVNode as te, createVNode as x, defineComponent as S, guardReactiveProps as C, isRef as ne, mergeModels as w, mergeProps as T, nextTick as E, normalizeProps as D, openBlock as O, ref as k, renderSlot as A, toDisplayString as j, toValue as M, unref as N, useId as re, useModel as ie, useSlots as ae, useTemplateRef as oe, vModelText as se, watch as ce, withCtx as P, withDirectives as le, withModifiers as ue } from "vue";
|
|
10
|
+
import { SIcon as de, useUiKitI18n as fe } from "@shtabapp/ui-kit-primitives";
|
|
11
|
+
//#region src/components/SSelect/utils/buildSelectListItemProps.ts
|
|
12
|
+
var pe = ({ listItemScope: e, itemTitle: t, itemSubtitle: n, itemDisabled: r, itemIconLeft: i, listActiveKey: a, isOptionSelected: o }) => {
|
|
13
|
+
let s = e.item;
|
|
14
|
+
return {
|
|
15
|
+
rowKey: e.key,
|
|
16
|
+
title: f(s, t),
|
|
17
|
+
subtitle: f(s, n),
|
|
18
|
+
disabled: p(s, r),
|
|
19
|
+
iconLeft: m(s, i),
|
|
20
|
+
selected: o,
|
|
21
|
+
active: a === e.key,
|
|
22
|
+
revealRight: e.revealRight,
|
|
23
|
+
tiny: !0
|
|
24
|
+
};
|
|
25
|
+
}, me = (e) => typeof e == "string" || typeof e == "number", F = (e, t) => {
|
|
26
|
+
let n = e[t];
|
|
27
|
+
if (me(n)) return n;
|
|
28
|
+
}, I = (e) => typeof e == "string" ? e : String(e), L = (e) => e == null ? !1 : typeof e == "string" ? e.length > 0 : !0, he = (e, t, n) => t.find((t) => I(F(t, n) ?? "") === e), ge = (e) => typeof e == "object" && !!e, R = (e, t, n) => {
|
|
29
|
+
let r = he(e, t, n);
|
|
30
|
+
if (r) return F(r, n);
|
|
31
|
+
}, z = /* @__PURE__ */ function(e) {
|
|
32
|
+
return e.INPUT = "input", e.CONTENT = "content", e;
|
|
33
|
+
}({}), B = (e, t, n) => {
|
|
34
|
+
if (!e) return !0;
|
|
35
|
+
let r = e.toLocaleLowerCase(), i = f(t, n.itemTitle)?.toLocaleLowerCase() ?? "", a = I(F(t, n.itemValue) ?? "").toLocaleLowerCase();
|
|
36
|
+
return i.includes(r) || a.includes(r);
|
|
37
|
+
}, V = (e, t, n, r) => {
|
|
38
|
+
let i = r ?? ((e, t) => B(e, t, n));
|
|
39
|
+
return t ? e.filter((e) => i(t, e)) : [...e];
|
|
40
|
+
}, H = (e) => typeof e == "string" && L(e), U = (e) => typeof e == "number" && L(e), W = (e, t, n) => {
|
|
41
|
+
if (t) {
|
|
42
|
+
if (!ge(e)) return;
|
|
43
|
+
let t = F(e, n);
|
|
44
|
+
return H(t) || U(t) ? t : void 0;
|
|
45
|
+
}
|
|
46
|
+
let r = typeof e == "string" || typeof e == "number" ? e : void 0;
|
|
47
|
+
if (H(r) || U(r)) return r;
|
|
48
|
+
}, G = (e, t, n) => e ? (Array.isArray(e) ? e : [e]).flatMap((e) => {
|
|
49
|
+
let r = W(e, t, n);
|
|
50
|
+
return L(r) ? [r] : [];
|
|
51
|
+
}) : [], _e = (e, t) => {
|
|
52
|
+
if (H(t)) {
|
|
53
|
+
e.value = t;
|
|
54
|
+
return;
|
|
55
|
+
}
|
|
56
|
+
if (U(t)) {
|
|
57
|
+
e.value = t;
|
|
58
|
+
return;
|
|
59
|
+
}
|
|
60
|
+
e.value = void 0;
|
|
61
|
+
}, ve = (e, t, n) => t.flatMap((t) => {
|
|
62
|
+
let r = I(t), i = e.find((e) => I(F(e, n) ?? "") === r);
|
|
63
|
+
return i ? [i] : [];
|
|
64
|
+
}), ye = ({ modelValue: e, options: t, itemFields: n, multiple: r, returnObject: a, searchable: o, filterOption: s, isDropdownOpen: c, searchQuery: l }) => {
|
|
65
|
+
let u = h(() => M(r)), d = h(() => M(a)), p = h(() => M(o) === z.INPUT), m = h(() => M(o) === z.CONTENT), ee = h(() => !!M(o)), g = h(() => {
|
|
66
|
+
let t = M(n);
|
|
67
|
+
return G(e.value, d.value, t.itemValue);
|
|
68
|
+
}), _ = h(() => {
|
|
69
|
+
let e = M(t), r = M(n);
|
|
70
|
+
return V(e, ee.value ? l.value : "", r, M(s));
|
|
71
|
+
}), v = h(() => u.value ? i.MULTIPLE : i.SINGLE), y = (t, n, r) => {
|
|
72
|
+
if (d.value) {
|
|
73
|
+
e.value = ve(n, t, r);
|
|
74
|
+
return;
|
|
75
|
+
}
|
|
76
|
+
e.value = t;
|
|
77
|
+
}, b = (t, n, r) => {
|
|
78
|
+
if (!t) {
|
|
79
|
+
e.value = void 0;
|
|
80
|
+
return;
|
|
81
|
+
}
|
|
82
|
+
if (d.value) {
|
|
83
|
+
e.value = he(t, n, r) ?? void 0;
|
|
84
|
+
return;
|
|
85
|
+
}
|
|
86
|
+
_e(e, R(t, n, r));
|
|
87
|
+
}, te = h({
|
|
88
|
+
get: () => {
|
|
89
|
+
if (u.value) return g.value.map((e) => I(e));
|
|
90
|
+
let e = g.value[0];
|
|
91
|
+
if (L(e)) return I(e);
|
|
92
|
+
},
|
|
93
|
+
set: (e) => {
|
|
94
|
+
let r = M(t), i = M(n);
|
|
95
|
+
if (u.value) {
|
|
96
|
+
y((Array.isArray(e) ? e : []).map((e) => R(e, r, i.itemValue)).filter((e) => L(e)), r, i.itemValue);
|
|
97
|
+
return;
|
|
98
|
+
}
|
|
99
|
+
b(typeof e == "string" ? e : void 0, r, i.itemValue);
|
|
100
|
+
}
|
|
101
|
+
}), x = h(() => g.value.length > 0), S = (e, t, n) => {
|
|
102
|
+
let r = I(t);
|
|
103
|
+
return e.find((e) => I(F(e, n) ?? "") === r);
|
|
104
|
+
}, C = h(() => {
|
|
105
|
+
let e = g.value[0];
|
|
106
|
+
if (!L(e)) return "";
|
|
107
|
+
let r = M(n), i = S(M(t), e, r.itemValue);
|
|
108
|
+
return i ? f(i, r.itemTitle) ?? "" : I(e);
|
|
109
|
+
}), ne = h(() => {
|
|
110
|
+
let e = M(t), r = M(n);
|
|
111
|
+
return g.value.map((t) => {
|
|
112
|
+
let n = S(e, t, r.itemValue);
|
|
113
|
+
return n ? f(n, r.itemTitle) ?? "" : I(t);
|
|
114
|
+
});
|
|
115
|
+
}), w = h(() => ne.value.join(", ")), T = h(() => u.value ? g.value.length === 0 : !C.value), E = h(() => p.value && (c.value || u.value)), D = () => {
|
|
116
|
+
l.value = "";
|
|
117
|
+
};
|
|
118
|
+
return ce(c, (e) => {
|
|
119
|
+
e || D();
|
|
120
|
+
}), ce(() => M(o), () => {
|
|
121
|
+
D();
|
|
122
|
+
}), {
|
|
123
|
+
searchQuery: l,
|
|
124
|
+
selectedValues: g,
|
|
125
|
+
filteredOptions: _,
|
|
126
|
+
listSelectionMode: v,
|
|
127
|
+
listSelectedModel: te,
|
|
128
|
+
hasSelectedValues: x,
|
|
129
|
+
singleDisplayLabel: C,
|
|
130
|
+
multipleDisplayLabels: ne,
|
|
131
|
+
multipleDisplayText: w,
|
|
132
|
+
showPlaceholder: T,
|
|
133
|
+
showInputSearchField: E,
|
|
134
|
+
isSearchableMode: ee,
|
|
135
|
+
isSearchableInputMode: p,
|
|
136
|
+
isSearchableContentMode: m,
|
|
137
|
+
isMultipleMode: u,
|
|
138
|
+
isReturnObjectMode: d,
|
|
139
|
+
clearSelection: () => {
|
|
140
|
+
e.value = void 0, D();
|
|
141
|
+
},
|
|
142
|
+
removeSelectedValue: (e) => {
|
|
143
|
+
let r = I(e);
|
|
144
|
+
y(g.value.filter((e) => I(e) !== r), M(t), M(n).itemValue);
|
|
145
|
+
},
|
|
146
|
+
resetSearchQuery: D,
|
|
147
|
+
formatSelectListKey: I,
|
|
148
|
+
resolveValueFromListKey: (e) => R(e, M(t), M(n).itemValue)
|
|
149
|
+
};
|
|
150
|
+
}, be = {
|
|
151
|
+
key: 1,
|
|
152
|
+
class: "s-ui-select__empty s-ui-typography-body-14-regular"
|
|
153
|
+
}, xe = [
|
|
154
|
+
"id",
|
|
155
|
+
"aria-expanded",
|
|
156
|
+
"aria-controls",
|
|
157
|
+
"aria-disabled",
|
|
158
|
+
"aria-readonly",
|
|
159
|
+
"aria-autocomplete",
|
|
160
|
+
"tabindex"
|
|
161
|
+
], Se = {
|
|
162
|
+
key: 0,
|
|
163
|
+
class: "s-ui-select__value"
|
|
164
|
+
}, Ce = {
|
|
165
|
+
key: 1,
|
|
166
|
+
class: "s-ui-select__placeholder"
|
|
167
|
+
}, we = {
|
|
168
|
+
key: 1,
|
|
169
|
+
class: "s-ui-select__placeholder"
|
|
170
|
+
}, Te = {
|
|
171
|
+
key: 2,
|
|
172
|
+
class: "s-ui-select__value"
|
|
173
|
+
}, Ee = {
|
|
174
|
+
key: 3,
|
|
175
|
+
class: "s-ui-select__value-suffix"
|
|
176
|
+
}, De = [
|
|
177
|
+
"name",
|
|
178
|
+
"placeholder",
|
|
179
|
+
"disabled",
|
|
180
|
+
"readonly"
|
|
181
|
+
], Oe = 20, ke = "100%", Ae = 20, je = /* @__PURE__ */ S({
|
|
182
|
+
inheritAttrs: !1,
|
|
183
|
+
__name: "SSelect",
|
|
184
|
+
props: /*@__PURE__*/ w({
|
|
185
|
+
options: {},
|
|
186
|
+
itemValue: { default: "value" },
|
|
187
|
+
itemTitle: { default: "label" },
|
|
188
|
+
itemSubtitle: { default: "subtitle" },
|
|
189
|
+
itemId: {},
|
|
190
|
+
itemDisabled: { default: "disabled" },
|
|
191
|
+
itemIconLeft: { default: "iconLeft" },
|
|
192
|
+
multiple: {
|
|
193
|
+
type: Boolean,
|
|
194
|
+
default: !1
|
|
195
|
+
},
|
|
196
|
+
returnObject: {
|
|
197
|
+
type: Boolean,
|
|
198
|
+
default: !1
|
|
199
|
+
},
|
|
200
|
+
clearable: {
|
|
201
|
+
type: Boolean,
|
|
202
|
+
default: !1
|
|
203
|
+
},
|
|
204
|
+
closableOptions: {
|
|
205
|
+
type: Boolean,
|
|
206
|
+
default: !1
|
|
207
|
+
},
|
|
208
|
+
searchable: {
|
|
209
|
+
type: [String, Boolean],
|
|
210
|
+
default: !1
|
|
211
|
+
},
|
|
212
|
+
closeOnSelect: {
|
|
213
|
+
type: Boolean,
|
|
214
|
+
default: !0
|
|
215
|
+
},
|
|
216
|
+
listHeight: { default: 320 },
|
|
217
|
+
searchPlaceholder: { default: "Search" },
|
|
218
|
+
filterOption: { type: Function },
|
|
219
|
+
fitViewport: {
|
|
220
|
+
type: Boolean,
|
|
221
|
+
default: !0
|
|
222
|
+
},
|
|
223
|
+
panelWidth: {},
|
|
224
|
+
surfaceClass: {},
|
|
225
|
+
canLoadMore: { type: Function },
|
|
226
|
+
endReachedDistance: { default: 0 },
|
|
227
|
+
label: {},
|
|
228
|
+
labelProps: {},
|
|
229
|
+
placeholder: {},
|
|
230
|
+
helpMessages: {},
|
|
231
|
+
errorMessages: {},
|
|
232
|
+
bordered: {
|
|
233
|
+
type: Boolean,
|
|
234
|
+
default: !0
|
|
235
|
+
},
|
|
236
|
+
disabled: {
|
|
237
|
+
type: Boolean,
|
|
238
|
+
default: !1
|
|
239
|
+
},
|
|
240
|
+
readonly: {
|
|
241
|
+
type: Boolean,
|
|
242
|
+
default: !1
|
|
243
|
+
},
|
|
244
|
+
iconLeft: {},
|
|
245
|
+
customize: { default: () => l.NONE },
|
|
246
|
+
name: {},
|
|
247
|
+
id: {}
|
|
248
|
+
}, {
|
|
249
|
+
modelValue: {},
|
|
250
|
+
modelModifiers: {},
|
|
251
|
+
searchQuery: { default: "" },
|
|
252
|
+
searchQueryModifiers: {}
|
|
253
|
+
}),
|
|
254
|
+
emits: /*@__PURE__*/ w([
|
|
255
|
+
"clear",
|
|
256
|
+
"focus",
|
|
257
|
+
"blur",
|
|
258
|
+
"open",
|
|
259
|
+
"close",
|
|
260
|
+
"endReached"
|
|
261
|
+
], ["update:modelValue", "update:searchQuery"]),
|
|
262
|
+
setup(i, { expose: l, emit: f }) {
|
|
263
|
+
let p = ie(i, "modelValue"), m = ie(i, "searchQuery"), S = f, { t: w } = fe(), M = ae(), { getRootAttrs: me, getAriaAttrs: F, getAriaAttr: I } = a(), he = re(), ge = re(), R = oe("triggerInputRef"), z = k(""), B = oe("searchInputElementRef"), V = oe("panelSearchInputElementRef"), H = oe("listElementRef"), U = k(), W = k(!1), G = k(!1), _e = h(() => i.panelWidth === void 0), ve = h(() => i.panelWidth ?? ke), je = h(() => i.itemId ?? i.itemValue), Me = h(() => ({
|
|
264
|
+
itemValue: i.itemValue,
|
|
265
|
+
itemTitle: i.itemTitle,
|
|
266
|
+
itemSubtitle: i.itemSubtitle,
|
|
267
|
+
itemId: je.value
|
|
268
|
+
})), { selectedValues: K, filteredOptions: Ne, listSelectionMode: Pe, listSelectedModel: q, hasSelectedValues: Fe, singleDisplayLabel: Ie, multipleDisplayLabels: Le, multipleDisplayText: Re, showPlaceholder: J, showInputSearchField: Y, isSearchableMode: ze, isSearchableInputMode: Be, isSearchableContentMode: X, isMultipleMode: Z, clearSelection: Ve, removeSelectedValue: He, resolveValueFromListKey: Ue, formatSelectListKey: We } = ye({
|
|
269
|
+
modelValue: p,
|
|
270
|
+
options: () => i.options,
|
|
271
|
+
itemFields: () => Me.value,
|
|
272
|
+
multiple: () => i.multiple,
|
|
273
|
+
returnObject: () => i.returnObject,
|
|
274
|
+
searchable: () => i.searchable,
|
|
275
|
+
filterOption: () => i.filterOption,
|
|
276
|
+
isDropdownOpen: W,
|
|
277
|
+
searchQuery: m
|
|
278
|
+
}), Ge = h(() => ({
|
|
279
|
+
disabled: i.disabled,
|
|
280
|
+
displayLabel: Ie.value
|
|
281
|
+
})), Ke = h(() => Ne.value.length > Ae), qe = h(() => X.value || Ke.value ? i.listHeight : "auto"), Je = h(() => {
|
|
282
|
+
if (!(X.value || Ke.value)) return i.listHeight;
|
|
283
|
+
}), Ye = h(() => K.value.map((e) => We(e))), Xe = (e) => Ye.value.includes(e), Ze = () => ({ tiny: !0 }), Qe = (e) => pe({
|
|
284
|
+
listItemScope: e,
|
|
285
|
+
itemTitle: i.itemTitle,
|
|
286
|
+
itemSubtitle: i.itemSubtitle,
|
|
287
|
+
itemDisabled: i.itemDisabled,
|
|
288
|
+
itemIconLeft: i.itemIconLeft,
|
|
289
|
+
listActiveKey: U.value,
|
|
290
|
+
isOptionSelected: Xe(e.key)
|
|
291
|
+
}), $e = (e) => {
|
|
292
|
+
let t = Ue(e);
|
|
293
|
+
if (L(t)) {
|
|
294
|
+
if (Z.value) {
|
|
295
|
+
He(t);
|
|
296
|
+
return;
|
|
297
|
+
}
|
|
298
|
+
p.value = void 0;
|
|
299
|
+
}
|
|
300
|
+
}, et = h(() => i.id ?? he), tt = h(() => ge), nt = h(() => c(et.value)), rt = () => {
|
|
301
|
+
let e = I("aria-label"), t = I("aria-labelledby");
|
|
302
|
+
return e || t ? {
|
|
303
|
+
"aria-label": e,
|
|
304
|
+
"aria-labelledby": t
|
|
305
|
+
} : i.label || M.label ? { "aria-labelledby": nt.value } : i.placeholder ? { "aria-label": i.placeholder } : {};
|
|
306
|
+
}, it = () => ({
|
|
307
|
+
...F(),
|
|
308
|
+
...rt()
|
|
309
|
+
}), at = h(() => R.value?.fieldElementRef ?? null), ot = h(() => ({
|
|
310
|
+
labels: Le.value,
|
|
311
|
+
values: K.value,
|
|
312
|
+
displayText: Re.value,
|
|
313
|
+
disabled: i.disabled || i.readonly,
|
|
314
|
+
removeValue: He
|
|
315
|
+
})), st = h(() => {
|
|
316
|
+
if (!i.disabled && (i.readonly && !Be.value || !Be.value)) return 0;
|
|
317
|
+
}), ct = h(() => ({
|
|
318
|
+
"s-ui-select--disabled": i.disabled,
|
|
319
|
+
"s-ui-select--readonly": i.readonly,
|
|
320
|
+
"s-ui-select--multiple": Z.value,
|
|
321
|
+
"s-ui-select--open": W.value
|
|
322
|
+
})), lt = () => {
|
|
323
|
+
if (X.value) {
|
|
324
|
+
V.value?.focus();
|
|
325
|
+
return;
|
|
326
|
+
}
|
|
327
|
+
B.value?.focus();
|
|
328
|
+
}, ut = async () => {
|
|
329
|
+
await E(), V.value?.focus();
|
|
330
|
+
}, dt = async () => {
|
|
331
|
+
await E(), await H.value?.focusNavigation();
|
|
332
|
+
}, Q = async () => {
|
|
333
|
+
if (!(i.disabled || i.readonly) && !W.value) {
|
|
334
|
+
if (W.value = !0, S("open"), X.value) {
|
|
335
|
+
await ut();
|
|
336
|
+
return;
|
|
337
|
+
}
|
|
338
|
+
if (Be.value) {
|
|
339
|
+
await E(), B.value?.focus();
|
|
340
|
+
return;
|
|
341
|
+
}
|
|
342
|
+
await dt();
|
|
343
|
+
}
|
|
344
|
+
}, ft = async () => {
|
|
345
|
+
i.disabled || i.readonly || W.value || await Q();
|
|
346
|
+
};
|
|
347
|
+
ce(m, async (e) => {
|
|
348
|
+
Be.value && (i.disabled || i.readonly || e && (W.value || await Q()));
|
|
349
|
+
});
|
|
350
|
+
let $ = () => {
|
|
351
|
+
W.value && (W.value = !1, U.value = void 0, S("close"));
|
|
352
|
+
}, pt = () => {
|
|
353
|
+
!i.closeOnSelect || Z.value || $();
|
|
354
|
+
};
|
|
355
|
+
ce(p, (e, t) => {
|
|
356
|
+
!i.closeOnSelect || Z.value || !W.value || !e || e === t || $();
|
|
357
|
+
});
|
|
358
|
+
let mt = (e) => {
|
|
359
|
+
W.value && e.target instanceof Element && e.target.closest(".s-ui-list-item") && pt();
|
|
360
|
+
}, ht = async (e) => {
|
|
361
|
+
e.key !== "Enter" && e.key !== " " && e.key !== "Spacebar" || W.value && (await E(), pt());
|
|
362
|
+
}, gt = async () => {
|
|
363
|
+
if (W.value) {
|
|
364
|
+
$();
|
|
365
|
+
return;
|
|
366
|
+
}
|
|
367
|
+
await Q();
|
|
368
|
+
}, _t = async (e) => {
|
|
369
|
+
if (!(i.disabled || i.readonly) && e.target instanceof HTMLElement) {
|
|
370
|
+
if (e.target.closest(".s-ui-select__search-input")) {
|
|
371
|
+
W.value || await Q();
|
|
372
|
+
return;
|
|
373
|
+
}
|
|
374
|
+
await gt();
|
|
375
|
+
}
|
|
376
|
+
}, vt = async () => {
|
|
377
|
+
i.disabled || i.readonly || await gt();
|
|
378
|
+
}, yt = async (e) => e.key !== "ArrowDown" && e.key !== "ArrowUp" ? !1 : (e.preventDefault(), e.stopPropagation(), W.value || await Q(), await dt(), await H.value?.handleKeyboardNavigation(e), !0), bt = (e) => {
|
|
379
|
+
let t = Ue(e);
|
|
380
|
+
if (t) {
|
|
381
|
+
if (Z.value) {
|
|
382
|
+
K.value.some((t) => We(t) === e) ? He(t) : q.value = [...K.value.map((e) => We(e)), e];
|
|
383
|
+
return;
|
|
384
|
+
}
|
|
385
|
+
q.value = e, pt();
|
|
386
|
+
}
|
|
387
|
+
}, xt = async (e) => {
|
|
388
|
+
if (!(i.disabled || i.readonly) && !await yt(e)) {
|
|
389
|
+
if (e.key === "Escape") {
|
|
390
|
+
e.preventDefault(), $();
|
|
391
|
+
return;
|
|
392
|
+
}
|
|
393
|
+
if (e.key === "Enter" || e.key === " ") {
|
|
394
|
+
if (e.preventDefault(), W.value && U.value) {
|
|
395
|
+
bt(U.value);
|
|
396
|
+
return;
|
|
397
|
+
}
|
|
398
|
+
await gt();
|
|
399
|
+
}
|
|
400
|
+
}
|
|
401
|
+
}, St = async (e) => {
|
|
402
|
+
if (e.key === "Escape") {
|
|
403
|
+
e.preventDefault(), $();
|
|
404
|
+
return;
|
|
405
|
+
}
|
|
406
|
+
await yt(e);
|
|
407
|
+
}, Ct = St, wt = (e) => {
|
|
408
|
+
i.disabled || (G.value || S("focus", e), G.value = !0);
|
|
409
|
+
}, Tt = (e) => {
|
|
410
|
+
if (!(e.currentTarget instanceof HTMLElement)) return;
|
|
411
|
+
let t = e.relatedTarget;
|
|
412
|
+
t instanceof Node && e.currentTarget.contains(t) || (G.value = !1, S("blur", e));
|
|
413
|
+
}, Et = () => {
|
|
414
|
+
Ve(), S("clear");
|
|
415
|
+
}, Dt = (e) => {
|
|
416
|
+
S("endReached", e);
|
|
417
|
+
};
|
|
418
|
+
return l({
|
|
419
|
+
open: Q,
|
|
420
|
+
close: $,
|
|
421
|
+
toggle: gt,
|
|
422
|
+
focusSearchInput: lt
|
|
423
|
+
}), (a, c) => (O(), v("div", T({ class: ["s-ui-select", ct.value] }, N(me)()), [x(N(o), {
|
|
424
|
+
modelValue: W.value,
|
|
425
|
+
"onUpdate:modelValue": c[4] ||= (e) => W.value = e,
|
|
426
|
+
reference: at.value,
|
|
427
|
+
disabled: i.disabled,
|
|
428
|
+
"match-reference-width": _e.value,
|
|
429
|
+
"fit-viewport": i.fitViewport,
|
|
430
|
+
"surface-class": i.surfaceClass,
|
|
431
|
+
"content-id": tt.value,
|
|
432
|
+
"dismiss-on-click-outside": !0,
|
|
433
|
+
"dismiss-on-escape": !0
|
|
434
|
+
}, {
|
|
435
|
+
content: P(() => [x(N(s), {
|
|
436
|
+
class: "s-ui-select__menu",
|
|
437
|
+
width: ve.value
|
|
438
|
+
}, b({
|
|
439
|
+
default: P(() => [y("div", {
|
|
440
|
+
class: "s-ui-select__menu-body",
|
|
441
|
+
onClick: mt,
|
|
442
|
+
onKeydown: ht
|
|
443
|
+
}, [N(Ne).length > 0 ? (O(), g(N(ee), T({
|
|
444
|
+
key: 0,
|
|
445
|
+
ref_key: "listElementRef",
|
|
446
|
+
ref: H,
|
|
447
|
+
modelValue: U.value,
|
|
448
|
+
"onUpdate:modelValue": c[2] ||= (e) => U.value = e,
|
|
449
|
+
selected: N(q),
|
|
450
|
+
"onUpdate:selected": c[3] ||= (e) => ne(q) ? q.value = e : null,
|
|
451
|
+
items: N(Ne),
|
|
452
|
+
"item-key": je.value,
|
|
453
|
+
"title-key": i.itemTitle,
|
|
454
|
+
"subtitle-key": i.itemSubtitle,
|
|
455
|
+
"icon-left-key": i.itemIconLeft,
|
|
456
|
+
"disabled-key": i.itemDisabled,
|
|
457
|
+
"selection-mode": N(Pe),
|
|
458
|
+
mandatory: !i.multiple,
|
|
459
|
+
height: qe.value,
|
|
460
|
+
"max-height": Je.value,
|
|
461
|
+
virtual: Ke.value,
|
|
462
|
+
"item-props": Ze,
|
|
463
|
+
"selected-on-top": N(Z),
|
|
464
|
+
"can-load-more": i.canLoadMore,
|
|
465
|
+
"end-reached-distance": i.endReachedDistance
|
|
466
|
+
}, rt(), { onEndReached: Dt }), b({ _: 2 }, [N(M).option || N(M)["option-icon"] || i.closableOptions || N(Z) ? {
|
|
467
|
+
name: "item",
|
|
468
|
+
fn: P((o) => [N(M).option ? A(a.$slots, "option", D(T({ key: 0 }, o))) : i.closableOptions ? (O(), g(N(d), D(T({ key: 1 }, Qe(o))), b({ _: 2 }, [N(M)["option-icon"] ? {
|
|
469
|
+
name: "icon-left",
|
|
470
|
+
fn: P(() => [A(a.$slots, "option-icon", D(C(o)))]),
|
|
471
|
+
key: "0"
|
|
472
|
+
} : void 0, Xe(o.key) ? {
|
|
473
|
+
name: "right",
|
|
474
|
+
fn: P((i) => [x(N(r), {
|
|
475
|
+
appearance: N(t).BARE,
|
|
476
|
+
variant: N(e).NEUTRAL,
|
|
477
|
+
size: N(n).SMALL,
|
|
478
|
+
icon: "closeMini",
|
|
479
|
+
"aria-label": N(w)("select.removeOption"),
|
|
480
|
+
disabled: i.disabled || i.readonly,
|
|
481
|
+
tabindex: -1,
|
|
482
|
+
onClick: ue((e) => $e(o.key), ["stop"])
|
|
483
|
+
}, null, 8, [
|
|
484
|
+
"appearance",
|
|
485
|
+
"variant",
|
|
486
|
+
"size",
|
|
487
|
+
"aria-label",
|
|
488
|
+
"disabled",
|
|
489
|
+
"onClick"
|
|
490
|
+
])]),
|
|
491
|
+
key: "1"
|
|
492
|
+
} : void 0]), 1040)) : (O(), g(N(d), D(T({ key: 2 }, Qe(o))), b({ _: 2 }, [N(M)["option-icon"] ? {
|
|
493
|
+
name: "icon-left",
|
|
494
|
+
fn: P(() => [A(a.$slots, "option-icon", D(C(o)))]),
|
|
495
|
+
key: "0"
|
|
496
|
+
} : void 0]), 1040))]),
|
|
497
|
+
key: "0"
|
|
498
|
+
} : void 0]), 1040, [
|
|
499
|
+
"modelValue",
|
|
500
|
+
"selected",
|
|
501
|
+
"items",
|
|
502
|
+
"item-key",
|
|
503
|
+
"title-key",
|
|
504
|
+
"subtitle-key",
|
|
505
|
+
"icon-left-key",
|
|
506
|
+
"disabled-key",
|
|
507
|
+
"selection-mode",
|
|
508
|
+
"mandatory",
|
|
509
|
+
"height",
|
|
510
|
+
"max-height",
|
|
511
|
+
"virtual",
|
|
512
|
+
"selected-on-top",
|
|
513
|
+
"can-load-more",
|
|
514
|
+
"end-reached-distance"
|
|
515
|
+
])) : (O(), v("div", be, [A(a.$slots, "empty", {}, () => [te(j(N(w)("select.noOptions")), 1)])]))], 32)]),
|
|
516
|
+
_: 2
|
|
517
|
+
}, [N(X) || N(M)["panel-header"] ? {
|
|
518
|
+
name: "header",
|
|
519
|
+
fn: P(() => [A(a.$slots, "panel-header"), N(X) ? (O(), g(N(u), {
|
|
520
|
+
key: 0,
|
|
521
|
+
ref_key: "panelSearchInputElementRef",
|
|
522
|
+
ref: V,
|
|
523
|
+
modelValue: m.value,
|
|
524
|
+
"onUpdate:modelValue": c[0] ||= (e) => m.value = e,
|
|
525
|
+
placeholder: i.searchPlaceholder,
|
|
526
|
+
disabled: i.disabled,
|
|
527
|
+
clearable: !1,
|
|
528
|
+
"aria-label": i.searchPlaceholder,
|
|
529
|
+
"icon-left": "search",
|
|
530
|
+
onClick: c[1] ||= ue(() => {}, ["stop"]),
|
|
531
|
+
onKeydown: N(Ct)
|
|
532
|
+
}, null, 8, [
|
|
533
|
+
"modelValue",
|
|
534
|
+
"placeholder",
|
|
535
|
+
"disabled",
|
|
536
|
+
"aria-label",
|
|
537
|
+
"onKeydown"
|
|
538
|
+
])) : _("", !0)]),
|
|
539
|
+
key: "0"
|
|
540
|
+
} : void 0, N(M)["panel-footer"] ? {
|
|
541
|
+
name: "footer",
|
|
542
|
+
fn: P(() => [A(a.$slots, "panel-footer")]),
|
|
543
|
+
key: "1"
|
|
544
|
+
} : void 0]), 1032, ["width"])]),
|
|
545
|
+
_: 3
|
|
546
|
+
}, 8, [
|
|
547
|
+
"modelValue",
|
|
548
|
+
"reference",
|
|
549
|
+
"disabled",
|
|
550
|
+
"match-reference-width",
|
|
551
|
+
"fit-viewport",
|
|
552
|
+
"surface-class",
|
|
553
|
+
"content-id"
|
|
554
|
+
]), x(N(u), {
|
|
555
|
+
ref_key: "triggerInputRef",
|
|
556
|
+
ref: R,
|
|
557
|
+
modelValue: z.value,
|
|
558
|
+
"onUpdate:modelValue": c[7] ||= (e) => z.value = e,
|
|
559
|
+
label: i.label,
|
|
560
|
+
"label-props": i.labelProps,
|
|
561
|
+
placeholder: i.placeholder,
|
|
562
|
+
"help-messages": i.helpMessages,
|
|
563
|
+
"error-messages": i.errorMessages,
|
|
564
|
+
bordered: i.bordered,
|
|
565
|
+
disabled: i.disabled,
|
|
566
|
+
readonly: i.readonly,
|
|
567
|
+
clearable: i.clearable,
|
|
568
|
+
"has-value": N(Fe),
|
|
569
|
+
focused: G.value || W.value,
|
|
570
|
+
"icon-left": i.iconLeft,
|
|
571
|
+
customize: i.customize,
|
|
572
|
+
name: i.name,
|
|
573
|
+
id: et.value,
|
|
574
|
+
onClear: Et,
|
|
575
|
+
onFocus: wt,
|
|
576
|
+
onBlur: Tt
|
|
577
|
+
}, b({
|
|
578
|
+
control: P(() => [y("div", T({
|
|
579
|
+
id: et.value,
|
|
580
|
+
class: ["s-ui-select__control s-ui-typography-body-14-regular", {
|
|
581
|
+
"s-ui-select__control--multiple": N(Z),
|
|
582
|
+
"s-ui-select__control--empty": N(Z) && !N(Fe) && !N(Y),
|
|
583
|
+
"s-ui-select__control--with-value-suffix": N(M)["value-suffix"] && !N(Z) && !N(Y) && !N(J)
|
|
584
|
+
}],
|
|
585
|
+
role: "combobox",
|
|
586
|
+
"aria-expanded": W.value,
|
|
587
|
+
"aria-controls": tt.value,
|
|
588
|
+
"aria-haspopup": "listbox",
|
|
589
|
+
"aria-disabled": i.disabled ? !0 : void 0,
|
|
590
|
+
"aria-readonly": i.readonly ? !0 : void 0,
|
|
591
|
+
"aria-autocomplete": N(ze) ? "list" : void 0
|
|
592
|
+
}, it(), {
|
|
593
|
+
tabindex: st.value,
|
|
594
|
+
onClick: _t,
|
|
595
|
+
onKeydown: xt
|
|
596
|
+
}), [
|
|
597
|
+
N(Z) ? A(a.$slots, "selection", D(T({ key: 0 }, ot.value)), () => [N(Re) ? (O(), v("span", Se, j(N(Re)), 1)) : N(J) && !N(Y) ? (O(), v("span", Ce, j(i.placeholder), 1)) : _("", !0)]) : N(J) && !N(Y) ? (O(), v("span", we, j(i.placeholder), 1)) : N(Y) ? _("", !0) : (O(), v("span", Te, j(N(Ie)), 1)),
|
|
598
|
+
N(M)["value-suffix"] && !N(Z) && !N(Y) && !N(J) ? (O(), v("div", Ee, [A(a.$slots, "value-suffix", D(C(Ge.value)))])) : _("", !0),
|
|
599
|
+
N(Y) ? le((O(), v("input", T({
|
|
600
|
+
key: 4,
|
|
601
|
+
ref_key: "searchInputElementRef",
|
|
602
|
+
ref: B,
|
|
603
|
+
"onUpdate:modelValue": c[5] ||= (e) => m.value = e,
|
|
604
|
+
class: "s-ui-select__search-input",
|
|
605
|
+
type: "text",
|
|
606
|
+
name: i.name,
|
|
607
|
+
placeholder: i.placeholder,
|
|
608
|
+
disabled: i.disabled,
|
|
609
|
+
readonly: i.readonly,
|
|
610
|
+
autocomplete: "off"
|
|
611
|
+
}, rt(), {
|
|
612
|
+
onClick: c[6] ||= ue(() => {}, ["stop"]),
|
|
613
|
+
onFocus: ft,
|
|
614
|
+
onKeydown: St
|
|
615
|
+
}), null, 16, De)), [[se, m.value]]) : _("", !0)
|
|
616
|
+
], 16, xe)]),
|
|
617
|
+
action: P(() => [x(N(de), {
|
|
618
|
+
name: "chevronMiniDown",
|
|
619
|
+
size: Oe,
|
|
620
|
+
class: "s-ui-select__chevron",
|
|
621
|
+
onClick: vt
|
|
622
|
+
})]),
|
|
623
|
+
_: 2
|
|
624
|
+
}, [
|
|
625
|
+
N(M).label ? {
|
|
626
|
+
name: "label",
|
|
627
|
+
fn: P(() => [A(a.$slots, "label")]),
|
|
628
|
+
key: "0"
|
|
629
|
+
} : void 0,
|
|
630
|
+
N(M).prefix ? {
|
|
631
|
+
name: "prefix",
|
|
632
|
+
fn: P((e) => [A(a.$slots, "prefix", D(C(e)))]),
|
|
633
|
+
key: "1"
|
|
634
|
+
} : void 0,
|
|
635
|
+
N(M).prepend ? {
|
|
636
|
+
name: "prepend",
|
|
637
|
+
fn: P((e) => [A(a.$slots, "prepend", D(C(e)))]),
|
|
638
|
+
key: "2"
|
|
639
|
+
} : void 0,
|
|
640
|
+
N(M).message ? {
|
|
641
|
+
name: "message",
|
|
642
|
+
fn: P(() => [A(a.$slots, "message")]),
|
|
643
|
+
key: "3"
|
|
644
|
+
} : void 0
|
|
645
|
+
]), 1032, [
|
|
646
|
+
"modelValue",
|
|
647
|
+
"label",
|
|
648
|
+
"label-props",
|
|
649
|
+
"placeholder",
|
|
650
|
+
"help-messages",
|
|
651
|
+
"error-messages",
|
|
652
|
+
"bordered",
|
|
653
|
+
"disabled",
|
|
654
|
+
"readonly",
|
|
655
|
+
"clearable",
|
|
656
|
+
"has-value",
|
|
657
|
+
"focused",
|
|
658
|
+
"icon-left",
|
|
659
|
+
"customize",
|
|
660
|
+
"name",
|
|
661
|
+
"id"
|
|
662
|
+
])], 16));
|
|
663
|
+
}
|
|
664
|
+
});
|
|
665
|
+
//#endregion
|
|
666
|
+
export { z as n, je as t };
|