efficient-shell 9.1.0 → 9.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +70 -20
- package/dist/Browser-GQ2ZK4PR.js +43 -0
- package/dist/Calculator-CSYRZAS5.js +29 -0
- package/dist/CurrencyConverter-SSR2XDIC.js +21 -0
- package/dist/{Documents-BOVXZFYC.js → Documents-5AC4WSNK.js} +27 -27
- package/dist/Files-4SD6LLKX.js +88 -0
- package/dist/Notepad-EUIQXFUA.js +25 -0
- package/dist/PdfViewer-XSISAJZP.js +1 -0
- package/dist/{PomodoroTimer-ZCJBTFV5.js → PomodoroTimer-EV6D4OFU.js} +28 -28
- package/dist/Preview-QK5HYJ6U.js +177 -0
- package/dist/Sidebar-Y4DTQYW2.js +43 -0
- package/dist/Spreadsheet-HR6GBICY.js +37 -0
- package/dist/Stock-6ZIQHGPH.js +16 -0
- package/dist/Weather-II7NFRMK.js +60 -0
- package/dist/WorldClock-NBLNO63Q.js +32 -0
- package/dist/ai/index.d.ts +34 -3
- package/dist/ai/index.js +56 -53
- package/dist/ai.css +1 -1
- package/dist/apps/index.js +1 -1
- package/dist/bin/media-host-check.js +1 -1
- package/dist/bin/ui-check.js +1 -1
- package/dist/brand.css +1 -1
- package/dist/charts/BoxPlotChart.js +1 -1
- package/dist/charts/CandlestickChart.js +1 -1
- package/dist/charts/CartesianPlot.js +1 -1
- package/dist/charts/ChartBrush.js +1 -1
- package/dist/charts/ChartFrame.js +1 -1
- package/dist/charts/ChartSkeleton.js +1 -1
- package/dist/charts/ChartTooltip.js +1 -1
- package/dist/charts/ChordChart.js +1 -1
- package/dist/charts/ColumnChart.js +1 -1
- package/dist/charts/FunnelChart.js +1 -1
- package/dist/charts/HeatmapChart.js +1 -1
- package/dist/charts/HistogramChart.js +1 -1
- package/dist/charts/Meter.js +1 -1
- package/dist/charts/PieChart.js +1 -1
- package/dist/charts/RadarChart.js +1 -1
- package/dist/charts/RadialBarChart.js +1 -1
- package/dist/charts/RangeChart.js +1 -1
- package/dist/charts/RankedBars.js +1 -1
- package/dist/charts/SankeyChart.js +1 -1
- package/dist/charts/ScatterChart.js +1 -1
- package/dist/charts/SpecChart.js +1 -1
- package/dist/charts/StatTile.js +1 -1
- package/dist/charts/SunburstChart.js +1 -1
- package/dist/charts/TimeSeriesChart.js +1 -1
- package/dist/charts/TreemapChart.js +1 -1
- package/dist/charts/WaterfallChart.js +1 -1
- package/dist/chunk-24K6GVNM.js +28 -0
- package/dist/{chunk-ZEKM6HAA.js → chunk-2HEJDLPP.js} +2 -2
- package/dist/{chunk-BRHIRE4D.js → chunk-2MLRK7IO.js} +2 -2
- package/dist/chunk-2R3BVU75.js +26 -0
- package/dist/chunk-2YLG32JY.js +2 -0
- package/dist/{chunk-TZSPJIP4.js → chunk-32VV2J22.js} +1 -1
- package/dist/{chunk-QQCHLRKG.js → chunk-3APSMJPN.js} +1 -1
- package/dist/{chunk-6SMQNPWS.js → chunk-43ONX6UZ.js} +1 -1
- package/dist/{chunk-L7IKTEOC.js → chunk-442FFHQJ.js} +13 -13
- package/dist/chunk-4MVRSCQE.js +1 -0
- package/dist/{chunk-BT3XDH3L.js → chunk-56RAOI7O.js} +6 -6
- package/dist/chunk-5F7HMNCX.js +5 -0
- package/dist/chunk-5GUBNCTP.js +1 -0
- package/dist/{chunk-LGLZTJ2W.js → chunk-5JRL5LXD.js} +6 -6
- package/dist/chunk-5SJ45P5E.js +8 -0
- package/dist/{chunk-OFHCDTJM.js → chunk-5VOVNIOU.js} +1 -1
- package/dist/{chunk-NID6MGGC.js → chunk-5VRMQTKV.js} +8 -8
- package/dist/chunk-6453ISTQ.js +4 -0
- package/dist/{chunk-TFMC2WAS.js → chunk-6JU3WQOR.js} +1 -1
- package/dist/{chunk-MVQBVPWP.js → chunk-6KBDNYRW.js} +1 -1
- package/dist/{chunk-D2AUUIKG.js → chunk-6MVHRNWC.js} +1 -1
- package/dist/{chunk-TW7TA2AB.js → chunk-6ZHX56NM.js} +1 -1
- package/dist/chunk-732XHVR4.js +9 -0
- package/dist/{chunk-RNBM5JZI.js → chunk-7JGR7WPD.js} +4 -4
- package/dist/{chunk-BIJ7ADTZ.js → chunk-7WGOLPGM.js} +1 -1
- package/dist/{chunk-SXSMIMFY.js → chunk-A6RB4PIX.js} +4 -4
- package/dist/{chunk-BMPBVI7P.js → chunk-AGUA3O5O.js} +1 -1
- package/dist/{chunk-UVUBZL7K.js → chunk-ANFLQSGX.js} +5 -5
- package/dist/chunk-ARWMJSQJ.js +3 -0
- package/dist/chunk-AYZY3YNC.js +1 -0
- package/dist/{chunk-BSNWVZHW.js → chunk-B4KMHEFZ.js} +1 -1
- package/dist/chunk-B6YOP2IX.js +6 -0
- package/dist/{chunk-4VLKDANH.js → chunk-BBEOFKLY.js} +1 -1
- package/dist/{chunk-22S6LG6D.js → chunk-BCDG4N6L.js} +1 -1
- package/dist/{chunk-DFDDRKIJ.js → chunk-BCUQXILM.js} +1 -1
- package/dist/{chunk-5TFTSYOD.js → chunk-BVTNGW5S.js} +1 -1
- package/dist/{chunk-TVJRENCQ.js → chunk-BWUU565Y.js} +9 -9
- package/dist/{chunk-SBHFEWR6.js → chunk-C4UL2UNR.js} +1 -1
- package/dist/{chunk-DOCUM3K7.js → chunk-CAG3TSV2.js} +1 -1
- package/dist/chunk-CE5BARZI.js +16 -0
- package/dist/chunk-CJB73MHF.js +2 -0
- package/dist/{chunk-N6DTTOB6.js → chunk-CKPVXDKX.js} +3 -3
- package/dist/chunk-CO5RKOVX.js +20 -0
- package/dist/chunk-CRXFSN5K.js +20 -0
- package/dist/chunk-CVNJSD2J.js +18 -0
- package/dist/{chunk-RYBJ6MMM.js → chunk-CXMTDYVI.js} +1 -1
- package/dist/chunk-D7IXMMZT.js +9 -0
- package/dist/chunk-DNWV6N4P.js +5 -0
- package/dist/{chunk-KZHPX4FM.js → chunk-DWBZ3Z34.js} +2 -2
- package/dist/chunk-DZTAGMNY.js +100 -0
- package/dist/chunk-E4E7MACR.js +20 -0
- package/dist/{chunk-DZNG34DC.js → chunk-EFFF3FCS.js} +23 -23
- package/dist/{chunk-CPK7JTN3.js → chunk-EGAV5LSX.js} +1 -1
- package/dist/{chunk-M5P6A7KS.js → chunk-ENL5L6NR.js} +1 -1
- package/dist/chunk-EW3L4W2I.js +14 -0
- package/dist/{chunk-6GWZ5UPX.js → chunk-EWVOGTEX.js} +1 -1
- package/dist/{chunk-I7HDD4IM.js → chunk-EXNAAHN4.js} +2 -2
- package/dist/{chunk-YDYDR72S.js → chunk-F4DIVARP.js} +1 -1
- package/dist/{chunk-WYN5KVU4.js → chunk-F7F6Z64G.js} +3 -3
- package/dist/{chunk-5PY4H4ZJ.js → chunk-FBUUXK5G.js} +1 -1
- package/dist/chunk-FKNJSD6B.js +14 -0
- package/dist/{chunk-D7FT2PXG.js → chunk-FLEG5KP5.js} +5 -5
- package/dist/{chunk-4OFD6ICH.js → chunk-FLQZ7GQ3.js} +10 -10
- package/dist/{chunk-DXTKNHWG.js → chunk-FPGRKHUW.js} +12 -12
- package/dist/chunk-G4EVQD5U.js +8 -0
- package/dist/chunk-G6CTTBKE.js +9 -0
- package/dist/{chunk-3CST4ZDP.js → chunk-GS5AISRS.js} +4 -4
- package/dist/{chunk-4Y4PWKMM.js → chunk-GVC535IA.js} +3 -3
- package/dist/{chunk-EYX6KLCZ.js → chunk-H7MJM2WI.js} +2 -2
- package/dist/chunk-HJWTWS5E.js +8 -0
- package/dist/{chunk-VH6GB73Q.js → chunk-HL6JSDN3.js} +1 -1
- package/dist/chunk-HNQPF5QZ.js +2 -0
- package/dist/{chunk-WRORJNS5.js → chunk-HQMN5THW.js} +10 -10
- package/dist/chunk-HUF34LSW.js +15 -0
- package/dist/chunk-IB4333CI.js +14 -0
- package/dist/chunk-IGNZULKG.js +17 -0
- package/dist/{chunk-EZULNHQH.js → chunk-IJIESSTX.js} +5 -5
- package/dist/{chunk-S7VSXUKS.js → chunk-IJWFKUYA.js} +4 -4
- package/dist/chunk-IK2WXW2E.js +27 -0
- package/dist/chunk-IMA5SXEC.js +2 -0
- package/dist/{chunk-UZMZ2EDW.js → chunk-IMOPDLMA.js} +1 -1
- package/dist/{chunk-2FLYC6I2.js → chunk-IN4KV3SJ.js} +1 -1
- package/dist/chunk-IPTCV6CQ.js +69 -0
- package/dist/{chunk-ZWAVSUWT.js → chunk-IQWIYZB5.js} +2 -2
- package/dist/chunk-IX6QMUJQ.js +9 -0
- package/dist/{chunk-4G5VLI7E.js → chunk-JDQGHQ2C.js} +1 -1
- package/dist/{chunk-3S3DYAVB.js → chunk-JIW5CJXC.js} +2 -2
- package/dist/{chunk-P42YNSKI.js → chunk-JKDEE35P.js} +1 -1
- package/dist/chunk-JKHWZ2ZY.js +19 -0
- package/dist/{chunk-CKZ6ZDU5.js → chunk-JS6ZSEZJ.js} +1 -1
- package/dist/chunk-K4D63NP3.js +12 -0
- package/dist/chunk-KEK47CP3.js +12 -0
- package/dist/chunk-KWT6GT4M.js +29 -0
- package/dist/{chunk-SR4XAYLC.js → chunk-L67VXJMF.js} +1 -1
- package/dist/chunk-LB3A53D5.js +8 -0
- package/dist/{chunk-D323R2FT.js → chunk-LNARMEEZ.js} +1 -1
- package/dist/{chunk-CZ25A5RS.js → chunk-LNQVTH5S.js} +1 -1
- package/dist/chunk-LUWRPPJA.js +7 -0
- package/dist/chunk-M554OMPA.js +2 -0
- package/dist/{chunk-BVW5U7QQ.js → chunk-M5GMIQ47.js} +3 -3
- package/dist/{chunk-GX2GSDJP.js → chunk-MAMWQCJ6.js} +1 -1
- package/dist/{chunk-ZTB6EMC7.js → chunk-MV6WDGB6.js} +1 -1
- package/dist/chunk-MWIT4UN2.js +14 -0
- package/dist/{chunk-JPRJQ6B7.js → chunk-N3JXHNID.js} +10 -10
- package/dist/{chunk-ZOSIPTXM.js → chunk-N45ACN3G.js} +2 -2
- package/dist/{chunk-EYKUKN32.js → chunk-N7T63BVD.js} +4 -4
- package/dist/chunk-NHH2MXFU.js +2 -0
- package/dist/chunk-NHVXVHUR.js +23 -0
- package/dist/{chunk-J47HXHSL.js → chunk-O5LQBBW2.js} +7 -7
- package/dist/{chunk-IHQX4GYD.js → chunk-OQ2EDMB2.js} +1 -1
- package/dist/chunk-OUSKOWNP.js +12 -0
- package/dist/chunk-OV2SWQPT.js +22 -0
- package/dist/chunk-OX2DOOOI.js +8 -0
- package/dist/{chunk-6KO5VTL7.js → chunk-OZAAIE4E.js} +1 -1
- package/dist/{chunk-Z2YGQBLZ.js → chunk-P3DTYFMC.js} +2 -2
- package/dist/chunk-P3OBE43Q.js +8 -0
- package/dist/{chunk-2UXAI77F.js → chunk-P4XTWAKJ.js} +1 -1
- package/dist/{chunk-7PCI6AUU.js → chunk-PB7G6CJ7.js} +1 -1
- package/dist/chunk-PDB5W7VI.js +6 -0
- package/dist/chunk-PDXPMHG3.js +4 -0
- package/dist/chunk-POCQ7ZL4.js +3 -0
- package/dist/chunk-PVR4KU7H.js +7 -0
- package/dist/{chunk-2RBWQVDC.js → chunk-PYLNMN6E.js} +13 -13
- package/dist/chunk-Q7KTTDUS.js +11 -0
- package/dist/{chunk-3PGK3VFS.js → chunk-QC6OK3ED.js} +1 -1
- package/dist/{chunk-MEJK6PBN.js → chunk-QSJR7EI7.js} +3 -3
- package/dist/chunk-QWHQJNKL.js +1 -0
- package/dist/{chunk-QDLGU62M.js → chunk-QZKWIVZW.js} +1 -1
- package/dist/chunk-R2VKEMZH.js +3 -0
- package/dist/{chunk-EXWGPXOS.js → chunk-RBD7SB6M.js} +1 -1
- package/dist/chunk-RC6UHOAV.js +4 -0
- package/dist/{chunk-VYXDI63I.js → chunk-RDKBMX6U.js} +1 -1
- package/dist/{chunk-45S6M77O.js → chunk-RULVWW4A.js} +6 -6
- package/dist/chunk-RUTUVS4H.js +1 -0
- package/dist/{chunk-MAOJENIB.js → chunk-RWJCKZEY.js} +1 -1
- package/dist/chunk-S4Z657L6.js +6 -0
- package/dist/{chunk-B2XDNBR3.js → chunk-SC63O7AL.js} +1 -1
- package/dist/{chunk-Q3OCGLW7.js → chunk-SOP447EP.js} +2 -2
- package/dist/{chunk-CDRXZBVR.js → chunk-TBPHW42V.js} +1 -1
- package/dist/chunk-TLRCTNUF.js +6 -0
- package/dist/chunk-TNTQL6SX.js +1 -0
- package/dist/chunk-TTHWXGT7.js +11 -0
- package/dist/{chunk-KWX6NAOR.js → chunk-TVL3JPMY.js} +1 -1
- package/dist/chunk-U5N6PSXO.js +9 -0
- package/dist/{chunk-LBLV64XG.js → chunk-UE4PVCA5.js} +2 -2
- package/dist/{chunk-SZIENHKR.js → chunk-UKDJUYIV.js} +1 -1
- package/dist/chunk-UQYNPYF4.js +1 -0
- package/dist/chunk-URHGHXDN.js +1 -0
- package/dist/{chunk-6WWAQC5V.js → chunk-VG2R6PZV.js} +1 -1
- package/dist/{chunk-RWGSMZGS.js → chunk-VVAJ23SD.js} +1 -1
- package/dist/chunk-VVGL5O4F.js +8 -0
- package/dist/chunk-VVJIKS47.js +1 -0
- package/dist/chunk-WE7CYRZT.js +7 -0
- package/dist/{chunk-NGBT7AHL.js → chunk-WH3JHMEA.js} +8 -8
- package/dist/chunk-WUKN5WUM.js +11 -0
- package/dist/{chunk-ET2EF5CI.js → chunk-X7PM7JOD.js} +1 -1
- package/dist/{chunk-4NXMMWL6.js → chunk-XD34TCRG.js} +1 -1
- package/dist/{chunk-Y4MI6NRI.js → chunk-XNWQ72WA.js} +1 -1
- package/dist/{chunk-Y6IQYQYN.js → chunk-XS4HFUTW.js} +2 -2
- package/dist/{chunk-Y5T257HX.js → chunk-XZYAFTW4.js} +4 -4
- package/dist/{chunk-KFJIO5ED.js → chunk-Y44ABEW3.js} +1 -1
- package/dist/chunk-YWGC7J6B.js +11 -0
- package/dist/{chunk-MMFJBWJC.js → chunk-Z3JW77LH.js} +1 -1
- package/dist/chunk-ZAU2HIRH.js +21 -0
- package/dist/{chunk-Y53KNQKL.js → chunk-ZDMZM7HD.js} +2 -2
- package/dist/{chunk-ZCHBOAPA.js → chunk-ZHHEMSOD.js} +2 -2
- package/dist/chunk-ZOHQVSB3.js +27 -0
- package/dist/{chunk-G63BCOQ6.js → chunk-ZTL2RPNY.js} +1 -1
- package/dist/{chunk-U4BMS5EV.js → chunk-ZYDZY6ED.js} +1 -1
- package/dist/data/DataTable.js +1 -1
- package/dist/data/Kanban.js +1 -1
- package/dist/data/ListFooter.js +1 -1
- package/dist/data/ListLoadError.js +1 -1
- package/dist/data/Pagination.js +1 -1
- package/dist/file-intake/index.js +1 -1
- package/dist/forms/AlignmentGrid.js +1 -1
- package/dist/forms/BorderInput.js +1 -1
- package/dist/forms/BrandAssetEditor.js +1 -1
- package/dist/forms/Button.js +1 -1
- package/dist/forms/Calendar.js +1 -1
- package/dist/forms/ColorPicker.js +1 -1
- package/dist/forms/ComposerAttachments.js +1 -1
- package/dist/forms/CornersInput.js +1 -1
- package/dist/forms/DatePicker.js +1 -1
- package/dist/forms/DateRangePicker.js +1 -1
- package/dist/forms/DateTimePicker.js +1 -1
- package/dist/forms/DisplayChips.js +1 -1
- package/dist/forms/FilePicker.js +1 -1
- package/dist/forms/FormErrorSummary.js +1 -1
- package/dist/forms/FormField.js +1 -1
- package/dist/forms/IconButton.js +1 -1
- package/dist/forms/IconPicker.js +1 -1
- package/dist/forms/ImageFocusPoint.js +1 -1
- package/dist/forms/Input.js +1 -1
- package/dist/forms/InputNumber.js +1 -1
- package/dist/forms/LinkPicker.js +1 -1
- package/dist/forms/MediaLibrary.d.ts +6 -1
- package/dist/forms/MediaLibrary.js +1 -1
- package/dist/forms/MediaUploadField.js +1 -1
- package/dist/forms/MediaUploadGrid.js +1 -1
- package/dist/forms/MediaUsedInList.js +1 -1
- package/dist/forms/NumericKeypad.js +1 -1
- package/dist/forms/PictureTiles.js +1 -1
- package/dist/forms/PositionInput.js +1 -1
- package/dist/forms/RadioGroup.js +1 -1
- package/dist/forms/Segmented.js +1 -1
- package/dist/forms/Select.d.ts +6 -0
- package/dist/forms/Select.js +1 -1
- package/dist/forms/SidesInput.js +1 -1
- package/dist/forms/Slider.js +1 -1
- package/dist/forms/Snippet.js +1 -1
- package/dist/forms/SplitButton.js +1 -1
- package/dist/forms/TagInput.js +1 -1
- package/dist/forms/TextToolbar.js +1 -1
- package/dist/forms/Textarea.js +1 -1
- package/dist/forms/TimePicker.js +1 -1
- package/dist/forms/WidthsBar.d.ts +7 -8
- package/dist/forms/WidthsBar.js +1 -1
- package/dist/forms/buttonStyles.js +1 -1
- package/dist/forms/mediaLibraryMenu.js +1 -1
- package/dist/forms/mediaMoveItems.js +1 -1
- package/dist/forms/styles.d.ts +2 -2
- package/dist/forms/styles.js +1 -1
- package/dist/forms/textAlign.js +1 -1
- package/dist/forms/useFileIntake.js +1 -1
- package/dist/icons/efficient-glyphs.js +1 -1
- package/dist/icons/efficient-looks.js +1 -1
- package/dist/icons/efficient.js +1 -1
- package/dist/icons/glyphs/SpinnerIcon.js +1 -1
- package/dist/icons/looks/map.js +1 -1
- package/dist/icons/sets.js +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.js +695 -695
- package/dist/locales/zh-Hans.js +1 -1
- package/dist/map/index.js +12 -12
- package/dist/markdown/index.js +5 -5
- package/dist/page-tabs/index.js +5 -5
- package/dist/pdf/index.js +1 -1
- package/dist/shell/Accordion.js +1 -1
- package/dist/shell/AppUpdateBanner.js +1 -1
- package/dist/shell/Avatar.js +1 -1
- package/dist/shell/Banner.js +1 -1
- package/dist/shell/Breadcrumbs.js +1 -1
- package/dist/shell/BudgetBar.js +1 -1
- package/dist/shell/Card.js +1 -1
- package/dist/shell/ColoredBadge.js +1 -1
- package/dist/shell/ConfirmDialog.js +1 -1
- package/dist/shell/ContainerFillChart.js +1 -1
- package/dist/shell/ContextMenu.js +1 -1
- package/dist/shell/CountBadge.js +1 -1
- package/dist/shell/Dialog.js +1 -1
- package/dist/shell/Drawer.js +1 -1
- package/dist/shell/DropdownMenu.js +1 -1
- package/dist/shell/EditableGrid.js +1 -1
- package/dist/shell/EmptyState.js +1 -1
- package/dist/shell/EmptyValue.js +1 -1
- package/dist/shell/GlobalSearch.js +1 -1
- package/dist/shell/HelpCenter.js +1 -1
- package/dist/shell/IconRail.js +1 -1
- package/dist/shell/ImageLightbox.js +1 -1
- package/dist/shell/ItemCount.d.ts +20 -0
- package/dist/shell/ItemCount.js +1 -0
- package/dist/shell/Kbd.js +1 -1
- package/dist/shell/LanguageSelect.js +1 -1
- package/dist/shell/Markdown.js +1 -1
- package/dist/shell/MetricBar.js +1 -1
- package/dist/shell/MetricBarLegend.js +1 -1
- package/dist/shell/MilestoneTimeline.js +1 -1
- package/dist/shell/PageHeader.js +1 -1
- package/dist/shell/Popover.js +1 -1
- package/dist/shell/PopupMenu.js +1 -1
- package/dist/shell/ProductionTimeline.js +1 -1
- package/dist/shell/ResizeHandle.js +1 -1
- package/dist/shell/Result.js +1 -1
- package/dist/shell/SearchableSelect.js +1 -1
- package/dist/shell/SettingReset.js +1 -1
- package/dist/shell/SettingRow.js +1 -1
- package/dist/shell/SidebarLayout.js +1 -1
- package/dist/shell/SidebarNav.d.ts +19 -5
- package/dist/shell/SidebarNav.js +1 -1
- package/dist/shell/SortableList.js +1 -1
- package/dist/shell/Spinner.js +1 -1
- package/dist/shell/Statistic.js +1 -1
- package/dist/shell/StatusBadge.js +1 -1
- package/dist/shell/StepChain.js +1 -1
- package/dist/shell/Tabs.js +1 -1
- package/dist/shell/TimeAgo.js +1 -1
- package/dist/shell/TimelineTrack.js +1 -1
- package/dist/shell/Tooltip.js +1 -1
- package/dist/shell/TopNav.js +1 -1
- package/dist/shell/TransferProgress.js +1 -1
- package/dist/shell/Tree.d.ts +15 -6
- package/dist/shell/Tree.js +1 -1
- package/dist/shell/language.js +1 -1
- package/dist/shell/strings.d.ts +24 -2
- package/dist/shell/strings.js +1 -1
- package/dist/shell/toast.js +1 -1
- package/dist/telemetry/index.js +1 -1
- package/dist/templates/AuthScreen.js +1 -1
- package/dist/templates/ChatTemplate.js +1 -1
- package/dist/templates/CheckoutTemplate.js +1 -1
- package/dist/templates/DashboardTemplate.js +1 -1
- package/dist/templates/DataTablePage.js +1 -1
- package/dist/templates/EmailTemplate.js +1 -1
- package/dist/templates/ErrorBoundary.js +1 -1
- package/dist/templates/ErrorPage.js +1 -1
- package/dist/templates/FormLayoutPage.js +1 -1
- package/dist/templates/GalleryTemplate.js +1 -1
- package/dist/themes.css +101 -0
- package/dist/tokens/colour.d.ts +42 -0
- package/dist/tokens/colour.js +1 -0
- package/dist/tokens/elevation.d.ts +3 -1
- package/dist/tokens/elevation.js +1 -1
- package/dist/ui/index.d.ts +2 -0
- package/dist/ui/index.js +1 -1
- package/dist/ui.css +266 -24
- package/dist/version.js +1 -1
- package/package.json +1 -1
- package/dist/Browser-FTCJCMD3.js +0 -43
- package/dist/Calculator-7O7HXEKH.js +0 -29
- package/dist/CurrencyConverter-IVJJCYZ7.js +0 -21
- package/dist/Files-YWBBU2FZ.js +0 -87
- package/dist/Notepad-KKKCTUB3.js +0 -25
- package/dist/PdfViewer-KJCJ6EPG.js +0 -1
- package/dist/Preview-CHV67AA7.js +0 -177
- package/dist/Sidebar-6I4FC5AK.js +0 -43
- package/dist/Spreadsheet-SNLKLOLL.js +0 -37
- package/dist/Stock-PHY6Z26A.js +0 -16
- package/dist/Weather-YQA5CAFQ.js +0 -60
- package/dist/WorldClock-J6L7FWI2.js +0 -32
- package/dist/chunk-2NMT3Y5H.js +0 -20
- package/dist/chunk-3WC6ITJ3.js +0 -11
- package/dist/chunk-3ZHFKOFX.js +0 -14
- package/dist/chunk-454DAGYG.js +0 -19
- package/dist/chunk-4CANQ3B3.js +0 -1
- package/dist/chunk-4CFOKYVR.js +0 -12
- package/dist/chunk-4IU5BSVE.js +0 -2
- package/dist/chunk-4IVT244O.js +0 -8
- package/dist/chunk-4SZDP3JF.js +0 -12
- package/dist/chunk-63EK6S3W.js +0 -3
- package/dist/chunk-64WSMLXG.js +0 -2
- package/dist/chunk-6BCFVOG7.js +0 -22
- package/dist/chunk-6NMDKOQA.js +0 -7
- package/dist/chunk-7C56GLLI.js +0 -28
- package/dist/chunk-7DKPJUGU.js +0 -2
- package/dist/chunk-7MSFHQAY.js +0 -8
- package/dist/chunk-7OCNF4AI.js +0 -5
- package/dist/chunk-AAW27HJY.js +0 -3
- package/dist/chunk-BI6ZLD4X.js +0 -11
- package/dist/chunk-BIYL7CEI.js +0 -2
- package/dist/chunk-BOBUSE33.js +0 -2
- package/dist/chunk-BUGAWNOC.js +0 -14
- package/dist/chunk-CRLSG5AY.js +0 -9
- package/dist/chunk-DITCVBR7.js +0 -15
- package/dist/chunk-DODH46ZQ.js +0 -8
- package/dist/chunk-E5ALJIXV.js +0 -9
- package/dist/chunk-E6UCGCOC.js +0 -1
- package/dist/chunk-EGDJEY4K.js +0 -27
- package/dist/chunk-EL2RLUT6.js +0 -20
- package/dist/chunk-ET32NQHX.js +0 -2
- package/dist/chunk-EZ3BQ6PK.js +0 -18
- package/dist/chunk-FRPNTDP4.js +0 -8
- package/dist/chunk-GATKJSGL.js +0 -8
- package/dist/chunk-GNPTNAZH.js +0 -4
- package/dist/chunk-JPP7UWQA.js +0 -4
- package/dist/chunk-K7KQDPLW.js +0 -27
- package/dist/chunk-K7U4RWXJ.js +0 -1
- package/dist/chunk-KJY57QPT.js +0 -100
- package/dist/chunk-LGAN7DNC.js +0 -9
- package/dist/chunk-MEYYQC43.js +0 -8
- package/dist/chunk-MVP6Q6KV.js +0 -1
- package/dist/chunk-NDO24PK6.js +0 -21
- package/dist/chunk-OSA24YH6.js +0 -19
- package/dist/chunk-P5BOTIJU.js +0 -6
- package/dist/chunk-PCQPV6MS.js +0 -6
- package/dist/chunk-PF3ANJFI.js +0 -1
- package/dist/chunk-PXEEDRPW.js +0 -14
- package/dist/chunk-Q23EHOXW.js +0 -17
- package/dist/chunk-Q5MD3VY6.js +0 -3
- package/dist/chunk-QR4RM7PO.js +0 -1
- package/dist/chunk-REVC6YPT.js +0 -7
- package/dist/chunk-RSO67DWS.js +0 -8
- package/dist/chunk-S2OIRC5H.js +0 -12
- package/dist/chunk-SB7OTZI4.js +0 -69
- package/dist/chunk-SRKSGUGT.js +0 -23
- package/dist/chunk-SURSVJA2.js +0 -6
- package/dist/chunk-TH6EAYMO.js +0 -29
- package/dist/chunk-TIQKDAON.js +0 -11
- package/dist/chunk-TVDVVPTN.js +0 -1
- package/dist/chunk-VU6VPKM3.js +0 -11
- package/dist/chunk-W5M6P4DZ.js +0 -8
- package/dist/chunk-X6PPP6NX.js +0 -14
- package/dist/chunk-XLD53X4P.js +0 -9
- package/dist/chunk-XSPDPN5O.js +0 -26
- package/dist/chunk-Y37PBT4H.js +0 -9
- package/dist/chunk-YAEUF3GP.js +0 -1
- package/dist/chunk-YALPQIBR.js +0 -7
- package/dist/chunk-ZK2SULCA.js +0 -16
- package/dist/chunk-ZSFUNXRD.js +0 -5
- /package/dist/{chunk-KJRYEKQP.js → chunk-DSIDJYH7.js} +0 -0
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{optionNoteClass as e}from"./chunk-
|
|
1
|
+
import{optionNoteClass as e}from"./chunk-URHGHXDN.js";import{DEFAULT_SHELL_STRINGS as n,useShellStrings as o}from"./chunk-QWHQJNKL.js";import{jsxs as t,jsx as a}from"react/jsx-runtime";function l(n){const o=n.depth?{paddingInlineStart:16*n.depth+"px"}:{};/* @__PURE__ */
|
|
2
2
|
return t("span",{"data-move-target":"",className:"flex min-w-0 flex-col",style:o,children:[
|
|
3
3
|
/* @__PURE__ */a("span",{children:n.label}),n.disabledReason&&/* @__PURE__ */a("span",{className:e(),children:n.disabledReason})]})}function r({count:e,kind:o="file",targets:t,onPick:a},r=n.media){const i=[{type:"label",key:"move-to",label:r.moveTo(e,o)}];if(!t.length)return i.push({type:"status",key:"move-nowhere",label:r.moveNowhere}),i;let s;return t.forEach((e,n)=>{(n>0&&e.group!==s||0===n&&e.group)&&(n>0&&i.push({type:"divider",key:`group-line:${n}`}),e.group&&i.push({type:"label",key:`group:${n}`,label:e.group})),s=e.group,i.push({key:e.key,label:l(e),disabled:!!e.disabledReason,onSelect:()=>a(e)})}),i}function i(e,o=n.media){const{head:t=!0,icon:a,disabled:l,key:i="move-to-menu",...s}=e,u=r(s,o);return{type:"submenu",key:i,label:o.moveToMenu,icon:a,disabled:l,maxHeight:320,items:t?u:u.slice(1)}}function s(e){return r(e,o().media)}export{r as mediaMoveItems,i as mediaMoveSubmenu,s as useMediaMoveItems};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{Icon as e}from"./chunk-FSPFV4MI.js";import{DEFAULT_SHELL_STRINGS as t}from"./chunk-
|
|
1
|
+
import{Icon as e}from"./chunk-FSPFV4MI.js";import{DEFAULT_SHELL_STRINGS as t}from"./chunk-QWHQJNKL.js";import{jsx as r}from"react/jsx-runtime";var n=["left","center","right","justify"],a={left:"align-left",center:"align-center",right:"align-right",justify:"align-justify"};function i(t){switch(t){case"left":/* @__PURE__ */
|
|
2
2
|
return r(e,{name:"align-left"});case"center":/* @__PURE__ */
|
|
3
3
|
return r(e,{name:"align-center"});case"right":/* @__PURE__ */
|
|
4
4
|
return r(e,{name:"align-right"});case"justify":/* @__PURE__ */
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import{FormField as e}from"./chunk-
|
|
2
|
-
return o(e,{label:g,htmlFor
|
|
3
|
-
/* @__PURE__ */o("button",{ref:C,type:"button",id
|
|
1
|
+
import{FormField as e}from"./chunk-6KBDNYRW.js";import{dropzoneClass as t,zoneFocusClass as a,CloseGlyph as r}from"./chunk-GVC535IA.js";import{useFileIntake as n,humanSize as i,FileIntakeAlert as s}from"./chunk-F4DIVARP.js";import{useShellStrings as l}from"./chunk-QWHQJNKL.js";import{forwardRef as c,useId as m}from"react";import{jsxs as o,jsx as d}from"react/jsx-runtime";var p=c(function({files:c,onChange:p,accept:u,acceptHint:h,multiple:x=!0,maxSizeBytes:b,maxFiles:f,disabled:y=!1,label:g,hint:N,error:j,required:k,className:v=""},C){const $=m(),z=l().files,F=n({accept:u,acceptHint:h,maxSizeBytes:b,maxFiles:f,multiple:x,disabled:y,currentCount:c.length,onAccept:e=>p(x?[...c,...e]:e.slice(0,1))}),q=j?`${$}-error`:N?`${$}-hint`:void 0;/* @__PURE__ */
|
|
2
|
+
return o(e,{label:g,htmlFor:$,hint:N,error:j,required:k,className:v,children:[
|
|
3
|
+
/* @__PURE__ */o("button",{ref:C,type:"button",id:$,disabled:y,onClick:F.open,"aria-invalid":!!j||void 0,"aria-required":k||void 0,"aria-describedby":q,...F.zoneProps,className:t(F.dragOver,y,a(y),"px-4 py-6"),children:[
|
|
4
4
|
/* @__PURE__ */o("span",{children:[
|
|
5
|
-
/* @__PURE__ */d("span",{className:"text-sm font-medium text-blue-600",children:x?
|
|
6
|
-
/* @__PURE__ */d("span",{className:"text-sm text-gray-500",children:` ${x?
|
|
7
|
-
/* @__PURE__ */d("input",{
|
|
5
|
+
/* @__PURE__ */d("span",{className:"text-sm font-medium text-blue-600",children:x?z.chooseMany:z.chooseOne}),
|
|
6
|
+
/* @__PURE__ */d("span",{className:"text-sm text-gray-500",children:` ${x?z.dragMany:z.dragOne}`})]}),h&&/* @__PURE__ */d("span",{className:"text-xs text-gray-400",children:h})]}),
|
|
7
|
+
/* @__PURE__ */d("input",{...F.inputProps}),c.length>0&&/* @__PURE__ */d("ul",{className:"mt-2 flex flex-col gap-1",children:c.map((e,t)=>/* @__PURE__ */o("li",{className:"flex items-center justify-between gap-3 rounded-md bg-gray-50 px-3 py-2",children:[
|
|
8
8
|
/* @__PURE__ */d("span",{className:"min-w-0 flex-1 truncate text-sm text-gray-800",title:e.name,children:e.name}),
|
|
9
|
-
/* @__PURE__ */d("span",{className:"shrink-0 text-xs tabular-nums text-gray-500",children:i(e.size,
|
|
10
|
-
/* @__PURE__ */d("button",{type:"button",disabled:y,onClick:()=>{
|
|
11
|
-
/* @__PURE__ */d(s,{rejections
|
|
9
|
+
/* @__PURE__ */d("span",{className:"shrink-0 text-xs tabular-nums text-gray-500",children:i(e.size,z)}),
|
|
10
|
+
/* @__PURE__ */d("button",{type:"button",disabled:y,onClick:()=>{F.clearRejections(),p(c.filter((e,a)=>a!==t))},"aria-label":z.remove(e.name),className:"shrink-0 text-gray-400 hover:text-gray-600",children:/* @__PURE__ */d(r,{})})]},`${e.name}-${t}`))}),
|
|
11
|
+
/* @__PURE__ */d(s,{rejections:F.rejections})]})});export{p as FilePicker_default};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{appendKey as r,backspace as a}from"./chunk-VEPVOHCV.js";import{Button_default as e}from"./chunk-
|
|
1
|
+
import{appendKey as r,backspace as a}from"./chunk-VEPVOHCV.js";import{Button_default as e}from"./chunk-NHH2MXFU.js";import{useShellStrings as n}from"./chunk-QWHQJNKL.js";import{jsxs as i,jsx as c}from"react/jsx-runtime";var o=["1","2","3","4","5","6","7","8","9",".","0"];function l({value:l,onChange:s,onEnter:t,enterLabel:m,enterDisabled:d,className:h=""}){const p=n().keypad,u=r=>{r!==l&&s(r)};/* @__PURE__ */
|
|
2
2
|
return i("div",{className:`grid grid-cols-3 gap-3 ${h}`.trim(),children:[o.map(a=>/* @__PURE__ */c(e,{size:"touch-xl",variant:"secondary",onClick:()=>u(r(l,a)),children:a},a)),
|
|
3
3
|
/* @__PURE__ */c(e,{size:"touch-xl",variant:"secondary","aria-label":p.backspace,onClick:()=>u(a(l)),children:"⌫"}),t&&/* @__PURE__ */c(e,{size:"touch-xl",variant:"primary",className:"col-span-3",disabled:d,onClick:t,children:m??p.enter})]})}export{l as NumericKeypad};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{useShellLanguage as e}from"./chunk-
|
|
1
|
+
import{useShellLanguage as e}from"./chunk-3APSMJPN.js";import{RadioGroup as a}from"./chunk-32VV2J22.js";import{Select_default as n}from"./chunk-CO5RKOVX.js";import{Icon as t}from"./chunk-FSPFV4MI.js";import{useShellStrings as l}from"./chunk-QWHQJNKL.js";import{jsxs as s,jsx as i}from"react/jsx-runtime";function r(e){const a=Math.max(0,...e.map(e=>[...e].reduce((e,a)=>e+((a.codePointAt(0)??0)>=11904?1:.62),0)));return Math.round(10*(a+3.5))/10}function m({size:a="sm",className:m=""}){const{language:o,languages:c,setLanguage:g}=e(),u=l().language;return c.length<2?null:/* @__PURE__ */s("span",{className:`inline-flex items-center gap-2 text-ink-faint ${m}`.trim(),children:[
|
|
2
2
|
/* @__PURE__ */i(t,{name:"globe","aria-hidden":!0,className:"h-4 w-4 shrink-0"}),
|
|
3
3
|
/* @__PURE__ */i("span",{className:"block",style:{width:`${r(c.map(e=>e.name))}em`},children:/* @__PURE__ */i(n,{size:a,touchSize:a,"aria-label":u.title,value:o,onChange:e=>{g(e)},options:c.map(({tag:e,name:a})=>({value:e,label:a,lang:e}))})})]})}function o({description:n,className:t=""}){const{language:r,languages:m,setLanguage:o}=e(),c=l().language;return m.length<2?null:/* @__PURE__ */s("div",{className:`space-y-4 ${t}`.trim(),children:[
|
|
4
4
|
/* @__PURE__ */s("div",{children:[
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import{useSidebarSheet as e}from"./chunk-QWK6DRSN.js";import{resolveSeverity as t,severityWord as n}from"./chunk-TZFNWAED.js";import{ItemCount as r}from"./chunk-PDXPMHG3.js";import{Icon as l}from"./chunk-FSPFV4MI.js";import{useBrowserState as a}from"./chunk-D65T4H6J.js";import{useShellStrings as i}from"./chunk-QWHQJNKL.js";import{useId as o,useRef as c,useEffect as s,Children as u,isValidElement as d}from"react";import{jsx as m,jsxs as h,Fragment as p}from"react/jsx-runtime";function f({children:e,count:t,countLabel:n}){return null==t?/* @__PURE__ */m("p",{className:"px-3 pb-1 pt-1 text-xs font-semibold uppercase tracking-wide text-gray-500",children:e}):/* @__PURE__ */h("p",{className:"flex items-center justify-between gap-2 px-3 pb-1 pt-1 text-xs font-semibold uppercase tracking-wide text-gray-500",children:[
|
|
2
|
+
/* @__PURE__ */m("span",{className:"min-w-0 truncate",children:e}),
|
|
3
|
+
/* @__PURE__ */m(r,{count:t,label:n,showZero:!0})]})}function b(e){return"flex min-w-0 flex-1 items-center justify-between gap-2 rounded-r-lg border-l-2 h-8 px-3 text-sm "+(e?"border-blue-500 bg-accent-tint font-medium text-blue-700":"border-line text-ink hover:bg-gray-100")}function x({label:l,count:a,countLabel:u,active:d,onClick:f,icon:x,trailing:g,severity:w,depth:k=0}){const y=t(w,"SidebarNavItem"),v=i().severity,N=y?n(y,v):void 0,j=e(),S=o(),I=c(null),C=c(l);C.current=l,s(()=>{if(j&&d)return j.report(S,()=>C.current,I.current)},[j,d,S]);const L=/* @__PURE__ */h(p,{children:[null!=x&&/* @__PURE__ */m("span",{"aria-hidden":"true",className:"shrink-0 h-4 w-4",children:x}),y&&
|
|
4
|
+
/* @__PURE__ */m("span",{"aria-hidden":"true",title:N,className:`shrink-0 h-1.5 w-1.5 rounded-full ${y.fill}`}),
|
|
5
|
+
/* @__PURE__ */m("span",{className:"min-w-0 truncate mr-auto",title:"string"==typeof l?l:void 0,children:l}),y&&/* @__PURE__ */m("span",{className:"sr-only",children:N}),null!=a&&/* @__PURE__ */m(r,{count:a,label:u,active:d}),null!=g&&/* @__PURE__ */m("span",{className:"shrink-0",children:g})]});/* @__PURE__ */
|
|
6
|
+
return m("button",1===k?{ref:I,type:"button",onClick:f,className:"flex w-full pl-5 text-left",children:/* @__PURE__ */m("span",{className:b(d),children:L})}:{ref:I,type:"button",onClick:f,className:"flex w-full items-center justify-between gap-2 rounded-lg h-8 px-3 text-sm text-left "+(d?"bg-accent-tint font-medium text-blue-700":"text-ink hover:bg-gray-100"),children:L})}function g({label:e,count:t,countLabel:n,children:i,defaultExpanded:c=!0,storageKey:s}){const p=o(),[f,b]=a(()=>{if(s){let e=null;try{e=window.localStorage.getItem(s)}catch{}if("1"===e||"0"===e)return"1"===e}return c},c),x=!f&&u.toArray(i).some(e=>d(e)&&!0===e.props.active);/* @__PURE__ */
|
|
7
|
+
return h("div",{children:[
|
|
8
|
+
/* @__PURE__ */h("button",{type:"button",onClick:()=>{const e=!f;if(b(e),s)try{window.localStorage.setItem(s,e?"1":"0")}catch{}},"aria-expanded":f,"aria-controls":p,className:"flex w-full items-center gap-2 rounded-lg h-8 px-3 text-sm font-medium text-left "+(x?"bg-accent-tint text-blue-700":"text-ink-strong hover:bg-gray-100"),children:[
|
|
9
|
+
/* @__PURE__ */m("span",{className:"min-w-0 truncate",title:e,children:e}),
|
|
10
|
+
/* @__PURE__ */m(l,{name:"chevron-down",className:"mr-auto ml-0.5 size-3 shrink-0 text-ink-faintest transition-transform "+(f?"":"-rotate-90"),strokeWidth:2.6,"aria-hidden":"true"}),null!=t&&/* @__PURE__ */m(r,{count:t,label:n,active:x})]}),
|
|
11
|
+
/* @__PURE__ */m("div",{id:p,role:"group","aria-label":e,hidden:!f,children:i})]})}function w({label:e,count:t,countLabel:n,children:i,active:c=!1,defaultExpanded:s=!0,storageKey:u}){const d=o(),[p,f]=a(()=>{if(u){let e=null;try{e=window.localStorage.getItem(u)}catch{}if("1"===e||"0"===e)return"1"===e}return s},s),b=!p&&c;/* @__PURE__ */
|
|
12
|
+
return h("div",{children:[
|
|
13
|
+
/* @__PURE__ */h("button",{type:"button",onClick:()=>{const e=!p;if(f(e),u)try{window.localStorage.setItem(u,e?"1":"0")}catch{}},"aria-expanded":p,"aria-controls":d,className:"flex w-full items-center gap-2 rounded-lg px-3 pb-1 pt-1 text-xs font-semibold uppercase tracking-wide text-left "+(b?"bg-blue-50 text-blue-700":"text-gray-500 hover:bg-gray-100"),children:[
|
|
14
|
+
/* @__PURE__ */m("span",{className:"min-w-0 truncate",title:e,children:e}),
|
|
15
|
+
/* @__PURE__ */m(l,{name:"chevron-down",className:"mr-auto ml-0.5 size-3 shrink-0 transition-transform "+(p?"":"-rotate-90"),strokeWidth:2.6,"aria-hidden":"true"}),null!=t&&/* @__PURE__ */m(r,{count:t,label:n,active:b,showZero:!0})]}),
|
|
16
|
+
/* @__PURE__ */m("div",{id:d,role:"group","aria-label":e,hidden:!p,children:i})]})}export{f as SidebarGroupLabel,g as SidebarNavGroup,x as SidebarNavItem,w as SidebarSection};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{TimelineCard as e}from"./chunk-S4Z657L6.js";import{TimelineTrack as n,TimelineMilestoneIcon as s}from"./chunk-EFFF3FCS.js";import{toDayMs as i,fmtSliderDate as t,DAY_MS as a}from"./chunk-YDEIXM2A.js";import{useBrowserValueOnce as l}from"./chunk-D65T4H6J.js";import{useShellStrings as o,useShellLocale as r}from"./chunk-QWHQJNKL.js";import{jsx as h}from"react/jsx-runtime";function m({title:m,heading:d,subject:c,milestones:p,summary:u,endDate:g,phaseLabels:k,variant:v="card",edgeCaptions:f,highlightKeys:y=null,onHoverChange:b}){const M=l(Date.now,null),j=[],C=[],x=o().timeline,D=r();for(const e of p){const n=i(e.date??null);null===n?C.push({key:e.key,label:e.label,kind:e.kind}):j.push({...e,ms:n})}j.sort((e,n)=>e.ms-n.ms);const F=i(g??null);let H,L,N=!0;0===j.length?(L=F??M??0,H=L-30*a,N=null!==F||null!==M):(H=j[0].ms,L=F??j[j.length-1].ms,L-H<a&&(L=H+a));const w=j.length>0?Math.max(0,Math.round((L-H)/a)):0,K=u??(w>0?x.duration(w):void 0),O=[j.length>0?x.started(t(j[0].ms,D)):void 0,K,C.length>0?x.reached(j.length,p.length):void 0],E=j.map(e=>{return{key:e.key,ms:e.ms,kind:e.kind,label:e.label,detail:e.detail,preview:e.preview,glyph:e.glyph,onClick:e.onClick,onOpen:e.onOpen,priority:(n=e.kind,"dfm"===n?1:0),caption:e.caption,provisional:e.provisional};var n}),J={};for(const e of j)e.phase&&(J[e.phase]=J[e.phase]||[]).push(e.ms);const Q=Object.entries(J).filter(([,e])=>e.length>=2).map(([e,n])=>({key:e,label:k?.[e]??e,minMs:Math.min(...n),maxMs:Math.max(...n)})),S="rail"===v,A=N&&/* @__PURE__ */h("div",{className:"select-none",children:/* @__PURE__ */h(n,{axis:S?"spread":"compressed",labels:S?"none":"lanes",items:E,pending:C,phases:Q,startMs:H,endMs:L,todayMs:M??void 0,edgeCaptions:f,highlightKeys:y,onHoverChange:b,ariaLabel:x.milestones(m)})});/* @__PURE__ */
|
|
2
|
+
return h("div",S?{className:"shrink-0","data-timeline-variant":"rail",children:A}:{className:"shrink-0",children:/* @__PURE__ */h(e,{icon:/* @__PURE__ */h(s,{}),heading:d??m,subject:c,meta:O,children:A})})}export{m as MilestoneTimeline};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{choiceTrackClass as e,choiceTipClass as l,ChoiceContent as a,choiceItemClass as i}from"./chunk-
|
|
2
|
-
return n("div",b?{role:"radiogroup",...
|
|
1
|
+
import{choiceTrackClass as e,choiceTipClass as l,ChoiceContent as a,choiceItemClass as i}from"./chunk-JDQGHQ2C.js";import{Tooltip as r}from"./chunk-BCDG4N6L.js";import{useId as s}from"react";import{jsx as n,jsxs as o}from"react/jsx-runtime";function t({value:t,onChange:c,options:d,name:b,size:u="md",block:m=!1,label:h,className:p="","aria-labelledby":v,"aria-describedby":f}){const N={"aria-label":v?void 0:h,"aria-labelledby":v,"aria-describedby":f},g=s(),y=e(m,p),k=l(m);/* @__PURE__ */
|
|
2
|
+
return n("div",b?{role:"radiogroup",...N,className:y,children:d.map(e=>{const l=`${g}-${e.value}`,s=e.value===t,d=/* @__PURE__ */o("label",{htmlFor:l,className:i({size:u,selected:s,disabled:e.disabled,block:m}),children:[
|
|
3
3
|
/* @__PURE__ */n("input",{id:l,type:"radio",name:b,value:e.value,checked:s,disabled:e.disabled,"aria-describedby":e.title?`${l}-note`:void 0,onChange:()=>c(e.value),className:"absolute inset-0 m-0 h-full w-full appearance-none rounded-[inherit] bg-transparent cursor-[inherit] rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]"}),
|
|
4
|
-
/* @__PURE__ */n(a,{icon:e.icon,label:e.label}),e.title&&/* @__PURE__ */n("span",{id:`${l}-note`,className:"sr-only",children:e.title})]},e.value);return e.title?/* @__PURE__ */n(r,{content:e.title,className:k,children:d},e.value):d})}:{role:"group",...
|
|
4
|
+
/* @__PURE__ */n(a,{icon:e.icon,label:e.label}),e.title&&/* @__PURE__ */n("span",{id:`${l}-note`,className:"sr-only",children:e.title})]},e.value);return e.title?/* @__PURE__ */n(r,{content:e.title,className:k,children:d},e.value):d})}:{role:"group",...N,className:y,children:d.map(e=>{const l=e.value===t,s=/* @__PURE__ */n("button",{type:"button","aria-pressed":l,disabled:e.disabled,onClick:()=>c(e.value),className:i({size:u,selected:l,disabled:e.disabled,block:m}),children:/* @__PURE__ */n(a,{icon:e.icon,label:e.label})},e.value);return e.title?/* @__PURE__ */n(r,{content:e.title,className:k,children:s},e.value):s})})}export{t as Segmented};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import{firstEnabledIndex as e,matchTypeahead as t,lastEnabledIndex as r,nextEnabledIndex as n}from"./chunk-EO5RLFRX.js";import{flattenOptionItems as i,groupedRows as a,isOptionGroup as l,OptionCheck as o}from"./chunk-5F7HMNCX.js";import{useSettingAuto as d,useInSettingRow as s}from"./chunk-L65BESIE.js";import{inputClasses as c,PLACEHOLDER_INK as u}from"./chunk-AYZY3YNC.js";import{useIsMobile as p}from"./chunk-UGTRSRIW.js";import{optionNoteClass as m}from"./chunk-URHGHXDN.js";import{Icon as v}from"./chunk-FSPFV4MI.js";import{onOverlayOpen as h}from"./chunk-PGN5ME7B.js";import{Z_LAYERS as f}from"./chunk-62LW225J.js";import{useDropdownPosition as b,MENU_MAX_HEIGHT as g}from"./chunk-GLUJS42B.js";import{solidSurfaceStyle as y}from"./chunk-DTJRIWFR.js";import{registerModalEscapeInterceptor as x}from"./chunk-TWVUQUUD.js";import{useShellStrings as N}from"./chunk-QWHQJNKL.js";import{forwardRef as k,useId as w,useState as $,useRef as D,useMemo as S,useCallback as j,useEffect as H,useLayoutEffect as E}from"react";import{createPortal as I}from"react-dom";import{jsxs as T,jsx as C,Fragment as z}from"react/jsx-runtime";var O=e=>e.labelStyle?{lineHeight:1.25,...e.labelStyle}:void 0,R=k(function({value:e,onChange:t,options:r,placeholder:n,invalid:i,className:a="",size:l,touchSize:o,renderOption:p,renderValue:m,valueText:h,readOnly:f,footer:b,changed:g,auto:y,multiple:x,"aria-describedby":k,...$},D){const S=t,j=N(),H=d(),E=y??H,I=w(),O=s(),R=/* @__PURE__ */T("select",{ref:D,value:e,multiple:x||void 0,onChange:e=>S(x?Array.from(e.target.selectedOptions,e=>e.value):e.target.value),"aria-invalid":i||void 0,"aria-describedby":[k,E?I:void 0].filter(Boolean).join(" ")||void 0,className:c({invalid:i,size:l,auto:E,className:`${O&&!x?"appearance-none ":""}pr-8 ${a}`.trim()}),...$,children:[void 0!==n&&!x&&/* @__PURE__ */C("option",{value:"",disabled:!0,children:n}),
|
|
2
|
+
/* @__PURE__ */C(A,{items:r})]}),B=O&&!x?/* @__PURE__ */T("div",{className:"relative",children:[R,
|
|
3
|
+
/* @__PURE__ */C(v,{name:"chevron-up-down","aria-hidden":"true",className:`pointer-events-none absolute right-2.5 top-1/2 h-4 w-4 -translate-y-1/2 ${u}`,strokeWidth:2})]}):R;return E?/* @__PURE__ */T(z,{children:[B,
|
|
4
|
+
/* @__PURE__ */C("span",{id:I,hidden:!0,children:j.settingView.auto})]}):B});function A({items:e}){const t=e=>/* @__PURE__ */C("option",{value:e.value,disabled:e.disabled,lang:e.lang,children:e.label},e.value);/* @__PURE__ */
|
|
5
|
+
return C(z,{children:e.map((e,r)=>(e=>l(e))(e)?/* @__PURE__ */C("optgroup",{label:e.label,children:e.options.map(t)},`group-${r}`):t(e))})}var B=k(function({value:l,onChange:s,options:p,placeholder:k,invalid:R,className:B="",id:F,disabled:K,size:U,touchSize:V,title:W,multiple:L,renderOption:M,renderValue:P,valueText:G,readOnly:J=!1,footer:Y,changed:Q=!1,auto:X,"aria-describedby":q,"aria-label":Z,"aria-labelledby":_,...ee},te){const[re,ne]=$(!1),[ie,ae]=$(-1),le=D(null),oe=D(null),de=D(null),se=D(null),ce=D([]),ue=()=>se.current??de.current,pe=!!Y?.length,me="sm"===U,ve=me?"min-h-7 px-3 py-1 text-xs leading-4":"min-h-(--row-height-menu) px-3 py-2 text-sm leading-5",he=m(me),[fe,be]=$(null),ge=N(),ye=D(re);ye.current=re;const xe=D({buffer:"",timer:null}),Ne=w(),ke=`${Ne}-listbox`,we=F??`${Ne}-trigger`,$e=e=>`${Ne}-opt-${e}`,De=`${Ne}-changed`,Se=d(),je=X??Se,He=`${Ne}-auto`,Ee=[q,Q?De:void 0,je?He:void 0].filter(Boolean).join(" ")||void 0,Ie=S(()=>i(p),[p]),Te=L?l:[],Ce=s,ze=b(oe,re,{matchTriggerWidth:!0,...Y?.length?{preferredMaxHeight:Number.POSITIVE_INFINITY}:{}}),Oe="undefined"==typeof window?H:E,Re=`${re}|${ze?.top}|${ze?.bottom}|${ze?.maxHeight}|${p.length}`;Oe(()=>{be(null)},[Re]),Oe(()=>{const e=de.current;if(!re||!e||null!==fe)return;if(e.scrollHeight<=e.clientHeight+1)return;const t=getComputedStyle(e),r=parseFloat(t.paddingTop)||0;parseFloat(t.paddingBottom);const n=e.getBoundingClientRect().top;let i=0;for(const t of e.querySelectorAll('[role="option"]')){const r=t.getBoundingClientRect().bottom-n+e.scrollTop;if(!(r<=e.clientHeight+.5))break;i=r}i>r&&be(Math.floor(i))},[re,fe,Re]);const Ae=L?Ie.findIndex(e=>Te.includes(e.value)):Ie.findIndex(e=>e.value===l),Be=L?Ie.filter(e=>Te.includes(e.value)).map(e=>e.label).join(", ")||void 0:Ae>=0?Ie[Ae].label:void 0,Fe=!L&&Ae>=0?Ie[Ae].lang:void 0,Ke=L?Ie.filter(e=>Te.includes(e.value)):Ae>=0?[Ie[Ae]]:[],Ue=P&&Ke.length?P(Ke):void 0,Ve=void 0!==Ue&&G?G(Ke):void 0,We=j((e=!0)=>{ne(!1),ae(-1),e&&oe.current?.focus()},[]),Le=j(()=>{K||J||(ae(Ae>=0?Ae:e(Ie)),ne(!0))},[K,J,Ie,Ae]),Me=j(e=>{const t=Ie[e];if(t&&!t.disabled){if(L){const r=l;return Ce(r.includes(t.value)?r.filter(e=>e!==t.value):[...r,t.value]),void ae(e)}Ce(t.value),We()}},[Ie,L,l,Ce,We]);H(()=>{if(!re)return;return x(e=>!("Escape"!==e.key||!ye.current)&&(We(),!0),ue)},[re,We]),H(()=>{if(!re)return;const e=e=>{const t=e.target;le.current?.contains(t)||ue()?.contains(t)||We(!1)};document.addEventListener("pointerdown",e);const t=h(()=>We(!1));return()=>{document.removeEventListener("pointerdown",e),t()}},[re,We]),H(()=>{!re||ie<0||de.current?.querySelector(`#${CSS.escape($e(ie))}`)?.scrollIntoView({block:"nearest"})},[re,ie]);const Pe=j(e=>{const r=xe.current;r.timer&&clearTimeout(r.timer),r.buffer+=e,r.timer=setTimeout(()=>{r.buffer="",r.timer=null},500);const n=re?ie:Ae,i=t(Ie,r.buffer,n);i<0||(re?ae(i):L?(ae(i),ne(!0)):Me(i))},[re,ie,Ae,Ie,Me,L]),Ge=re?a(p,(e,t)=>{const r=(n=e.value,L?Te.includes(n):l===n);var n;const i=t===ie;/* @__PURE__ */
|
|
6
|
+
return T("div",{id:$e(t),role:"option",lang:e.description||e.labelStyle||M?void 0:e.lang,"aria-selected":r,"aria-disabled":e.disabled||void 0,onPointerEnter:()=>{e.disabled||ae(t)},onClick:()=>Me(t),className:`mx-1 cursor-pointer truncate rounded-lg ${ve}${L?" flex items-center gap-2":""}\n ${e.disabled?"cursor-not-allowed text-gray-400":i?"bg-blue-50 text-blue-700":r?"font-medium text-blue-600":"text-gray-700"}`,children:[L&&/* @__PURE__ */C(o,{selected:r}),M?/* @__PURE__ */C("span",{className:"block min-w-0 flex-1 truncate",children:M(e,{selected:r,active:i})}):L?/* @__PURE__ */T("span",{className:"block min-w-0 flex-1",children:[
|
|
7
|
+
/* @__PURE__ */C("span",{lang:e.lang,className:"block truncate",style:O(e),children:e.label}),e.description&&/* @__PURE__ */C("span",{className:he,children:e.description})]}):e.description||e.labelStyle?
|
|
8
|
+
/* @__PURE__ */T(z,{children:[
|
|
9
|
+
/* @__PURE__ */C("span",{lang:e.lang,className:"block truncate",style:O(e),children:e.label}),e.description&&/* @__PURE__ */C("span",{className:he,children:e.description})]}):e.label]},e.value)},Ne,"mx-1"):null,Je=void 0!==Ue?
|
|
10
|
+
/* @__PURE__ */T("span",{className:"relative block min-w-0 truncate",children:[
|
|
11
|
+
/* @__PURE__ */C("span",{"aria-hidden":"true","data-select-value":"",className:"flex min-w-0 items-center gap-2 truncate",children:Ue}),
|
|
12
|
+
/* @__PURE__ */C("span",{lang:void 0===Ve?Fe:void 0,className:"sr-only",children:Ve??Be})]}):/* @__PURE__ */C("span",{lang:Fe,className:`block truncate ${void 0===Be?u:""}`,children:Be??k??" "}),Ye={zIndex:f.popup,left:ze?.left,top:ze?.top,bottom:ze?.bottom,width:ze?.width,maxHeight:ze?.maxHeight??g,visibility:ze?void 0:"hidden",...y()},Qe=/* @__PURE__ */C("div",{ref:de,id:ke,role:"listbox","aria-labelledby":_??(Z?void 0:we),"aria-label":_?void 0:Z,"aria-multiselectable":L||void 0,className:pe?"min-h-0 shrink overflow-y-auto py-1":"fixed overflow-y-auto rounded-(--radius-popup) py-1",style:pe?null!==fe?{maxHeight:fe}:void 0:null!==fe?{...Ye,maxHeight:fe}:Ye,children:Ge}),Xe=pe?/* @__PURE__ */T("div",{ref:se,className:"fixed flex flex-col overflow-hidden rounded-(--radius-popup)",style:Ye,children:[Qe,
|
|
13
|
+
/* @__PURE__ */C("div",{className:"shrink-0 border-t border-(--rosh-glass-solid-border) px-1 py-1",children:Y.map((e,t)=>/* @__PURE__ */T("button",{ref:e=>{ce.current[t]=e},type:"button","data-select-action":"","aria-disabled":e.disabled||void 0,onClick:()=>(e=>{e.disabled||(We(),e.onSelect())})(e),onKeyDown:e=>((e,t)=>{const r=(Y?.length??0)-1,n=t=>{e.preventDefault(),ce.current[t]?.focus()},i=()=>{e.preventDefault(),oe.current?.focus()};switch(e.key){case"ArrowDown":return void n(Math.min(t+1,r));case"ArrowUp":return void(0===t?i():n(t-1));case"Home":return void n(0);case"End":return void n(r);case"Tab":return e.shiftKey?void(0===t?i():n(t-1)):t<r?void n(t+1):(e.preventDefault(),void We());case"Escape":return e.preventDefault(),e.stopPropagation(),void We()}})(e,t),className:`flex w-full items-center gap-2 rounded-lg ${ve} text-left rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)] ${e.disabled?"cursor-not-allowed text-ink-faintest":"cursor-pointer text-ink hover:bg-accent-tint hover:text-blue-700"}`,children:[e.icon&&/* @__PURE__ */C(v,{name:e.icon,"aria-hidden":"true",className:"h-4 w-4 shrink-0"}),
|
|
14
|
+
/* @__PURE__ */C("span",{className:"min-w-0 flex-1 truncate",children:e.label})]},e.label))})]}):Qe;/* @__PURE__ */
|
|
15
|
+
return T("div",{ref:le,className:"relative",children:[
|
|
16
|
+
/* @__PURE__ */C("button",{ref:oe,id:we,type:"button",role:"combobox","aria-haspopup":"listbox","aria-expanded":re,"aria-controls":re?ke:void 0,"aria-activedescendant":re&&ie>=0?$e(ie):void 0,"aria-invalid":R||void 0,"aria-describedby":Ee,"aria-label":Z,"aria-labelledby":_,title:W,disabled:K,"aria-readonly":J||void 0,onClick:()=>re?We():Le(),onKeyDown:t=>{if(!K&&!J)switch(t.key){case"ArrowDown":return t.preventDefault(),void(re?ae(e=>n(Ie,e,1)):Le());case"ArrowUp":return t.preventDefault(),void(re?ae(e=>n(Ie,e,-1)):Le());case"Home":return void(re&&(t.preventDefault(),ae(e(Ie))));case"End":return void(re&&(t.preventDefault(),ae(r(Ie))));case"Enter":return void(re&&(t.preventDefault(),Me(ie)));case" ":return t.preventDefault(),void(re?Me(ie):Le());case"Escape":return void(re&&(t.preventDefault(),t.stopPropagation(),We()));case"Tab":return re&&pe&&!t.shiftKey?(t.preventDefault(),void ce.current[0]?.focus()):void(re&&We(!1));default:1!==t.key.length||t.metaKey||t.ctrlKey||t.altKey||(t.preventDefault(),Pe(t.key))}},className:c({invalid:R,size:U,readOnly:J,auto:je,className:`${J?"":"pr-8 "}text-left ${B}`.trim()}),children:Q?
|
|
17
|
+
/* @__PURE__ */T("span",{className:"flex min-w-0 items-center gap-1",children:[Je,
|
|
18
|
+
/* @__PURE__ */C("span",{"aria-hidden":"true","data-select-changed":"",className:"shrink-0",children:"*"})]}):Je}),Q&&/* @__PURE__ */C("span",{id:De,hidden:!0,children:ge.select.changed}),je&&/* @__PURE__ */C("span",{id:He,hidden:!0,children:ge.settingView.auto}),!J&&/* @__PURE__ */C(v,{name:"chevron-up-down","aria-hidden":"true",className:`pointer-events-none absolute right-2.5 top-1/2 h-4 w-4 -translate-y-1/2 ${u}`,strokeWidth:2}),
|
|
19
|
+
/* @__PURE__ */T("select",{ref:te,value:l,multiple:L||void 0,onChange:e=>Ce(L?Array.from(e.target.selectedOptions,e=>e.value):e.target.value),disabled:K,"aria-hidden":"true",tabIndex:-1,className:"sr-only",...ee,children:[void 0!==k&&!L&&/* @__PURE__ */C("option",{value:"",disabled:!0,children:k}),
|
|
20
|
+
/* @__PURE__ */C(A,{items:p})]}),re&&I(Xe,document.body)]})}),F=k(function({touchSize:e,...t},r){const n=p(),i=s(),a=e??(i?t.size??"md":"touch");return!n||void 0===t.footer&&void 0===t.changed||t.readOnly?n&&!t.readOnly?/* @__PURE__ */C(R,{ref:r,...t,size:a}):/* @__PURE__ */C(B,{ref:r,...t}):/* @__PURE__ */C(B,{ref:r,...t,size:a})});export{R as NativeSelect,F as Select_default};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import{MOVE_KEYS as e,MoveGrip as t,MoveHint as r,moveFromKey as a}from"./chunk-QC6OK3ED.js";import{ItemCount as n}from"./chunk-PDXPMHG3.js";import{GROUP_COLORS as o}from"./chunk-LNARMEEZ.js";import{Icon as i}from"./chunk-FSPFV4MI.js";import{OneLineLabel as s}from"./chunk-OZAAIE4E.js";import{Tooltip as l}from"./chunk-BCDG4N6L.js";import{useBrowserLayoutEffect as c}from"./chunk-D65T4H6J.js";import{useShellStrings as d}from"./chunk-QWHQJNKL.js";import{useRef as u,useCallback as p,useId as m,isValidElement as f}from"react";import{jsx as h,jsxs as g}from"react/jsx-runtime";var b='[role="treeitem"]';function v(e){return[...e.querySelectorAll(b)].filter(t=>{for(let r=t.parentElement?.closest('[role="group"]');r&&e.contains(r);r=r.parentElement?.closest('[role="group"]')??null)if(r.hasAttribute("hidden"))return!1;return!0})}function y({"aria-label":e,"aria-labelledby":t,children:r,className:a="",rootProps:n}){const o=u(null);c(()=>{const e=o.current;if(!e)return;const t=[...e.querySelectorAll(b)];if(0===t.length)return;const r=t.find(e=>e===document.activeElement)??t.find(e=>"true"===e.getAttribute("aria-selected"))??v(e)[0]??t[0];for(const e of t)e.tabIndex=e===r?0:-1});const i=p(e=>{n?.onKeyDown?.(e);const t=o.current,r=e.target.closest?.(b);if(!t||!r||e.target!==r||e.defaultPrevented)return;if(e.altKey||e.ctrlKey||e.metaKey)return;const a=v(t),i=a.indexOf(r),s=Number(r.getAttribute("aria-level")??"1"),l=r=>{e.preventDefault(),function(e,t){if(t){for(const r of e.querySelectorAll(b))r.tabIndex=r===t?0:-1;t.focus()}}(t,r)};switch(e.key){case"ArrowDown":l(a[i+1]);break;case"ArrowUp":l(a[i-1]);break;case"Home":l(a[0]);break;case"End":l(a[a.length-1]);break;case"ArrowRight":if("true"===r.getAttribute("aria-expanded")){const t=a[i+1];t&&Number(t.getAttribute("aria-level")??"1")>s?l(t):e.preventDefault()}break;case"ArrowLeft":if("true"!==r.getAttribute("aria-expanded"))for(let e=i-1;e>=0;e--)if(Number(a[e].getAttribute("aria-level")??"1")<s){l(a[e]);break}}},[n]);/* @__PURE__ */
|
|
2
|
+
return h("div",{...n,ref:o,role:"tree","aria-label":t?void 0:e,"aria-labelledby":t,onKeyDown:i,className:`flex flex-col gap-1 ${a}`.trim(),children:r})}function x({children:e,hidden:t,className:r=""}){/* @__PURE__ */
|
|
3
|
+
return h("div",{role:"group",hidden:t,className:`ml-4 flex flex-col gap-1 border-l border-gray-200 pl-2 ${r}`.trim(),children:e})}var k=["inline-flex h-5 min-w-5 shrink-0 items-center justify-center rounded-full px-2","text-2xs font-medium normal-case tabular-nums tracking-normal"].join(" "),w=`${k} bg-[color:color-mix(in_srgb,var(--ink-faint)_12%,transparent)] text-gray-600`;function N(e){return"object"==typeof e&&null!==e&&!Array.isArray(e)&&!f(e)&&"label"in e}function A(e){if(null==e||!1===e||"number"==typeof e)return null;const t=Array.isArray(e)&&e.length>0&&e.every(N)?e:N(e)?[e]:null;return t?t.map((e,t)=>/* @__PURE__ */h("span",{"data-tree-count":"","data-tone":e.tone,className:e.tone?`${k} ${o[e.tone]}`:w,children:e.label},t)):/* @__PURE__ */h("span",{"data-tree-count":"",className:w,children:e})}function j({children:e,count:t,countLabel:r,expanded:a,onToggle:o}){const i=void 0!==a,l=
|
|
4
|
+
/* @__PURE__ */h("span",{"data-tree-label-text":"",className:"flex min-w-0 flex-1 text-left",children:/* @__PURE__ */h(s,{children:e})}),c="number"==typeof t?/* @__PURE__ */h(n,{count:t,label:r,showZero:!0}):null!=t&&!1!==t&&/* @__PURE__ */h("span",{"data-tree-count":"",className:w,children:t}),d="text-xs font-semibold uppercase tracking-wide text-ink-faint";return i?/* @__PURE__ */h("div",{role:"presentation",className:"pb-1 pt-3",children:/* @__PURE__ */g("button",{type:"button","aria-expanded":a,onClick:o,className:["flex w-full items-center gap-2 rounded-md px-2 hover:text-ink-strongest","rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",d].join(" "),children:[
|
|
5
|
+
/* @__PURE__ */h("span",{"aria-hidden":"true","data-tree-caret":"",className:"flex h-4 w-4 shrink-0 items-center justify-center",children:D(!!a)}),l,c]})}):/* @__PURE__ */g("div",{role:"presentation",className:`flex items-center gap-2 px-2 pb-1 pt-3 ${d}`,children:[
|
|
6
|
+
/* @__PURE__ */h("span",{"aria-hidden":"true",className:"h-4 w-4 shrink-0"}),l,c]})}var D=e=>/* @__PURE__ */h(i,{name:"chevron-right","aria-hidden":"true",strokeWidth:2.6,className:"h-3 w-3 transition-transform "+(e?"rotate-90":"")}),P={backgroundColor:"inherit",maskImage:"linear-gradient(to right, transparent, black 12px)",WebkitMaskImage:"linear-gradient(to right, transparent, black 12px)"};function $({label:o,level:i=1,icon:l,preview:c,selected:d=!1,tone:u,expanded:p,onToggle:f,onSelect:b,muted:v=!1,badge:y,count:x,countLabel:k,actions:w,actionsPinned:N=!1,actionsOverlay:j=!0,rename:$,drop:C,dragging:K=!1,draggable:E=!1,dragHint:I,onMove:H,rowProps:L,className:M=""}){const S=void 0!==p,O=m(),T=x??("number"==typeof y?y:void 0),W=[L?.["aria-describedby"],H?O:void 0].filter(Boolean).join(" ")||void 0,Z="shared"===u?"text-[color:var(--status-success-soft-ink)]":null,q=d?Z?`bg-[var(--status-success-soft)] ${Z}`:"bg-accent-tint text-blue-700":"into"===C?`bg-accent-tint ${Z??"text-ink-strongest"}`:`${Z??"text-ink"} hover:bg-gray-100`;/* @__PURE__ */
|
|
7
|
+
return g("div",{...L,role:"treeitem","aria-level":i,"aria-selected":d,"aria-expanded":S?p:void 0,"data-tone":u,tabIndex:d?0:-1,"aria-keyshortcuts":L?.["aria-keyshortcuts"]??(H?e:void 0),"aria-describedby":W,"data-drop":C,"data-draggable":E||void 0,onKeyDown:e=>{if(L?.onKeyDown?.(e),e.target!==e.currentTarget||e.defaultPrevented)return;const t=a(e);t&&H?(e.preventDefault(),H(t)):"Enter"!==e.key&&" "!==e.key||!b?("ArrowRight"===e.key&&S&&!p&&f||"ArrowLeft"===e.key&&S&&p&&f)&&(e.preventDefault(),f()):(e.preventDefault(),b())},onClick:e=>{L?.onClick?.(e),e.defaultPrevented||b?.()},className:["group/treerow relative flex h-8 shrink-0 select-none items-center gap-2 rounded-md px-2 text-sm",E?"cursor-grab active:cursor-grabbing":"cursor-pointer","rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",q,"into"===C?"ring-2 ring-inset ring-[color:var(--rosh-drop-ring)]":"",K?"opacity-40":"",M].filter(Boolean).join(" "),children:["before"===C&&/* @__PURE__ */h("span",{"aria-hidden":"true","data-tree-drop-line":"",className:"pointer-events-none absolute inset-x-2 -top-0.5 h-0.5 rounded-full bg-blue-500"}),"after"===C&&/* @__PURE__ */h("span",{"aria-hidden":"true","data-tree-drop-line":"",className:"pointer-events-none absolute inset-x-2 -bottom-0.5 h-0.5 rounded-full bg-blue-500"}),E&&
|
|
8
|
+
/* @__PURE__ */h(t,{marker:"tree",hint:I,dragging:K,revealClassName:"group-hover/treerow:opacity-100"}),
|
|
9
|
+
/* @__PURE__ */h("span",S?{"aria-hidden":"true","data-tree-caret":"",onClick:e=>{e.stopPropagation(),f?.()},className:"flex h-4 w-4 shrink-0 items-center justify-center rounded text-gray-500 hover:bg-gray-200 hover:text-gray-900",children:D(!!p)}:{"aria-hidden":"true",className:"h-4 w-4 shrink-0"}),null!=l&&/* @__PURE__ */h("span",{"aria-hidden":"true",className:"flex h-4 w-4 shrink-0 items-center justify-center "+(v?"text-ink-faintest":""),children:l}),
|
|
10
|
+
/* @__PURE__ */g("span",{className:"relative flex min-w-0 flex-1 items-center gap-2",children:[$??
|
|
11
|
+
/* @__PURE__ */h("span",{"data-tree-name":"",className:`flex min-w-0 ${d?"font-semibold":"font-medium"} ${v?"text-ink-faintest line-through":""}`,children:/* @__PURE__ */g(s,{children:[o,null!=c&&/* @__PURE__ */h("span",{className:"ml-2 font-normal text-ink-faint",children:c})]})}),A(y),null!=T&&/* @__PURE__ */h(n,{count:T,label:k,active:d,showZero:!0,className:"ml-auto"}),null!=w&&!j&&/* @__PURE__ */h("span",{"data-tree-actions":"",onClick:e=>e.stopPropagation(),onKeyDown:e=>e.stopPropagation(),className:`${null!=T?"":"ml-auto "}flex shrink-0 items-center gap-0.5 transition-opacity ${N||v?"opacity-100":"opacity-0 group-hover/treerow:opacity-100 group-focus-within/treerow:opacity-100"}`,children:w})]}),null!=w&&j&&
|
|
12
|
+
/* @__PURE__ */g("span",{"data-tree-actions":"","data-tree-actions-overlay":"",onClick:e=>e.stopPropagation(),onKeyDown:e=>e.stopPropagation(),style:P,className:"absolute inset-y-0 right-0 grid rounded-r-md transition-opacity "+(N||v||d?"opacity-100":"pointer-events-none opacity-0 group-hover/treerow:pointer-events-auto group-hover/treerow:opacity-100 group-focus-within/treerow:pointer-events-auto group-focus-within/treerow:opacity-100"),children:[
|
|
13
|
+
/* @__PURE__ */h("span",{"aria-hidden":"true","data-tree-actions-scrim":"",className:"col-start-1 row-start-1",style:{background:"var(--rosh-tree-ground, var(--surface))"}}),
|
|
14
|
+
/* @__PURE__ */h("span",{"aria-hidden":"true",className:"col-start-1 row-start-1",style:{backgroundColor:"inherit"}}),
|
|
15
|
+
/* @__PURE__ */h("span",{className:"col-start-1 row-start-1 flex items-center gap-0.5 pl-4 pr-2",children:w})]}),H&&/* @__PURE__ */h(r,{id:O})]})}function C({onAdd:e,label:t,drop:r=!1,slotProps:a}){const n=d().tree,o=r?n.dropHere:t??n.empty,i="flex min-h-8 w-full items-center gap-2 rounded-md border border-dashed px-3 text-sm "+(r?"border-blue-500 bg-blue-50 text-blue-700":"border-gray-300 text-gray-500");/* @__PURE__ */
|
|
16
|
+
return h("div",{...a,role:"presentation","data-drop":r||void 0,children:e?/* @__PURE__ */g("button",{type:"button",onClick:e,className:`${i} text-left hover:bg-gray-100 hover:text-gray-900 rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]`,children:[
|
|
17
|
+
/* @__PURE__ */h("span",{"aria-hidden":"true",children:"+"}),o]}):/* @__PURE__ */h("span",{className:i,children:o})})}function K({onInsert:e,label:t,drop:r=!1,seamProps:a}){const n=d().tree,o=t??n.insertHere,s=r?"opacity-100":e?"opacity-0 group-hover/seam:opacity-100 group-focus-within/seam:opacity-100":"opacity-0";/* @__PURE__ */
|
|
18
|
+
return g("div",{...a,role:"presentation","data-tree-seam":"","data-drop":r||void 0,className:`group/seam relative z-10 -my-1 h-1 shrink-0 ${a?.className??""}`.trim(),children:[
|
|
19
|
+
/* @__PURE__ */h("span",{"aria-hidden":"true",className:"absolute inset-x-0 -bottom-1 -top-1"}),
|
|
20
|
+
/* @__PURE__ */h("span",{"aria-hidden":"true","data-tree-seam-line":"",className:`pointer-events-none absolute inset-x-2 top-1/2 h-0.5 -translate-y-1/2 rounded-full bg-blue-500 transition-opacity ${s}`}),e&&/* @__PURE__ */h(l,{content:o,className:"absolute left-1/2 top-1/2 inline-flex -translate-x-1/2 -translate-y-1/2",children:/* @__PURE__ */h("button",{type:"button","aria-label":o,onClick:e,className:"flex h-5 w-5 items-center justify-center rounded-full bg-blue-600 text-white transition rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)] "+(r?"scale-75 opacity-0":"scale-75 opacity-0 group-hover/seam:scale-100 group-hover/seam:opacity-100 focus-visible:scale-100 focus-visible:opacity-100"),children:/* @__PURE__ */h(i,{name:"add","aria-hidden":"true",strokeWidth:2.6,className:"h-3 w-3"})})})]})}export{y as Tree,C as TreeEmptySlot,x as TreeGroup,j as TreeGroupLabel,$ as TreeRow,K as TreeSeam};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import{useShellStrings as e}from"./chunk-QWHQJNKL.js";import{jsxs as t,jsx as a,Fragment as l}from"react/jsx-runtime";var n=e=>"number"==typeof e?e:parseInt(String(e??""))||0;function s({items:s,getVolume:i,getInstructionVolume:r,getActualVolume:c,qtyField:m="instruction",showNewIndicator:d=!1,getInstructionQty:u=e=>e.quantity,getActualQty:h=e=>e.actual_qty,isFilled:o,isNew:g=e=>Boolean(e._isNew),className:x,style:f}){const p=e().containers,N=o?s.filter(o):s,y=e=>n(u(e)),b=e=>n(h(e)),w=N.some(e=>null!=h(e)&&b(e)>0),v=e=>w?y(e):"actual"===m?h(e)??u(e)??0:u(e)??0,M=N.reduce((e,t)=>e+n(v(t)),0),$=N.filter(e=>g(e)).length,k=N.filter(e=>g(e)).reduce((e,t)=>e+n(v(t)),0),j=N.reduce((e,t)=>e+y(t),0),I=N.reduce((e,t)=>e+b(t),0),Q=e=>i?.(e)??0,V=r??(e=>Q(e)*y(e)),q=c??(e=>Q(e)*b(e)),A=N.reduce((e,t)=>e+V(t),0),F=N.reduce((e,t)=>e+q(t),0),_=w?Math.max(A,F):"actual"===m&&F||A,B=_<=34.65?"20ft":"40ft",H="20ft"===B?33:67,J=_>0?Math.max(1,Math.ceil(_/H)):0,K=J*H,L=_>0&&_>=.95*K&&_<=1.1*K;if(0===N.length)return null;const S=(e,t)=>H>0?Math.max(0,Math.min((e-t*H)/H*100,100)):0;/* @__PURE__ */
|
|
2
|
+
return t("div",{className:`mt-2 px-1 space-y-2 ${x??""}`.trim(),style:f,children:[
|
|
3
|
+
/* @__PURE__ */t("div",{className:"flex items-center justify-between text-xs text-gray-500",children:[
|
|
4
|
+
/* @__PURE__ */t("span",{children:[`${p.items(N.length)} · ${p.pieces(M)}`,w&&j!==I&&/* @__PURE__ */a("span",{className:"ml-1 text-gray-400",children:p.split(j,I)})]}),d&&$>0&&/* @__PURE__ */t("span",{className:"flex items-center gap-1 text-green-600",children:[
|
|
5
|
+
/* @__PURE__ */a("span",{className:"w-1.5 h-1.5 rounded-full bg-green-500"}),p.added($,k)]})]}),_>0?/* @__PURE__ */t("div",{className:"space-y-2",children:[Array.from({length:J}).map((e,l)=>{const n=S(A,l),s=S(F,l),i=w,r=Math.max(n,s),c=Math.min(n,s),m=n>=s,d=i?m?"bg-blue-500":"bg-green-500":"bg-blue-500",u=i?m?"bg-green-500":"bg-blue-500":"";/* @__PURE__ */
|
|
6
|
+
return t("div",{className:"flex items-center gap-2",children:[
|
|
7
|
+
/* @__PURE__ */a("span",{className:"text-2xs text-ink-faintest w-8 shrink-0",children:B}),
|
|
8
|
+
/* @__PURE__ */t("div",{className:"relative flex-1 h-4 bg-gray-100 rounded-full overflow-hidden border border-gray-200",children:[
|
|
9
|
+
/* @__PURE__ */a("div",{className:`absolute inset-y-0 left-0 ${d} transition-all`,style:{width:`${r}%`}}),i&&c>0&&/* @__PURE__ */a("div",{className:`absolute inset-y-0 left-0 ${u} transition-all`,style:{width:`${c}%`}})]}),
|
|
10
|
+
/* @__PURE__ */a("span",{className:"text-2xs text-ink-faint w-16 text-right",children:i?p.fill(Math.min(F-l*H,H),H):p.fill(Math.min(A-l*H,H),H)})]},`bar-${l}`)}),
|
|
11
|
+
/* @__PURE__ */t("div",{className:"flex items-center justify-between text-xs pt-0.5",children:[
|
|
12
|
+
/* @__PURE__ */t("span",{className:"text-gray-500 inline-flex items-center gap-1",children:[p.total,w?/* @__PURE__ */t(l,{children:[
|
|
13
|
+
/* @__PURE__ */t("span",{className:"inline-flex items-center gap-1 text-blue-700",children:[
|
|
14
|
+
/* @__PURE__ */a("span",{className:"inline-block w-2 h-2 rounded-full bg-blue-500"}),p.instructed(A)]}),
|
|
15
|
+
/* @__PURE__ */a("span",{className:"text-gray-400",children:"/"}),
|
|
16
|
+
/* @__PURE__ */t("span",{className:"inline-flex items-center gap-1 text-green-700",children:[
|
|
17
|
+
/* @__PURE__ */a("span",{className:"inline-block w-2 h-2 rounded-full bg-green-500"}),p.loaded(F)]})]}):/* @__PURE__ */a("b",{className:"text-gray-700",children:p.volume(_)})]}),
|
|
18
|
+
/* @__PURE__ */t("span",{className:"font-medium "+(L?"text-green-600":"text-gray-500"),children:[L&&"✓ ",J," × ",B]})]})]}):/* @__PURE__ */a("div",{className:"text-xs text-gray-400",children:p.noVolume})]})}export{s as ContainerFillChart};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{TICK_INK as e}from"./chunk-URBCGEXG.js";import{useShellStrings as n}from"./chunk-
|
|
1
|
+
import{TICK_INK as e}from"./chunk-URBCGEXG.js";import{useShellStrings as n}from"./chunk-QWHQJNKL.js";import{jsxs as r,jsx as i}from"react/jsx-runtime";function a({ink:e}){/* @__PURE__ */
|
|
2
2
|
return i("span",{"aria-hidden":"true",className:`h-3 w-0.5 shrink-0 rounded-[1px] ${e}`})}function t({link:t,className:l=""}){const c=n().meter;/* @__PURE__ */
|
|
3
3
|
return r("div",{className:`flex flex-wrap items-center gap-x-3 gap-y-1 text-xs text-gray-500 ${l}`.trim(),children:[
|
|
4
4
|
/* @__PURE__ */r("span",{className:"inline-flex items-center gap-1",children:[
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import{AccessibleTable as e}from"./chunk-TBPHW42V.js";import{bumpPath as t}from"./chunk-VFC6QUEN.js";import{useHighlight as n}from"./chunk-CNYAHYE6.js";import{ChartTooltip as o}from"./chunk-TLRCTNUF.js";import{usePlotWidth as l}from"./chunk-MAFUXCPZ.js";import{resolveSeriesColor as r,CHART_INK as a}from"./chunk-TZFACUMR.js";import{useShellStrings as i,useShellLocale as s}from"./chunk-QWHQJNKL.js";import{formatPlain as h}from"./chunk-C3QOHMR6.js";import{useRef as c,useState as m}from"react";import{jsx as d,jsxs as u}from"react/jsx-runtime";function f({nodes:f,links:k,height:p=320,width:x,nodeWidth:g=14,nodePadding:y=12,formatValue:v,className:M,emptyLabel:w}){const b=i().charts,N=s(),j=v??(e=>h(e,N)),$=w??b.noFlows,C=c(null),F=l(C),E=x??F,[T,A]=m(null),{highlighted:H}=n();if(0===f.length||0===k.length)/* @__PURE__ */
|
|
2
|
+
return d("div",{className:M,ref:C,children:/* @__PURE__ */d("p",{className:"py-8 text-center text-sm text-gray-500",children:$})});const L=[...new Set(f.map(e=>e.depth))].sort((e,t)=>e-t),Q=e=>L.length<=1?0:L.indexOf(e)/(L.length-1)*(E-g-140)+70,U=new Map(f.map(e=>{const t=k.filter(t=>t.from===e.key).reduce((e,t)=>e+t.value,0),n=k.filter(t=>t.to===e.key).reduce((e,t)=>e+t.value,0);return[e.key,Math.max(t,n,e.value??0)]})),W=/* @__PURE__ */new Map;for(const e of f)W.set(e.depth,[...W.get(e.depth)??[],e]);const z=Math.max(...[...W.values()].map(e=>e.reduce((e,t)=>e+(U.get(t.key)??0),0))),O=p-20,P=z>0?(O-y*(Math.max(...[...W.values()].map(e=>e.length))-1))/z:0,R=/* @__PURE__ */new Map;for(const[e,t]of W){const n=t.map(e=>Math.max(2,(U.get(e.key)??0)*P)),o=n.reduce((e,t)=>e+t,0)+y*(t.length-1),l=n.reduce((e,t)=>e+Math.max(0,t-2),0),r=o>O&&l>0?Math.max(0,1-(o-O)/l):1;let a=10;t.forEach((t,o)=>{const l=2+Math.max(0,n[o]-2)*r;R.set(t.key,{x:Q(e),y:a,h:l,index:o}),a+=l+y})}const V=/* @__PURE__ */new Map,B=/* @__PURE__ */new Map,S=/* @__PURE__ */new Map,Y=(e,t)=>e.from===t||e.to===t,Z="link"===T?.kind?k[T.index]:void 0,J="node"===T?.kind?f.find(e=>e.key===T.key):void 0;/* @__PURE__ */
|
|
3
|
+
return u("div",{className:`relative ${M??""}`,ref:C,children:[
|
|
4
|
+
/* @__PURE__ */u("svg",{width:"100%",height:p,viewBox:`0 0 ${E} ${p}`,role:"img","aria-label":b.sankey(f.length,k.length),onMouseLeave:()=>A(null),children:[k.map((e,n)=>{const o=R.get(e.from),l=R.get(e.to);if(!o||!l)return null;const a=Math.max(1,e.value*P),i=o.y+(V.get(e.from)??0)+a/2,s=l.y+(B.get(e.to)??0)+a/2;V.set(e.from,(V.get(e.from)??0)+a),B.set(e.to,(B.get(e.to)??0)+a);const h=o.x+g,c=l.x,m=r(o.index,e.color),u=`${e.from}→${e.to}`,f=S.get(u)??0;S.set(u,f+1);const k=((e,t)=>T?"link"===T.kind?T.index===t:Y(e,T.key):null!==H?Y(e,H):null)(e,n);/* @__PURE__ */
|
|
5
|
+
return d("path",{d:t([[h,i],[c,s]]),fill:"none",stroke:m,strokeWidth:a,strokeOpacity:null===k||k?.42:.12,onMouseEnter:()=>A({kind:"link",index:n})},f?`${u}#${f}`:u)}),f.map(e=>{const t=R.get(e.key);if(!t)return null;const n=t.x>E/2,o=(l=e.key,T?"node"===T.kind?T.key===l:Y(k[T.index],l):null!==H?H===l:null);var l;/* @__PURE__ */
|
|
6
|
+
return u("g",{opacity:null===o||o?1:.45,onMouseEnter:()=>A({kind:"node",key:e.key}),children:[
|
|
7
|
+
/* @__PURE__ */d("rect",{x:t.x,y:t.y,width:g,height:t.h,rx:2,fill:r(t.index,e.color,e.tone)}),
|
|
8
|
+
/* @__PURE__ */d("text",{x:n?t.x-8:t.x+g+8,y:t.y+t.h/2+4,textAnchor:n?"end":"start",fontSize:11,fill:a.label,children:e.label})]},e.key)})]}),Z&&/* @__PURE__ */d("div",{className:"pointer-events-none absolute top-2 left-2 z-10",children:/* @__PURE__ */d(o,{title:`${Z.from} → ${Z.to}`,rows:[{key:"value",label:b.flow,color:r(R.get(Z.from)?.index??0,Z.color),value:j(Z.value)}]})}),J&&/* @__PURE__ */d("div",{className:"pointer-events-none absolute top-2 left-2 z-10",children:/* @__PURE__ */d(o,{title:J.label,rows:[{key:"value",label:b.throughput,color:r(R.get(J.key)?.index??0,J.color,J.tone),value:j(U.get(J.key)??0)}]})}),
|
|
9
|
+
/* @__PURE__ */d(e,{caption:b.sankey(f.length,k.length),head:[b.tableFrom,b.tableTo,b.value],rows:k.map(e=>[e.from,e.to,j(e.value)])})]})}export{f as SankeyChart};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import{swallowPress as e,describedByWith as i,OffWithReason as r}from"./chunk-HL6JSDN3.js";import{Icon as a}from"./chunk-FSPFV4MI.js";import{OneLineLabel as o}from"./chunk-OZAAIE4E.js";import{Tooltip as s}from"./chunk-BCDG4N6L.js";import{useShellStrings as n}from"./chunk-QWHQJNKL.js";import{useId as l,Fragment as d}from"react";import{jsx as t,jsxs as c}from"react/jsx-runtime";function b({items:b,onChange:h,label:m,className:u="","aria-labelledby":f,"aria-describedby":p}){const w=n().displayChips,g=l();/* @__PURE__ */
|
|
2
|
+
return t("div",{role:"group","aria-label":f?void 0:m,"aria-labelledby":f,"aria-describedby":p,className:`flex flex-wrap gap-2 ${u}`.trim(),children:b.map((n,l)=>{const b=`${g}-${l}-state`,m=`${g}-${l}-reason`,u=Boolean(n.disabled)&&null!=n.disabledReason&&""!==n.disabledReason,f=/* @__PURE__ */c("button",{type:"button","aria-pressed":n.shown,disabled:!(!n.disabled||u)||void 0,"aria-disabled":!!u||void 0,"aria-describedby":i(b,u?m:void 0),onClick:u?e:()=>h(n.id,!n.shown),className:"inline-flex h-6 max-w-full shrink-0 items-center gap-1 whitespace-nowrap rounded-full border pl-2 pr-3 text-xs font-medium transition-colors rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring)] disabled:cursor-not-allowed disabled:opacity-60 aria-disabled:cursor-not-allowed aria-disabled:opacity-60 "+(n.shown?"border-blue-200 bg-accent-tint text-blue-700 hover:bg-blue-100":"border-line bg-surface text-ink-faint hover:bg-row-hover hover:text-ink-strongest"),children:[
|
|
3
|
+
/* @__PURE__ */t(a,{name:n.shown?"eye":"eye-off",className:"h-4 w-4 shrink-0",strokeWidth:"1.75"}),
|
|
4
|
+
/* @__PURE__ */t(o,{children:n.label})]}),p=/* @__PURE__ */t("span",{id:b,className:"sr-only",children:n.shown?w.shown:w.hidden});/* @__PURE__ */
|
|
5
|
+
return c(d,{children:[u?/* @__PURE__ */t(r,{reason:n.disabledReason,id:m,children:f}):/* @__PURE__ */t(s,{content:n.shown?w.shownHint:w.hiddenHint,describe:!1,className:"relative inline-flex max-w-full",children:f}),p]},n.id)})})}export{b as DisplayChips};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Tooltip as e}from"./chunk-
|
|
2
|
-
return s(e,{content:z??
|
|
1
|
+
import{Tooltip as e}from"./chunk-BCDG4N6L.js";import{useBrowserLayoutEffect as r}from"./chunk-D65T4H6J.js";import{useShellStrings as t}from"./chunk-QWHQJNKL.js";import{useRef as o,useEffect as n,useCallback as i}from"react";import{jsx as s}from"react/jsx-runtime";var a=(e,r,t)=>Math.min(t,Math.max(r,e));function l(e,r,t,o,n){return Math.round(a("left"===t||"top"===t?e+r:e-r,o,n))}function u(e,r,t){let o=null;try{o=window.localStorage.getItem(e)}catch{return null}const n=o?parseInt(o,10):NaN;return Number.isNaN(n)?null:a(n,r,t)}function c({width:c,onResize:d,orientation:h="vertical",side:m,min:f,max:p,defaultWidth:v=f,step:g=16,storageKey:b,label:w,hint:z,controls:y,className:x=""}){const N="horizontal"===h,P=t().resizeHandle,k=o(null),D=o({onResize:d,min:f,max:p,side:m});D.current={onResize:d,min:f,max:p,side:m},r(()=>{if(!b)return;const e=u(b,f,p);null!==e&&e!==c&&d(e)},[b]),n(()=>{if(!b)return;const e=window.setTimeout(()=>{try{window.localStorage.setItem(b,String(Math.round(c)))}catch{}},200);return()=>window.clearTimeout(e)},[c,b]);const C=i(()=>{k.current=null,document.body.style.removeProperty("cursor"),document.body.style.removeProperty("user-select")},[]);n(()=>C,[C]);const M=e=>{k.current&&(e.currentTarget.hasPointerCapture?.(k.current.pointer)&&e.currentTarget.releasePointerCapture(k.current.pointer),C())},I="left"===m?"right-0":"right"===m?"left-0":"top"===m?"bottom-0":"top-0",T="left"===m?"right":"right"===m?"left":"top"===m?"bottom":"top",$=N?`absolute inset-x-0 ${I} z-10 flex h-2`:`absolute inset-y-0 ${I} z-10 flex w-2`;/* @__PURE__ */
|
|
2
|
+
return s(e,{content:z??P.hint,side:T,delay:600,className:`${$} ${x}`.trim(),children:/* @__PURE__ */s("div",{role:"separator",tabIndex:0,"aria-orientation":h,"aria-label":w??P.label,"aria-valuenow":Math.round(c),"aria-valuemin":f,"aria-valuemax":p,"aria-controls":y,"data-resize-handle":m,onPointerDown:e=>{0===e.button&&(e.preventDefault(),k.current={x:N?e.clientY:e.clientX,width:c,moved:!1,pointer:e.pointerId},e.currentTarget.setPointerCapture?.(e.pointerId),document.body.style.cursor=N?"row-resize":"col-resize",document.body.style.userSelect="none")},onPointerMove:e=>{const r=k.current;if(!r)return;if(0===e.buttons)return void C();const t=(N?e.clientY:e.clientX)-r.x;if(!r.moved){if(Math.abs(t)<3)return;r.moved=!0}const{onResize:o,min:n,max:i,side:s}=D.current;o(l(r.width,t,s,n,i))},onPointerUp:M,onPointerCancel:M,onLostPointerCapture:()=>{k.current&&C()},onDoubleClick:()=>d(a(v,f,p)),onKeyDown:e=>{const r=N?"ArrowDown":"ArrowRight",t=N?"ArrowUp":"ArrowLeft",o=e.key===r?g:e.key===t?-g:null,n=null!==o?l(c,o,m,f,p):"Home"===e.key?f:"End"===e.key?p:"Enter"===e.key?a(v,f,p):null;null!==n&&(e.preventDefault(),n!==c&&d(n))},className:N?"group/resize relative h-full w-full cursor-row-resize touch-none rosh-focus-ring focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-[color:var(--rosh-focus-ring-solid)]":"group/resize relative h-full w-full cursor-col-resize touch-none rosh-focus-ring focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-[color:var(--rosh-focus-ring-solid)]",children:/* @__PURE__ */s("div",{"aria-hidden":"true",className:N?`absolute inset-x-0 ${I} h-px bg-transparent transition-colors group-hover/resize:bg-[var(--accent-500,var(--rosh-resize-handle))] group-focus-visible/resize:h-0.5 group-focus-visible/resize:bg-[var(--accent-500,var(--rosh-resize-handle))]`:`absolute inset-y-0 ${I} w-px bg-transparent transition-colors group-hover/resize:bg-[var(--accent-500,var(--rosh-resize-handle))] group-focus-visible/resize:w-0.5 group-focus-visible/resize:bg-[var(--accent-500,var(--rosh-resize-handle))]`})})})}export{c as ResizeHandle,u as readStoredWidth,l as resizedWidth};
|