efficient-shell 12.7.0 → 12.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +44 -3
- package/dist/{Browser-AKBOECNB.js → Browser-G2HGYZVD.js} +16 -16
- package/dist/Calculator-ALPNISJT.js +29 -0
- package/dist/{CurrencyConverter-UVOKFPMG.js → CurrencyConverter-KBY2OXQ2.js} +8 -8
- package/dist/Files-OY5TSWUZ.js +126 -0
- package/dist/{Notepad-P6JFXK3G.js → Notepad-CRHG5FLI.js} +10 -10
- package/dist/PdfViewer-L4FJS3M6.js +1 -0
- package/dist/{PomodoroTimer-UOV4CCYH.js → PomodoroTimer-NGQPYDI3.js} +68 -68
- package/dist/{Preview-XF5FKLVZ.js → Preview-BVTWP7RW.js} +24 -24
- package/dist/Sidebar-QOGK5LJ2.js +44 -0
- package/dist/{Stock-6D4I2EWM.js → Stock-O7AQ2WUN.js} +3 -3
- package/dist/{Weather-BCOAQJDT.js → Weather-WHXA5TTP.js} +21 -21
- package/dist/{WorldClock-WX3O3EDU.js → WorldClock-CZCIVYKB.js} +6 -6
- package/dist/ai/index.js +57 -57
- package/dist/apps/ImageAnnotator.js +1 -1
- package/dist/apps/index.d.ts +55 -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/ChordChart.js +1 -1
- package/dist/charts/ColumnChart.js +1 -1
- package/dist/charts/FlowChart.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-UDHJTQBA.js → chunk-22LU6FKN.js} +12 -12
- package/dist/{chunk-NC36LJCA.js → chunk-2GS2VOQT.js} +10 -10
- package/dist/{chunk-3PWI5IH7.js → chunk-2NZBQOA6.js} +11 -11
- package/dist/{chunk-4ZUV6WQT.js → chunk-2WNTDGOP.js} +1 -1
- package/dist/{chunk-RFKCSRJX.js → chunk-2X4U3VX2.js} +6 -6
- package/dist/chunk-3C5NKOVF.js +1 -0
- package/dist/{chunk-SYZLS2JA.js → chunk-3DWVSQIJ.js} +1 -1
- package/dist/{chunk-6JDR6T4U.js → chunk-3RDJFCIZ.js} +1 -1
- package/dist/{chunk-5NDONLH5.js → chunk-42BVXJZN.js} +3 -3
- package/dist/chunk-457SK2XV.js +9 -0
- package/dist/chunk-4GTXRVDF.js +3 -0
- package/dist/{chunk-G2X5YYIQ.js → chunk-4MUE4CYB.js} +2 -2
- package/dist/{chunk-3CMCGOOV.js → chunk-4UQNNA4K.js} +4 -4
- package/dist/{chunk-NEAT7BIP.js → chunk-5G4CB3E6.js} +1 -1
- package/dist/{chunk-PH3P54QQ.js → chunk-5HOXR3L4.js} +1 -1
- package/dist/{chunk-QNYZTD7V.js → chunk-5MFWM6L4.js} +1 -1
- package/dist/{chunk-Y4RERPFN.js → chunk-5QVCBAK2.js} +1 -1
- package/dist/chunk-5RT5XDHG.js +6 -0
- package/dist/{chunk-3UHTHQGK.js → chunk-5S4YF5XA.js} +8 -8
- package/dist/{chunk-FLTPVFKA.js → chunk-5WCHUZ6O.js} +1 -1
- package/dist/{chunk-YRJJKF5H.js → chunk-5YPCZLBW.js} +1 -1
- package/dist/{chunk-PT77FC5X.js → chunk-5Z6XJPAX.js} +1 -1
- package/dist/{chunk-MGW7SX53.js → chunk-63J2MBXV.js} +10 -10
- package/dist/chunk-675RYIWR.js +7 -0
- package/dist/{chunk-ND5IZ37V.js → chunk-67BWG353.js} +9 -9
- package/dist/{chunk-SCU2CWNJ.js → chunk-6BK3KRT5.js} +18 -18
- package/dist/chunk-6BQUSUNK.js +14 -0
- package/dist/{chunk-XMH2JOZ2.js → chunk-6ITEA6SX.js} +1 -1
- package/dist/{chunk-4KJ7MLWO.js → chunk-6JLXXX4H.js} +5 -5
- package/dist/{chunk-6BATVJBA.js → chunk-6P7SIIG4.js} +14 -14
- package/dist/{chunk-CNVYM3HP.js → chunk-6YIVKPWQ.js} +1 -1
- package/dist/{chunk-2HZQZTW5.js → chunk-7Q4DE4CT.js} +1 -1
- package/dist/{chunk-56GGBTAD.js → chunk-7XGUX3TH.js} +3 -3
- package/dist/{chunk-BKKKIHHV.js → chunk-A2JYBUPB.js} +6 -6
- package/dist/{chunk-IYPRFUTT.js → chunk-AKTEMZOT.js} +1 -1
- package/dist/{chunk-I5BS6AP6.js → chunk-AMSE4PMQ.js} +3 -3
- package/dist/{chunk-TX5FZBPQ.js → chunk-ASOVTAIT.js} +1 -1
- package/dist/{chunk-CD7P34VC.js → chunk-AUCNJFTP.js} +7 -7
- package/dist/{chunk-BGJMDP6J.js → chunk-BJAJOIVY.js} +1 -1
- package/dist/chunk-BR7L5NE3.js +13 -0
- package/dist/{chunk-DJ2XDBAO.js → chunk-BUZ5AJLR.js} +6 -6
- package/dist/{chunk-EOGXCGQF.js → chunk-BYDSBDVS.js} +6 -6
- package/dist/{chunk-MOMOZVOW.js → chunk-C3E6XFIC.js} +3 -3
- package/dist/{chunk-45IVWLKF.js → chunk-C7M7KYNY.js} +1 -1
- package/dist/chunk-CA3OC4YY.js +9 -0
- package/dist/{chunk-H7HRYFRQ.js → chunk-CB5FQMFB.js} +9 -9
- package/dist/{chunk-62275PI2.js → chunk-CINGDJPM.js} +1 -1
- package/dist/{chunk-IFQXTIMY.js → chunk-CRRC72EE.js} +9 -9
- package/dist/{chunk-NS37Y5CN.js → chunk-D4K72BHN.js} +1 -1
- package/dist/{chunk-BFO72WQB.js → chunk-EDANELWX.js} +1 -1
- package/dist/chunk-EHVBJUQI.js +28 -0
- package/dist/{chunk-KUEYOJBN.js → chunk-EIXMUGVZ.js} +2 -2
- package/dist/{chunk-7FBAZLBX.js → chunk-EVEGK57J.js} +1 -1
- package/dist/chunk-EVYD6UFQ.js +2 -0
- package/dist/chunk-F7BXUVN4.js +6 -0
- package/dist/{chunk-EIY6YGEZ.js → chunk-FOCQEWUH.js} +1 -1
- package/dist/chunk-FQHY6DTF.js +4 -0
- package/dist/{chunk-4UGFNTZ3.js → chunk-FZWAOYAM.js} +7 -7
- package/dist/{chunk-NEYHBQLG.js → chunk-G3VRO4CK.js} +2 -2
- package/dist/{chunk-CJH2BGXY.js → chunk-G67CJAQ2.js} +1 -1
- package/dist/{chunk-FPYABAOX.js → chunk-GB2XLSR5.js} +11 -11
- package/dist/{chunk-TS36J7RW.js → chunk-GBEDLYND.js} +2 -2
- package/dist/{chunk-IXBKWVEP.js → chunk-GMJ5WOB2.js} +1 -1
- package/dist/{chunk-GEXETMGL.js → chunk-GMLDGXNQ.js} +1 -1
- package/dist/{chunk-JM2IQC4J.js → chunk-HD7OBASH.js} +1 -1
- package/dist/{chunk-RBMZSZOH.js → chunk-HE24VQMU.js} +1 -1
- package/dist/{chunk-3WFJ4PYV.js → chunk-HEX3EP5F.js} +3 -3
- package/dist/chunk-HL3V67JZ.js +2 -0
- package/dist/{chunk-GZQD6IBV.js → chunk-HRDR56SK.js} +3 -3
- package/dist/chunk-HULQSIX5.js +8 -0
- package/dist/{chunk-OY3JH66O.js → chunk-HV4VQ5XV.js} +7 -7
- package/dist/{chunk-EYPKBJYG.js → chunk-HY6CBG4M.js} +1 -1
- package/dist/{chunk-E227NVFX.js → chunk-IARCNQD3.js} +1 -1
- package/dist/{chunk-34SPT4I6.js → chunk-ICNGLA5O.js} +4 -4
- package/dist/{chunk-KDTL6VEC.js → chunk-IIMFLLYT.js} +8 -8
- package/dist/{chunk-N442GPRJ.js → chunk-INFL4YZF.js} +1 -1
- package/dist/{chunk-Y46WPTKY.js → chunk-ISU4FCEX.js} +7 -7
- package/dist/chunk-ISZOD5S6.js +2 -0
- package/dist/{chunk-H6PFTU3L.js → chunk-J4IT5C3A.js} +1 -1
- package/dist/chunk-J7BMSKOM.js +7 -0
- package/dist/{chunk-DW45EZHA.js → chunk-JGJWPONL.js} +5 -5
- package/dist/{chunk-JPNAEN53.js → chunk-JMGDGNM7.js} +1 -1
- package/dist/chunk-JOD5ISTB.js +11 -0
- package/dist/{chunk-TRWHVG3A.js → chunk-JTZVUO3I.js} +1 -1
- package/dist/{chunk-WCPAQHHA.js → chunk-JVNJCRHM.js} +4 -4
- package/dist/chunk-KFS7WSCC.js +15 -0
- package/dist/{chunk-XZH5PEML.js → chunk-KIRLSUQT.js} +5 -5
- package/dist/{chunk-WMLBMR4E.js → chunk-KOPTKTHN.js} +3 -3
- package/dist/{chunk-3LTZ4N46.js → chunk-KPHYWZXL.js} +13 -13
- package/dist/chunk-KRUI4LVW.js +4 -0
- package/dist/chunk-KVU5IQOZ.js +7 -0
- package/dist/{chunk-N7JX27JE.js → chunk-KWTK6TGH.js} +1 -1
- package/dist/{chunk-DFYXIW4O.js → chunk-KZ7RR7EU.js} +1 -1
- package/dist/{chunk-YU6KOO6O.js → chunk-LFW3CQMF.js} +4 -4
- package/dist/{chunk-2BMGV6DE.js → chunk-LFWRHBTM.js} +2 -2
- package/dist/{chunk-X32TVINY.js → chunk-LS6VU6F7.js} +1 -1
- package/dist/{chunk-J53LQWWY.js → chunk-M4MN2GOE.js} +13 -13
- package/dist/{chunk-XWFLIGDQ.js → chunk-M5K4AX4E.js} +1 -1
- package/dist/{chunk-GJ23UZDQ.js → chunk-MAI2DN7N.js} +1 -1
- package/dist/{chunk-7B5KFESH.js → chunk-MBXCXFQO.js} +1 -1
- package/dist/{chunk-32WEY6O5.js → chunk-MEAJGM6F.js} +1 -1
- package/dist/{chunk-DNLRUZGS.js → chunk-MPTOEXED.js} +1 -1
- package/dist/chunk-MTP3MBZA.js +22 -0
- package/dist/{chunk-EUUCNDIS.js → chunk-NAWIVFAN.js} +13 -13
- package/dist/{chunk-54K2ADBT.js → chunk-NDAZPAQL.js} +1 -1
- package/dist/{chunk-ZKQWS2ML.js → chunk-NKZINXHG.js} +2 -2
- package/dist/chunk-NOCOLZ2W.js +1 -0
- package/dist/{chunk-SCGBCBXP.js → chunk-NV7QRWQJ.js} +1 -1
- package/dist/{chunk-XK4U5MAS.js → chunk-O3YCIWHF.js} +1 -1
- package/dist/chunk-OAFFHLJ4.js +8 -0
- package/dist/{chunk-DANLBFBD.js → chunk-OCI3PZDU.js} +1 -1
- package/dist/chunk-OSNHRKX6.js +5 -0
- package/dist/{chunk-C5LBNLFJ.js → chunk-OSQ5NRV3.js} +1 -1
- package/dist/{chunk-UVBX5LEU.js → chunk-OW5LQWPU.js} +4 -4
- package/dist/chunk-PEIRPNXT.js +23 -0
- package/dist/{chunk-LGK47SEN.js → chunk-PHJFGLXB.js} +12 -12
- package/dist/{chunk-N6Q7HNAH.js → chunk-PICRPJBL.js} +1 -1
- package/dist/{chunk-G7I255HN.js → chunk-POOPWYJL.js} +9 -9
- package/dist/chunk-PY7GHIYF.js +19 -0
- package/dist/{chunk-7HIHQR3X.js → chunk-Q3RJMQYE.js} +1 -1
- package/dist/{chunk-JQBVSPF5.js → chunk-QAS22BIS.js} +1 -1
- package/dist/{chunk-TTQ7K4AJ.js → chunk-QIMMZVWV.js} +1 -1
- package/dist/{chunk-RQDVAUXD.js → chunk-QJGZOD6X.js} +3 -3
- package/dist/{chunk-NHWDB7R6.js → chunk-QMNDKNK2.js} +1 -1
- package/dist/{chunk-RIXX6NRV.js → chunk-QQM36CYU.js} +1 -1
- package/dist/{chunk-QIUIP6YZ.js → chunk-QSK2OWT3.js} +2 -2
- package/dist/{chunk-AHJAJLSK.js → chunk-RAQBZUU2.js} +23 -23
- package/dist/{chunk-YMAU4EIK.js → chunk-RGKSJBXJ.js} +8 -8
- package/dist/{chunk-UVGEOQI4.js → chunk-RHD4V6CE.js} +9 -9
- package/dist/{chunk-XK4SMAVR.js → chunk-RIF6BFEH.js} +1 -1
- package/dist/{chunk-6U25ELYF.js → chunk-RLGPIJHB.js} +1 -1
- package/dist/{chunk-R3K3LVVS.js → chunk-RQKD5AAL.js} +1 -1
- package/dist/{chunk-I3QFYBOP.js → chunk-SEHKTBVM.js} +1 -1
- package/dist/{chunk-75MSXRFY.js → chunk-SFFELHLP.js} +5 -5
- package/dist/chunk-SOZCWT6I.js +6 -0
- package/dist/{chunk-UGOJLNYR.js → chunk-SV5RRBVA.js} +1 -1
- package/dist/{chunk-SBZCJNNP.js → chunk-SY65V6K7.js} +10 -10
- package/dist/{chunk-UIWGVOFH.js → chunk-T3NLFOLW.js} +2 -1
- package/dist/{chunk-57YY4J6T.js → chunk-TDMZFQRB.js} +1 -1
- package/dist/chunk-TJSJVC6P.js +1 -0
- package/dist/{chunk-VYMM2BPX.js → chunk-TKFINWY6.js} +2 -2
- package/dist/{chunk-MM5AFQ24.js → chunk-TVVSFXWY.js} +7 -7
- package/dist/{chunk-5JUG74UR.js → chunk-UD4NESX7.js} +1 -1
- package/dist/{chunk-NJTFI7AA.js → chunk-UG5GKEU5.js} +1 -1
- package/dist/{chunk-5MO5JBBK.js → chunk-UMZJRZFN.js} +1 -1
- package/dist/{chunk-LTESFDTF.js → chunk-V6FHZGCL.js} +1 -1
- package/dist/{chunk-ZOZEQZUA.js → chunk-VLCHHTX6.js} +1 -1
- package/dist/{chunk-A4KQKN32.js → chunk-VN3A43SA.js} +1 -1
- package/dist/{chunk-UPTKROT7.js → chunk-VPZOSVDF.js} +10 -10
- package/dist/{chunk-DPUM3H5N.js → chunk-VWNHSLFY.js} +1 -1
- package/dist/{chunk-HE767CVB.js → chunk-W5B7UNMJ.js} +1 -1
- package/dist/{chunk-RNQBWWYR.js → chunk-WDAOTHX5.js} +5 -5
- package/dist/{chunk-R3JKZXII.js → chunk-WJBP5SND.js} +5 -5
- package/dist/{chunk-RVQUSPXC.js → chunk-WM2BBRT6.js} +1 -1
- package/dist/{chunk-EEVLRCMA.js → chunk-Y4YXZIES.js} +9 -9
- package/dist/chunk-YMD2F3NL.js +1 -0
- package/dist/{chunk-525O4AUQ.js → chunk-YRG6XJ6M.js} +8 -8
- package/dist/chunk-YVAJ42M2.js +8 -0
- package/dist/{chunk-DZBGJ6X4.js → chunk-YVIV7SKG.js} +1 -1
- package/dist/{chunk-53EW4M5S.js → chunk-YX4MRM7A.js} +6 -6
- package/dist/chunk-Z334LCCX.js +4 -0
- package/dist/{chunk-J4KYZGHQ.js → chunk-Z6KW4WZ6.js} +20 -20
- package/dist/{chunk-7KIDOIPY.js → chunk-Z7RXWXR5.js} +1 -1
- package/dist/{chunk-WVHGHMW3.js → chunk-ZC6MXV4L.js} +1 -1
- package/dist/chunk-ZPHUMLET.js +1 -0
- package/dist/{chunk-7H7U3HC6.js → chunk-ZR2UWJIR.js} +4 -4
- package/dist/data/DataTable.js +1 -1
- package/dist/data/EntityList.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/data/ResizableTable.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/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.d.ts +6 -0
- package/dist/forms/InputNumber.js +1 -1
- package/dist/forms/LinkPicker.js +1 -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/RenameField.js +1 -1
- package/dist/forms/Segmented.js +1 -1
- package/dist/forms/Select.js +1 -1
- package/dist/forms/SidesInput.d.ts +12 -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/TimePicker.js +1 -1
- package/dist/forms/UnitMenu.d.ts +16 -0
- package/dist/forms/UnitMenu.js +1 -0
- package/dist/forms/WidthsBar.js +1 -1
- package/dist/forms/mediaLibraryMenu.js +1 -1
- package/dist/forms/mediaMoveItems.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-meanings.d.ts +37 -37
- package/dist/icons/efficient-meanings.js +1 -1
- package/dist/icons/efficient.js +1 -1
- package/dist/icons/index.js +1 -1
- package/dist/icons/looks/map.js +1 -1
- package/dist/icons/sets.js +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +665 -665
- package/dist/locales/zh-Hans.js +1 -1
- package/dist/map/index.js +3 -3
- package/dist/markdown/index.js +1 -1
- 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.d.ts +13 -2
- package/dist/shell/DropdownMenu.js +1 -1
- package/dist/shell/EditableGrid.js +1 -1
- package/dist/shell/EmptyState.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.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/PopupMenu.d.ts +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.js +1 -1
- package/dist/shell/SortableList.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/Stepper.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.js +1 -1
- package/dist/shell/discardGuard.js +1 -1
- package/dist/shell/language.js +1 -1
- package/dist/shell/strings.d.ts +8 -0
- 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/ui/index.d.ts +1 -0
- package/dist/ui/index.js +1 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
- package/dist/Calculator-OJLVM42W.js +0 -29
- package/dist/Files-CRQDRSFS.js +0 -121
- package/dist/PdfViewer-GUXUWGMG.js +0 -1
- package/dist/Sidebar-F7HHC5GY.js +0 -44
- package/dist/chunk-2YRLRMZH.js +0 -23
- package/dist/chunk-43MCNASD.js +0 -1
- package/dist/chunk-6DZGOGB2.js +0 -1
- package/dist/chunk-6EHPEBGP.js +0 -5
- package/dist/chunk-7RRJPNYN.js +0 -4
- package/dist/chunk-A6WZF65N.js +0 -22
- package/dist/chunk-BG2OL3MO.js +0 -7
- package/dist/chunk-BTFBXZS2.js +0 -1
- package/dist/chunk-BUGTNNZQ.js +0 -15
- package/dist/chunk-C57PNNAW.js +0 -13
- package/dist/chunk-EB2UE6ZR.js +0 -10
- package/dist/chunk-EZPSNUYR.js +0 -14
- package/dist/chunk-FVZXRGVM.js +0 -8
- package/dist/chunk-GEZ45J4Z.js +0 -2
- package/dist/chunk-GUIJCTFJ.js +0 -8
- package/dist/chunk-I64TVNHS.js +0 -6
- package/dist/chunk-IHPAYSTJ.js +0 -8
- package/dist/chunk-M54OL3YR.js +0 -2
- package/dist/chunk-N7YHXL2F.js +0 -3
- package/dist/chunk-OLVKHYHV.js +0 -9
- package/dist/chunk-P2C33RHT.js +0 -1
- package/dist/chunk-PIWC3CAC.js +0 -4
- package/dist/chunk-PM4Y2FMQ.js +0 -9
- package/dist/chunk-PVXX77MY.js +0 -6
- package/dist/chunk-PWYLGTZS.js +0 -1
- package/dist/chunk-QQ2LDC6C.js +0 -6
- package/dist/chunk-SZT72QMD.js +0 -28
- package/dist/chunk-TQWLJ5VM.js +0 -7
- package/dist/chunk-UDVQORQM.js +0 -19
- package/dist/chunk-UJJXWLHE.js +0 -2
- package/dist/chunk-YZR4T5FZ.js +0 -7
- /package/dist/{chunk-T75VCE6K.js → chunk-GMHMWDXU.js} +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import{CartesianPlot as e}from"./chunk-
|
|
2
|
-
return c(e,{labels:h.map(e=>e.label),values:v,height:p,width:d,min:j-
|
|
1
|
+
import{CartesianPlot as e}from"./chunk-YRG6XJ6M.js";import{ChartTooltip as l}from"./chunk-WDQI3FV6.js";import{STATUS_VARS as o}from"./chunk-TZFACUMR.js";import{useShellStrings as t,useShellLocale as a}from"./chunk-TJSJVC6P.js";import{formatPlain as i,formatFixed as r}from"./chunk-C3QOHMR6.js";import{jsx as c,jsxs as n,Fragment as s}from"react/jsx-runtime";function h({candles:h,variant:m="candle",height:p=260,width:d,formatValue:u,yAxisLabel:b,label:y,className:x,emptyLabel:k}){const g=t().charts,f=a(),w=u??(e=>Number.isInteger(e)?i(e,f):r(e,2,f)),M=y??g.price,v=h.flatMap(e=>[e.low,e.high]).filter(Number.isFinite),j=Math.min(...v),L=Math.max(...v),W=.08*(L-j)||1;/* @__PURE__ */
|
|
2
|
+
return c(e,{labels:h.map(e=>e.label),values:v,height:p,width:d,min:j-W,max:L+W,bandPadding:.42,formatValue:w,yAxisLabel:b,className:x,emptyLabel:k,ariaLabel:g.ohlc(M,h.length),tooltip:e=>{const t=h[e],a=t.close>=t.open,i=a?o.good:o.critical;/* @__PURE__ */
|
|
3
3
|
return c(l,{title:t.label,rows:[{key:"open",label:g.open,color:i,value:w(t.open)},{key:"high",label:g.high,color:i,value:w(t.high)},{key:"low",label:g.low,color:i,value:w(t.low)},{key:"close",label:g.close,color:i,value:w(t.close)}],emphasisKey:"close",footnote:a?g.closedAbove:g.closedBelow})},children:({x:e,y:l,active:t})=>/* @__PURE__ */c("g",{children:h.map((a,i)=>{const r=a.close>=a.open,h=r?o.good:o.critical,p=e.center(i),d=Math.max(3,e.bandwidth),u=null!==t&&t!==i,b=l(Math.max(a.open,a.close)),y=Math.max(1,Math.abs(l(a.close)-l(a.open)));/* @__PURE__ */
|
|
4
4
|
return n("g",{opacity:u?.45:1,children:[
|
|
5
5
|
/* @__PURE__ */c("line",{x1:p,y1:l(a.high),x2:p,y2:l(a.low),stroke:h,strokeWidth:1.5}),"candle"===m?/* @__PURE__ */c("rect",{x:p-d/2,y:b,width:d,height:y,rx:1,fill:r?h:"transparent",fillOpacity:r?.85:1,stroke:h,strokeWidth:1.5}):/* @__PURE__ */n(s,{children:[
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{useInsideTooltip as e,Tooltip as n}from"./chunk-
|
|
1
|
+
import{useInsideTooltip as e,Tooltip as n}from"./chunk-SOZCWT6I.js";import{useRef as r,useState as t}from"react";import{jsx as c}from"react/jsx-runtime";var i="whitespace-nowrap";function l({children:i}){const l=e(),o=r(null),[a,s]=t(!1),m=/* @__PURE__ */c("span",{ref:o,className:"min-w-0 truncate",onMouseEnter:()=>{const e=o.current;s(!!e&&e.scrollWidth>e.clientWidth+1)},children:i});return l?m:/* @__PURE__ */c(n,{content:a?i:null,describe:!1,className:"relative inline-flex min-w-0 max-w-full",children:m})}export{l as OneLineLabel,i as TH_ONE_LINE};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{toast_default as e}from"./chunk-
|
|
1
|
+
import{toast_default as e}from"./chunk-JTZVUO3I.js";import{useShellStrings as t}from"./chunk-TJSJVC6P.js";import{forwardRef as r,useRef as n,useState as o,useMemo as i,useEffect as a,useImperativeHandle as l}from"react";import{jsx as s,jsxs as c,Fragment as d}from"react/jsx-runtime";var h=["#ef4444","#f97316","#eab308","#22c55e","#3b82f6","#8b5cf6","#000000","#ffffff"],u=[{id:"system",name:"fontSystem",css:"-apple-system, system-ui, sans-serif"},{id:"serif",name:"fontSerif",css:'Georgia, "Times New Roman", serif'},{id:"mono",name:"fontMono",css:'ui-monospace, "SF Mono", Menlo, monospace'},{id:"cursive",name:"fontCursive",css:'"Brush Script MT", "Comic Sans MS", cursive'}],p=()=>Math.random().toString(36).slice(2,9),y=r(function({src:r,filename:y,onApply:m,onCancel:g},N){const L=n(null),z=n(null),D=n(null),P=n(null),$=t().annotator,E=n($);E.current=$;const[I,S]=o("select"),[W,B]=o(h[0]),[R,j]=o(4),[T,H]=o(24),[F,U]=o(u[0].id),[A,O]=o(!0),[V,K]=o(!1),[Z,J]=o(!1),[X,q]=o(null),[G,Y]=o(null),[_,Q]=o(6),[ee,te]=o(12),[re,ne]=o([]),[oe,ie]=o(null),[ae,le]=o(null),[se,ce]=o(null),[de,he]=o(1),[ue,pe]=o(null),[ye,xe]=o(null),[me,ge]=o(null),we=n(null),[fe,ve]=o(!1),be=i(()=>se?{w:se.w*de,h:se.h*de}:null,[se,de]),ke=be&&ae?be.w/ae.w:1,Me=i(()=>re.find(e=>e.id===oe)??null,[re,oe]);a(()=>{"select"===I&&Me&&("color"in Me&&B(Me.color),"stroke"in Me&&j(Me.stroke),"rect"===Me.type&&te(Me.radius),"text"===Me.type&&(H(Me.size),U(Me.font),O(Me.bold),K(Me.italic),J(Me.underline),q(Me.borderColor),Y(Me.background),Q(Me.padding)))},[oe]),a(()=>{const t=new Image;t.crossOrigin="anonymous",t.onload=()=>{P.current=t,le({w:t.naturalWidth,h:t.naturalHeight}),ne([]),ie(null)},t.onerror=()=>e.error(E.current.loadFailed),t.src=r},[r]),a(()=>{if(!ae)return;const e=()=>{const e=L.current;if(!e)return;const t=e.getBoundingClientRect(),r=Math.max(0,t.width-32),n=Math.max(0,t.height-32);if(0===r||0===n)return;const o=ae.w/ae.h;let i=ae.w,a=ae.h;i>r&&(i=r,a=i/o),a>n&&(a=n,i=a*o),ce({w:i,h:a})};e();const t=new ResizeObserver(e);return L.current&&t.observe(L.current),()=>t.disconnect()},[ae]);const Ne=i(()=>re.filter(e=>"mosaic"===e.type),[re]);a(()=>{const e=P.current,t=z.current;if(!e||!t||!ae)return;t.width=ae.w,t.height=ae.h;const r=t.getContext("2d");r.drawImage(e,0,0);for(const e of Ne)C(r,e)},[ae,Ne,se]);const Ce=e=>{const t=D.current;if(!t)return{x:0,y:0};const r=t.createSVGPoint();r.x=e.clientX,r.y=e.clientY;const n=t.getScreenCTM();if(!n)return{x:0,y:0};const o=r.matrixTransform(n.inverse());return{x:o.x,y:o.y}},Le=e=>{we.current=e,ve(!0)};a(()=>{if(!fe)return;const e=e=>{const t=we.current;if(!t)return;const r=Ce(e);if("draw"===t.kind)pe(v(I,t.start,r,W,R,ee));else if("pen"===t.kind){const e=t.points[t.points.length-1];(Math.abs(r.x-e.x)>1||Math.abs(r.y-e.y)>1)&&(t.points.push(r),pe({id:"",type:"draw",points:t.points.slice(),color:W,stroke:R}))}else if("crop"===t.kind)ge(M(t.start,r));else if("move"===t.kind){const e=r.x-t.start.x,n=r.y-t.start.y;ne(r=>r.map(r=>r.id===t.id?b(t.original,e,n):r))}else"resize"===t.kind&&ne(e=>e.map(e=>e.id===t.id?function(e,t,r){if("arrow"===e.type)return"start"===t?{...e,x1:r.x,y1:r.y}:"end"===t?{...e,x2:r.x,y2:r.y}:e;if("text"===e.type||"draw"===e.type)return e;const n=e.x,o=e.x+e.w,i=e.y,a=e.y+e.h;let l=n,s=i,c=o,d=a;"nw"===t&&(l=r.x,s=r.y);"ne"===t&&(c=r.x,s=r.y);"se"===t&&(c=r.x,d=r.y);"sw"===t&&(l=r.x,d=r.y);const h=M({x:l,y:s},{x:c,y:d});return{...e,x:h.x,y:h.y,w:h.w,h:h.h}}(t.original,t.corner,r):e))},t=()=>{const e=we.current;if(we.current=null,ve(!1),"draw"===e?.kind)pe(e=>{if(!e||("arrow"===(t=e).type?Math.abs(t.x2-t.x1)<4&&Math.abs(t.y2-t.y1)<4:"draw"===t.type?t.points.length<2:"w"in t&&"h"in t&&(t.w<4||t.h<4)))return null;var t;const r={...e,id:p()};return ne(e=>[...e,r]),ie(r.id),S("select"),null});else if("pen"===e?.kind){if(e.points.length<2)return void pe(null);const t={id:p(),type:"draw",points:e.points,color:W,stroke:R};ne(e=>[...e,t]),ie(t.id),S("select"),pe(null)}};return window.addEventListener("pointermove",e),window.addEventListener("pointerup",t),window.addEventListener("pointercancel",t),()=>{window.removeEventListener("pointermove",e),window.removeEventListener("pointerup",t),window.removeEventListener("pointercancel",t)}},[fe,I,W,R,ee]);a(()=>{const e=e=>{if(!document.activeElement||!/^(INPUT|TEXTAREA)$/.test(document.activeElement.tagName))return!e.metaKey&&!e.ctrlKey||"z"!==e.key&&"Z"!==e.key||e.shiftKey?void(oe&&("Delete"===e.key||"Backspace"===e.key?(e.preventDefault(),ne(e=>e.filter(e=>e.id!==oe)),ie(null)):"Escape"===e.key&&ie(null))):(e.preventDefault(),ne(e=>e.slice(0,-1)),void ie(null))};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[oe]);const ze=e=>{const t=!{bold:A,italic:V,underline:Z}[e];"bold"===e&&O(t),"italic"===e&&K(t),"underline"===e&&J(t),oe&&ne(r=>r.map(r=>r.id===oe&&"text"===r.type?{...r,[e]:t}:r))},De=e=>{q(e),oe&&ne(t=>t.map(t=>t.id===oe&&"text"===t.type?{...t,borderColor:e}:t))},Pe=e=>{Y(e),oe&&ne(t=>t.map(t=>t.id===oe&&"text"===t.type?{...t,background:e}:t))},$e=e=>{if(!ye)return;const t=e??ye.value;if(!t.trim())return ye.editingId&&ne(e=>e.filter(e=>e.id!==ye.editingId)),void xe(null);if(ye.editingId)ne(e=>e.map(e=>e.id===ye.editingId&&"text"===e.type?{...e,text:t}:e));else{const e={id:p(),type:"text",x:ye.x,y:ye.y,text:t,color:W,size:T,font:F,bold:A,italic:V,underline:Z,borderColor:X,background:G,padding:_};ne(t=>[...t,e]),ie(e.id),S("select")}xe(null)},Ee=async()=>{const e=z.current,t=D.current;if(!e||!t||!ae)return null;const r=document.createElement("canvas");r.width=ae.w,r.height=ae.h;const n=r.getContext("2d");n.drawImage(e,0,0);const o=t.cloneNode(!0);o.querySelectorAll("[data-chrome]").forEach(e=>e.remove());const i=(new XMLSerializer).serializeToString(o),a=new Blob([i],{type:"image/svg+xml;charset=utf-8"}),l=URL.createObjectURL(a),s=new Image;return await new Promise(e=>{s.onload=()=>e(),s.onerror=()=>e(),s.src=l}),n.drawImage(s,0,0,ae.w,ae.h),URL.revokeObjectURL(l),r};l(N,()=>({save:async()=>{const t=await Ee();t&&t.toBlob(t=>{if(!t)return void e.error(E.current.exportFailed);const r=URL.createObjectURL(t),n=document.createElement("a");n.href=r;const o=y.replace(/\.[^.]+$/,"");n.download=`${o}-annotated.png`,n.click(),URL.revokeObjectURL(r)},"image/png")},copy:async()=>{if(!("clipboard"in navigator)||"undefined"==typeof ClipboardItem)return void e.error(E.current.clipboardUnsupported);const t=await Ee();t&&t.toBlob(async t=>{if(t)try{await navigator.clipboard.write([new ClipboardItem({"image/png":t})]),e.success(E.current.copied)}catch{e.error(E.current.copyRefused)}else e.error(E.current.copyFailed)},"image/png")}}),[ae,y]);const Ie=i(()=>[{id:"select",label:$.toolSelect,icon:/* @__PURE__ */s("svg",{className:"h-4 w-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */s("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M5 3l7 17 2-7 7-2L5 3z"})})},{id:"draw",label:$.toolDraw,icon:/* @__PURE__ */s("svg",{className:"h-4 w-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */s("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M16.862 4.487l1.687-1.688a1.875 1.875 0 112.652 2.652L6.832 19.82a4.5 4.5 0 01-1.897 1.13l-2.685.8.8-2.685a4.5 4.5 0 011.13-1.897L16.863 4.487z"})})},{id:"rect",label:$.toolRect,icon:/* @__PURE__ */s("svg",{className:"h-4 w-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */s("rect",{x:"4",y:"6",width:"16",height:"12",rx:"3"})})},{id:"circle",label:$.toolEllipse,icon:/* @__PURE__ */s("svg",{className:"h-4 w-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */s("ellipse",{cx:"12",cy:"12",rx:"8",ry:"6"})})},{id:"arrow",label:$.toolArrow,icon:/* @__PURE__ */s("svg",{className:"h-4 w-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */s("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M5 19L19 5m0 0h-7m7 0v7"})})},{id:"mosaic",label:$.toolMosaic,icon:/* @__PURE__ */s("svg",{className:"h-4 w-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */s("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M4 4h6v6H4zM14 4h6v6h-6zM4 14h6v6H4zM14 14h6v6h-6z"})})},{id:"text",label:$.toolText,icon:/* @__PURE__ */s("svg",{className:"h-4 w-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */s("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M4 6h16M12 6v14M9 20h6"})})},{id:"crop",label:$.toolCrop,icon:/* @__PURE__ */s("svg",{className:"h-4 w-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.8,children:/* @__PURE__ */s("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 2v15a1 1 0 001 1h15M2 6h15a1 1 0 011 1v15"})})}],[$]),Se=e=>"p-2 rounded transition-colors "+(e?"bg-blue-500 text-on-accent":"text-ink hover:bg-gray-200"),We=Me?.type??("select"===I?null:I),Be="rect"===We||"circle"===We||"arrow"===We||"draw"===We,Re="rect"===We,je="text"===We;/* @__PURE__ */
|
|
2
2
|
return c("div",{className:"flex flex-col h-full bg-gray-100",children:[
|
|
3
3
|
/* @__PURE__ */c("div",{className:"flex items-center gap-2 px-3 py-2 border-b border-line bg-surface shrink-0 flex-wrap text-xs",children:[Ie.map(e=>/* @__PURE__ */s("button",{onClick:()=>{S(e.id),ie(null)},title:e.label,className:Se(I===e.id),children:e.icon},e.id)),
|
|
4
4
|
/* @__PURE__ */s("div",{className:"h-5 w-px bg-gray-300 mx-1"}),
|
|
@@ -14,26 +14,26 @@ return c("div",{className:"flex flex-col h-full bg-gray-100",children:[
|
|
|
14
14
|
/* @__PURE__ */s("input",{type:"range",min:0,max:48,step:1,value:ee,onChange:e=>{return t=Number(e.target.value),te(t),void(oe&&ne(e=>e.map(e=>e.id===oe&&"rect"===e.type?{...e,radius:t}:e)));var t},className:"w-16 accent-blue-500"}),
|
|
15
15
|
/* @__PURE__ */s("span",{className:"tabular-nums w-6 text-right",children:ee})]})]}),je&&/* @__PURE__ */c(d,{children:[
|
|
16
16
|
/* @__PURE__ */s("div",{className:"h-5 w-px bg-gray-300 mx-1"}),
|
|
17
|
-
/* @__PURE__ */s("select",{value:F,onChange:e=>{return t=e.target.value,
|
|
18
|
-
/* @__PURE__ */s("button",{onClick:()=>ze("bold"),className:Se(
|
|
19
|
-
/* @__PURE__ */s("button",{onClick:()=>ze("italic"),className:Se(
|
|
17
|
+
/* @__PURE__ */s("select",{value:F,onChange:e=>{return t=e.target.value,U(t),void(oe&&ne(e=>e.map(e=>e.id===oe&&"text"===e.type?{...e,font:t}:e)));var t},className:"text-xs border border-gray-300 rounded px-1 py-0.5 bg-white",children:u.map(e=>/* @__PURE__ */s("option",{value:e.id,children:$[e.name]},e.id))}),
|
|
18
|
+
/* @__PURE__ */s("button",{onClick:()=>ze("bold"),className:Se(A),title:$.bold,children:/* @__PURE__ */s("span",{className:"font-bold",children:$.boldLetter})}),
|
|
19
|
+
/* @__PURE__ */s("button",{onClick:()=>ze("italic"),className:Se(V),title:$.italic,children:/* @__PURE__ */s("span",{className:"italic",children:$.italicLetter})}),
|
|
20
20
|
/* @__PURE__ */s("button",{onClick:()=>ze("underline"),className:Se(Z),title:$.underline,children:/* @__PURE__ */s("span",{className:"underline",children:$.underlineLetter})}),
|
|
21
21
|
/* @__PURE__ */c("label",{className:"flex items-center gap-2 text-gray-600",children:[
|
|
22
22
|
/* @__PURE__ */s("span",{children:$.size}),
|
|
23
|
-
/* @__PURE__ */s("input",{type:"range",min:10,max:96,step:1,value:
|
|
24
|
-
/* @__PURE__ */s("span",{className:"tabular-nums w-7 text-right",children:
|
|
23
|
+
/* @__PURE__ */s("input",{type:"range",min:10,max:96,step:1,value:T,onChange:e=>{return t=Number(e.target.value),H(t),void(oe&&ne(e=>e.map(e=>e.id===oe&&"text"===e.type?{...e,size:t}:e)));var t},className:"w-16 accent-blue-500"}),
|
|
24
|
+
/* @__PURE__ */s("span",{className:"tabular-nums w-7 text-right",children:T})]}),
|
|
25
25
|
/* @__PURE__ */c("label",{className:"flex items-center gap-1 text-gray-600",children:[
|
|
26
26
|
/* @__PURE__ */s("span",{children:$.border}),X?/* @__PURE__ */c(d,{children:[
|
|
27
27
|
/* @__PURE__ */s("input",{type:"color",value:X,onChange:e=>De(e.target.value),title:$.borderColor,className:"h-5 w-6 rounded border border-gray-300 bg-white p-0 cursor-pointer"}),
|
|
28
28
|
/* @__PURE__ */s("button",{onClick:()=>De(null),title:$.removeBorder,className:"px-0.5 text-gray-400 hover:text-gray-700",children:"✕"})]}):/* @__PURE__ */s("button",{onClick:()=>De(W),title:$.addBorder,className:"px-2 py-0.5 rounded border border-line-strong text-gray-600 hover:bg-gray-100",children:$.add})]}),
|
|
29
29
|
/* @__PURE__ */c("label",{className:"flex items-center gap-1 text-gray-600",children:[
|
|
30
|
-
/* @__PURE__ */s("span",{children:$.fill}),
|
|
31
|
-
/* @__PURE__ */s("input",{type:"color",value:
|
|
30
|
+
/* @__PURE__ */s("span",{children:$.fill}),G?/* @__PURE__ */c(d,{children:[
|
|
31
|
+
/* @__PURE__ */s("input",{type:"color",value:G,onChange:e=>Pe(e.target.value),title:$.fillColor,className:"h-5 w-6 rounded border border-gray-300 bg-white p-0 cursor-pointer"}),
|
|
32
32
|
/* @__PURE__ */s("button",{onClick:()=>Pe(null),title:$.removeFill,className:"px-0.5 text-gray-400 hover:text-gray-700",children:"✕"})]}):/* @__PURE__ */s("button",{onClick:()=>Pe("#ffffff"),title:$.addFill,className:"px-2 py-0.5 rounded border border-line-strong text-gray-600 hover:bg-gray-100",children:$.add})]}),
|
|
33
33
|
/* @__PURE__ */c("label",{className:"flex items-center gap-2 text-gray-600",children:[
|
|
34
34
|
/* @__PURE__ */s("span",{children:$.padding}),
|
|
35
|
-
/* @__PURE__ */s("input",{type:"range",min:0,max:40,step:1,value:
|
|
36
|
-
/* @__PURE__ */s("span",{className:"tabular-nums w-6 text-right",children:
|
|
35
|
+
/* @__PURE__ */s("input",{type:"range",min:0,max:40,step:1,value:_,onChange:e=>{return t=Number(e.target.value),Q(t),void(oe&&ne(e=>e.map(e=>e.id===oe&&"text"===e.type?{...e,padding:t}:e)));var t},className:"w-14 accent-blue-500"}),
|
|
36
|
+
/* @__PURE__ */s("span",{className:"tabular-nums w-6 text-right",children:_})]})]}),
|
|
37
37
|
/* @__PURE__ */s("div",{className:"h-5 w-px bg-gray-300 mx-1"}),
|
|
38
38
|
/* @__PURE__ */s("button",{onClick:()=>he(e=>Math.max(.25,Math.round(100*(e-.25))/100)),className:"px-2 py-1 rounded hover:bg-gray-200 text-gray-700",title:$.zoomOut,children:"−"}),
|
|
39
39
|
/* @__PURE__ */c("span",{className:"text-gray-600 tabular-nums w-10 text-center",children:[Math.round(100*de),"%"]}),
|
|
@@ -47,7 +47,7 @@ return c("div",{className:"flex flex-col h-full bg-gray-100",children:[
|
|
|
47
47
|
/* @__PURE__ */s("button",{onClick:async()=>{const t=await Ee();t?t.toBlob(t=>{t?m(t):e.error(E.current.exportFailed)},"image/png"):e.error(E.current.exportFailed)},className:"px-3 py-1 rounded bg-blue-500 text-white hover:bg-blue-600 text-xs font-medium",children:$.apply})]})]})]}),
|
|
48
48
|
/* @__PURE__ */s("div",{ref:L,className:"flex-1 overflow-auto bg-gray-200 flex items-center justify-center p-4 relative",children:be&&ae&&/* @__PURE__ */c("div",{className:"relative shadow-lg rounded overflow-hidden bg-white shrink-0",style:{width:be.w,height:be.h},children:[
|
|
49
49
|
/* @__PURE__ */s("canvas",{ref:z,style:{position:"absolute",inset:0,width:"100%",height:"100%",display:"block"}}),
|
|
50
|
-
/* @__PURE__ */c("svg",{ref:D,viewBox:`0 0 ${ae.w} ${ae.h}`,preserveAspectRatio:"none",style:{position:"absolute",inset:0,width:"100%",height:"100%",touchAction:"none",cursor:"select"===I?"default":"text"===I?"text":"crosshair"},onPointerDown:e=>{if("select"===I)return void ie(null);if("text"===I){if(ye)return void $e();const t=Ce(e);return void xe({x:t.x,y:t.y,value:""})}const t=Ce(e);if("crop"!==I){if("draw"===I)return Le({kind:"pen",points:[t]}),void pe({id:"",type:"draw",points:[t],color:W,stroke:R});pe(v(I,t,t,W,R,ee)),Le({kind:"draw",start:t})}else Le({kind:"crop",start:t})},children:[re.map(e=>/* @__PURE__ */s(x,{anno:e,selected:oe===e.id,zoom:de,onPointerDown:t=>((e,t)=>{"select"===I&&(e.stopPropagation(),ie(t.id),Le({kind:"move",id:t.id,start:Ce(e),original:t}))})(t,e),onDoubleClick:()=>{var t;"text"===(t=e).type&&xe({x:t.x,y:t.y,value:t.text,editingId:t.id})},onHandlePointerDown:(t,r)=>((e,t,r)=>{e.stopPropagation(),Le({kind:"resize",id:t.id,corner:r,start:Ce(e),original:t})})(t,e,r)},e.id)),ue&&/* @__PURE__ */s(x,{anno:{...ue,id:"__preview"},preview:!0}),me&&/* @__PURE__ */s(w,{rect:me,imageSize:ae})]}),ye&&/* @__PURE__ */s(f,{pendingText:ye,color:W,size:
|
|
50
|
+
/* @__PURE__ */c("svg",{ref:D,viewBox:`0 0 ${ae.w} ${ae.h}`,preserveAspectRatio:"none",style:{position:"absolute",inset:0,width:"100%",height:"100%",touchAction:"none",cursor:"select"===I?"default":"text"===I?"text":"crosshair"},onPointerDown:e=>{if("select"===I)return void ie(null);if("text"===I){if(ye)return void $e();const t=Ce(e);return void xe({x:t.x,y:t.y,value:""})}const t=Ce(e);if("crop"!==I){if("draw"===I)return Le({kind:"pen",points:[t]}),void pe({id:"",type:"draw",points:[t],color:W,stroke:R});pe(v(I,t,t,W,R,ee)),Le({kind:"draw",start:t})}else Le({kind:"crop",start:t})},children:[re.map(e=>/* @__PURE__ */s(x,{anno:e,selected:oe===e.id,zoom:de,onPointerDown:t=>((e,t)=>{"select"===I&&(e.stopPropagation(),ie(t.id),Le({kind:"move",id:t.id,start:Ce(e),original:t}))})(t,e),onDoubleClick:()=>{var t;"text"===(t=e).type&&xe({x:t.x,y:t.y,value:t.text,editingId:t.id})},onHandlePointerDown:(t,r)=>((e,t,r)=>{e.stopPropagation(),Le({kind:"resize",id:t.id,corner:r,start:Ce(e),original:t})})(t,e,r)},e.id)),ue&&/* @__PURE__ */s(x,{anno:{...ue,id:"__preview"},preview:!0}),me&&/* @__PURE__ */s(w,{rect:me,imageSize:ae})]}),ye&&/* @__PURE__ */s(f,{pendingText:ye,color:W,size:T,font:u.find(e=>e.id===F)?.css??u[0].css,bold:A,italic:V,underline:Z,borderColor:X,background:G,padding:_,scale:ke,onChange:e=>xe({...ye,value:e}),onCommit:$e,onCancel:()=>xe(null)})]})}),
|
|
51
51
|
/* @__PURE__ */s("div",{className:"px-3 py-2 border-t border-line bg-surface text-2xs text-ink-faint shrink-0",children:"select"===I?oe?$.hintSelected:$.hintSelect:"text"===I?$.hintText:"crop"===I?$.hintCrop:"draw"===I?$.hintDraw:$.hintShape})]})});function x({anno:e,selected:t,preview:r,zoom:n=1,onPointerDown:o,onDoubleClick:i,onHandlePointerDown:a}){const l=k(e),h=o?{onPointerDown:o,pointerEvents:"all",style:{cursor:"move"}}:{},p=i?{onDoubleClick:i}:{};let y;if("rect"===e.type)y=/* @__PURE__ */s("rect",{x:e.x,y:e.y,width:e.w,height:e.h,rx:e.radius,ry:e.radius,fill:"none",stroke:e.color,strokeWidth:e.stroke,strokeLinecap:"round",strokeLinejoin:"round",...h});else if("circle"===e.type)y=/* @__PURE__ */s("ellipse",{cx:e.x+e.w/2,cy:e.y+e.h/2,rx:e.w/2,ry:e.h/2,fill:"none",stroke:e.color,strokeWidth:e.stroke,...h});else if("arrow"===e.type)y=/* @__PURE__ */s(g,{anno:e,interactive:h});else if("draw"===e.type)y=/* @__PURE__ */s("path",{d:N(e.points),fill:"none",stroke:e.color,strokeWidth:e.stroke,strokeLinecap:"round",strokeLinejoin:"round",...h});else if("mosaic"===e.type)y=/* @__PURE__ */s("rect",{x:e.x,y:e.y,width:e.w,height:e.h,fill:"rgba(0,0,0,0.001)",stroke:"none",strokeWidth:t?2:0,strokeDasharray:t?"6,4":void 0,...h,style:t?{...h.style,stroke:"var(--rosh-annotator-selection)"}:h.style});else{const t=u.find(t=>t.id===e.font)?.css??u[0].css,r=e.padding??0,n=!!e.borderColor||!!e.background,o=k(e),i=e.borderColor?Math.max(1,Math.round(e.size/12)):0;y=/* @__PURE__ */c("g",{...h,...p,children:[n&&/* @__PURE__ */s("rect",{x:o.x-r,y:o.y-r,width:Math.max(0,o.w)+2*r,height:Math.max(0,o.h)+2*r,rx:Math.min(8,r),ry:Math.min(8,r),fill:e.background??"none",stroke:e.borderColor??"none",strokeWidth:i}),
|
|
52
52
|
/* @__PURE__ */s("text",{x:e.x,y:e.y+e.size,fill:e.color,fontSize:e.size,fontWeight:e.bold?700:400,fontStyle:e.italic?"italic":"normal",textDecoration:e.underline?"underline":void 0,fontFamily:t,style:{userSelect:"none"},children:e.text.split("\n").map((t,r)=>/* @__PURE__ */s("tspan",{x:e.x,dy:0===r?0:1.2*e.size,children:t},r))})]})}/* @__PURE__ */
|
|
53
53
|
return c("g",{children:[y,t&&!r&&/* @__PURE__ */c(d,{children:[
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{useShellPrefs as t}from"./chunk-KC3EX26K.js";import{toast_default as e}from"./chunk-
|
|
2
|
-
return(new Date).toISOString()}var K=null,
|
|
1
|
+
import{useShellPrefs as t}from"./chunk-KC3EX26K.js";import{toast_default as e}from"./chunk-JTZVUO3I.js";import{useSyncExternalStore as n,useCallback as o,useMemo as a}from"react";var r=[{id:"bell",label:"Bell",description:"Soft bell with one harmonic"},{id:"chime",label:"Chime",description:"Two-note ascending chime"},{id:"bowl",label:"Singing Bowl",description:"Long-decay meditation tone"},{id:"wind-chimes",label:"Wind Chimes",description:"Four soft tones in succession"},{id:"off",label:"Off (silent)",description:"No sound — only desktop notification"}],i=[{id:"none",label:"None"},{id:"tick-fast",label:"Ticking Fast"},{id:"tick-slow",label:"Ticking Slow"},{id:"rain",label:"Rain"},{id:"fireplace",label:"Fireplace"},{id:"white",label:"White Noise"},{id:"pink",label:"Pink Noise"},{id:"brown",label:"Brown Noise"}],c=()=>`pomodoro-${/* @__PURE__ */(new Date).toISOString().slice(0,10)}`,l={focus:1500,short:300,long:900},s="bell",u=100,d=1,f="none",m=50,h={autoStartBreaks:!1,autoStartPomodoros:!1,longBreakInterval:4},g={running:!1,remaining:l.focus,mode:"focus",total:l.focus,streak:0,count:"undefined"!=typeof localStorage?(()=>{try{return parseInt(localStorage.getItem(c())||"0",10)||0}catch{return 0}})():0},p=null,k=/* @__PURE__ */new Set,w=t=>{g={...g,...t},k.forEach(t=>t())};function M(){return g}function S(t){return k.add(t),()=>{k.delete(t)}}function b(t){l=t,g.running||g.remaining!==g.total||w({remaining:t[g.mode],total:t[g.mode]})}function y(t){s=t}function v(t,e){u=Math.max(0,Math.min(100,Math.round(t))),d=Math.max(1,Math.min(5,Math.round(e)))}function T(t){h={autoStartBreaks:!!t.autoStartBreaks,autoStartPomodoros:!!t.autoStartPomodoros,longBreakInterval:Math.max(1,Math.min(20,Math.round(t.longBreakInterval||4)))}}function A(t,e){f=t,m=Math.max(0,Math.min(100,Math.round(e))),g.running&&"focus"===g.mode?(V(),R()):"none"!==t&&0!==m||V()}function I(){g.running||(w({running:!0}),p=setInterval(C,1e3),"focus"===g.mode&&R())}function x(){(g.running||null!==p)&&(null!==p&&(clearInterval(p),p=null),w({running:!1}),V())}function B(t){x(),w({mode:t,remaining:l[t],total:l[t]})}function C(){g.remaining<=1?function(){null!==p&&(clearInterval(p),p=null);V(),N(s,{volume:u,repeat:d});const t="focus"===g.mode?"Pomodoro complete — time for a break! 🍅":"Break's over — back to work!";if("undefined"!=typeof Notification&&"granted"===Notification.permission)try{new Notification(t)}catch{}try{e.info(t)}catch{}if("focus"===g.mode){const t=g.streak+1,e=g.count+1;(t=>{try{localStorage.setItem(c(),String(t))}catch{}})(e);const n=t%h.longBreakInterval===0?"long":"short";w({running:!1,streak:t,count:e,mode:n,remaining:l[n],total:l[n]}),h.autoStartBreaks&&setTimeout(()=>I(),50)}else w({running:!1,mode:"focus",remaining:l.focus,total:l.focus}),h.autoStartPomodoros&&setTimeout(()=>I(),50)}():w({remaining:g.remaining-1})}function N(t=s,e={}){if("off"===t)return;const n=Math.max(0,Math.min(100,e.volume??100))/100;if(0===n)return;const o=Math.max(1,Math.min(5,e.repeat??1));for(let e=0;e<o;e++)setTimeout(()=>P(t,n),2500*e)}function P(t,e){try{const n=window.AudioContext||window.webkitAudioContext;if(!n)return;const o=new n,a=(t,n,a,r=.22,i="sine")=>{const c=o.createOscillator(),l=o.createGain();c.connect(l),l.connect(o.destination),c.type=i,c.frequency.value=t;const s=o.currentTime+n;l.gain.setValueAtTime(0,s),l.gain.linearRampToValueAtTime(r*e,s+.03),l.gain.exponentialRampToValueAtTime(1e-4,s+a),c.start(s),c.stop(s+a)};let r=2;"bell"===t?(a(880,0,1.8),a(1320,0,1.4,.1),r=2):"chime"===t?(a(659.25,0,.7),a(880,.2,1.3),r=2):"bowl"===t?(a(440,0,3.4,.22),a(660,0,3,.08),a(880,.05,2.8,.05),r=4):"wind-chimes"===t&&(a(1175,0,1.1,.16),a(880,.15,1.3,.16),a(1318,.3,1.5,.16),a(1047,.5,1.7,.13),r=3),setTimeout(()=>{try{o.close()}catch{}},1e3*r+500)}catch{}}var D=null,O={none:0,white:.3,pink:.3,brown:.3,"tick-fast":.6,"tick-slow":.6,rain:.4,fireplace:.5};function _(t,e){if("none"===e)return null;const n=t.sampleRate,o="white"===e||"pink"===e||"brown"===e?2:4,a=n*o,r=t.createBuffer(1,a,n),i=r.getChannelData(0);if("white"===e)for(let t=0;t<a;t++)i[t]=.5*(2*Math.random()-1);else if("pink"===e){let t=0,e=0,n=0,o=0,r=0,c=0,l=0;for(let s=0;s<a;s++){const a=2*Math.random()-1;t=.99886*t+.0555179*a,e=.99332*e+.0750759*a,n=.969*n+.153852*a,o=.8665*o+.3104856*a,r=.55*r+.5329522*a,c=-.7616*c-.016898*a,i[s]=.11*(t+e+n+o+r+c+l+.5362*a)*.55,l=.115926*a}}else if("brown"===e){let t=0;for(let e=0;e<a;e++){t=(t+.02*(2*Math.random()-1))/1.02,i[e]=3.5*t*.5}}else if("tick-fast"===e||"tick-slow"===e){const t="tick-fast"===e?.5:1,r=Math.floor(.045*n);for(let e=0;e<o;e+=t){const t=Math.floor(e*n);for(let e=0;e<r&&t+e<a;e++){const o=Math.exp(-e/n*180),a=2*Math.random()-1,r=Math.sin(2*Math.PI*1100*(e/n));i[t+e]+=(.7*a+.25*r)*o*.55}}}else if("rain"===e){let t=0;for(let e=0;e<a;e++){const o=2*Math.random()-1,a=o-.93*t;t=o;const r=.7+.3*Math.sin(e/n*2*Math.PI*.25);i[e]=a*r*.4}}else if("fireplace"===e){let t=0;for(let e=0;e<a;e++){t=(t+.02*(2*Math.random()-1))/1.02,i[e]=1.6*t}let e=.4*Math.random()*n;for(;e<a;){const t=Math.floor((.012+.05*Math.random())*n),o=.35+.45*Math.random(),r=Math.floor(e);for(let e=0;e<t&&r+e<a;e++){const t=Math.exp(-e/n*90);i[r+e]+=(2*Math.random()-1)*t*o}e+=(.08+.62*Math.random())*n}}return r}function R(){if(!D&&"none"!==f&&0!==m)try{const t=window.AudioContext||window.webkitAudioContext;if(!t)return;const e=new t,n=_(e,f);if(!n){try{e.close()}catch{}return}const o=e.createBufferSource();o.buffer=n,o.loop=!0;const a=e.createGain();a.gain.value=m/100*O[f],o.connect(a).connect(e.destination),o.start(),D={ctx:e,src:o,gain:a}}catch{}}function V(){if(D){try{D.src.stop()}catch{}try{D.ctx.close()}catch{}D=null}}function F(t,e){if("none"!==t&&0!==e)try{const n=window.AudioContext||window.webkitAudioContext;if(!n)return;const o=new n,a=_(o,t);if(!a){try{o.close()}catch{}return}const r=o.createBufferSource();r.buffer=a,r.loop=!0;const i=o.createGain();i.gain.value=e/100*O[t],r.connect(i).connect(o.destination),r.start(),setTimeout(()=>{try{r.stop()}catch{}try{o.close()}catch{}},3e3)}catch{}}var G="pomodoro_tasks",j="pomodoro_tasks_migrated";function E(){return Math.random().toString(36).slice(2,11)}function J(){/* @__PURE__ */
|
|
2
|
+
return(new Date).toISOString()}var K=null,W=[],q=!1,L=null,U=/* @__PURE__ */new Set;function X(){for(const t of U)t()}function Z(t){W=t,X()}function $(){const t=K;return t?L=t.list().then(e=>{K===t&&(W=e,q=!0,X())}).catch(()=>{K===t&&(q=!0,X())}).finally(()=>{L=null}):(W=[],q=!0,X(),Promise.resolve())}function z(t){K=t,W=[],q=!1,t?$():X()}function H(t){return U.add(t),!K||q||L||$(),()=>{U.delete(t)}}function Q(){return W}function Y(){const e=function(){const{prefs:e,save:n}=t(),r=a(()=>{const t=e.todo_tasks;return Array.isArray(t)?t:[]},[e.todo_tasks]),i=o(t=>{n({todo_tasks:t})},[n]),c=o(t=>{const e=E(),n=J(),o={done:!1,...t,name:t.name.trim(),id:e,createdAt:n,updatedAt:n};return i([...r,o]),e},[r,i]),l=o((t,e)=>{i(r.map(n=>n.id===t?{...n,...e,id:n.id,updatedAt:J()}:n))},[r,i]),s=o(t=>{i(r.filter(e=>e.id!==t))},[r,i]),u=o(t=>{const e=r.find(e=>e.id===t);e&&l(t,{done:!e.done})},[r,l]);return{tasks:r,addTask:c,updateTask:l,removeTask:s,toggleDone:u,setAllTasks:i}}(),r=n(H,Q,Q),i=o(t=>{const n=K;if(!n)return e.addTask(t);const o="tmp-"+E(),a=J(),r={done:!1,...t,name:t.name.trim(),id:o,createdAt:a,updatedAt:a};return Z([...W,r]),n.create({...t,name:t.name.trim()}).then(t=>Z(W.map(e=>e.id===o?{...r,...t}:e))).catch(()=>Z(W.filter(t=>t.id!==o))),o},[e]),c=o((t,n)=>{const o=K;if(!o)return e.updateTask(t,n);Z(W.map(e=>e.id===t?{...e,...n,id:t,updatedAt:J()}:e)),o.update(t,n).catch(()=>{$()})},[e]),l=o(t=>{const n=K;if(!n)return e.removeTask(t);const o=W;Z(W.filter(e=>e.id!==t)),n.remove(t).catch(()=>Z(o))},[e]),s=o(t=>{if(!K)return e.toggleDone(t);const n=W.find(e=>e.id===t);n&&c(t,{done:!n.done})},[e,c]),u=o(t=>{K||e.setAllTasks(t)},[e]);return null===K?e:{tasks:r,addTask:i,updateTask:c,removeTask:l,toggleDone:s,setAllTasks:u}}function tt(t,e){try{if(localStorage.getItem(j))return;const n=localStorage.getItem(G);if(!n)return void localStorage.setItem(j,"1");const o=JSON.parse(n);if(!Array.isArray(o)||0===o.length)return localStorage.removeItem(G),void localStorage.setItem(j,"1");const a=J(),r=o.filter(t=>"string"==typeof t?.name).map(t=>({id:t.id||E(),name:String(t.name),done:!!t.done,estimated:"number"==typeof t.estimated?t.estimated:void 0,completed:"number"==typeof t.completed?t.completed:void 0,createdAt:a,updatedAt:a})),i=new Set(t.map(t=>t.id));e([...r.filter(t=>!i.has(t.id)),...t]),localStorage.removeItem(G),localStorage.setItem(j,"1")}catch{try{localStorage.setItem(j,"1")}catch{}}}export{r as ALARM_OPTIONS,i as FOCUS_SOUND_OPTIONS,M as getPomoSnapshot,tt as migratePomodoroTasksOnce,N as playAlarm,x as pomoPause,I as pomoStart,B as pomoSwitchMode,F as previewFocusSound,y as setPomoAlarm,v as setPomoAlarmConfig,T as setPomoBehaviour,b as setPomoDurations,A as setPomoFocusSound,z as setShellTodoProvider,S as subscribePomo,Y as useTodoTasks};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{railLabelsShown as e}from"./chunk-FQEALPZJ.js";import{CountBadge as t}from"./chunk-
|
|
1
|
+
import{railLabelsShown as e}from"./chunk-FQEALPZJ.js";import{CountBadge as t}from"./chunk-V6FHZGCL.js";import{Tooltip as n}from"./chunk-SOZCWT6I.js";import{useBrowserLayoutEffect as r}from"./chunk-D65T4H6J.js";import{createContext as o,useRef as a,useState as i,useEffect as l,useContext as s}from"react";import{jsx as c,jsxs as d,Fragment as u}from"react/jsx-runtime";var h=o({labels:"none",shown:"none"}),f="button[data-icon-rail-button]:not([disabled])";function b(e,t,n){const r=getComputedStyle(e),o=(parseFloat(r.paddingLeft)||0)+(parseFloat(r.paddingRight)||0)+(parseFloat(r.borderLeftWidth)||0)+(parseFloat(r.borderRightWidth)||0),a="horizontal"===t?(parseFloat(r.columnGap)||0)*Math.max(0,n-1):0,i=e.parentElement;let l=1/0;if(i){const e=getComputedStyle(i);l=i.clientWidth-(parseFloat(e.paddingLeft)||0)-(parseFloat(e.paddingRight)||0)}return{chrome:o+a,room:l}}function m({"aria-label":t,orientation:n="vertical",children:o,className:s="",labels:d="none",labelsFit:u=!1,onLabelsShown:m}){const p=a(null),g="none"!==d&&u,[v,y]=i(null),w="none"===d?"none":g?v??"none":"all",x=a(()=>{});x.current=()=>{const t=p.current;if(!t||!g)return;const r=function(e,t){return[...e.querySelectorAll("button[data-icon-rail-button]")].map(e=>{const n=getComputedStyle(e),r=(parseFloat(n.paddingLeft)||0)+(parseFloat(n.paddingRight)||0)+(parseFloat(n.borderLeftWidth)||0)+(parseFloat(n.borderRightWidth)||0),o=parseFloat(n.minWidth)||0,a=e.querySelector("[data-icon-rail-glyph]")?.getBoundingClientRect().width??0,i=e.querySelector("[data-icon-rail-word]")?.scrollWidth??0;return{bare:Math.max(o,r+a),worded:"below"===t?Math.max(o,r+Math.max(a,i)):Math.max(o,r+a+8+i),active:"true"===e.getAttribute("aria-pressed")}})}(t,d);y(e({buttons:r,orientation:n,...b(t,n,r.length)}))},r(()=>{x.current()}),l(()=>{const e=p.current?.parentElement;if(!g||!e)return;let t=!0;const n=()=>{t&&x.current()},r="undefined"==typeof ResizeObserver?void 0:ResizeObserver,o=r?new r(n):null;return o?.observe(e),document.fonts?.ready.then(n,()=>{}),()=>{t=!1,o?.disconnect()}},[g]);const F=a(null),k=a(m);k.current=m,l(()=>{g&&null!==v&&F.current!==v&&(F.current=v,k.current?.(v))},[g,v]),r(()=>{const e=p.current;if(!e)return;const t=[...e.querySelectorAll(f)];if(0===t.length)return;const n=t.find(e=>e===document.activeElement)??t.find(e=>"true"===e.getAttribute("aria-pressed"))??t[0];for(const t of e.querySelectorAll("button[data-icon-rail-button]"))t.tabIndex=t===n?0:-1});/* @__PURE__ */
|
|
2
2
|
return c("div",{ref:p,role:"toolbar","aria-label":t,"aria-orientation":n,"data-orientation":n,onKeyDown:e=>{const t=p.current;if(!t)return;const r=[...t.querySelectorAll(f)],o=r.indexOf(e.target);if(o<0)return;const a="vertical"===n?"ArrowUp":"ArrowLeft",i="vertical"===n?"ArrowDown":"ArrowRight",l=e.key===i?(o+1)%r.length:e.key===a?(o-1+r.length)%r.length:"Home"===e.key?0:"End"===e.key?r.length-1:-1;if(!(l<0)){e.preventDefault();for(const e of r)e.tabIndex=e===r[l]?0:-1;r[l].focus()}},"data-labels":"none"===d?void 0:d,"data-labels-shown":"none"===d?void 0:w,className:`flex gap-1 ${"vertical"===n?"flex-col items-center":"flex-row items-center"} ${s}`.trim(),children:/* @__PURE__ */c(h.Provider,{value:{labels:d,shown:w},children:o})})}function p({label:e,icon:r,active:o,disabled:a,onClick:i,badge:l,tooltipSide:f="right",className:b=""}){const m=!0===o,{labels:p,shown:g}=s(h),v=void 0===l||!1===l||0===l?r:/* @__PURE__ */c(t,{count:"number"==typeof l?l:void 0,dot:!0===l,max:99,children:r}),y="none"!==p,w=y&&("all"===g||"chosen"===g&&m),x=/* @__PURE__ */c("button",{type:"button","data-icon-rail-button":"","aria-label":e,"aria-pressed":"boolean"==typeof o?o:void 0,disabled:a,onClick:a?void 0:i,className:[`relative inline-flex ${y?"beside"===p?"h-9 min-w-9 justify-center px-2":"min-h-9 min-w-9 flex-col justify-center px-1 py-1":"h-9 w-9 justify-center"} shrink-0 items-center rounded-lg transition-colors`,"rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)]","disabled:cursor-not-allowed disabled:opacity-40",m?"bg-accent-tint text-blue-700":"text-gray-600 not-disabled:not-aria-disabled:hover:bg-gray-100 not-disabled:not-aria-disabled:hover:text-ink-strongest",b].filter(Boolean).join(" "),children:y?/* @__PURE__ */d(u,{children:[
|
|
3
3
|
/* @__PURE__ */c("span",{"data-icon-rail-glyph":"",className:"inline-flex shrink-0 items-center justify-center",children:v}),
|
|
4
4
|
/* @__PURE__ */c("span",{"data-icon-rail-word":"","aria-hidden":"true",className:["overflow-hidden whitespace-nowrap text-xs font-medium leading-none",w?"beside"===p?"ml-2":"mt-1":"max-h-0 max-w-0"].join(" "),children:e})]}):v});/* @__PURE__ */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{Tabs as e}from"./chunk-
|
|
1
|
+
import{Tabs as e}from"./chunk-QJGZOD6X.js";import{Card as a}from"./chunk-BYDSBDVS.js";import{StatusBadgeProvider as r,StatusBadge as t}from"./chunk-JMGDGNM7.js";import{Button_default as l}from"./chunk-EVYD6UFQ.js";import{useState as i}from"react";import{jsx as d,jsxs as s}from"react/jsx-runtime";var n={featured:"success",new:"active",draft:"draft"},c=["linear-gradient(135deg,#60a5fa,#a78bfa)","linear-gradient(135deg,#34d399,#10b981)","linear-gradient(135deg,#fbbf24,#f59e0b)","linear-gradient(135deg,#f472b6,#ec4899)","linear-gradient(135deg,#38bdf8,#6366f1)","linear-gradient(135deg,#fb7185,#ef4444)","linear-gradient(135deg,#4ade80,#22c55e)","linear-gradient(135deg,#c084fc,#8b5cf6)"].map((e,a)=>({id:a,title:["Sunrise","Forest","Desert","Bloom","Ocean","Ember","Meadow","Dusk"][a],tag:["featured","new","draft"][a%3],bg:e}));function m(){const[m,g]=i("all"),f="all"===m?c:c.filter(e=>e.tag===m);/* @__PURE__ */
|
|
2
2
|
return d(r,{groups:n,children:/* @__PURE__ */d("div",{className:"h-full overflow-auto bg-gray-50 p-6",children:/* @__PURE__ */s("div",{className:"mx-auto max-w-5xl space-y-4",children:[
|
|
3
3
|
/* @__PURE__ */s("div",{className:"flex items-center justify-between gap-4",children:[
|
|
4
4
|
/* @__PURE__ */d("h1",{className:"text-xl font-semibold text-gray-900",children:"Gallery"}),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{layoutFlow as e}from"./chunk-FAERBT6Y.js";import{Button_default as t}from"./chunk-
|
|
1
|
+
import{layoutFlow as e}from"./chunk-FAERBT6Y.js";import{Button_default as t}from"./chunk-EVYD6UFQ.js";import{Icon as n}from"./chunk-T3NLFOLW.js";import{CHART_INK as r,STATUS_VARS as o,SERIES_VARS as i}from"./chunk-TZFACUMR.js";import{useMemo as l,useRef as a,useId as c}from"react";import{jsxs as d,jsx as s}from"react/jsx-runtime";var h={downloadPng:"Download PNG",downloadSvg:"Download SVG",toPdf:"Add to the PDF"},m={label:"var(--ink-strong)",note:r.label,line:r.label},f={step:i[0],decision:o.warning,start:r.muted,end:r.muted};function u(e,t){return`${(e.title??"flowchart").toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-|-$/g,"")||"flowchart"}.${t}`}function g(e){const t=new Map(e.nodes.map(e=>[e.id,e.label]));return e.edges.map(e=>`${t.get(e.from)} to ${t.get(e.to)}${e.label?` (${e.label})`:""}`).join("; ")}function w({node:e}){const t=f[e.kind],n=e.x+e.width/2,r=e.y+e.height/2,o=e.note?[...e.lines,e.note]:e.lines,i=r-15*(o.length-1)/2,l="decision"===e.kind?/* @__PURE__ */s("polygon",{points:`${n},${e.y} ${e.x+e.width},${r} ${n},${e.y+e.height} ${e.x},${r}`}):/* @__PURE__ */s("rect",{x:e.x,y:e.y,width:e.width,height:e.height,rx:"step"===e.kind?4:e.height/2});/* @__PURE__ */
|
|
2
2
|
return d("g",{fill:t,fillOpacity:.14,stroke:t,strokeWidth:1,children:[l,o.map((t,r)=>{const l=void 0!==e.note&&r===o.length-1;/* @__PURE__ */
|
|
3
3
|
return s("text",{x:n,y:i+15*r,textAnchor:"middle",dominantBaseline:"central",fontSize:l?11:12.5,fontWeight:l?400:600,fill:l?m.note:m.label,fillOpacity:1,stroke:"none",children:t},r)})]})}function p(e){const t=e.cloneNode(!0),n=[e,...Array.from(e.querySelectorAll("*"))],r=[t,...Array.from(t.querySelectorAll("*"))],o=e.ownerDocument.defaultView;n.forEach((e,t)=>{for(const n of["fill","stroke"]){const i=e.getAttribute(n);i&&i.includes("var(")&&o&&r[t].setAttribute(n,o.getComputedStyle(e).getPropertyValue(n)||i)}});const i=o?.getComputedStyle(e).getPropertyValue("--viz-surface").trim();if(i){const n=e.ownerDocument.createElementNS("http://www.w3.org/2000/svg","rect");n.setAttribute("width","100%"),n.setAttribute("height","100%"),n.setAttribute("fill",i),t.insertBefore(n,t.firstChild)}return t.setAttribute("xmlns","http://www.w3.org/2000/svg"),t.setAttribute("font-family","system-ui, -apple-system, Segoe UI, sans-serif"),(new XMLSerializer).serializeToString(t)}function b(e,t){const n=URL.createObjectURL(e),r=document.createElement("a");r.href=n,r.download=t,r.click(),setTimeout(()=>URL.revokeObjectURL(n),1e3)}function y({spec:r,labels:o,onToPdf:i,bare:f=!1,className:y}){const k={...h,...o},v=l(()=>e(r),[r]),x=a(null),$=r.title??"Flowchart",A=`flow-arrow-${c().replace(/:/g,"")}`;/* @__PURE__ */
|
|
4
4
|
return d("figure",{className:`my-2 ${y??""}`,children:[
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{ErrorPage as r}from"./chunk-
|
|
1
|
+
import{ErrorPage as r}from"./chunk-6YIVKPWQ.js";import{reportBoundaryError as e}from"./chunk-KNUR2UEG.js";import{Button_default as t}from"./chunk-EVYD6UFQ.js";import{useShellStrings as s}from"./chunk-TJSJVC6P.js";import{Component as o}from"react";import{jsxs as i,jsx as a,Fragment as n}from"react/jsx-runtime";function c({pick:r}){/* @__PURE__ */
|
|
2
2
|
return a(n,{children:r(s().errors)})}var l=class extends o{state={error:null};static getDerivedStateFromError(r){return{error:r}}componentDidCatch(r,t){console.error("ErrorBoundary caught an error:",r,t),e(r),this.props.onError?.(r,t)}componentDidUpdate(r){if(!this.state.error)return;const e=r.resetKeys??[],t=this.props.resetKeys??[];(e.length!==t.length||e.some((r,e)=>!Object.is(r,t[e])))&&this.reset()}reset=()=>this.setState({error:null});render(){const{error:e}=this.state;return e?this.props.fallback?this.props.fallback(e,this.reset):
|
|
3
3
|
/* @__PURE__ */i("div",{className:"flex h-full flex-col",children:[
|
|
4
4
|
/* @__PURE__ */a("div",{role:"alert",className:"min-h-0 flex-1",children:/* @__PURE__ */a(r,{code:500,actions:/* @__PURE__ */i(n,{children:[
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import{LoadingSpinner as e}from"./chunk-R2VKEMZH.js";import{useBrowserLayoutEffect as n}from"./chunk-D65T4H6J.js";import{useShellStrings as t,useShellLocale as r}from"./chunk-
|
|
2
|
-
return u("div",{className:"group flex flex-col w-72 shrink-0 rounded-xl bg-gray-50 border transition-colors "+(t?"border-blue-400 ring-2 ring-blue-300/60":"border-gray-200"),onDragOver:e=>{e.preventDefault();try{e.dataTransfer.dropEffect="move"}catch{}},onDrop:n=>{n.preventDefault(),(e=>{if(H&&S&&S.col===e){const n=(
|
|
1
|
+
import{LoadingSpinner as e}from"./chunk-R2VKEMZH.js";import{useBrowserLayoutEffect as n}from"./chunk-D65T4H6J.js";import{useShellStrings as t,useShellLocale as r}from"./chunk-TJSJVC6P.js";import{formatPlain as a}from"./chunk-C3QOHMR6.js";import{useState as o,useMemo as l,useRef as i,Fragment as s}from"react";import{jsx as d,Fragment as c,jsxs as u}from"react/jsx-runtime";function m({items:m,columns:f,columnOf:p,getId:g,onMove:h,renderCard:x,onCardClick:b,sortInColumn:y,isLoading:v=!1,loadingText:N,emptyState:k,showColumnsWhenEmpty:w=!1,columnEmptyText:C,onAddItem:D,addItemText:E}){const j=t().kanban,I=r(),T=N??j.loading,M=C??j.dropHere,A=E??j.addItem,[H,O]=o(null),[S,$]=o(null),J=l(()=>{const e={};for(const n of f)e[n.value]=[];for(const n of m)(e[p(n)]??=[]).push(n);if(y)for(const n of Object.keys(e))e[n].sort(y);return e},[m,f,p,y]),R=()=>{O(null),$(null)},q=i(null),z=i(/* @__PURE__ */new Map);n(()=>{if(null!==H)return;const e=q.current;if(!e)return;const n=/* @__PURE__ */new Map,t=[];if(e.querySelectorAll("[data-kanban-card]").forEach(e=>{const r=e.dataset.kanbanCard,a=e.getBoundingClientRect();n.set(r,a);const o=z.current.get(r);if(o){const n=o.left-a.left,r=o.top-a.top;(n||r)&&t.push([e,n,r])}}),z.current=n,t.length){for(const[e,n,r]of t)e.style.transition="none",e.style.transform=`translate(${n}px, ${r}px)`;requestAnimationFrame(()=>{for(const[e]of t)e.style.transition="transform 200ms cubic-bezier(0.2, 0, 0, 1)",e.style.transform="",e.addEventListener("transitionend",()=>{e.style.transition="",e.style.transform=""},{once:!0})})}},[J,H]);return v?/* @__PURE__ */d(e,{size:"sm",padding:"p-4",label:T}):0!==m.length||w?/* @__PURE__ */d("div",{ref:q,className:"flex-1 overflow-x-auto grid-scroll",children:/* @__PURE__ */d("div",{className:"flex gap-3 h-full min-w-max pb-2",children:f.map(e=>{const n=J[e.value]??[],t=null!==S&&S.col===e.value,r=null!==H?n.findIndex(e=>g(e)===H):-1,o=t&&(-1===r||S.index!==r&&S.index!==r+1)?S.index:-1;/* @__PURE__ */
|
|
2
|
+
return u("div",{className:"group flex flex-col w-72 shrink-0 rounded-xl bg-gray-50 border transition-colors "+(t?"border-blue-400 ring-2 ring-blue-300/60":"border-gray-200"),onDragOver:e=>{e.preventDefault();try{e.dataTransfer.dropEffect="move"}catch{}},onDrop:n=>{n.preventDefault(),(e=>{if(H&&S&&S.col===e){const n=(J[e]??[]).findIndex(e=>g(e)===H),t=-1!==n;if(!t||S.index!==n&&S.index!==n+1){const r=t&&S.index>n?S.index-1:S.index;h(H,e,r)}}R()})(e.value)},children:[
|
|
3
3
|
/* @__PURE__ */u("div",{className:`flex items-center justify-between px-3 py-2 rounded-t-xl text-sm font-medium ${e.accent??"text-gray-700 bg-gray-100"}`,children:[
|
|
4
4
|
/* @__PURE__ */u("span",{className:"flex items-center gap-2",children:[
|
|
5
5
|
/* @__PURE__ */d("span",{className:`h-2 w-2 rounded-full ${e.dot??"bg-gray-400"}`}),e.label]}),
|
|
6
6
|
/* @__PURE__ */d("span",{className:"text-xs opacity-70",children:a(n.length,I)})]}),
|
|
7
7
|
/* @__PURE__ */u("div",{className:"flex-1 overflow-y-auto p-2 space-y-2 min-h-[120px]",onDragEnter:()=>$(t=>t&&t.col===e.value&&t.index===n.length?t:{col:e.value,index:n.length}),children:[n.map((t,r)=>{const a=g(t),l=a===H;/* @__PURE__ */
|
|
8
8
|
return u(s,{children:[o===r&&/* @__PURE__ */d("div",{className:"h-0.5 rounded-full bg-blue-500","aria-hidden":!0}),
|
|
9
|
-
/* @__PURE__ */d("div",{"data-kanban-card":a,draggable:!0,onDragStart:e=>{O(a);try{e.dataTransfer.effectAllowed="move"}catch{}},onDragEnter:t=>{t.stopPropagation();const a=null!==H?n.findIndex(e=>g(e)===H):-1,o=-1!==a&&a<r?r+1:r;$(n=>n&&n.col===e.value&&n.index===o?n:{col:e.value,index:o})},onDragEnd:
|
|
9
|
+
/* @__PURE__ */d("div",{"data-kanban-card":a,draggable:!0,onDragStart:e=>{O(a);try{e.dataTransfer.effectAllowed="move"}catch{}},onDragEnter:t=>{t.stopPropagation();const a=null!==H?n.findIndex(e=>g(e)===H):-1,o=-1!==a&&a<r?r+1:r;$(n=>n&&n.col===e.value&&n.index===o?n:{col:e.value,index:o})},onDragEnd:R,onClick:b?()=>b(t):void 0,style:null===H?void 0:{opacity:l?.4:1,transition:"opacity 120ms ease"},className:"rounded-lg bg-white border border-gray-200 p-3 shadow-sm hover:border-blue-400 hover:shadow transition "+(b?"cursor-pointer":""),children:x(t)})]},a)}),n.length>0&&o===n.length&&/* @__PURE__ */d("div",{className:"h-0.5 rounded-full bg-blue-500","aria-hidden":!0}),0===n.length&&/* @__PURE__ */d("div",{className:"text-2xs text-center rounded-lg transition-all duration-150 "+(t?"border-2 border-dashed border-blue-300 bg-blue-50/50 text-blue-400 py-8":"text-gray-400 py-6"),children:M})]}),D&&/* @__PURE__ */d("div",{className:"p-2 pt-0",children:/* @__PURE__ */u("button",{type:"button",onClick:()=>D(e.value),className:"flex w-full items-center justify-center gap-1 rounded-lg px-2 min-h-8 py-1 text-xs font-medium text-ink-faint opacity-0 transition hover:bg-gray-100 hover:text-ink focus-visible:opacity-100 group-hover:opacity-100",children:[
|
|
10
10
|
/* @__PURE__ */d("span",{"aria-hidden":!0,className:"text-sm leading-none",children:"+"}),A]})})]},e.value)})})}):/* @__PURE__ */d(c,{children:k??/* @__PURE__ */d("div",{className:"text-sm text-gray-500 p-4",children:j.empty})})}export{m as Kanban};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{TimelineCard as e}from"./chunk-S4Z657L6.js";import{TimelineTrack as n,TimelineMilestoneIcon as s}from"./chunk-FZWAOYAM.js";import{toDayMs as i,fmtSliderDate as t,DAY_MS as a}from"./chunk-7TC3LJQM.js";import{useBrowserValueOnce as l}from"./chunk-D65T4H6J.js";import{useShellStrings as o,useShellLocale as r}from"./chunk-TJSJVC6P.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,J=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 L=i(g??null);let O,w,D=!0;0===j.length?(w=L??M??0,O=w-30*a,D=null!==L||null!==M):(O=j[0].ms,w=L??j[j.length-1].ms,w-O<a&&(w=O+a));const H=j.length>0?Math.max(0,Math.round((w-O)/a)):0,N=u??(H>0?x.duration(H):void 0),T=[j.length>0?x.started(t(j[0].ms,J)):void 0,N,C.length>0?x.reached(j.length,p.length):void 0],A=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}),K={};for(const e of j)e.phase&&(K[e.phase]=K[e.phase]||[]).push(e.ms);const S=Object.entries(K).filter(([,e])=>e.length>=2).map(([e,n])=>({key:e,label:k?.[e]??e,minMs:Math.min(...n),maxMs:Math.max(...n)})),Z="rail"===v,F=D&&/* @__PURE__ */h("div",{className:"select-none",children:/* @__PURE__ */h(n,{axis:Z?"spread":"compressed",labels:Z?"none":"lanes",items:A,pending:C,phases:S,startMs:O,endMs:w,todayMs:M??void 0,edgeCaptions:f,highlightKeys:y,onHoverChange:b,ariaLabel:x.milestones(m)})});/* @__PURE__ */
|
|
2
|
+
return h("div",Z?{className:"shrink-0","data-timeline-variant":"rail",children:F}:{className:"shrink-0",children:/* @__PURE__ */h(e,{icon:/* @__PURE__ */h(s,{}),heading:d??m,subject:c,meta:T,children:F})})}export{m as MilestoneTimeline};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import{DropdownMenu as e}from"./chunk-
|
|
1
|
+
import{DropdownMenu as e}from"./chunk-KVU5IQOZ.js";import{IconButton_default as r}from"./chunk-SV5RRBVA.js";import{inputClasses as n,PLACEHOLDER_INK as t}from"./chunk-AYZY3YNC.js";import{Tooltip as i}from"./chunk-SOZCWT6I.js";import{iconButtonClasses as a}from"./chunk-UQYNPYF4.js";import{forwardRef as s}from"react";import{jsx as o,jsxs as l}from"react/jsx-runtime";var c={sm:"sm",md:"sm",lg:"md",touch:"touch-sm"},m={sm:"pr-8",md:"pr-8",lg:"pr-10",touch:"pr-12"};function p({children:e}){/* @__PURE__ */
|
|
2
2
|
return o("span",{className:"absolute right-1 top-1/2 flex -translate-y-1/2 items-center gap-1",children:e})}function d({action:e,size:r="md"}){/* @__PURE__ */
|
|
3
3
|
return o(h,{action:e,size:c[r]})}var u=["","pr-8","pr-16"];function h({action:n,size:t}){const{label:s,icon:l,onClick:c,menu:m}=n;/* @__PURE__ */
|
|
4
|
-
return o(i,{content:s,describe:!1,children:m?/* @__PURE__ */o(e,{"aria-label":s,trigger:l,items:m,triggerClassName:a({size:t})}):/* @__PURE__ */o(r,{"aria-label":s,size:t,onClick:c,children:l})})}var f=s(function({invalid:e,leftIcon:r,rightAdornment:i,endAction:a,size:s,className:c="",readOnly:u,...h},f){const g=s??"md",
|
|
5
|
-
/* @__PURE__ */o("input",{ref:f,"aria-invalid":e||void 0,readOnly:u,className:n({invalid:e,size:s,readOnly:u,className:[
|
|
4
|
+
return o(i,{content:s,describe:!1,children:m?/* @__PURE__ */o(e,{"aria-label":s,trigger:l,items:m,triggerClassName:a({size:t})}):/* @__PURE__ */o(r,{"aria-label":s,size:t,onClick:c,children:l})})}var f=s(function({invalid:e,leftIcon:r,rightAdornment:i,endAction:a,size:s,className:c="",readOnly:u,...h},f){const g=s??"md",v=`${r?"pl-10":""} ${a?m[g]:i?"pr-10":""}`.trim(),N=
|
|
5
|
+
/* @__PURE__ */o("input",{ref:f,"aria-invalid":e||void 0,readOnly:u,className:n({invalid:e,size:s,readOnly:u,className:[v,c].filter(Boolean).join(" ")}),...h});return r||i||a?/* @__PURE__ */l("div",{className:"relative",children:[r&&/* @__PURE__ */o("span",{className:`pointer-events-none absolute left-3 top-1/2 -translate-y-1/2 ${t}`,children:r}),N,a?/* @__PURE__ */o(p,{children:/* @__PURE__ */o(d,{action:a,size:g})}):i&&/* @__PURE__ */o("span",{className:"absolute right-3 top-1/2 -translate-y-1/2 text-gray-400",children:i})]}):N});export{u as END_ACTIONS_PAD,c as INPUT_END_ACTION_SIZE,d as InputEndActionButton,p as InputEndActionSlot,f as Input_default};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import{AccessibleTable as t}from"./chunk-HY6CBG4M.js";import{arcPath as e}from"./chunk-VFC6QUEN.js";import{useHighlight as o}from"./chunk-CNYAHYE6.js";import{ChartTooltip as n}from"./chunk-WDQI3FV6.js";import{CHART_INK as r,resolveSeriesColor as a}from"./chunk-TZFACUMR.js";import{useShellStrings as l,useShellLocale as i}from"./chunk-TJSJVC6P.js";import{formatPlain as s}from"./chunk-C3QOHMR6.js";import{useState as c}from"react";import{jsx as d,jsxs as m}from"react/jsx-runtime";function h(t,e,o,n){const r=(t,o)=>{const n=e[t]?.[o];return"number"==typeof n&&Number.isFinite(n)?n:0},a=t.map((e,o)=>t.reduce((t,e,n)=>t+r(o,n)+r(n,o),0)),l=Math.max(2,o),i=t.length>l,s=i?t.map((t,e)=>e).sort((t,e)=>a[e]-a[t]).slice(0,l-1).sort((t,e)=>t-e):t.map((t,e)=>e),c=new Map(s.map((t,e)=>[t,e])),d=i?s.length:-1,m=i?[...s.map(e=>t[e]),n]:[...t],h=m.map(()=>m.map(()=>0));let u=0;t.forEach((e,o)=>t.forEach((t,e)=>{const n=c.get(o)??d,a=c.get(e)??d;n!==d||a!==d?h[n][a]+=r(o,e):u+=r(o,e)}));const f=m.map((t,e)=>m.reduce((t,o,n)=>t+h[e][n]+h[n][e],0));return d>=0&&(f[d]+=u),{labels:m,matrix:h,totals:f,otherIndex:d,foldedCount:i?t.length-s.length:0}}function u({labels:u,matrix:f,size:p=340,maxNodes:x=8,padAngle:g=.04,arcWidth:b=12,formatValue:k,className:v,emptyLabel:M}){const $=l().charts,w=i(),N=k??(t=>s(t,w)),j=M??$.noFlows,[y,C]=c(null),{highlighted:F}=o(),E=h(u,f,x,$.other),{labels:I,matrix:z,otherIndex:A,foldedCount:Q}=E,V=(t,e)=>z[t]?.[e]??0,H=t=>t===A?r.muted:a(t),L=E.totals,O=I.map((t,e)=>e).sort((t,e)=>L[e]-L[t]),P=O.reduce((t,e)=>t+L[e],0);if(P<=0)/* @__PURE__ */return d("p",{className:`text-sm text-gray-500 ${v??""}`,children:j});const T=p/2,W=p/2,Y=p/2-44,B=Y-b,J=g*O.length,R=/* @__PURE__ */new Map;let S=-Math.PI/2;O.forEach((t,e)=>{const o=L[t]/P*(2*Math.PI-J);R.set(t,{start:S,end:S+o,slot:e}),S+=o+g});const U=/* @__PURE__ */new Map,D=[];for(const t of O)for(const e of O){const o=V(t,e);if(o<=0)continue;const n=R.get(t),r=o/Math.max(1,L[t])*(n.end-n.start),a=U.get(t)??0;U.set(t,a+r),D.push({from:t,to:e,value:o,a:n.start+a+r/2,b:R.get(e).start+(R.get(e).end-R.get(e).start)/2})}const G=(t,e)=>[T+e*Math.cos(t),W+e*Math.sin(t)],Z="arc"===y?.kind?y.index:void 0,q="ribbon"===y?.kind?D[y.index]:void 0;/* @__PURE__ */
|
|
2
|
+
return m("div",{className:`relative ${v??""}`,children:[
|
|
3
|
+
/* @__PURE__ */m("svg",{width:"100%",height:p,viewBox:`0 0 ${p} ${p}`,role:"img","aria-label":$.chord(O.length),onMouseLeave:()=>C(null),children:[D.map((t,e)=>{const[o,n]=G(t.a,B),[r,a]=G(t.b,B),l=H(t.from),i=((t,e)=>y?"ribbon"===y.kind?y.index===e:y.index===t.from||y.index===t.to:null!==F?I[t.from]===F||I[t.to]===F:null)(t,e);/* @__PURE__ */
|
|
4
|
+
return d("path",{d:`M${o},${n} Q${T},${W} ${r},${a}`,fill:"none",stroke:l,strokeWidth:Math.max(1,t.value/P*p*.9),strokeOpacity:null===i||i?.34:.07,strokeLinecap:"round",onMouseEnter:()=>C({kind:"ribbon",index:e})},`${I[t.from]}→${I[t.to]}`)}),O.map(t=>{const o=R.get(t),n=(o.start+o.end)/2,[a,l]=G(n,Y+16),i=(t=>y?"arc"===y.kind?y.index===t:D[y.index].from===t||D[y.index].to===t:null!==F?I[t]===F:null)(t);/* @__PURE__ */
|
|
5
|
+
return m("g",{onMouseEnter:()=>C({kind:"arc",index:t}),children:[
|
|
6
|
+
/* @__PURE__ */d("path",{d:e(T,W,B,Y,o.start,o.end),fill:H(t),fillOpacity:null===i||i?1:.45}),
|
|
7
|
+
/* @__PURE__ */d("text",{x:a,y:l+4,fontSize:11,fill:r.label,textAnchor:Math.cos(n)>.15?"start":Math.cos(n)<-.15?"end":"middle",children:I[t]})]},t)})]}),Q>0&&/* @__PURE__ */d("p",{className:"mt-1 text-xs text-ink-faint",children:$.chordFolded(Q)}),void 0!==Z&&/* @__PURE__ */d("div",{className:"pointer-events-none absolute top-2 left-2 z-10",children:/* @__PURE__ */d(n,{title:I[Z],rows:[{key:"total",label:$.totalFlow,color:H(Z),value:N(L[Z])}]})}),q&&/* @__PURE__ */d("div",{className:"pointer-events-none absolute top-2 left-2 z-10",children:/* @__PURE__ */d(n,{title:`${I[q.from]} → ${I[q.to]}`,rows:[{key:"value",label:$.flow,color:H(q.from),value:N(q.value)}]})}),
|
|
8
|
+
/* @__PURE__ */d(t,{caption:$.chord(O.length),head:[$.tableFrom,$.tableTo,$.value],rows:D.map(t=>[I[t.from],I[t.to],N(t.value)])})]})}export{u as ChordChart,h as foldChord};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import{navIcons as e}from"./chunk-4LXCCZDM.js";import{Icon as t}from"./chunk-
|
|
2
|
-
return o(t,{name:"folder",look:"solid",className:e})}function
|
|
3
|
-
return o("div",{className:"w-12 h-12 flex items-center justify-center "+(t?"rounded-lg bg-blue-400/30 ring-2 ring-blue-500":""),children:/* @__PURE__ */o(N,{className:"h-12 w-12 text-amber-500 drop-shadow-[0_2px_3px_rgba(0,0,0,0.3)]"})});if("page"===e){const e=
|
|
4
|
-
return o("div",{className:"w-12 h-12 flex items-center justify-center "+(t?"rounded-lg bg-blue-400/30 ring-2 ring-blue-500":""),children:/* @__PURE__ */o("span",{className:`h-11 w-11 rounded-xl bg-gradient-to-br ${i} flex items-center justify-center text-white border border-white/30 drop-shadow-[0_2px_3px_rgba(0,0,0,0.3)]`,children:e&&n(e)?r(e,{className:"h-7 w-7 text-white"}):
|
|
1
|
+
import{navIcons as e}from"./chunk-4LXCCZDM.js";import{Icon as t}from"./chunk-T3NLFOLW.js";import{isValidElement as n,cloneElement as r}from"react";import{jsx as o,jsxs as i}from"react/jsx-runtime";var a="react-os-shell:spreadsheet-preview-update",s=null,l=0;function d(e){const t=++l,n={token:t,data:e};return s=n,{update(e){s===n&&(n.data=e),"undefined"!=typeof window&&window.dispatchEvent(new CustomEvent(a,{detail:{token:t,data:e}}))}}}function c(){return s}function p(e){s===e&&(s=null)}var u=class extends Error{limit;used;attempted;constructor(e,t,n){super("Not enough space"),this.name="FilesQuotaError",this.limit=e,this.used=t,this.attempted=n}};function f(e,t){return e&&"/"!==e?e.replace(/\/$/,"")+"/"+t:"/"+t}async function h(e,t){const n=await e.json().catch(()=>({}));return new Error(n.error||`${t} failed (${e.status})`)}function w(e){const t=()=>(e??(("undefined"!=typeof window?window.__REACT_OS_SHELL_FILE_SERVER__:void 0)||"http://localhost:4000").replace(/\/$/,"")).replace(/\/$/,""),n=(e,n={})=>fetch(`${t()}${e}`,{...n,credentials:"include"}),r=e=>({method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)});return{async quota(){const e=await n("/api/quota");if(!e.ok)throw await h(e,"Quota");const t=await e.json();return{used:t.used,limit:t.limit}},async list(e){const t=e??"/",r=await n(`/api/files?path=${encodeURIComponent(t)}`);if(!r.ok)throw await h(r,"Listing");const o=await r.json(),i=o.path||t,a=i.split("/").filter(Boolean);return{folder:{id:"/"===i?null:i,name:a[a.length-1]??"",role:"owner",path:[{id:null,name:""},...a.map((e,t)=>({id:"/"+a.slice(0,t+1).join("/"),name:e}))]},entries:(o.entries||[]).map(e=>({id:f(i,e.name),name:e.name,kind:e.kind,size:e.size,modifiedAt:e.modifiedAt}))}},async upload(e,t){const r=new FormData;r.append("file",t);const o=await n(`/api/upload?path=${encodeURIComponent(e??"/")}`,{method:"POST",body:r});if(413===o.status){const e=await o.json().catch(()=>({}));throw new u(e.limit||0,e.used||0,e.attempted||t.size)}if(!o.ok)throw await h(o,"Upload")},async createFolder(e,t){const o=await n("/api/folder",r({path:f(e,t)}));if(!o.ok)throw await h(o,"Create folder")},async rename(e,t){const o=e.replace(/\/[^/]*$/,"")||"/",i=await n("/api/rename",r({from:e,to:f(o,t)}));if(!i.ok)throw await h(i,"Rename")},async remove(e){const t=await n(`/api/files?path=${encodeURIComponent(e)}`,{method:"DELETE"});if(!t.ok)throw await h(t,"Delete")},async read(e){const t=await n(`/api/file?path=${encodeURIComponent(e)}`);if(!t.ok)throw await h(t,"Download");return t.blob()},async trash(){const e=await n("/api/trash");if(!e.ok)throw await h(e,"Listing trash");return(await e.json()).entries||[]},async restore(e){const t=await n("/api/trash/restore",r({id:e}));if(!t.ok)throw await h(t,"Restore")},async purge(e){const t=await n(`/api/trash/${encodeURIComponent(e)}`,{method:"DELETE"});if(!t.ok)throw await h(t,"Delete")},async emptyTrash(){const e=await n("/api/trash",{method:"DELETE"});if(!e.ok)throw await h(e,"Empty trash")}}}var m=null;function y(e){m=e}function g(){return m??w()}function x(){return null!==m}var b=["from-blue-500 to-blue-700","from-indigo-500 to-purple-600","from-purple-500 to-pink-600","from-pink-500 to-rose-600","from-red-500 to-rose-600","from-orange-500 to-red-600","from-amber-500 to-orange-600","from-yellow-500 to-amber-500","from-lime-500 to-green-600","from-green-500 to-emerald-600","from-emerald-500 to-teal-600","from-teal-500 to-cyan-600","from-cyan-500 to-sky-600","from-sky-500 to-blue-600","from-violet-500 to-fuchsia-600"];function v(e){let t=0;for(let n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n);return b[Math.abs(t)%b.length]}var _={order:"text-blue-600",purchase_order:"text-purple-600",invoice:"text-green-600",client:"text-indigo-600",manufacturer:"text-orange-600",shipment:"text-teal-600",part_number:"text-gray-600",project:"text-pink-600",mould:"text-red-600",design:"text-cyan-600",brand:"text-amber-600",price_sheet:"text-emerald-600",folder:"text-yellow-600",page:"text-blue-500"},k={order:"SO",purchase_order:"PO",invoice:"INV",client:"CLI",manufacturer:"MFR",shipment:"DN",part_number:"PN",project:"PRJ",mould:"MLD",design:"DSN",brand:"BRD",price_sheet:"PS",vendor_invoice:"VI",vendor_payment:"VP",warranty_claim:"WC",qc_report:"QC",vendor_shipment:"GRN",bank_account:"BA",wheel_finish:"WF",weight_log:"WL",production_progress:"PP",vendor_price_sheet:"VPS",proposal:"PR",folder:"FLD"},E={pdf:"PDF",dxf:"DXF","3d":"STP",image:"IMG",csv:"CSV"},C={pdf:"text-red-600",dxf:"text-blue-600","3d":"text-purple-600",image:"text-emerald-600",csv:"text-green-600"};function N({className:e}){/* @__PURE__ */
|
|
2
|
+
return o(t,{name:"folder",look:"solid",className:e})}function T(t,n){return n&&e[n]||(t?e[t]:void 0)}var j=/* @__PURE__ */o("svg",{className:"h-7 w-7",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:/* @__PURE__ */o("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3.75 6A2.25 2.25 0 016 3.75h2.25A2.25 2.25 0 0110.5 6v2.25a2.25 2.25 0 01-2.25 2.25H6a2.25 2.25 0 01-2.25-2.25V6z"})});function L({entityType:e,isSelected:t,entityId:a,label:s,fileKind:l}){const d="preview-file"===e&&l,c=d?C[l]:null,p=d?E[l]:null;if("folder"===e)/* @__PURE__ */
|
|
3
|
+
return o("div",{className:"w-12 h-12 flex items-center justify-center "+(t?"rounded-lg bg-blue-400/30 ring-2 ring-blue-500":""),children:/* @__PURE__ */o(N,{className:"h-12 w-12 text-amber-500 drop-shadow-[0_2px_3px_rgba(0,0,0,0.3)]"})});if("page"===e){const e=T(a,s),i=v(a||s||"page");/* @__PURE__ */
|
|
4
|
+
return o("div",{className:"w-12 h-12 flex items-center justify-center "+(t?"rounded-lg bg-blue-400/30 ring-2 ring-blue-500":""),children:/* @__PURE__ */o("span",{className:`h-11 w-11 rounded-xl bg-gradient-to-br ${i} flex items-center justify-center text-white border border-white/30 drop-shadow-[0_2px_3px_rgba(0,0,0,0.3)]`,children:e&&n(e)?r(e,{className:"h-7 w-7 text-white"}):j})})}/* @__PURE__ */
|
|
5
5
|
return i("div",{className:"w-12 h-12 relative flex items-center justify-center "+(t?"rounded-lg bg-blue-400/30 ring-2 ring-blue-500":""),children:[
|
|
6
6
|
/* @__PURE__ */i("svg",{className:`w-10 h-12 drop-shadow-[0_2px_3px_rgba(0,0,0,0.3)] ${c??_[e]??"text-gray-500"}`,viewBox:"0 0 40 48",fill:"none",children:[
|
|
7
7
|
/* @__PURE__ */o("path",{d:"M4 0h22l10 10v34a4 4 0 01-4 4H4a4 4 0 01-4-4V4a4 4 0 014-4z",fill:"white",fillOpacity:"0.92"}),
|
|
8
8
|
/* @__PURE__ */o("path",{d:"M26 0l10 10H30a4 4 0 01-4-4V0z",fill:"currentColor",fillOpacity:"0.2"}),
|
|
9
9
|
/* @__PURE__ */o("path",{d:"M4 0h22l10 10v34a4 4 0 01-4 4H4a4 4 0 01-4-4V4a4 4 0 014-4z",stroke:"currentColor",strokeWidth:"1.5",strokeOpacity:"0.5"})]}),
|
|
10
|
-
/* @__PURE__ */o("span",{className:`absolute inset-0 flex items-center justify-center text-3xs font-bold pt-2 ${c??_[e]??"text-gray-600"}`,children:p??k[e]??e.slice(0,3).toUpperCase()})]})}function
|
|
11
|
-
return o(N,{className:"h-4 w-4 shrink-0 text-amber-500"});if("page"===e.entityType){const t=
|
|
10
|
+
/* @__PURE__ */o("span",{className:`absolute inset-0 flex items-center justify-center text-3xs font-bold pt-2 ${c??_[e]??"text-gray-600"}`,children:p??k[e]??e.slice(0,3).toUpperCase()})]})}function I({item:e}){if("folder"===e.entityType)/* @__PURE__ */
|
|
11
|
+
return o(N,{className:"h-4 w-4 shrink-0 text-amber-500"});if("page"===e.entityType){const t=T(e.entityId,e.label);/* @__PURE__ */
|
|
12
12
|
return o("span",{className:`h-4 w-4 rounded bg-gradient-to-br ${v(e.entityId||e.label||"page")} flex items-center justify-center text-white shrink-0`,children:t&&n(t)?r(t,{className:"h-3 w-3 text-white"}):/* @__PURE__ */o("span",{className:"h-1.5 w-1.5 rounded-[2px] border border-white/80"})})}const i=("preview-file"===e.entityType&&e.fileKind?C[e.fileKind]:_[e.entityType])??"text-gray-400";/* @__PURE__ */
|
|
13
|
-
return o(t,{name:"page",className:`h-4 w-4 shrink-0 ${i}`,strokeWidth:1.5})}function $(e){return"preview-file"===e.entityType&&e.fileKind?E[e.fileKind]:"page"===e.entityType?"App":"folder"===e.entityType?"Folder":k[e.entityType]??e.entityType.slice(0,3).toUpperCase()}var S=null,R=/* @__PURE__ */new Set;function D(e){S=e,R.forEach(e=>e())}function P(e){return R.add(e),()=>{R.delete(e)}}function F(){return S}var
|
|
13
|
+
return o(t,{name:"page",className:`h-4 w-4 shrink-0 ${i}`,strokeWidth:1.5})}function $(e){return"preview-file"===e.entityType&&e.fileKind?E[e.fileKind]:"page"===e.entityType?"App":"folder"===e.entityType?"Folder":k[e.entityType]??e.entityType.slice(0,3).toUpperCase()}var S=null,R=/* @__PURE__ */new Set;function D(e){S=e,R.forEach(e=>e())}function P(e){return R.add(e),()=>{R.delete(e)}}function F(){return S}var O="__REACT_OS_SHELL_FILES_VIEW__",V="react-os-shell:files-show-trash",A="react-os-shell:files-open-desktop-folder";function M(){"undefined"!=typeof window&&(window[O]="trash",window.dispatchEvent(new CustomEvent(V)))}function U(e){"undefined"!=typeof window&&(window[O]={view:"desktop-folder",folderId:e},window.dispatchEvent(new CustomEvent(A,{detail:{folderId:e}})))}function W(){if("undefined"==typeof window)return null;const e=window[O];return"trash"===e?"trash":e&&"object"==typeof e&&"desktop-folder"===e.view&&"string"==typeof e.folderId?e:null}function z(){const e=W();return"undefined"!=typeof window&&(window[O]=null),e}export{I as DesktopItemMiniIcon,A as FILES_OPEN_DESKTOP_FOLDER_EVENT,V as FILES_SHOW_TRASH_EVENT,L as FileIconTile,u as FilesQuotaError,N as FolderGlyph,a as SPREADSHEET_PREVIEW_UPDATE_EVENT,p as claimSpreadsheetPreviewStage,z as consumeFilesViewRequest,w as createFileServerStore,$ as desktopItemTypeLabel,F as getDesktopFoldersSnapshot,g as getFilesStore,x as hasHostFilesStore,W as peekFilesViewRequest,c as peekSpreadsheetPreviewStage,D as publishDesktopFolders,U as requestFilesDesktopFolderView,M as requestFilesTrashView,y as setFilesStore,d as setSpreadsheetPreview,P as subscribeDesktopFolders};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{TH_ONE_LINE as r}from"./chunk-
|
|
1
|
+
import{TH_ONE_LINE as r}from"./chunk-G67CJAQ2.js";import{jsxs as e,jsx as c}from"react/jsx-runtime";function n({caption:n,head:t,rows:i}){/* @__PURE__ */
|
|
2
2
|
return e("table",{className:"sr-only",children:[
|
|
3
3
|
/* @__PURE__ */c("caption",{children:n}),
|
|
4
4
|
/* @__PURE__ */c("thead",{children:/* @__PURE__ */c("tr",{children:t.map(e=>/* @__PURE__ */c("th",{className:r,scope:"col",children:e},e))})}),
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{EmptyValue as r}from"./chunk-HNQPF5QZ.js";import{toInstant as e,timeAgo as t}from"./chunk-GEYM4WN3.js";import{formatDateTime as o}from"./chunk-Y3JW2GW5.js";import{useShellLocale as c}from"./chunk-
|
|
1
|
+
import{EmptyValue as r}from"./chunk-HNQPF5QZ.js";import{toInstant as e,timeAgo as t}from"./chunk-GEYM4WN3.js";import{formatDateTime as o}from"./chunk-Y3JW2GW5.js";import{useShellLocale as c}from"./chunk-TJSJVC6P.js";import{jsx as i}from"react/jsx-runtime";function m({value:m,precise:n,locale:s,className:l}){const a=c(),p=e(m);if(!p)/* @__PURE__ */return i(r,{});const u="string"==typeof m?m:p.toISOString();/* @__PURE__ */
|
|
2
2
|
return i("time",{dateTime:u,title:o(u,{locale:s??a}),className:l,children:t(p,{precise:n,locale:s??a})})}export{m as TimeAgo};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import{MediaUploadField as e}from"./chunk-
|
|
1
|
+
import{MediaUploadField as e}from"./chunk-457SK2XV.js";import{BrandMark as r}from"./chunk-MI67DI3H.js";import{Button_default as a}from"./chunk-EVYD6UFQ.js";import{useShellStrings as t}from"./chunk-TJSJVC6P.js";import{useRef as i,useState as l,useEffect as s}from"react";import{jsxs as n,jsx as c}from"react/jsx-runtime";function d({committedUrl:d,committedHasAlpha:o=null,committedIsLight:m=null,fallbackUrl:g,fallbackHasAlpha:h=null,fallbackIsLight:u=null,subjectName:b,assetName:p,onSave:x,onRemove:f,accept:v="image/png,image/x-icon,image/vnd.microsoft.icon,.ico,image/svg+xml,image/jpeg,image/webp",acceptHint:y="PNG · ICO · SVG · JPG · WEBP",maxBytes:N=5242880,previews:w=[],disabled:k=!1}){const j=i(null),[L,U]=l(null),[R,C]=l(""),[F,H]=l(""),[I,S]=l(!1),[A,E]=l(!1),O=function(e){return e.trim().toLocaleLowerCase().split(/\s+/).at(-1)||"image"}(p),P=t().brandAsset,V=R||d||g||"",B=L?null:d?o:h,G=L?null:d?m:u;s(()=>()=>{j.current&&URL.revokeObjectURL(j.current)},[]);const J=()=>{j.current&&(URL.revokeObjectURL(j.current),j.current=null)};/* @__PURE__ */
|
|
2
2
|
return n("section",{"aria-label":P.region(p,b),className:"grid gap-4 lg:grid-cols-2",children:[
|
|
3
3
|
/* @__PURE__ */n("div",{className:"rounded-lg border border-gray-200 bg-white p-4",children:[
|
|
4
|
-
/* @__PURE__ */c(e,{value:
|
|
4
|
+
/* @__PURE__ */c(e,{value:V,onChange:()=>{},onFile:e=>{if(k)return;J();const r=URL.createObjectURL(e);j.current=r,U(e),C(r),H("")},label:p,hint:F||P.usedFor(b),error:F||void 0,accept:v,acceptHint:y,maxSizeBytes:N,fit:"contain",height:180,allowRemove:!1,busy:I||A,disabled:k}),
|
|
5
5
|
/* @__PURE__ */n("div",{className:"mt-3 flex flex-wrap gap-2",children:[
|
|
6
|
-
/* @__PURE__ */c(a,{onClick:async()=>{if(L&&!k&&!
|
|
6
|
+
/* @__PURE__ */c(a,{onClick:async()=>{if(L&&!k&&!I){S(!0),H("");try{await x(L),J(),U(null),C("")}catch(e){H(e instanceof Error?e.message:P.saveFailed(O,p))}finally{S(!1)}}},disabled:!L||k,loading:I,children:P.save(O,p)}),(L||d)&&/* @__PURE__ */c(a,{variant:"ghost-danger",onClick:async()=>{if(!k&&!A){if(L)return J(),U(null),C(""),void H("");if(d){E(!0),H("");try{await f()}catch(e){H(e instanceof Error?e.message:P.removeFailed(O,p))}finally{E(!1)}}}},disabled:k,loading:A,children:L?P.discard:P.remove(O,p)})]})]}),w.length>0&&/* @__PURE__ */n("div",{className:"rounded-lg border border-gray-200 bg-white p-4","aria-label":P.previews(p),children:[
|
|
7
7
|
/* @__PURE__ */c("h3",{className:"text-sm font-semibold text-gray-900",children:P.preview}),
|
|
8
|
-
/* @__PURE__ */c("div",{className:"mt-3 grid gap-3",children:w.map(e=>{const a=/* @__PURE__ */c(r,{src:
|
|
8
|
+
/* @__PURE__ */c("div",{className:"mt-3 grid gap-3",children:w.map(e=>{const a=/* @__PURE__ */c(r,{src:V,alt:P.alt(b,p),slot:e.slot,surface:e.surface,adaptive:!0,hasAlpha:B,isLight:G,size:"browser-tab"===e.kind?16:void 0});/* @__PURE__ */
|
|
9
9
|
return n("div",{"data-brand-preview":!0,className:"dark"===e.surface?"text-white":"text-gray-900",children:[
|
|
10
10
|
/* @__PURE__ */c("div",{className:"mb-2 text-xs font-medium text-gray-500",children:e.label}),"browser-tab"===e.kind?/* @__PURE__ */n("div",{className:"flex items-end gap-1 border-b border-gray-200",children:[
|
|
11
11
|
/* @__PURE__ */n("div",{className:"flex max-w-[220px] items-center gap-2 rounded-t-lg border border-b-0 border-gray-200 bg-white px-3 py-2",children:[a,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{Markdown as e}from"./chunk-
|
|
1
|
+
import{Markdown as e}from"./chunk-LS6VU6F7.js";import{PLACEHOLDER_INK as t}from"./chunk-AYZY3YNC.js";import{Icon as l}from"./chunk-T3NLFOLW.js";import{LoadingSpinner as r}from"./chunk-R2VKEMZH.js";import{useShellStrings as s}from"./chunk-TJSJVC6P.js";import{useState as a,useMemo as n}from"react";import{jsxs as i,jsx as o,Fragment as c}from"react/jsx-runtime";var d=({open:e})=>/* @__PURE__ */o(l,{name:"chevron-right",look:"mini",className:"h-3.5 w-3.5 shrink-0 transition-transform "+(e?"rotate-90":""),"aria-hidden":"true"});function h({docs:h,loading:m=!1,categoryOrder:p,canEdit:u=!1,onNew:g,onEdit:x,renderBody:f,emptyMessage:b}){const y=s(),[N,v]=a(""),[w,k]=a(null),[C,j]=a({}),L=N.trim().toLowerCase(),M=n(()=>{const e=/* @__PURE__ */new Map;for(const t of h){let l=e.get(t.category);l||(l={key:t.category,label:t.category_label||t.category,docs:[]},e.set(t.category,l)),l.docs.push(t)}if(!p?.length)return[...e.values()];const t=new Map(p.map((e,t)=>[e,t]));return[...e.values()].sort((e,l)=>(t.get(e.key)??1/0)-(t.get(l.key)??1/0))},[h,p]),_=e=>!L||e.title.toLowerCase().includes(L)||e.body.toLowerCase().includes(L)||e.category_label.toLowerCase().includes(L),A=n(()=>M.map(e=>({...e,docs:e.docs.filter(_)})).filter(e=>e.docs.length>0),[M,L]),E=n(()=>A.flatMap(e=>e.docs),[A]),V=(w?E.find(e=>e.slug===w):void 0)??E[0]??null,Y=e=>!!L||(C[e]??e===V?.category);/* @__PURE__ */
|
|
2
2
|
return i("div",{className:"flex h-full gap-4 px-4 py-3 min-h-0",children:[
|
|
3
3
|
/* @__PURE__ */i("aside",{className:"w-64 shrink-0 flex flex-col bg-white rounded-lg shadow overflow-hidden",children:[
|
|
4
4
|
/* @__PURE__ */i("div",{className:"flex items-center justify-between gap-2 px-3 py-2 border-b border-gray-200 bg-gray-50 shrink-0",children:[
|
|
@@ -6,16 +6,16 @@ return i("div",{className:"flex h-full gap-4 px-4 py-3 min-h-0",children:[
|
|
|
6
6
|
/* @__PURE__ */o("div",{className:"px-3 py-2 border-b border-line-subtle shrink-0",children:/* @__PURE__ */i("div",{className:"relative",children:[
|
|
7
7
|
/* @__PURE__ */o(l,{name:"search",look:"mini",className:`pointer-events-none absolute left-2.5 top-1/2 -translate-y-1/2 h-4 w-4 ${t}`,"aria-hidden":"true"}),
|
|
8
8
|
/* @__PURE__ */o("input",{type:"text",value:N,onChange:e=>v(e.target.value),placeholder:y.help.searchPlaceholder,className:"w-full rounded-md border border-line-strong bg-surface h-8 pl-8 pr-2 text-sm shadow-sm focus:border-blue-500 rosh-focus-ring focus-visible:ring-1 focus-visible:ring-[color:var(--rosh-focus-ring-accent)]"})]})}),
|
|
9
|
-
/* @__PURE__ */o("div",{className:"flex-1 overflow-y-auto py-1",children:m?/* @__PURE__ */o(r,{size:"sm",padding:"py-6",label:y.help.loading}):0===
|
|
9
|
+
/* @__PURE__ */o("div",{className:"flex-1 overflow-y-auto py-1",children:m?/* @__PURE__ */o(r,{size:"sm",padding:"py-6",label:y.help.loading}):0===A.length?/* @__PURE__ */o("p",{className:"px-3 py-6 text-center text-xs text-gray-500",children:L?y.help.noResults:b??y.help.empty}):A.map(e=>{const t=Y(e.key);/* @__PURE__ */
|
|
10
10
|
return i("div",{className:"py-0.5",children:[
|
|
11
|
-
/* @__PURE__ */i("button",{type:"button",onClick:()=>{return t=e.key,j(e=>({...e,[t]:!
|
|
11
|
+
/* @__PURE__ */i("button",{type:"button",onClick:()=>{return t=e.key,j(e=>({...e,[t]:!Y(t)}));var t},className:"w-full flex items-center gap-2 h-8 px-3 text-left text-3xs font-semibold uppercase tracking-wide text-ink-faintest hover:text-gray-600",children:[
|
|
12
12
|
/* @__PURE__ */o(d,{open:t}),
|
|
13
|
-
/* @__PURE__ */o("span",{className:"truncate",children:e.label})]}),t&&e.docs.map(e=>{const t=
|
|
13
|
+
/* @__PURE__ */o("span",{className:"truncate",children:e.label})]}),t&&e.docs.map(e=>{const t=V?.slug===e.slug;/* @__PURE__ */
|
|
14
14
|
return i("button",{type:"button",onClick:()=>k(e.slug),className:"w-full text-left pl-8 pr-3 min-h-(--row-height-menu) py-2 text-sm flex items-center gap-2 transition-colors "+(t?"bg-blue-50 text-blue-700 font-medium":"text-gray-700 hover:bg-gray-50"),children:[
|
|
15
15
|
/* @__PURE__ */o("span",{className:"truncate",children:e.title}),!1===e.is_published&&/* @__PURE__ */o("span",{className:"ml-auto shrink-0 text-2xs text-amber-600",children:y.help.draft})]},e.slug)})]},e.key)})})]}),
|
|
16
|
-
/* @__PURE__ */o("main",{className:"flex-1 min-w-0 bg-white rounded-lg shadow overflow-hidden flex flex-col",children:
|
|
16
|
+
/* @__PURE__ */o("main",{className:"flex-1 min-w-0 bg-white rounded-lg shadow overflow-hidden flex flex-col",children:V?/* @__PURE__ */i(c,{children:[
|
|
17
17
|
/* @__PURE__ */i("div",{className:"flex items-start justify-between gap-4 px-5 py-3 border-b border-gray-200 bg-gray-50 shrink-0",children:[
|
|
18
18
|
/* @__PURE__ */i("div",{className:"min-w-0",children:[
|
|
19
|
-
/* @__PURE__ */o("h1",{className:"text-lg font-semibold text-gray-900 truncate",children:
|
|
20
|
-
/* @__PURE__ */i("p",{className:"text-xs text-gray-500 mt-0.5",children:[
|
|
21
|
-
/* @__PURE__ */o("div",{className:"flex-1 overflow-auto px-5 py-4",children:f?f(
|
|
19
|
+
/* @__PURE__ */o("h1",{className:"text-lg font-semibold text-gray-900 truncate",children:V.title}),
|
|
20
|
+
/* @__PURE__ */i("p",{className:"text-xs text-gray-500 mt-0.5",children:[V.category_label,!1===V.is_published&&/* @__PURE__ */i("span",{className:"ml-2 text-amber-600",children:["· ",y.help.draft]})]})]}),u&&x&&/* @__PURE__ */o("button",{type:"button",onClick:()=>x(V),className:"shrink-0 text-sm text-blue-600 hover:underline",children:y.help.edit})]}),
|
|
21
|
+
/* @__PURE__ */o("div",{className:"flex-1 overflow-auto px-5 py-4",children:f?f(V):V.body?/* @__PURE__ */o(e,{children:V.body}):/* @__PURE__ */o("p",{className:"text-sm text-gray-500 italic",children:y.help.noBody})})]}):/* @__PURE__ */o("div",{className:"flex-1 flex items-center justify-center px-6 text-center",children:m?/* @__PURE__ */o(r,{size:"sm",padding:"",label:y.help.loading}):/* @__PURE__ */o("p",{className:"text-sm text-ink-faint",children:y.help.pickArticle})})})]})}export{h as HelpCenter};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{InputNumber_default as a}from"./chunk-
|
|
1
|
+
import{InputNumber_default as a}from"./chunk-4GTXRVDF.js";import{Icon as e}from"./chunk-T3NLFOLW.js";import{jsxs as r,jsx as i}from"react/jsx-runtime";var n="h-3.5 w-3.5",l={x:/* @__PURE__ */i(e,{name:"nudge-x","aria-hidden":"true",className:n}),y:/* @__PURE__ */i(e,{name:"nudge-y","aria-hidden":"true",className:n})};function s({label:e,value:n,onChange:s,words:m,placeholder:o,min:d=-200,max:c=200,step:t=1,readOnly:p}){const u=e=>/* @__PURE__ */i("div",{"data-axis":e,className:"min-w-0",children:/* @__PURE__ */i(a,{value:n[e],onChange:a=>s({...n,[e]:a}),min:d,max:c,step:t,precision:0,steppers:"compact",readOnly:p,placeholder:o[e],prefix:l[e],suffix:m.unit,"aria-label":m[e]})});/* @__PURE__ */
|
|
2
2
|
return r("div",{role:"group","aria-label":e,className:"grid min-w-0 grid-cols-2 gap-2",children:[u("x"),u("y")]})}export{s as PositionInput};
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import{useShellStrings as e}from"./chunk-
|
|
1
|
+
import{useShellStrings as e}from"./chunk-TJSJVC6P.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,y=o?s.filter(o):s,N=e=>n(u(e)),b=e=>n(h(e)),w=y.some(e=>null!=h(e)&&b(e)>0),v=e=>w?N(e):"actual"===m?h(e)??u(e)??0:u(e)??0,M=y.reduce((e,t)=>e+n(v(t)),0),$=y.filter(e=>g(e)).length,k=y.filter(e=>g(e)).reduce((e,t)=>e+n(v(t)),0),V=y.reduce((e,t)=>e+N(t),0),j=y.reduce((e,t)=>e+b(t),0),I=e=>i?.(e)??0,q=r??(e=>I(e)*N(e)),A=c??(e=>I(e)*b(e)),F=y.reduce((e,t)=>e+q(t),0),J=y.reduce((e,t)=>e+A(t),0),Q=w?Math.max(F,J):"actual"===m&&J||F,S=Q<=34.65?"20ft":"40ft",_="20ft"===S?33:67,B=Q>0?Math.max(1,Math.ceil(Q/_)):0,C=B*_,P=Q>0&&Q>=.95*C&&Q<=1.1*C;if(0===y.length)return null;const T=(e,t)=>_>0?Math.max(0,Math.min((e-t*_)/_*100,100)):0;/* @__PURE__ */
|
|
2
2
|
return t("div",{className:`mt-2 px-1 space-y-2 ${x??""}`.trim(),style:f,children:[
|
|
3
3
|
/* @__PURE__ */t("div",{className:"flex items-center justify-between text-xs text-gray-500",children:[
|
|
4
|
-
/* @__PURE__ */t("span",{children:[`${p.items(
|
|
5
|
-
/* @__PURE__ */a("span",{className:"w-1.5 h-1.5 rounded-full bg-green-500"}),p.added($,k)]})]}),
|
|
4
|
+
/* @__PURE__ */t("span",{children:[`${p.items(y.length)} · ${p.pieces(M)}`,w&&V!==j&&/* @__PURE__ */a("span",{className:"ml-1 text-gray-400",children:p.split(V,j)})]}),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)]})]}),Q>0?/* @__PURE__ */t("div",{className:"space-y-2",children:[Array.from({length:B}).map((e,l)=>{const n=T(F,l),s=T(J,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
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:
|
|
7
|
+
/* @__PURE__ */a("span",{className:"text-2xs text-ink-faintest w-8 shrink-0",children:S}),
|
|
8
8
|
/* @__PURE__ */t("div",{className:"relative flex-1 h-4 bg-gray-100 rounded-full overflow-hidden border border-gray-200",children:[
|
|
9
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(
|
|
10
|
+
/* @__PURE__ */a("span",{className:"text-2xs text-ink-faint w-16 text-right",children:i?p.fill(Math.min(J-l*_,_),_):p.fill(Math.min(F-l*_,_),_)})]},`bar-${l}`)}),
|
|
11
11
|
/* @__PURE__ */t("div",{className:"flex items-center justify-between text-xs pt-0.5",children:[
|
|
12
12
|
/* @__PURE__ */t("span",{className:"text-gray-500 inline-flex items-center gap-1",children:[p.total,w?/* @__PURE__ */t(l,{children:[
|
|
13
13
|
/* @__PURE__ */t("span",{className:"inline-flex items-center gap-1 text-blue-700",children:[
|
|
14
14
|
/* @__PURE__ */a("span",{className:"inline-block w-2 h-2 rounded-full bg-blue-500"}),p.instructed(F)]}),
|
|
15
15
|
/* @__PURE__ */a("span",{className:"text-gray-400",children:"/"}),
|
|
16
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(
|
|
18
|
-
/* @__PURE__ */t("span",{className:"font-medium "+(
|
|
17
|
+
/* @__PURE__ */a("span",{className:"inline-block w-2 h-2 rounded-full bg-green-500"}),p.loaded(J)]})]}):/* @__PURE__ */a("b",{className:"text-gray-700",children:p.volume(Q)})]}),
|
|
18
|
+
/* @__PURE__ */t("span",{className:"font-medium "+(P?"text-green-600":"text-gray-500"),children:[P&&"✓ ",B," × ",S]})]})]}):/* @__PURE__ */a("div",{className:"text-xs text-gray-400",children:p.noVolume})]})}export{s as ContainerFillChart};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{CartesianPlot as t}from"./chunk-YRG6XJ6M.js";import{binValues as o}from"./chunk-2JWPNR2U.js";import{ChartTooltip as r}from"./chunk-WDQI3FV6.js";import{resolveSeriesColor as a}from"./chunk-TZFACUMR.js";import{useShellStrings as e,useShellLocale as i}from"./chunk-TJSJVC6P.js";import{formatPlain as m,formatFixed as n}from"./chunk-C3QOHMR6.js";import{jsx as l}from"react/jsx-runtime";function c({values:c,bins:s=10,precomputed:h,height:u=220,width:p,color:b,tone:f,formatBound:d,formatCount:x,yAxisLabel:g,label:k,className:y,emptyLabel:j}){const v=e().charts,w=i(),A=d??(t=>Number.isInteger(t)?m(t,w):n(t,1,w)),L=x??(t=>m(t,w)),M=g??v.countAxis,C=k??v.distribution,J=h??o(c??[],s),N=a(0,b,f),R=J.map(t=>A(t.from)),P=J.map(t=>t.count);/* @__PURE__ */
|
|
2
|
+
return l(t,{labels:R,values:P,height:u,width:p,bandPadding:0,xTickAnchor:"start",formatValue:L,yAxisLabel:M,className:y,emptyLabel:j,ariaLabel:v.histogram(C,J.length,(c??[]).length),tooltip:t=>/* @__PURE__ */l(r,{title:`${A(J[t].from)} – ${A(J[t].to)}`,rows:[{key:"count",label:v.observations,color:N,value:L(J[t].count)}]}),children:({x:t,y:o,bottom:r,active:a})=>/* @__PURE__ */l("g",{children:J.map((e,i)=>/* @__PURE__ */l("rect",{x:t(i)+.5,y:o(e.count),width:Math.max(1,t.bandwidth-1),height:Math.max(0,r-o(e.count)),fill:N,fillOpacity:null===a||a===i?.85:.42},i))})})}export{c as HistogramChart};
|