efficient-shell 12.23.0 → 12.24.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 +1 -1
- package/dist/{Browser-G3NJJDFN.js → Browser-I3RMT2LB.js} +15 -15
- package/dist/Calculator-LSDVIJVQ.js +29 -0
- package/dist/CurrencyConverter-G5IYUCN7.js +21 -0
- package/dist/{Files-A5MD7QNE.js → Files-WKTSGZLO.js} +141 -141
- package/dist/Notepad-GMDSZEAO.js +24 -0
- package/dist/PomodoroTimer-SFTPXEDV.js +91 -0
- package/dist/{Preview-DRNDT6WX.js → Preview-XYR5M6UU.js} +10 -10
- package/dist/{Stock-JY3PJI2M.js → Stock-YCPMLYPR.js} +3 -3
- package/dist/{Weather-POQXLYFA.js → Weather-TLFNIPDG.js} +13 -13
- package/dist/{WorldClock-FUJOPJ5G.js → WorldClock-66IRFS2W.js} +6 -6
- package/dist/ai/index.js +30 -30
- 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/charts/PieChart.js +1 -1
- package/dist/charts/RadarChart.js +1 -1
- package/dist/charts/RadialBarChart.js +1 -1
- package/dist/charts/SpecChart.js +1 -1
- package/dist/charts/TimeSeriesChart.js +1 -1
- package/dist/{chunk-F4XGUOVL.js → chunk-4BKJ6A5H.js} +4 -4
- package/dist/{chunk-ZNLCITYY.js → chunk-5MWXBDRG.js} +2 -2
- package/dist/{chunk-QJWQ6OMF.js → chunk-AQCUGTOR.js} +6 -6
- package/dist/{chunk-MFSDS6CN.js → chunk-BKPP47DR.js} +1 -1
- package/dist/{chunk-T2OSPUS6.js → chunk-BZHP645G.js} +3 -3
- package/dist/{chunk-OGWQABFP.js → chunk-CALBDO7B.js} +1 -1
- package/dist/chunk-EC3P3W7Z.js +28 -0
- package/dist/chunk-EIFNESXS.js +1 -0
- package/dist/{chunk-XQWHKXLS.js → chunk-F37II2EH.js} +13 -13
- package/dist/{chunk-ZLKEPDJE.js → chunk-H6WXTJOT.js} +1 -1
- package/dist/{chunk-DG2TGWXI.js → chunk-JUFCEWE3.js} +5 -5
- package/dist/chunk-KZRZYLN7.js +99 -0
- package/dist/chunk-N56HV4IH.js +1 -0
- package/dist/{chunk-2NZ7CVMW.js → chunk-OALFCXD6.js} +1 -1
- package/dist/{chunk-VP2GI3UP.js → chunk-OHSRZLRD.js} +2 -2
- package/dist/{chunk-FVKXDF2Q.js → chunk-RB7IU7ZK.js} +5 -5
- package/dist/{chunk-WLX24TG6.js → chunk-TUPPFC74.js} +4 -4
- package/dist/{chunk-EEB5XPWP.js → chunk-VXDW6ZPG.js} +2 -2
- package/dist/format/index.js +1 -1
- package/dist/forms/BrandAssetEditor.js +1 -1
- package/dist/forms/LinkPicker.js +1 -1
- package/dist/forms/MediaLibrary.d.ts +4 -3
- package/dist/forms/MediaLibrary.js +1 -1
- package/dist/forms/MediaUploadField.js +1 -1
- package/dist/icons/index.js +1 -1
- package/dist/index.js +120 -120
- package/dist/shell/Dialog.d.ts +5 -0
- package/dist/shell/LanguageSelect.js +1 -1
- package/dist/shell/SettingRow.js +1 -1
- package/dist/telemetry/index.js +1 -1
- package/dist/templates/DashboardTemplate.js +1 -1
- package/dist/ui/index.js +1 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
- package/dist/Calculator-OUPD7SZV.js +0 -29
- package/dist/CurrencyConverter-CNGYEKE3.js +0 -21
- package/dist/Notepad-CUWBPETD.js +0 -24
- package/dist/PomodoroTimer-I53C5QYM.js +0 -91
- package/dist/chunk-EEGTFJUQ.js +0 -28
- package/dist/chunk-MDVABA4H.js +0 -1
- package/dist/chunk-XQNZJNEJ.js +0 -99
package/dist/shell/Dialog.d.ts
CHANGED
|
@@ -60,6 +60,11 @@ interface DialogProps {
|
|
|
60
60
|
* behind. Only for the editors' media popup while a file is dragged out of
|
|
61
61
|
* it onto the canvas (harness UI-20, UI-50); the host turns it off when the
|
|
62
62
|
* drag ends, and closes the dialog when the file was dropped.
|
|
63
|
+
*
|
|
64
|
+
* @deprecated No host uses it since the media popup became the Media
|
|
65
|
+
* Library window: a window that holds a `MediaLibrary` steps aside
|
|
66
|
+
* by itself while a file is dragged out of it (`Modal`, `windowDragAside`).
|
|
67
|
+
* Removed in the next major.
|
|
63
68
|
*/
|
|
64
69
|
aside?: boolean;
|
|
65
70
|
/**
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
export{LanguagePanel,LanguageSelect,languageSelectWidth}from"../chunk-4ZRGMK7Y.js";import"../chunk-7ZJRBFHA.js";import"../chunk-HNBMBC77.js";import"../chunk-
|
|
2
|
+
export{LanguagePanel,LanguageSelect,languageSelectWidth}from"../chunk-4ZRGMK7Y.js";import"../chunk-7ZJRBFHA.js";import"../chunk-HNBMBC77.js";import"../chunk-64ACCUNN.js";import"../chunk-32VV2J22.js";import"../chunk-NI5FXWK5.js";import"../chunk-TM4CRQ3W.js";import"../chunk-EO5RLFRX.js";import"../chunk-GLRRX4AL.js";import"../chunk-VQCKMT5F.js";import"../chunk-2NMW66P5.js";import"../chunk-6KBDNYRW.js";import"../chunk-CGZBDI6C.js";import"../chunk-AYZY3YNC.js";import"../chunk-UGTRSRIW.js";import"../chunk-URHGHXDN.js";import"../chunk-XZXFUZIK.js";import"../chunk-J75ZT2JQ.js";import"../chunk-PGN5ME7B.js";import"../chunk-62LW225J.js";import"../chunk-GLUJS42B.js";import"../chunk-D65T4H6J.js";import"../chunk-TWVUQUUD.js";import"../chunk-5FYDNH4Y.js";import"../chunk-LNXBTK7Q.js";import"../chunk-JSHMIMAJ.js";import"../chunk-C3QOHMR6.js";
|
package/dist/shell/SettingRow.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
export{SettingRow as default}from"../chunk-
|
|
2
|
+
export{SettingRow as default}from"../chunk-4BKJ6A5H.js";import"../chunk-OM6VWUAZ.js";import"../chunk-2NMW66P5.js";import"../chunk-HCP7WOAL.js";import"../chunk-JSHMIMAJ.js";import"../chunk-C3QOHMR6.js";
|
package/dist/telemetry/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{startClientTelemetry}from"../chunk-
|
|
1
|
+
export{startClientTelemetry}from"../chunk-BKPP47DR.js";import"../chunk-KNUR2UEG.js";import"../chunk-N56HV4IH.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{DashboardTemplate as default}from"../chunk-
|
|
1
|
+
export{DashboardTemplate as default}from"../chunk-OALFCXD6.js";import"../chunk-WESNFWM4.js";import"../chunk-CEIIQRK5.js";import"../chunk-CKCDGSTC.js";import"../chunk-OHSRZLRD.js";import"../chunk-GC4N4UQM.js";import"../chunk-465RRWBY.js";import"../chunk-WXZZGHET.js";import"../chunk-VFC6QUEN.js";import"../chunk-CNYAHYE6.js";import"../chunk-JMGDGNM7.js";import"../chunk-EVYD6UFQ.js";import"../chunk-M5K4AX4E.js";import"../chunk-R2VKEMZH.js";import"../chunk-G67CJAQ2.js";import"../chunk-SOZCWT6I.js";import"../chunk-PGN5ME7B.js";import"../chunk-62LW225J.js";import"../chunk-GLUJS42B.js";import"../chunk-D65T4H6J.js";import"../chunk-UQYNPYF4.js";import"../chunk-MRJKZWWV.js";import"../chunk-ENFXDIIZ.js";import"../chunk-2DYVVHZA.js";import"../chunk-MAFUXCPZ.js";import"../chunk-2JWPNR2U.js";import"../chunk-WDQI3FV6.js";import"../chunk-TZFACUMR.js";import"../chunk-TWVUQUUD.js";import"../chunk-5FYDNH4Y.js";import"../chunk-LNXBTK7Q.js";import"../chunk-JSHMIMAJ.js";import"../chunk-C3QOHMR6.js";
|
package/dist/ui/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import"../chunk-GMHMWDXU.js";export{ACCENT_ROLES,COLOUR_ROLES,FLAT_STATUS_ROLES,IDENTITY_ROLES,NEUTRAL_ROLES,SCRIM_ROLES,STATUS_GROUPS,STATUS_ROLES}from"../chunk-VVJIKS47.js";export{ELEVATION_LEVELS,RADIUS_ROLES}from"../chunk-4MVRSCQE.js";export{BORDER_WIDTHS,FONT_WEIGHTS,MOTION_DURATIONS,TYPE_SCALE}from"../chunk-LH7IKIGE.js";export{DashboardTemplate}from"../chunk-2NZ7CVMW.js";export{DataTablePage}from"../chunk-34EBBZFK.js";export{EmailTemplate}from"../chunk-HOEHV2J5.js";export{ErrorBoundary}from"../chunk-VFHKD7TQ.js";export{ErrorPage}from"../chunk-75H4BWNC.js";export{FormLayoutPage}from"../chunk-YRY64DQV.js";export{GalleryTemplate}from"../chunk-4PIQG2ZK.js";export{useTransferProgress}from"../chunk-QHOEMRR7.js";export{AuthScreen}from"../chunk-L543DFHF.js";export{ChatTemplate}from"../chunk-RKXCB5ZJ.js";export{CheckoutTemplate}from"../chunk-JN5NUZ6D.js";export{TopNav}from"../chunk-ILDPJ26Y.js";export{Statistic}from"../chunk-Z66QBDNU.js";export{Stepper}from"../chunk-SY66VJAI.js";export{Tabs,tabButtonId,tabPanelId}from"../chunk-I5EVMLPB.js";export{Paragraph,Text,Title}from"../chunk-5KUE6IHF.js";export{TimeAgo}from"../chunk-ZGWXSHVM.js";export{SidebarActionButton}from"../chunk-KMTCYDJH.js";export{SidebarLayout}from"../chunk-JGRDG7CB.js";export{SidebarGroupLabel,SidebarNavGroup,SidebarNavItem,SidebarSection}from"../chunk-B4GRHE44.js";import"../chunk-QWK6DRSN.js";export{Skeleton}from"../chunk-4Z62SEA5.js";export{ListRow,SortableList}from"../chunk-6GWYFUME.js";export{Grid,Inline,Stack}from"../chunk-3RPER7VH.js";export{POST_PRODUCTION_STATUSES,ProductionTimeline,STAGES,calcOverall,calcReportOverall,useProductionTimeline}from"../chunk-4ZLFAXOC.js";export{ResizeHandle}from"../chunk-OOWPLQD5.js";export{SettingReset}from"../chunk-I7JU4IU3.js";export{SettingRow}from"../chunk-F4XGUOVL.js";export{LanguagePanel,LanguageSelect,languageSelectWidth}from"../chunk-4ZRGMK7Y.js";export{MetricBar}from"../chunk-7K3FYCRZ.js";export{isSeverityTone,severityOf}from"../chunk-TZFNWAED.js";export{MetricBarLegend}from"../chunk-YO26RV3H.js";import"../chunk-URBCGEXG.js";export{MilestoneTimeline}from"../chunk-BHHFVIAD.js";import"../chunk-S4Z657L6.js";export{TimelineTrack}from"../chunk-CMJD5URC.js";export{DAY_MS,fmtSliderDate,toDayMs}from"../chunk-7TC3LJQM.js";export{PageHeader}from"../chunk-RY7JCGLI.js";export{EmptyValue}from"../chunk-HNQPF5QZ.js";export{FloatingBar}from"../chunk-7KWYVQMX.js";export{GlobalSearch,openGlobalSearch}from"../chunk-N2445WHJ.js";export{pushRecent as pushRecentSearch,sanitizeRecent as sanitizeRecentSearches}from"../chunk-HGOWQO63.js";export{HelpCenter}from"../chunk-SSNTJ3M4.js";export{IconRail,IconRailButton}from"../chunk-CBVKGAZH.js";import"../chunk-FQEALPZJ.js";export{CountBadge}from"../chunk-OM6VWUAZ.js";export{EditableGrid}from"../chunk-SE6IQZYW.js";export{Avatar,AvatarGroup}from"../chunk-WESNFWM4.js";export{BudgetBar,budgetState}from"../chunk-4LOHQ4QB.js";export{Card,StatCard}from"../chunk-CEIIQRK5.js";export{ContainerFillChart}from"../chunk-SR4W2SYQ.js";export{ENGLISH,SHELL_LANGUAGE_STORAGE_KEY,ShellLanguageProvider,matchShellLanguage,readSavedShellLanguage,resolveShellLanguage,saveShellLanguage,useShellLanguage}from"../chunk-7ZJRBFHA.js";export{Accordion,AccordionBody,AccordionHeading}from"../chunk-W2663E4S.js";export{APP_UPDATE_POLL_MS,AppUpdateBanner,useAppUpdate}from"../chunk-3J3FBYIZ.js";export{CORNERS,CORNERS_FOR_THEME,applyCorners,applyIconSet,applyThemePrefs,cornersFor,resolveCorners,resolveTheme,useTheme}from"../chunk-CUZQVBPC.js";export{BRAND_ICON_NAMES,ICON_NAMES,isBrandIconName,isIconName}from"../chunk-HNBMBC77.js";export{ICON_SET_FOR_THEME,THEME_ICON_SETS,iconSetFor,loadIconSet}from"../chunk-VQCKMT5F.js";export{BRAND_MAX_HEIGHT,BRAND_MIN_HEIGHT_PX,brandBox}from"../chunk-64ACCUNN.js";export{useDebouncedValue}from"../chunk-SLGT5WPJ.js";export{useRootIsDark}from"../chunk-UPXDDO3U.js";export{TileButton_default as TileButton}from"../chunk-H2R4SNNO.js";export{TimePicker_default as TimePicker}from"../chunk-VBLCYL4L.js";export{WidthsBar}from"../chunk-XHZVUO6F.js";export{COLUMN_COUNT_MAX,COLUMN_COUNT_WIDTHS,COLUMN_SHARES_EQUAL,COLUMN_SHARE_MIN,columnSharesWidths,resolveColumnShares,resolveColumnWidths}from"../chunk-PLGJOHEG.js";export{SidesEachToggle,SidesInput,sidesStartEach}from"../chunk-OM42AUMS.js";export{Slider,SliderGroup}from"../chunk-63TCQAGE.js";export{Snippet}from"../chunk-QPSJYSET.js";export{SplitButton_default as SplitButton}from"../chunk-LCEQIFPK.js";export{Switch_default as Switch}from"../chunk-M3R4C3A6.js";export{TagInput}from"../chunk-YIUWX2IU.js";export{TextToolbar,textToolbarRows,textToolbarWindowColumns}from"../chunk-OQ6TECLX.js";export{TEXT_ALIGNS,TEXT_ALIGN_FIT,TEXT_ALIGN_ICONS,textAlignFit,textAlignOptions,textAlignWords}from"../chunk-Y523KUQC.js";export{Textarea_default as Textarea}from"../chunk-PB7G6CJ7.js";export{PictureTiles}from"../chunk-GCTJIZTJ.js";export{PositionInput}from"../chunk-G2Y5I5OR.js";export{RadioGroup}from"../chunk-32VV2J22.js";export{Radio_default as Radio}from"../chunk-NI5FXWK5.js";export{ShowWhen}from"../chunk-YEM4KYCW.js";export{LinkPicker,TextLinkField}from"../chunk-WLX24TG6.js";export{SearchableSelect}from"../chunk-ZQ24H5UO.js";export{Label,labelClasses}from"../chunk-EQKUFYX6.js";export{MEDIA_FILES_DRAG_TYPE,MEDIA_FILE_DRAG_TYPE,MEDIA_FOLDER_DRAG_TYPE,MediaLibrary,readMediaFileDrag}from"../chunk-EEGTFJUQ.js";export{Tree,TreeEmptySlot,TreeGroup,TreeGroupLabel,TreeRow,TreeSeam}from"../chunk-OLCRYT3N.js";import"../chunk-RF3ZFTAU.js";export{MarqueeBox}from"../chunk-IC72MGON.js";export{EmptyState}from"../chunk-T2TZBTSM.js";export{ImageLightbox,lightboxKind}from"../chunk-436PJFHC.js";export{LIGHTBOX_PICTURE_FIT,ZoomableImage}from"../chunk-CGUMJZUB.js";export{DescriptionList}from"../chunk-SACUSHVN.js";export{Drawer}from"../chunk-UP4HLGMZ.js";export{Breadcrumbs}from"../chunk-QMSINDXL.js";export{useGridSelection}from"../chunk-VLKDWKVR.js";export{MARQUEE_IGNORE,marqueeHits,rectsIntersect,useMarquee}from"../chunk-OLFYNMTD.js";export{edgeScrollDelta,getScrollParent,scrollBoundsOf}from"../chunk-LACL4MAR.js";export{mediaLibraryMenu}from"../chunk-VQ4X3OBR.js";export{mediaMoveItems,mediaMoveSubmenu,useMediaMoveItems}from"../chunk-NOGSS432.js";export{RenameField}from"../chunk-GEZM6ARD.js";export{NativeSelect,Select_default as Select}from"../chunk-TM4CRQ3W.js";import"../chunk-EO5RLFRX.js";import"../chunk-GLRRX4AL.js";export{FULL_BADGE_TILE_PX,MediaUploadGrid}from"../chunk-OG53D3R5.js";export{MediaUsedInList}from"../chunk-FQ4IRBMA.js";export{NumericKeypad}from"../chunk-TYQ2JL4J.js";export{MAX_FRACTION_DIGITS,appendKey,backspace}from"../chunk-VEPVOHCV.js";export{DisplayChips}from"../chunk-3JL4TCA7.js";export{FilePicker_default as FilePicker}from"../chunk-KBI3T6UC.js";export{FormErrorSummary}from"../chunk-QADNVFV5.js";export{CornersInput}from"../chunk-WBGJ4XB7.js";export{DatePicker_default as DatePicker}from"../chunk-N32LNPPP.js";export{DateRangePicker,toISODate}from"../chunk-BM2QIV64.js";export{Calendar}from"../chunk-CCK2UWQ5.js";export{DateTimePicker_default as DateTimePicker}from"../chunk-VEQ45GAH.js";export{slugify}from"../chunk-24AL3CDS.js";export{ENTRANCE_ATTR,ENTRANCE_FROM,ENTRANCE_FROM_ATTR,ENTRANCE_FROM_DEFAULT,ENTRANCE_KINDS,ENTRANCE_KINDS_WITH_FROM,ENTRANCE_STATE_ATTR,armEntrance,entranceAttrs,playEntrance,readEntrance}from"../chunk-ZSEB7XW4.js";export{HOVER_MOTION,MOTION_EASING,MOTION_GROUPS,MOTION_TIMING,motionSeconds,rotateDegrees}from"../chunk-AIJ3G6BD.js";export{hexWithAlpha,mixHex,rgbToHex}from"../chunk-CJSZW3OS.js";export{addShowWhenFacts,isShown,lazyShowWhenContext,showWhenFactReaders,showWhenFactsContext,showWhenOf,shownForOption,truthy,withRowRules,withRowsShownWhen,withShowWhen,withShowWhenFacts}from"../chunk-HCP7WOAL.js";export{fromDateKey,toDateKey}from"../chunk-2HMNOLKX.js";export{AlignmentGrid}from"../chunk-3DWVSQIJ.js";export{BorderInput,borderSides,borderStartEach}from"../chunk-YW3UKSON.js";export{IconPicker}from"../chunk-X34ZBXIU.js";export{ColorPicker,ColorPickerPanel,ColorSwatch,HexInput,colorFill,colorSwatchClasses}from"../chunk-MEN4B6NP.js";export{Popover}from"../chunk-64RHGJXK.js";export{InputNumber_default as InputNumber}from"../chunk-LBKKKZ4M.js";export{UnitMenu}from"../chunk-TOVEZAIM.js";export{useSettingAuto,useSettingRowName}from"../chunk-2NMW66P5.js";export{BORDER_LINE_STYLES}from"../chunk-NOMWJTN2.js";export{contrastRatio,hexToHsv,hexToRgb,hsvToHex,parseHexColor,readableInk,relativeLuminance}from"../chunk-S6OB6HJB.js";export{BrandAssetEditor}from"../chunk-QJWQ6OMF.js";export{MediaUploadField}from"../chunk-T2OSPUS6.js";export{Segmented}from"../chunk-HNIIDDLJ.js";import"../chunk-EFKJLUYP.js";export{FormField}from"../chunk-6KBDNYRW.js";export{ImageFocusPoint}from"../chunk-232YPI2L.js";export{FOCAL_DEFAULT,FOCAL_NUDGE_COARSE,FOCAL_NUDGE_STEP,focalFromRect,formatFocal,nudgeFocal,parseFocal}from"../chunk-25RR3GQW.js";export{BrandMark,resolveBrandMarkTreatment}from"../chunk-MI67DI3H.js";export{Kanban}from"../chunk-JFGJJNT2.js";export{useSort}from"../chunk-E6FDUFPH.js";export{PortalBrandingProvider,resolvePortalBrandAsset,usePortalBranding}from"../chunk-ACYYVK6G.js";export{DataTable}from"../chunk-XKNKRKHH.js";export{Pagination}from"../chunk-WPG3ZHYT.js";export{EntityList}from"../chunk-KP2JYXEU.js";import"../chunk-Y7KDCC6E.js";export{useTableNav}from"../chunk-ATMJ5ZPK.js";export{escapeHtml}from"../chunk-G6DKCCWH.js";export{ListFooter}from"../chunk-XHSMDUEW.js";export{ListLoadError}from"../chunk-YI6SYUAK.js";export{ResizableTable}from"../chunk-3E3LR2PM.js";export{useClickOutside}from"../chunk-SI26KESU.js";export{useColumnConfig}from"../chunk-UKBXQXDZ.js";import"../chunk-ULJQYXHB.js";export{Checkbox_default as Checkbox}from"../chunk-CGZBDI6C.js";export{TreemapChart}from"../chunk-A4PFVMQ2.js";export{squarify}from"../chunk-46BYGPGD.js";export{WaterfallChart}from"../chunk-DGHSCKOE.js";export{RangeChart}from"../chunk-4IHYWLWE.js";export{RankedBars}from"../chunk-RZ2DWX4N.js";export{SankeyChart}from"../chunk-WNOXHJVT.js";export{SCATTER_SERIES_CAP,ScatterChart}from"../chunk-4Y33Y4OX.js";export{StatTile}from"../chunk-GEVNBBM7.js";export{Sparkline}from"../chunk-CKCDGSTC.js";export{SunburstChart}from"../chunk-YX2OOGV7.js";export{FunnelChart}from"../chunk-FI6IJTAJ.js";export{HeatmapChart}from"../chunk-T7D73HT7.js";export{HistogramChart}from"../chunk-VDYF3WPJ.js";export{Meter}from"../chunk-LIWBCIRZ.js";export{PieChart}from"../chunk-VP2GI3UP.js";export{RADAR_SERIES_CAP,RadarChart}from"../chunk-DG2TGWXI.js";export{RadialBarChart}from"../chunk-FVKXDF2Q.js";export{ChordChart}from"../chunk-574SLTKO.js";import"../chunk-HY6CBG4M.js";export{StepChain,StepChainItem}from"../chunk-R62JKPYY.js";export{Markdown,Markdown as MarkdownLite,plainCell,tableToCsv}from"../chunk-LPPJNZQ6.js";export{Divider}from"../chunk-DFOFEBYX.js";import"../chunk-UJUTS6LJ.js";export{isSafeLinkHref}from"../chunk-Z5TE3MEG.js";export{ContextMenu,useContextMenu}from"../chunk-6FZ5JTBY.js";export{Banner}from"../chunk-N3R6N7LG.js";export{AttachButton,AttachmentDropZone,AttachmentList,ComposerAttachments,PaperclipGlyph}from"../chunk-Z3CTYK3U.js";export{Input_default as Input}from"../chunk-6RK6R3RY.js";export{DropdownMenu}from"../chunk-SFULX4E3.js";import"../chunk-FTMCNC66.js";export{IconButton_default as IconButton}from"../chunk-SV5RRBVA.js";export{INPUT_BASE,INPUT_SIZES,PLACEHOLDER_INK,inputClasses}from"../chunk-AYZY3YNC.js";export{mediaFileName}from"../chunk-VLMBXPRM.js";export{TransferProgress}from"../chunk-FJVZ2W55.js";export{FileIntakeAlert,acceptsFile,useFileIntake}from"../chunk-V4XR4MOS.js";export{CHART_SPEC_LIMITS,parseChartSpec}from"../chunk-CR7T435F.js";export{SpecChart}from"../chunk-EEB5XPWP.js";export{currencyDecimals,currencySymbol,formatBytes,formatMoney,setCurrencyFormats,timeAgo}from"../chunk-GEYM4WN3.js";export{DATE_FORMAT_OPTIONS,TZ_AUTO,firstDayOfWeek,formatDate,formatDateTime,formatTime,getUserDateFormat,getUserTimezone,setUserDateFormat,setUserTimezone,syncTimezoneFromProfile}from"../chunk-Y3JW2GW5.js";export{EMPTY_VALUE}from"../chunk-36BRD5J3.js";import"../chunk-LF27WIN2.js";export{TimeSeriesChart}from"../chunk-XQWHKXLS.js";export{DEFAULT_FLOW_CHART_LABELS,FlowChart}from"../chunk-DCCYUCBM.js";export{FLOW_LAYOUT,FLOW_SPEC_LIMITS,layoutFlow,parseFlowSpec}from"../chunk-FAERBT6Y.js";export{ChartBrush}from"../chunk-TU2L7NW3.js";export{ChartDot}from"../chunk-CK2YOGUS.js";export{ChartFrame}from"../chunk-RBS3AWE7.js";export{arcPath,areaBetween,areaFrom,bumpPath,curvePath,linearPath,monotonePath,polygonPoints,splinePath,stepPath}from"../chunk-VFC6QUEN.js";export{ColumnChart}from"../chunk-GC4N4UQM.js";export{ChartDefs,MOTION,dashFor,fillFor,fillId,glowId,groundId,maskId,stagger}from"../chunk-465RRWBY.js";export{ChartSkeleton}from"../chunk-WXZZGHET.js";export{ChartHighlightProvider,autoHighlightIndex,highlightOpacity,useHighlight}from"../chunk-CNYAHYE6.js";export{ImageAnnotator_default as ImageAnnotator}from"../chunk-74JMBOQH.js";export{CONTROL_HEIGHTS,ROW_HEIGHTS,SPACING_ROLES,SPACING_SCALE,isSpacingStep}from"../chunk-AW7TOB6N.js";import"../chunk-KNUR2UEG.js";export{NEXT_CHUNK_PATH_PREFIX,STALE_CHUNK_RELOAD_COOLDOWN_MS,STALE_CHUNK_RELOAD_KEY,VITE_PRELOAD_ERROR_EVENT,installStaleChunkReload,isStaleChunkError}from"../chunk-JDCM2VHG.js";export{Result}from"../chunk-DK5SXOXJ.js";export{ALT,ALT_SHIFT_D,ALT_SHIFT_E,ALT_SHIFT_N,CMD_A,CMD_DOT,CMD_ENTER,CMD_K,CMD_S,ENTER,Kbd,MOD,SHIFT,isMac}from"../chunk-ZDMZM7HD.js";import"../chunk-5A7MWTXX.js";export{ConfirmProvider,confirm,confirmDestructive,prompt,useConfirm}from"../chunk-HMT3MES3.js";export{Dialog}from"../chunk-D2WJAF62.js";export{ItemCount}from"../chunk-MWTCGJAI.js";import"../chunk-RIG5FEVS.js";import"../chunk-5WK56FA3.js";import"../chunk-VWGWZY7A.js";import"../chunk-7QSDPSXP.js";export{ColoredBadge}from"../chunk-CJHYOHMU.js";import"../chunk-JZBLOIL7.js";import"../chunk-F3ZOO23R.js";import"../chunk-2QY5BJLA.js";export{useIsMobile}from"../chunk-UGTRSRIW.js";export{ShellPrefsProvider,useLocalStoragePrefs,useShellPrefs}from"../chunk-KC3EX26K.js";export{VERSION}from"../chunk-MDVABA4H.js";export{useFocusTrap,useScrollLock}from"../chunk-DWGYC7OD.js";export{GROUP_COLORS,GROUP_COLORS_SOLID,StatusBadge,StatusBadgeProvider,groupColors,useStatusLabel}from"../chunk-JMGDGNM7.js";export{PopupMenu,PopupMenuDivider,PopupMenuItem,PopupMenuLabel,PopupSubmenu}from"../chunk-THLXDI76.js";import"../chunk-URHGHXDN.js";export{MENU_ON_MEDIA_ATTR,leavesContextMenuAlone}from"../chunk-5QFPTDQF.js";export{Button_default as Button}from"../chunk-EVYD6UFQ.js";import"../chunk-M5K4AX4E.js";export{Icon}from"../chunk-XZXFUZIK.js";export{activeIconSet,iconSets,iconsVersion,registerIconSet,registerIcons,resolveIcon,setDefaultIconSet,setIconSet,subscribeIcons}from"../chunk-J75ZT2JQ.js";export{LoadingSpinner,SpinnerRing}from"../chunk-R2VKEMZH.js";import"../chunk-G67CJAQ2.js";export{Tooltip}from"../chunk-SOZCWT6I.js";export{OVERLAY_OPEN_EVENT,dismissPopups}from"../chunk-PGN5ME7B.js";export{Z_LAYERS}from"../chunk-62LW225J.js";export{MENU_MAX_HEIGHT,POPUP_MAX_WIDTH,placeMenu,popupBounds,useDropdownPosition}from"../chunk-GLUJS42B.js";import"../chunk-D65T4H6J.js";export{setShellApiClient}from"../chunk-STKJA4PV.js";export{UNDOABLE_MS,toast_default as toast}from"../chunk-3YBXA72C.js";export{buttonClasses,iconButtonClasses}from"../chunk-UQYNPYF4.js";import"../chunk-MRJKZWWV.js";export{BoxPlotChart}from"../chunk-KAKJ7ENS.js";export{CandlestickChart}from"../chunk-GUHCKMC7.js";export{CartesianPlot}from"../chunk-ENFXDIIZ.js";import"../chunk-2DYVVHZA.js";export{usePlotWidth}from"../chunk-MAFUXCPZ.js";export{angleScale,bandScale,binValues,ladderScale,linearScale,logScale,niceAxis,niceMax,radiusScale}from"../chunk-2JWPNR2U.js";export{ChartTooltip}from"../chunk-WDQI3FV6.js";export{CHART_INK,SERIES_SLOT_COUNT,SERIES_VARS,STATUS_VARS,assignSeriesSlots,resolveSeriesColor,resolveSeriesColorWithin,seriesColor,toggleSeriesSlot}from"../chunk-TZFACUMR.js";export{registerModalEscapeInterceptor}from"../chunk-TWVUQUUD.js";export{GLASS_DIVIDER,glassStyle,solidSurfaceStyle}from"../chunk-5FYDNH4Y.js";import"../chunk-LNXBTK7Q.js";export{DEFAULT_SHELL_STRINGS,ShellStringsProvider,useShellLocale,useShellStrings}from"../chunk-JSHMIMAJ.js";import"../chunk-C3QOHMR6.js";
|
|
2
|
+
import"../chunk-GMHMWDXU.js";export{ACCENT_ROLES,COLOUR_ROLES,FLAT_STATUS_ROLES,IDENTITY_ROLES,NEUTRAL_ROLES,SCRIM_ROLES,STATUS_GROUPS,STATUS_ROLES}from"../chunk-VVJIKS47.js";export{ELEVATION_LEVELS,RADIUS_ROLES}from"../chunk-4MVRSCQE.js";export{BORDER_WIDTHS,FONT_WEIGHTS,MOTION_DURATIONS,TYPE_SCALE}from"../chunk-LH7IKIGE.js";export{DashboardTemplate}from"../chunk-OALFCXD6.js";export{DataTablePage}from"../chunk-34EBBZFK.js";export{EmailTemplate}from"../chunk-HOEHV2J5.js";export{ErrorBoundary}from"../chunk-VFHKD7TQ.js";export{ErrorPage}from"../chunk-75H4BWNC.js";export{FormLayoutPage}from"../chunk-YRY64DQV.js";export{GalleryTemplate}from"../chunk-4PIQG2ZK.js";export{useTransferProgress}from"../chunk-QHOEMRR7.js";export{AuthScreen}from"../chunk-L543DFHF.js";export{ChatTemplate}from"../chunk-RKXCB5ZJ.js";export{CheckoutTemplate}from"../chunk-JN5NUZ6D.js";export{TopNav}from"../chunk-ILDPJ26Y.js";export{Statistic}from"../chunk-Z66QBDNU.js";export{Stepper}from"../chunk-SY66VJAI.js";export{Tabs,tabButtonId,tabPanelId}from"../chunk-I5EVMLPB.js";export{Paragraph,Text,Title}from"../chunk-5KUE6IHF.js";export{TimeAgo}from"../chunk-ZGWXSHVM.js";export{SidebarActionButton}from"../chunk-KMTCYDJH.js";export{SidebarLayout}from"../chunk-JGRDG7CB.js";export{SidebarGroupLabel,SidebarNavGroup,SidebarNavItem,SidebarSection}from"../chunk-B4GRHE44.js";import"../chunk-QWK6DRSN.js";export{Skeleton}from"../chunk-4Z62SEA5.js";export{ListRow,SortableList}from"../chunk-6GWYFUME.js";export{Grid,Inline,Stack}from"../chunk-3RPER7VH.js";export{POST_PRODUCTION_STATUSES,ProductionTimeline,STAGES,calcOverall,calcReportOverall,useProductionTimeline}from"../chunk-4ZLFAXOC.js";export{ResizeHandle}from"../chunk-OOWPLQD5.js";export{SettingReset}from"../chunk-I7JU4IU3.js";export{SettingRow}from"../chunk-4BKJ6A5H.js";export{LanguagePanel,LanguageSelect,languageSelectWidth}from"../chunk-4ZRGMK7Y.js";export{MetricBar}from"../chunk-7K3FYCRZ.js";export{isSeverityTone,severityOf}from"../chunk-TZFNWAED.js";export{MetricBarLegend}from"../chunk-YO26RV3H.js";import"../chunk-URBCGEXG.js";export{MilestoneTimeline}from"../chunk-BHHFVIAD.js";import"../chunk-S4Z657L6.js";export{TimelineTrack}from"../chunk-CMJD5URC.js";export{DAY_MS,fmtSliderDate,toDayMs}from"../chunk-7TC3LJQM.js";export{PageHeader}from"../chunk-RY7JCGLI.js";export{EmptyValue}from"../chunk-HNQPF5QZ.js";export{FloatingBar}from"../chunk-7KWYVQMX.js";export{GlobalSearch,openGlobalSearch}from"../chunk-N2445WHJ.js";export{pushRecent as pushRecentSearch,sanitizeRecent as sanitizeRecentSearches}from"../chunk-HGOWQO63.js";export{HelpCenter}from"../chunk-SSNTJ3M4.js";export{IconRail,IconRailButton}from"../chunk-CBVKGAZH.js";import"../chunk-FQEALPZJ.js";export{CountBadge}from"../chunk-OM6VWUAZ.js";export{EditableGrid}from"../chunk-SE6IQZYW.js";export{Avatar,AvatarGroup}from"../chunk-WESNFWM4.js";export{BudgetBar,budgetState}from"../chunk-4LOHQ4QB.js";export{Card,StatCard}from"../chunk-CEIIQRK5.js";export{ContainerFillChart}from"../chunk-SR4W2SYQ.js";export{ENGLISH,SHELL_LANGUAGE_STORAGE_KEY,ShellLanguageProvider,matchShellLanguage,readSavedShellLanguage,resolveShellLanguage,saveShellLanguage,useShellLanguage}from"../chunk-7ZJRBFHA.js";export{Accordion,AccordionBody,AccordionHeading}from"../chunk-W2663E4S.js";export{APP_UPDATE_POLL_MS,AppUpdateBanner,useAppUpdate}from"../chunk-3J3FBYIZ.js";export{BRAND_ICON_NAMES,ICON_NAMES,isBrandIconName,isIconName}from"../chunk-HNBMBC77.js";export{BRAND_MAX_HEIGHT,BRAND_MIN_HEIGHT_PX,brandBox}from"../chunk-64ACCUNN.js";export{WidthsBar}from"../chunk-XHZVUO6F.js";export{COLUMN_COUNT_MAX,COLUMN_COUNT_WIDTHS,COLUMN_SHARES_EQUAL,COLUMN_SHARE_MIN,columnSharesWidths,resolveColumnShares,resolveColumnWidths}from"../chunk-PLGJOHEG.js";export{Snippet}from"../chunk-QPSJYSET.js";export{SplitButton_default as SplitButton}from"../chunk-LCEQIFPK.js";export{Switch_default as Switch}from"../chunk-M3R4C3A6.js";export{TagInput}from"../chunk-YIUWX2IU.js";export{TextToolbar,textToolbarRows,textToolbarWindowColumns}from"../chunk-OQ6TECLX.js";export{TEXT_ALIGNS,TEXT_ALIGN_FIT,TEXT_ALIGN_ICONS,textAlignFit,textAlignOptions,textAlignWords}from"../chunk-Y523KUQC.js";export{Textarea_default as Textarea}from"../chunk-PB7G6CJ7.js";export{TileButton_default as TileButton}from"../chunk-H2R4SNNO.js";export{TimePicker_default as TimePicker}from"../chunk-VBLCYL4L.js";export{RadioGroup}from"../chunk-32VV2J22.js";export{Radio_default as Radio}from"../chunk-NI5FXWK5.js";export{ShowWhen}from"../chunk-YEM4KYCW.js";export{SidesEachToggle,SidesInput,sidesStartEach}from"../chunk-OM42AUMS.js";export{Slider,SliderGroup}from"../chunk-63TCQAGE.js";export{LinkPicker,TextLinkField}from"../chunk-TUPPFC74.js";export{SearchableSelect}from"../chunk-ZQ24H5UO.js";export{MEDIA_FILES_DRAG_TYPE,MEDIA_FILE_DRAG_TYPE,MEDIA_FOLDER_DRAG_TYPE,MediaLibrary,readMediaFileDrag}from"../chunk-EC3P3W7Z.js";export{Tree,TreeEmptySlot,TreeGroup,TreeGroupLabel,TreeRow,TreeSeam}from"../chunk-OLCRYT3N.js";import"../chunk-RF3ZFTAU.js";export{MarqueeBox}from"../chunk-IC72MGON.js";export{EmptyState}from"../chunk-T2TZBTSM.js";export{ImageLightbox,lightboxKind}from"../chunk-436PJFHC.js";export{LIGHTBOX_PICTURE_FIT,ZoomableImage}from"../chunk-CGUMJZUB.js";export{DescriptionList}from"../chunk-SACUSHVN.js";export{Drawer}from"../chunk-UP4HLGMZ.js";export{Breadcrumbs}from"../chunk-QMSINDXL.js";export{mediaLibraryMenu}from"../chunk-VQ4X3OBR.js";export{mediaMoveItems,mediaMoveSubmenu,useMediaMoveItems}from"../chunk-NOGSS432.js";export{RenameField}from"../chunk-GEZM6ARD.js";export{NativeSelect,Select_default as Select}from"../chunk-TM4CRQ3W.js";import"../chunk-EO5RLFRX.js";import"../chunk-GLRRX4AL.js";export{FULL_BADGE_TILE_PX,MediaUploadGrid}from"../chunk-OG53D3R5.js";export{MediaUsedInList}from"../chunk-FQ4IRBMA.js";export{NumericKeypad}from"../chunk-TYQ2JL4J.js";export{MAX_FRACTION_DIGITS,appendKey,backspace}from"../chunk-VEPVOHCV.js";export{PictureTiles}from"../chunk-GCTJIZTJ.js";export{PositionInput}from"../chunk-G2Y5I5OR.js";export{FormErrorSummary}from"../chunk-QADNVFV5.js";export{Label,labelClasses}from"../chunk-EQKUFYX6.js";export{CornersInput}from"../chunk-WBGJ4XB7.js";export{DatePicker_default as DatePicker}from"../chunk-N32LNPPP.js";export{DateRangePicker,toISODate}from"../chunk-BM2QIV64.js";export{DateTimePicker_default as DateTimePicker}from"../chunk-VEQ45GAH.js";export{DisplayChips}from"../chunk-3JL4TCA7.js";export{FilePicker_default as FilePicker}from"../chunk-KBI3T6UC.js";export{CORNERS,CORNERS_FOR_THEME,applyCorners,applyIconSet,applyThemePrefs,cornersFor,resolveCorners,resolveTheme,useTheme}from"../chunk-CUZQVBPC.js";export{ICON_SET_FOR_THEME,THEME_ICON_SETS,iconSetFor,loadIconSet}from"../chunk-VQCKMT5F.js";export{AlignmentGrid}from"../chunk-3DWVSQIJ.js";export{BorderInput,borderSides,borderStartEach}from"../chunk-YW3UKSON.js";export{IconPicker}from"../chunk-X34ZBXIU.js";export{ColorPicker,ColorPickerPanel,ColorSwatch,HexInput,colorFill,colorSwatchClasses}from"../chunk-MEN4B6NP.js";export{Popover}from"../chunk-64RHGJXK.js";export{InputNumber_default as InputNumber}from"../chunk-LBKKKZ4M.js";export{UnitMenu}from"../chunk-TOVEZAIM.js";export{useSettingAuto,useSettingRowName}from"../chunk-2NMW66P5.js";export{BrandAssetEditor}from"../chunk-AQCUGTOR.js";export{MediaUploadField}from"../chunk-BZHP645G.js";export{Segmented}from"../chunk-HNIIDDLJ.js";import"../chunk-EFKJLUYP.js";export{ImageFocusPoint}from"../chunk-232YPI2L.js";export{FormField}from"../chunk-6KBDNYRW.js";export{BrandMark,resolveBrandMarkTreatment}from"../chunk-MI67DI3H.js";export{Calendar}from"../chunk-CCK2UWQ5.js";export{slugify}from"../chunk-24AL3CDS.js";export{ENTRANCE_ATTR,ENTRANCE_FROM,ENTRANCE_FROM_ATTR,ENTRANCE_FROM_DEFAULT,ENTRANCE_KINDS,ENTRANCE_KINDS_WITH_FROM,ENTRANCE_STATE_ATTR,armEntrance,entranceAttrs,playEntrance,readEntrance}from"../chunk-ZSEB7XW4.js";export{HOVER_MOTION,MOTION_EASING,MOTION_GROUPS,MOTION_TIMING,motionSeconds,rotateDegrees}from"../chunk-AIJ3G6BD.js";export{hexWithAlpha,mixHex,rgbToHex}from"../chunk-CJSZW3OS.js";export{addShowWhenFacts,isShown,lazyShowWhenContext,showWhenFactReaders,showWhenFactsContext,showWhenOf,shownForOption,truthy,withRowRules,withRowsShownWhen,withShowWhen,withShowWhenFacts}from"../chunk-HCP7WOAL.js";export{BORDER_LINE_STYLES}from"../chunk-NOMWJTN2.js";export{contrastRatio,hexToHsv,hexToRgb,hsvToHex,parseHexColor,readableInk,relativeLuminance}from"../chunk-S6OB6HJB.js";export{FOCAL_DEFAULT,FOCAL_NUDGE_COARSE,FOCAL_NUDGE_STEP,focalFromRect,formatFocal,nudgeFocal,parseFocal}from"../chunk-25RR3GQW.js";export{fromDateKey,toDateKey}from"../chunk-2HMNOLKX.js";export{useDebouncedValue}from"../chunk-SLGT5WPJ.js";export{useGridSelection}from"../chunk-VLKDWKVR.js";export{MARQUEE_IGNORE,marqueeHits,rectsIntersect,useMarquee}from"../chunk-OLFYNMTD.js";export{edgeScrollDelta,getScrollParent,scrollBoundsOf}from"../chunk-LACL4MAR.js";export{useRootIsDark}from"../chunk-UPXDDO3U.js";export{Kanban}from"../chunk-JFGJJNT2.js";export{useSort}from"../chunk-E6FDUFPH.js";export{DataTable}from"../chunk-XKNKRKHH.js";export{Pagination}from"../chunk-WPG3ZHYT.js";export{EntityList}from"../chunk-KP2JYXEU.js";import"../chunk-Y7KDCC6E.js";export{useTableNav}from"../chunk-ATMJ5ZPK.js";export{escapeHtml}from"../chunk-G6DKCCWH.js";export{ListFooter}from"../chunk-XHSMDUEW.js";export{ListLoadError}from"../chunk-YI6SYUAK.js";export{ResizableTable}from"../chunk-3E3LR2PM.js";export{useClickOutside}from"../chunk-SI26KESU.js";export{useColumnConfig}from"../chunk-UKBXQXDZ.js";import"../chunk-ULJQYXHB.js";export{Checkbox_default as Checkbox}from"../chunk-CGZBDI6C.js";export{SunburstChart}from"../chunk-YX2OOGV7.js";export{TreemapChart}from"../chunk-A4PFVMQ2.js";export{squarify}from"../chunk-46BYGPGD.js";export{WaterfallChart}from"../chunk-DGHSCKOE.js";export{RadialBarChart}from"../chunk-RB7IU7ZK.js";export{RangeChart}from"../chunk-4IHYWLWE.js";export{RankedBars}from"../chunk-RZ2DWX4N.js";export{SankeyChart}from"../chunk-WNOXHJVT.js";export{SCATTER_SERIES_CAP,ScatterChart}from"../chunk-4Y33Y4OX.js";export{StatTile}from"../chunk-GEVNBBM7.js";export{Sparkline}from"../chunk-CKCDGSTC.js";export{FunnelChart}from"../chunk-FI6IJTAJ.js";export{HeatmapChart}from"../chunk-T7D73HT7.js";export{HistogramChart}from"../chunk-VDYF3WPJ.js";export{Meter}from"../chunk-LIWBCIRZ.js";export{PieChart}from"../chunk-OHSRZLRD.js";export{RADAR_SERIES_CAP,RadarChart}from"../chunk-JUFCEWE3.js";export{CandlestickChart}from"../chunk-GUHCKMC7.js";export{ChordChart}from"../chunk-574SLTKO.js";import"../chunk-HY6CBG4M.js";export{StepChain,StepChainItem}from"../chunk-R62JKPYY.js";export{Markdown,Markdown as MarkdownLite,plainCell,tableToCsv}from"../chunk-LPPJNZQ6.js";export{Divider}from"../chunk-DFOFEBYX.js";import"../chunk-UJUTS6LJ.js";export{isSafeLinkHref}from"../chunk-Z5TE3MEG.js";export{ContextMenu,useContextMenu}from"../chunk-6FZ5JTBY.js";export{Banner}from"../chunk-N3R6N7LG.js";export{AttachButton,AttachmentDropZone,AttachmentList,ComposerAttachments,PaperclipGlyph}from"../chunk-Z3CTYK3U.js";export{Input_default as Input}from"../chunk-6RK6R3RY.js";export{DropdownMenu}from"../chunk-SFULX4E3.js";import"../chunk-FTMCNC66.js";export{IconButton_default as IconButton}from"../chunk-SV5RRBVA.js";export{INPUT_BASE,INPUT_SIZES,PLACEHOLDER_INK,inputClasses}from"../chunk-AYZY3YNC.js";export{mediaFileName}from"../chunk-VLMBXPRM.js";export{TransferProgress}from"../chunk-FJVZ2W55.js";export{FileIntakeAlert,acceptsFile,useFileIntake}from"../chunk-V4XR4MOS.js";export{CHART_SPEC_LIMITS,parseChartSpec}from"../chunk-CR7T435F.js";export{SpecChart}from"../chunk-VXDW6ZPG.js";export{currencyDecimals,currencySymbol,formatBytes,formatMoney,setCurrencyFormats,timeAgo}from"../chunk-GEYM4WN3.js";export{DATE_FORMAT_OPTIONS,TZ_AUTO,firstDayOfWeek,formatDate,formatDateTime,formatTime,getUserDateFormat,getUserTimezone,setUserDateFormat,setUserTimezone,syncTimezoneFromProfile}from"../chunk-Y3JW2GW5.js";export{EMPTY_VALUE}from"../chunk-36BRD5J3.js";import"../chunk-LF27WIN2.js";export{TimeSeriesChart}from"../chunk-F37II2EH.js";export{ColumnChart}from"../chunk-GC4N4UQM.js";export{DEFAULT_FLOW_CHART_LABELS,FlowChart}from"../chunk-DCCYUCBM.js";export{FLOW_LAYOUT,FLOW_SPEC_LIMITS,layoutFlow,parseFlowSpec}from"../chunk-FAERBT6Y.js";export{ChartDefs,MOTION,dashFor,fillFor,fillId,glowId,groundId,maskId,stagger}from"../chunk-465RRWBY.js";export{ChartBrush}from"../chunk-TU2L7NW3.js";export{ChartDot}from"../chunk-CK2YOGUS.js";export{ChartFrame}from"../chunk-RBS3AWE7.js";export{ChartSkeleton}from"../chunk-WXZZGHET.js";export{arcPath,areaBetween,areaFrom,bumpPath,curvePath,linearPath,monotonePath,polygonPoints,splinePath,stepPath}from"../chunk-VFC6QUEN.js";export{ChartHighlightProvider,autoHighlightIndex,highlightOpacity,useHighlight}from"../chunk-CNYAHYE6.js";export{ImageAnnotator_default as ImageAnnotator}from"../chunk-74JMBOQH.js";export{CONTROL_HEIGHTS,ROW_HEIGHTS,SPACING_ROLES,SPACING_SCALE,isSpacingStep}from"../chunk-AW7TOB6N.js";import"../chunk-KNUR2UEG.js";export{NEXT_CHUNK_PATH_PREFIX,STALE_CHUNK_RELOAD_COOLDOWN_MS,STALE_CHUNK_RELOAD_KEY,VITE_PRELOAD_ERROR_EVENT,installStaleChunkReload,isStaleChunkError}from"../chunk-JDCM2VHG.js";export{Result}from"../chunk-DK5SXOXJ.js";export{ALT,ALT_SHIFT_D,ALT_SHIFT_E,ALT_SHIFT_N,CMD_A,CMD_DOT,CMD_ENTER,CMD_K,CMD_S,ENTER,Kbd,MOD,SHIFT,isMac}from"../chunk-ZDMZM7HD.js";import"../chunk-5A7MWTXX.js";export{ConfirmProvider,confirm,confirmDestructive,prompt,useConfirm}from"../chunk-HMT3MES3.js";export{Dialog}from"../chunk-D2WJAF62.js";import"../chunk-EIFNESXS.js";export{ItemCount}from"../chunk-MWTCGJAI.js";import"../chunk-RIG5FEVS.js";import"../chunk-5WK56FA3.js";import"../chunk-VWGWZY7A.js";import"../chunk-7QSDPSXP.js";export{ColoredBadge}from"../chunk-CJHYOHMU.js";import"../chunk-JZBLOIL7.js";import"../chunk-F3ZOO23R.js";import"../chunk-2QY5BJLA.js";export{useIsMobile}from"../chunk-UGTRSRIW.js";export{ShellPrefsProvider,useLocalStoragePrefs,useShellPrefs}from"../chunk-KC3EX26K.js";export{VERSION}from"../chunk-N56HV4IH.js";export{useFocusTrap,useScrollLock}from"../chunk-DWGYC7OD.js";export{GROUP_COLORS,GROUP_COLORS_SOLID,StatusBadge,StatusBadgeProvider,groupColors,useStatusLabel}from"../chunk-JMGDGNM7.js";export{PopupMenu,PopupMenuDivider,PopupMenuItem,PopupMenuLabel,PopupSubmenu}from"../chunk-THLXDI76.js";import"../chunk-URHGHXDN.js";export{MENU_ON_MEDIA_ATTR,leavesContextMenuAlone}from"../chunk-5QFPTDQF.js";export{Button_default as Button}from"../chunk-EVYD6UFQ.js";import"../chunk-M5K4AX4E.js";export{Icon}from"../chunk-XZXFUZIK.js";export{activeIconSet,iconSets,iconsVersion,registerIconSet,registerIcons,resolveIcon,setDefaultIconSet,setIconSet,subscribeIcons}from"../chunk-J75ZT2JQ.js";export{LoadingSpinner,SpinnerRing}from"../chunk-R2VKEMZH.js";import"../chunk-G67CJAQ2.js";export{Tooltip}from"../chunk-SOZCWT6I.js";export{OVERLAY_OPEN_EVENT,dismissPopups}from"../chunk-PGN5ME7B.js";export{Z_LAYERS}from"../chunk-62LW225J.js";export{MENU_MAX_HEIGHT,POPUP_MAX_WIDTH,placeMenu,popupBounds,useDropdownPosition}from"../chunk-GLUJS42B.js";import"../chunk-D65T4H6J.js";export{setShellApiClient}from"../chunk-STKJA4PV.js";export{UNDOABLE_MS,toast_default as toast}from"../chunk-3YBXA72C.js";export{buttonClasses,iconButtonClasses}from"../chunk-UQYNPYF4.js";import"../chunk-MRJKZWWV.js";export{PortalBrandingProvider,resolvePortalBrandAsset,usePortalBranding}from"../chunk-ACYYVK6G.js";export{BoxPlotChart}from"../chunk-KAKJ7ENS.js";export{CartesianPlot}from"../chunk-ENFXDIIZ.js";import"../chunk-2DYVVHZA.js";export{usePlotWidth}from"../chunk-MAFUXCPZ.js";export{angleScale,bandScale,binValues,ladderScale,linearScale,logScale,niceAxis,niceMax,radiusScale}from"../chunk-2JWPNR2U.js";export{ChartTooltip}from"../chunk-WDQI3FV6.js";export{CHART_INK,SERIES_SLOT_COUNT,SERIES_VARS,STATUS_VARS,assignSeriesSlots,resolveSeriesColor,resolveSeriesColorWithin,seriesColor,toggleSeriesSlot}from"../chunk-TZFACUMR.js";export{registerModalEscapeInterceptor}from"../chunk-TWVUQUUD.js";export{GLASS_DIVIDER,glassStyle,solidSurfaceStyle}from"../chunk-5FYDNH4Y.js";import"../chunk-LNXBTK7Q.js";export{DEFAULT_SHELL_STRINGS,ShellStringsProvider,useShellLocale,useShellStrings}from"../chunk-JSHMIMAJ.js";import"../chunk-C3QOHMR6.js";
|
package/dist/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{APP_VERSION,VERSION}from"./chunk-
|
|
1
|
+
export{APP_VERSION,VERSION}from"./chunk-N56HV4IH.js";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "efficient-shell",
|
|
3
|
-
"version": "12.
|
|
3
|
+
"version": "12.24.0",
|
|
4
4
|
"description": "Desktop-style React UI shell — windows, taskbar, start menu, sticky notes, frosted glass theming, and bundled apps.",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"author": "Efficient Pty Ltd",
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import{loadAppearance as e,WidgetSettingsModal as t}from"./chunk-ZLKEPDJE.js";import{useWidgetSettings as n}from"./chunk-XQNZJNEJ.js";import"./chunk-4LXCCZDM.js";import"./chunk-AW7TOB6N.js";import"./chunk-KNUR2UEG.js";import"./chunk-JDCM2VHG.js";import"./chunk-DK5SXOXJ.js";import"./chunk-ZDMZM7HD.js";import"./chunk-5A7MWTXX.js";import"./chunk-UR2ECNBB.js";import"./chunk-HMT3MES3.js";import"./chunk-D2WJAF62.js";import"./chunk-MWTCGJAI.js";import"./chunk-RIG5FEVS.js";import"./chunk-5WK56FA3.js";import"./chunk-VWGWZY7A.js";import"./chunk-7QSDPSXP.js";import"./chunk-CJHYOHMU.js";import"./chunk-JZBLOIL7.js";import"./chunk-F3ZOO23R.js";import"./chunk-2QY5BJLA.js";import"./chunk-UGTRSRIW.js";import"./chunk-KC3EX26K.js";import"./chunk-DWGYC7OD.js";import"./chunk-JMGDGNM7.js";import"./chunk-THLXDI76.js";import"./chunk-URHGHXDN.js";import"./chunk-5QFPTDQF.js";import"./chunk-EVYD6UFQ.js";import"./chunk-M5K4AX4E.js";import{Icon as r}from"./chunk-XZXFUZIK.js";import"./chunk-J75ZT2JQ.js";import"./chunk-R2VKEMZH.js";import"./chunk-G67CJAQ2.js";import"./chunk-SOZCWT6I.js";import"./chunk-PGN5ME7B.js";import"./chunk-62LW225J.js";import"./chunk-GLUJS42B.js";import"./chunk-D65T4H6J.js";import"./chunk-STKJA4PV.js";import"./chunk-UQYNPYF4.js";import"./chunk-MRJKZWWV.js";import"./chunk-TWVUQUUD.js";import"./chunk-5FYDNH4Y.js";import"./chunk-LNXBTK7Q.js";import"./chunk-JSHMIMAJ.js";import"./chunk-C3QOHMR6.js";import{useState as c,useRef as i,useCallback as o,useEffect as s}from"react";import{jsxs as l,Fragment as a,jsx as u}from"react/jsx-runtime";var h="calc_appearance";function m(){const[m,k]=c("0"),[p,d]=c(null),[b,g]=c(null),[j,N]=c(!1),[y,x]=c(""),[C,f]=c([]),[v,$]=c(!1),[E,J]=c(()=>e(h)),[D,M]=c(!1),[T,W]=c(E),S=i(null);n(o(()=>{W({...E}),M(!0)},[E]));const A=o(e=>{x(""),k(t=>j||"0"===t?(N(!1),"."===e?"0.":e):"."===e&&t.includes(".")?t:t+e)},[j]),F=o(()=>{k("0"),d(null),g(null),N(!1)},[]),X=o((e,t,n)=>{switch(n){case"+":return e+t;case"-":return e-t;case"×":return e*t;case"÷":return 0===t?0:e/t;default:return t}},[]),w=o(e=>{const t=parseFloat(m);if(null!==p&&b&&!j){const e=X(p,t,b);k(String(e)),d(e),f(n=>[`${p} ${b} ${t} = ${e}`,...n].slice(0,20))}else d(t);g(e),N(!0)},[m,p,b,j,X]),U=o(()=>{if(null===p||!b)return;const e=parseFloat(m),t=X(p,e,b),n=`${p} ${b} ${e} =`;f(e=>[`${n} ${t}`,...e].slice(0,20)),x(n),k(String(t)),d(null),g(null),N(!0)},[m,p,b,X]),Z=o(()=>{k(e=>String(parseFloat(e)/100))},[]),G=o(()=>{k(e=>e.startsWith("-")?e.slice(1):"0"===e?e:"-"+e)},[]);s(()=>{const e=e=>{const t=e.target.tagName;"INPUT"!==t&&"TEXTAREA"!==t&&"SELECT"!==t&&(e.key>="0"&&e.key<="9"?A(e.key):"."===e.key?A("."):"+"===e.key?w("+"):"-"===e.key?w("-"):"*"===e.key?w("×"):"/"===e.key?(e.preventDefault(),w("÷")):"Enter"===e.key||"="===e.key?("Enter"===e.key&&e.target instanceof Node&&S.current?.contains(e.target)&&e.preventDefault(),U()):"Escape"===e.key?F():"Backspace"===e.key?k(e=>e.length>1?e.slice(0,-1):"0"):"%"===e.key&&Z())};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[A,w,U,F,Z]);const H="flex items-center justify-center rounded-lg text-sm font-medium transition-colors",K=`${H} bg-white border border-gray-200 text-gray-900 hover:bg-gray-50 active:bg-gray-100`,L=`${H} bg-blue-50 border border-blue-200 text-blue-700 hover:bg-blue-100 active:bg-blue-200`,Q=`${H} bg-gray-100 border border-gray-200 text-gray-600 hover:bg-gray-200 active:bg-gray-300`,B=`${H} bg-blue-600 text-white hover:bg-blue-700 active:bg-blue-800`;/* @__PURE__ */
|
|
2
|
-
return l(a,{children:[
|
|
3
|
-
/* @__PURE__ */l("div",{ref:S,className:"flex flex-col h-full",style:{opacity:E.activeOpacity/100,backdropFilter:E.activeBlur>0?`blur(${E.activeBlur}px)`:void 0},children:[
|
|
4
|
-
/* @__PURE__ */l("div",{className:"bg-slate-200 rounded-t-lg px-4 py-2 group/display relative flex flex-col justify-end min-h-[120px] border-b border-slate-300",children:[
|
|
5
|
-
/* @__PURE__ */u("div",{className:"flex flex-col justify-end flex-1 overflow-hidden",children:C.slice(0,3).reverse().map((e,t)=>/* @__PURE__ */u("div",{className:"text-2xs text-slate-400 text-right font-mono truncate",children:e},t))}),(y||b&&null!==p)&&/* @__PURE__ */u("div",{className:"text-base text-slate-600 text-right font-mono",children:y||`${p} ${b} ${j?"":m}`}),
|
|
6
|
-
/* @__PURE__ */l("div",{className:"flex items-center gap-2",children:[
|
|
7
|
-
/* @__PURE__ */u("button",{onClick:()=>{navigator.clipboard.writeText(m),$(!0),setTimeout(()=>$(!1),1200)},title:"Copy result",className:"shrink-0 text-slate-300 hover:text-slate-500 transition-colors opacity-0 group-hover/display:opacity-100",children:/* @__PURE__ */u(r,v?{name:"check",className:"h-5 w-5 text-green-500",strokeWidth:2}:{name:"copy",className:"h-5 w-5",strokeWidth:2})}),
|
|
8
|
-
/* @__PURE__ */u("div",{className:"text-right text-4xl font-mono font-bold text-slate-800 truncate flex-1",children:(e=>{const t=parseFloat(e);return isNaN(t)||e.endsWith(".")||e.endsWith(".0")||Math.abs(t)<1e15&&e.length<16?e:t.toExponential(6)})(m)})]})]}),
|
|
9
|
-
/* @__PURE__ */l("div",{className:"grid grid-cols-4 grid-rows-5 gap-2 flex-1 min-h-0 p-2",children:[
|
|
10
|
-
/* @__PURE__ */u("button",{onClick:F,className:Q,children:"AC"}),
|
|
11
|
-
/* @__PURE__ */u("button",{onClick:G,className:Q,children:"+/−"}),
|
|
12
|
-
/* @__PURE__ */u("button",{onClick:Z,className:Q,children:"%"}),
|
|
13
|
-
/* @__PURE__ */u("button",{onClick:()=>w("÷"),className:`${L} ${"÷"===b?"ring-2 ring-blue-400":""}`,children:"÷"}),
|
|
14
|
-
/* @__PURE__ */u("button",{onClick:()=>A("7"),className:K,children:"7"}),
|
|
15
|
-
/* @__PURE__ */u("button",{onClick:()=>A("8"),className:K,children:"8"}),
|
|
16
|
-
/* @__PURE__ */u("button",{onClick:()=>A("9"),className:K,children:"9"}),
|
|
17
|
-
/* @__PURE__ */u("button",{onClick:()=>w("×"),className:`${L} ${"×"===b?"ring-2 ring-blue-400":""}`,children:"×"}),
|
|
18
|
-
/* @__PURE__ */u("button",{onClick:()=>A("4"),className:K,children:"4"}),
|
|
19
|
-
/* @__PURE__ */u("button",{onClick:()=>A("5"),className:K,children:"5"}),
|
|
20
|
-
/* @__PURE__ */u("button",{onClick:()=>A("6"),className:K,children:"6"}),
|
|
21
|
-
/* @__PURE__ */u("button",{onClick:()=>w("-"),className:`${L} ${"-"===b?"ring-2 ring-blue-400":""}`,children:"−"}),
|
|
22
|
-
/* @__PURE__ */u("button",{onClick:()=>A("1"),className:K,children:"1"}),
|
|
23
|
-
/* @__PURE__ */u("button",{onClick:()=>A("2"),className:K,children:"2"}),
|
|
24
|
-
/* @__PURE__ */u("button",{onClick:()=>A("3"),className:K,children:"3"}),
|
|
25
|
-
/* @__PURE__ */u("button",{onClick:()=>w("+"),className:`${L} ${"+"===b?"ring-2 ring-blue-400":""}`,children:"+"}),
|
|
26
|
-
/* @__PURE__ */u("button",{onClick:()=>A("0"),className:`${K} col-span-2`,children:"0"}),
|
|
27
|
-
/* @__PURE__ */u("button",{onClick:()=>A("."),className:K,children:"."}),
|
|
28
|
-
/* @__PURE__ */u("button",{onClick:U,className:B,children:"="})]})]}),
|
|
29
|
-
/* @__PURE__ */u(t,{open:D,onClose:()=>M(!1),title:"Calculator Settings",appearance:T,onAppearanceChange:W,onSave:()=>{J(T),localStorage.setItem(h,JSON.stringify(T)),M(!1)}})]})}export{m as default};
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import{loadAppearance as t,WidgetSettingsModal as e}from"./chunk-ZLKEPDJE.js";import{useWidgetSettings as r}from"./chunk-XQNZJNEJ.js";import"./chunk-4LXCCZDM.js";import"./chunk-AW7TOB6N.js";import"./chunk-KNUR2UEG.js";import"./chunk-JDCM2VHG.js";import"./chunk-DK5SXOXJ.js";import"./chunk-ZDMZM7HD.js";import"./chunk-5A7MWTXX.js";import"./chunk-UR2ECNBB.js";import"./chunk-HMT3MES3.js";import"./chunk-D2WJAF62.js";import"./chunk-MWTCGJAI.js";import"./chunk-RIG5FEVS.js";import"./chunk-5WK56FA3.js";import"./chunk-VWGWZY7A.js";import"./chunk-7QSDPSXP.js";import"./chunk-CJHYOHMU.js";import"./chunk-JZBLOIL7.js";import"./chunk-F3ZOO23R.js";import"./chunk-2QY5BJLA.js";import"./chunk-UGTRSRIW.js";import"./chunk-KC3EX26K.js";import"./chunk-DWGYC7OD.js";import"./chunk-JMGDGNM7.js";import"./chunk-THLXDI76.js";import"./chunk-URHGHXDN.js";import"./chunk-5QFPTDQF.js";import"./chunk-EVYD6UFQ.js";import"./chunk-M5K4AX4E.js";import"./chunk-XZXFUZIK.js";import"./chunk-J75ZT2JQ.js";import{LoadingSpinner as n}from"./chunk-R2VKEMZH.js";import"./chunk-G67CJAQ2.js";import"./chunk-SOZCWT6I.js";import"./chunk-PGN5ME7B.js";import"./chunk-62LW225J.js";import"./chunk-GLUJS42B.js";import"./chunk-D65T4H6J.js";import"./chunk-STKJA4PV.js";import"./chunk-UQYNPYF4.js";import"./chunk-MRJKZWWV.js";import"./chunk-TWVUQUUD.js";import"./chunk-5FYDNH4Y.js";import"./chunk-LNXBTK7Q.js";import"./chunk-JSHMIMAJ.js";import"./chunk-C3QOHMR6.js";import{useState as s,useCallback as o,useEffect as c}from"react";import{jsxs as i,Fragment as a,jsx as m}from"react/jsx-runtime";var l=["USD","CNY","AUD","GBP","EUR","JPY","CAD","THB","NZD","SGD","HKD","CHF","KRW","INR","MXN","BRL"],u=[["USD","CNY"],["USD","AUD"],["GBP","USD"],["USD","JPY"]],p="currency_pairs",h="currency_appearance",d="currency_rates_cache";function k(t){try{const e=JSON.parse(localStorage.getItem(d)||"{}")[t];if(e&&Date.now()-e.timestamp<36e5)return e.rates}catch{}return null}function g(t,e){try{const r=JSON.parse(localStorage.getItem(d)||"{}");r[t]={rates:e,timestamp:Date.now()},localStorage.setItem(d,JSON.stringify(r))}catch{}}function j(){try{const t=JSON.parse(localStorage.getItem(p)||"");if(Array.isArray(t)&&t.length)return t.slice(0,4)}catch{}return u}var N={USD:"🇺🇸",CNY:"🇨🇳",AUD:"🇦🇺",GBP:"🇬🇧",JPY:"🇯🇵",CAD:"🇨🇦",EUR:"🇪🇺",THB:"🇹🇭",NZD:"🇳🇿",SGD:"🇸🇬",HKD:"🇭🇰",CHF:"🇨🇭",KRW:"🇰🇷",INR:"🇮🇳",MXN:"🇲🇽",BRL:"🇧🇷"};function f(){const[u,d]=s(j),[f,x]=s(()=>t(h)),[y,D]=s({}),[b,S]=s(!1),[J,C]=s(!1),[v,U]=s([]),[M,A]=s(f),[H,B]=s("USD"),[G,R]=s("CNY");r(o(()=>{U([...u]),A({...f}),C(!0)},[u,f])),c(()=>{const t=[...new Set(u.map(([t])=>t))];let e=!0;return async function(){S(!0);const r={};for(const e of t){const t=k(e);if(t)r[e]=t;else try{const t=await fetch(`https://open.er-api.com/v6/latest/${e}`),n=await t.json();n.rates&&(r[e]=n.rates,g(e,n.rates))}catch{}}e&&(D(r),S(!1))}(),()=>{e=!1}},[u]);/* @__PURE__ */
|
|
2
|
-
return i(a,{children:[
|
|
3
|
-
/* @__PURE__ */m("div",{style:{backgroundColor:`rgb(var(--taskbar-bg-rgb, 243 244 246) / ${f.activeOpacity/100})`,backdropFilter:f.activeBlur>0?`blur(${f.activeBlur}px)`:void 0},children:/* @__PURE__ */i("div",{className:"px-4 py-3 space-y-1",children:[b&&/* @__PURE__ */m(n,{size:"sm",padding:"py-4",label:"Loading rates"}),u.map(([t,e],r)=>{const n=y[t]?.[e];/* @__PURE__ */
|
|
4
|
-
return i("button",{onClick:()=>{const t=u.map((t,e)=>e===r?[t[1],t[0]]:t);d(t),localStorage.setItem(p,JSON.stringify(t))},className:"flex items-center justify-between px-2 py-2 border-b border-gray-200 last:border-0 w-full hover:bg-gray-100 rounded transition-colors cursor-pointer",children:[
|
|
5
|
-
/* @__PURE__ */i("div",{className:"flex items-center gap-2",children:[
|
|
6
|
-
/* @__PURE__ */m("span",{className:"text-base",children:N[t]||""}),
|
|
7
|
-
/* @__PURE__ */m("span",{className:"text-sm font-semibold text-gray-700",children:t}),
|
|
8
|
-
/* @__PURE__ */m("svg",{className:"h-3 w-3 text-gray-400",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:/* @__PURE__ */m("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M7 16V4m0 0L3 8m4-4l4 4m6 0v12m0 0l4-4m-4 4l-4-4"})}),
|
|
9
|
-
/* @__PURE__ */m("span",{className:"text-base",children:N[e]||""}),
|
|
10
|
-
/* @__PURE__ */m("span",{className:"text-sm font-semibold text-gray-700",children:e})]}),
|
|
11
|
-
/* @__PURE__ */m("div",{className:"text-base font-mono font-semibold text-gray-900 tabular-nums",children:null!=n?n.toLocaleString(void 0,{minimumFractionDigits:2,maximumFractionDigits:4}):"—"})]},`${t}-${e}-${r}`)})]})}),
|
|
12
|
-
/* @__PURE__ */m(e,{open:J,onClose:()=>C(!1),title:"Currency Settings",appearance:M,onAppearanceChange:A,onSave:()=>{if(0===v.length)return;const t=v.slice(0,4);d(t),x(M),localStorage.setItem(p,JSON.stringify(t)),localStorage.setItem(h,JSON.stringify(M)),C(!1)},children:/* @__PURE__ */i("div",{children:[
|
|
13
|
-
/* @__PURE__ */i("h3",{className:"text-sm font-semibold text-ink mb-2",children:["Currency Pairs ",
|
|
14
|
-
/* @__PURE__ */i("span",{className:"text-2xs font-normal text-ink-faintest",children:["(",v.length,"/",4,")"]})]}),
|
|
15
|
-
/* @__PURE__ */m("div",{className:"space-y-1 mb-2",children:v.map(([t,e],r)=>/* @__PURE__ */i("div",{className:"flex items-center justify-between py-1 px-2 bg-gray-50 rounded",children:[
|
|
16
|
-
/* @__PURE__ */i("span",{className:"text-sm",children:[N[t]||""," ",t," → ",N[e]||""," ",e]}),
|
|
17
|
-
/* @__PURE__ */m("button",{onClick:()=>U(t=>t.filter((t,e)=>e!==r)),className:"text-red-400 hover:text-red-600",children:"×"})]},r))}),v.length<4?/* @__PURE__ */i("div",{className:"flex items-center gap-2",children:[
|
|
18
|
-
/* @__PURE__ */m("select",{value:H,onChange:t=>B(t.target.value),className:"bg-gray-50 border border-gray-200 rounded px-2 py-1 text-sm focus:outline-none focus:ring-1 focus:ring-blue-500",children:l.map(t=>/* @__PURE__ */m("option",{children:t},t))}),
|
|
19
|
-
/* @__PURE__ */m("span",{className:"text-gray-400",children:"→"}),
|
|
20
|
-
/* @__PURE__ */m("select",{value:G,onChange:t=>R(t.target.value),className:"bg-gray-50 border border-gray-200 rounded px-2 py-1 text-sm focus:outline-none focus:ring-1 focus:ring-blue-500",children:l.map(t=>/* @__PURE__ */m("option",{children:t},t))}),
|
|
21
|
-
/* @__PURE__ */m("button",{onClick:()=>{H!==G&&v.length<4&&U(t=>[...t,[H,G]])},className:"text-sm font-medium text-blue-600 hover:text-blue-800 px-2",children:"+ Add"})]}):/* @__PURE__ */i("p",{className:"text-2xs text-ink-faintest italic",children:["Max ",4," pairs — remove one to add another."]})]})})]})}export{f as default};
|
package/dist/Notepad-CUWBPETD.js
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import{getNumberingConfigs as e}from"./chunk-OGWQABFP.js";import{SidebarLayout as t}from"./chunk-JGRDG7CB.js";import"./chunk-QWK6DRSN.js";import"./chunk-OOWPLQD5.js";import{timeAgo as r}from"./chunk-GEYM4WN3.js";import"./chunk-Y3JW2GW5.js";import"./chunk-36BRD5J3.js";import"./chunk-LF27WIN2.js";import{AboutApp as n}from"./chunk-ZNLCITYY.js";import{useWindowManager as o,client_default as i}from"./chunk-XQNZJNEJ.js";import"./chunk-4LXCCZDM.js";import"./chunk-AW7TOB6N.js";import"./chunk-KNUR2UEG.js";import"./chunk-JDCM2VHG.js";import"./chunk-DK5SXOXJ.js";import"./chunk-ZDMZM7HD.js";import"./chunk-5A7MWTXX.js";import"./chunk-UR2ECNBB.js";import"./chunk-HMT3MES3.js";import"./chunk-D2WJAF62.js";import"./chunk-MWTCGJAI.js";import"./chunk-RIG5FEVS.js";import"./chunk-5WK56FA3.js";import"./chunk-VWGWZY7A.js";import"./chunk-7QSDPSXP.js";import"./chunk-CJHYOHMU.js";import"./chunk-JZBLOIL7.js";import"./chunk-F3ZOO23R.js";import"./chunk-2QY5BJLA.js";import"./chunk-UGTRSRIW.js";import{useShellPrefs as c}from"./chunk-KC3EX26K.js";import"./chunk-MDVABA4H.js";import"./chunk-DWGYC7OD.js";import"./chunk-JMGDGNM7.js";import"./chunk-THLXDI76.js";import"./chunk-URHGHXDN.js";import"./chunk-5QFPTDQF.js";import"./chunk-EVYD6UFQ.js";import"./chunk-M5K4AX4E.js";import{Icon as s}from"./chunk-XZXFUZIK.js";import"./chunk-J75ZT2JQ.js";import"./chunk-R2VKEMZH.js";import"./chunk-G67CJAQ2.js";import"./chunk-SOZCWT6I.js";import"./chunk-PGN5ME7B.js";import"./chunk-62LW225J.js";import"./chunk-GLUJS42B.js";import"./chunk-D65T4H6J.js";import"./chunk-STKJA4PV.js";import{toast_default as l}from"./chunk-3YBXA72C.js";import"./chunk-UQYNPYF4.js";import"./chunk-MRJKZWWV.js";import"./chunk-TWVUQUUD.js";import"./chunk-5FYDNH4Y.js";import"./chunk-LNXBTK7Q.js";import"./chunk-JSHMIMAJ.js";import"./chunk-C3QOHMR6.js";import{useRef as a,useEffect as p,useState as d,useCallback as m}from"react";import{useQuery as u}from"@tanstack/react-query";import{jsxs as h,Fragment as g,jsx as x}from"react/jsx-runtime";var y=[{key:"yellow",bg:"bg-yellow-100",border:"border-yellow-300",text:"text-yellow-900",dot:"bg-yellow-400"},{key:"blue",bg:"bg-blue-100",border:"border-blue-300",text:"text-blue-900",dot:"bg-blue-400"},{key:"green",bg:"bg-green-100",border:"border-green-300",text:"text-green-900",dot:"bg-green-400"},{key:"pink",bg:"bg-pink-100",border:"border-pink-300",text:"text-pink-900",dot:"bg-pink-400"},{key:"purple",bg:"bg-purple-100",border:"border-purple-300",text:"text-purple-900",dot:"bg-purple-400"},{key:"orange",bg:"bg-orange-100",border:"border-orange-300",text:"text-orange-900",dot:"bg-orange-400"},{key:"white",bg:"bg-white",border:"border-gray-300",text:"text-gray-900",dot:"bg-gray-300"}];var k={sales_order:{entityType:"order",endpoint:"/orders/sales-orders/"},purchase_order:{entityType:"purchase_order",endpoint:"/purchase-orders/"},invoice:{entityType:"invoice",endpoint:"/invoicing/invoices/"},vendor_invoice:{entityType:"vendor_invoice",endpoint:"/invoicing/vendor-invoices/"},shipment:{entityType:"shipment",endpoint:"/shipments/delivery-notes/"},receipt:{entityType:"payment",endpoint:"/invoicing/payments/"},vendor_payment:{entityType:"vendor_payment",endpoint:"/invoicing/vendor-payments/"},vendor_price_sheet:{entityType:"vendor_price_sheet",endpoint:"/pricing/manufacturer-price-sheets/"},client_price_sheet:{entityType:"price_sheet",endpoint:"/pricing/price-sheets/"},qc_report:{entityType:"qc_report",endpoint:"/qc-reports/"},warranty_claim:{entityType:"warranty_claim",endpoint:"/warranty-claims/claims/"},vendor_shipment:{entityType:"vendor_shipment",endpoint:"/shipments/goods-receipts/"}},b=/\[([ xX]?)\]/g;function f(){const{openEntity:f}=o(),{prefs:j,save:N}=c(),{data:v}=u({queryKey:["numbering-configs"],queryFn:()=>e(),retry:!1}),w=a({});p(()=>{if(!v)return;const e={};for(const t of v){const r=k[t.entity_type];if(!r)continue;const n=(t.prefix||"").replace("#","").toUpperCase();if(n&&(e[n]={...r,prefix:t.prefix}),t.alt_prefix){const n=t.alt_prefix.replace("#","").toUpperCase();n&&(e[n]={...r,prefix:t.alt_prefix})}}w.current=e},[v]);const T=j.notepad_notes||[],[_,W]=d(null),[C,D]=d(""),[J,S]=d(""),[X,M]=d("yellow"),[$,G]=d(!1),[O,A]=d(!1),U=a(null),I=a();p(()=>{if(!_&&T.length>0){const e=T[0];W(e.id),D(e.title),S(e.content),M(e.color)}},[T.length]);const Q=m(e=>{N({notepad_notes:e})},[N]),Z=m(()=>{if(!_||!$)return;const e=T.map(e=>e.id===_?{...e,title:C,content:J,color:X,updated_at:/* @__PURE__ */(new Date).toISOString()}:e);Q(e),G(!1)},[_,$,C,J,X,T,Q]);p(()=>{if($)return I.current&&clearTimeout(I.current),I.current=setTimeout(Z,800),()=>{I.current&&clearTimeout(I.current)}},[$,Z]),p(()=>()=>{$&&Z()},[]);const B=e=>{$&&Z(),W(e.id),D(e.title),S(e.content),M(e.color),G(!1),A(!1)},E=e=>{const t=J.slice(0,e),r=J.slice(e).match(/^\[([ xX]?)\]/);if(!r)return;const n="x"===r[1]||"X"===r[1]?"[ ]":"[x]",o=J.slice(e+r[0].length);S(t+n+o),G(!0)},F=async(e,t)=>{const r=w.current[e];if(!r)return;const n=`${e}#${t}`;try{const{data:e}=await i.get(r.endpoint,{params:{search:n,page_size:1}}),t=(e?.results??e??[])[0];t?f(r.entityType,t.id,t,n):l.error(`${n} not found`)}catch{l.error(`Failed to look up ${n}`)}},H="Start writing...\n\nTips:\n [] Type [] for a checkbox, click to toggle\n SO#35001 Type XX#NNNNN to link entities (SO, PO, CI, VI, PL, etc.)",K=/* @__PURE__ */h(g,{children:[
|
|
2
|
-
/* @__PURE__ */x("div",{className:"p-2 border-b border-gray-200",children:/* @__PURE__ */h("button",{onClick:()=>{$&&Z();const e={id:`note-${Date.now()}-${Math.random().toString(36).slice(2,6)}`,title:"",content:"",color:"yellow",updated_at:/* @__PURE__ */(new Date).toISOString()},t=[e,...T];Q(t),W(e.id),D(""),S(""),M("yellow"),G(!1),A(!0),setTimeout(()=>U.current?.focus(),50)},className:"w-full flex items-center justify-center gap-2 rounded-lg bg-accent-fill text-on-accent px-3 min-h-8 py-1 text-sm font-medium hover:bg-accent-fill-hover transition-colors",children:[
|
|
3
|
-
/* @__PURE__ */x(s,{name:"add",className:"h-4 w-4",strokeWidth:2}),"New Note"]})}),
|
|
4
|
-
/* @__PURE__ */x("div",{className:"flex-1 overflow-y-auto",children:0===T.length?/* @__PURE__ */x("p",{className:"text-sm text-gray-400 text-center py-8 px-4",children:"No notes yet. Create one to get started."}):T.map(e=>{const t=(n=e.color,y.find(e=>e.key===n)||y[0]);var n;/* @__PURE__ */
|
|
5
|
-
return h("button",{onClick:()=>B(e),className:"w-full text-left px-3 py-3 border-b border-line-subtle transition-colors "+(_===e.id?"bg-accent-tint":"hover:bg-row-hover"),children:[
|
|
6
|
-
/* @__PURE__ */h("div",{className:"flex items-center gap-2",children:[
|
|
7
|
-
/* @__PURE__ */x("div",{className:`w-3 h-3 rounded-full shrink-0 ${t.dot}`}),
|
|
8
|
-
/* @__PURE__ */x("span",{className:"text-sm font-medium text-gray-900 truncate flex-1",children:e.title||"Untitled"})]}),
|
|
9
|
-
/* @__PURE__ */x("p",{className:"text-xs text-ink-faintest mt-0.5 truncate ml-5",children:e.content.replace(/\[[ xX]?\]/g,"").slice(0,60)||"Empty note"}),
|
|
10
|
-
/* @__PURE__ */x("p",{className:"text-2xs text-gray-300 mt-0.5 ml-5",children:r(e.updated_at)})]},e.id)})})]});/* @__PURE__ */
|
|
11
|
-
return h("div",{className:"h-full",children:[
|
|
12
|
-
/* @__PURE__ */x(n,{app:"notepad"}),
|
|
13
|
-
/* @__PURE__ */x(t,{sidebar:K,storageKey:"notepad.sidebarWidth",defaultWidth:224,minWidth:180,maxWidth:360,children:_?/* @__PURE__ */h("div",{className:"flex-1 flex flex-col min-w-0",children:[
|
|
14
|
-
/* @__PURE__ */h("div",{className:"flex items-center gap-2 px-4 py-2 border-b border-gray-200",children:[
|
|
15
|
-
/* @__PURE__ */x("input",{value:C,onChange:e=>{D(e.target.value),G(!0)},placeholder:"Note title...",className:"flex-1 text-lg font-semibold text-gray-900 outline-none bg-transparent placeholder:text-gray-300"}),
|
|
16
|
-
/* @__PURE__ */x("div",{className:"flex gap-1",children:y.map(e=>/* @__PURE__ */x("button",{onClick:()=>{M(e.key),G(!0)},className:`w-5 h-5 rounded-full border-2 transition-all ${e.dot} ${X===e.key?"border-gray-600 scale-110":"border-transparent hover:border-gray-400"}`,title:e.key},e.key))}),
|
|
17
|
-
/* @__PURE__ */x("button",{onClick:()=>(e=>{const t=T.filter(t=>t.id!==e);if(Q(t),_===e){const e=t[0];e?B(e):(W(null),D(""),S(""))}})(_),title:"Delete note",className:"p-1 rounded text-gray-300 hover:text-red-500 transition-colors",children:/* @__PURE__ */x(s,{name:"trash",className:"h-4 w-4",strokeWidth:1.5})})]}),O?/* @__PURE__ */x("textarea",{ref:U,value:J,onChange:e=>{S(e.target.value),G(!0)},onBlur:()=>{A(!1),$&&Z()},placeholder:H,className:"flex-1 p-4 text-sm text-gray-700 outline-none resize-none bg-transparent leading-relaxed placeholder:text-gray-300 font-mono"}):/* @__PURE__ */x("div",{onClick:()=>{A(!0),setTimeout(()=>U.current?.focus(),50)},className:"flex-1 p-4 text-sm text-gray-700 overflow-y-auto leading-relaxed cursor-text",children:J?(e=>{if(!e)return[];const t=e.split("\n");return t.map((e,r)=>{const n=[];let o=0;const i=[],c=/([A-Z]{2,4})#(\d{4,6})/g;let l;for(;null!==(l=c.exec(e));){const e=l[1],t=l[2];if(w.current[e]){const n=l.index,o=l[0];i.push({idx:n,len:o.length,render:()=>/* @__PURE__ */x("button",{onClick:()=>F(e,t),className:"text-blue-600 hover:text-blue-800 hover:underline font-medium cursor-pointer",children:o},`ref-${r}-${n}`)})}}b.lastIndex=0;let a=0;for(let e=0;e<r;e++)a+=t[e].length+1;for(;null!==(l=b.exec(e));){const e="x"===l[1]||"X"===l[1],t=l.index,n=a+t;i.push({idx:t,len:l[0].length,render:()=>/* @__PURE__ */x("button",{onClick:()=>E(n),className:`inline-flex items-center justify-center w-4 h-4 rounded border ${e?"bg-blue-500 border-blue-500 text-white":"border-gray-400 bg-white hover:border-blue-400"} cursor-pointer align-text-bottom mr-0.5`,children:e&&/* @__PURE__ */x(s,{name:"check",className:"w-3 h-3",strokeWidth:3})},`cb-${r}-${t}`)})}i.sort((e,t)=>e.idx-t.idx);for(const t of i)t.idx>o&&n.push(/* @__PURE__ */x("span",{children:e.slice(o,t.idx)},`t-${r}-${o}`)),n.push(t.render()),o=t.idx+t.len;o<e.length&&n.push(/* @__PURE__ */x("span",{children:e.slice(o)},`t-${r}-${o}`)),0===n.length&&n.push(/* @__PURE__ */x("span",{children:""},`empty-${r}`));const p=/^\[x\]/i.test(e.trimStart());/* @__PURE__ */
|
|
18
|
-
return x("div",{className:p?"line-through text-gray-400":"",children:n},r)})})(J):/* @__PURE__ */x("p",{className:"text-gray-300 whitespace-pre-line",children:H})}),
|
|
19
|
-
/* @__PURE__ */h("div",{className:"px-4 min-h-8 py-1 border-t border-line-subtle flex items-center gap-4 text-2xs text-ink-faintest",children:[
|
|
20
|
-
/* @__PURE__ */x("span",{children:"[] checkbox"}),
|
|
21
|
-
/* @__PURE__ */x("span",{children:"SO#35001 entity link"}),
|
|
22
|
-
/* @__PURE__ */x("span",{className:"ml-auto",children:O?"Editing":"Click to edit"})]})]}):/* @__PURE__ */x("div",{className:"flex-1 flex items-center justify-center",children:/* @__PURE__ */h("div",{className:"text-center text-gray-400",children:[
|
|
23
|
-
/* @__PURE__ */x(s,{name:"page",className:"h-12 w-12 mx-auto mb-3 text-gray-300",strokeWidth:1}),
|
|
24
|
-
/* @__PURE__ */x("p",{className:"text-sm",children:"Select a note or create a new one"})]})})})]})}export{f as default};
|
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
import{loadAppearance as e,WidgetSettingsModal as t}from"./chunk-ZLKEPDJE.js";import{subscribePomo as o,getPomoSnapshot as a,setPomoDurations as n,setPomoAlarm as r,setPomoAlarmConfig as s,setPomoBehaviour as i,setPomoFocusSound as l,useTodoTasks as c,migratePomodoroTasksOnce as u,pomoSwitchMode as d,pomoPause as m,pomoStart as h,ALARM_OPTIONS as p,playAlarm as g,FOCUS_SOUND_OPTIONS as k,previewFocusSound as f}from"./chunk-DJXXY23A.js";import{PLACEHOLDER_INK as b}from"./chunk-AYZY3YNC.js";import{pad2 as x}from"./chunk-LF27WIN2.js";import{useWidgetSettings as v}from"./chunk-XQNZJNEJ.js";import"./chunk-4LXCCZDM.js";import"./chunk-AW7TOB6N.js";import"./chunk-KNUR2UEG.js";import"./chunk-JDCM2VHG.js";import"./chunk-DK5SXOXJ.js";import"./chunk-ZDMZM7HD.js";import"./chunk-5A7MWTXX.js";import"./chunk-UR2ECNBB.js";import"./chunk-HMT3MES3.js";import"./chunk-D2WJAF62.js";import"./chunk-MWTCGJAI.js";import"./chunk-RIG5FEVS.js";import"./chunk-5WK56FA3.js";import"./chunk-VWGWZY7A.js";import"./chunk-7QSDPSXP.js";import"./chunk-CJHYOHMU.js";import"./chunk-JZBLOIL7.js";import"./chunk-F3ZOO23R.js";import"./chunk-2QY5BJLA.js";import"./chunk-UGTRSRIW.js";import{useShellPrefs as y}from"./chunk-KC3EX26K.js";import"./chunk-DWGYC7OD.js";import"./chunk-JMGDGNM7.js";import"./chunk-THLXDI76.js";import"./chunk-URHGHXDN.js";import"./chunk-5QFPTDQF.js";import"./chunk-EVYD6UFQ.js";import"./chunk-M5K4AX4E.js";import{Icon as N}from"./chunk-XZXFUZIK.js";import"./chunk-J75ZT2JQ.js";import"./chunk-R2VKEMZH.js";import"./chunk-G67CJAQ2.js";import"./chunk-SOZCWT6I.js";import"./chunk-PGN5ME7B.js";import"./chunk-62LW225J.js";import"./chunk-GLUJS42B.js";import"./chunk-D65T4H6J.js";import"./chunk-STKJA4PV.js";import"./chunk-3YBXA72C.js";import"./chunk-UQYNPYF4.js";import"./chunk-MRJKZWWV.js";import"./chunk-TWVUQUUD.js";import"./chunk-5FYDNH4Y.js";import"./chunk-LNXBTK7Q.js";import"./chunk-JSHMIMAJ.js";import"./chunk-C3QOHMR6.js";import{useSyncExternalStore as C,useEffect as S,useMemo as w,useState as j,useRef as B,useCallback as M}from"react";import{jsxs as T,Fragment as I,jsx as P}from"react/jsx-runtime";var A="pomodoro_appearance",D="pomodoro_active_task_id",L={focus:"Pomodoro",short:"Short Break",long:"Long Break"},J={focus:"#0f172a",short:"#508a52",long:"#5b7898"};var V=25,W=5,$=15,E=!1,R=!1,F=4,X=!0,U=!0,Z="bell",H=100,K=1,O="none",Y=50,G=(e,t,o,a)=>"number"==typeof e&&isFinite(e)?Math.max(t,Math.min(o,Math.round(e))):a;function Q(){const t=C(o,a,a),{prefs:g,save:f}=y(),b=function(e){const t=e&&"object"==typeof e?e:{};return{focusMinutes:G(t.focusMinutes,1,120,V),shortBreakMinutes:G(t.shortBreakMinutes,1,120,W),longBreakMinutes:G(t.longBreakMinutes,1,120,$),autoStartBreaks:"boolean"==typeof t.autoStartBreaks?t.autoStartBreaks:E,autoStartPomodoros:"boolean"==typeof t.autoStartPomodoros?t.autoStartPomodoros:R,longBreakInterval:G(t.longBreakInterval,1,20,F),autoCheckTasks:"boolean"==typeof t.autoCheckTasks?t.autoCheckTasks:X,checkToBottom:"boolean"==typeof t.checkToBottom?t.checkToBottom:U,alarmSound:p.some(e=>e.id===t.alarmSound)?t.alarmSound:Z,alarmVolume:G(t.alarmVolume,0,100,H),alarmRepeat:G(t.alarmRepeat,1,5,K),focusSound:k.some(e=>e.id===t.focusSound)?t.focusSound:O,focusVolume:G(t.focusVolume,0,100,Y)}}(g.pomodoro_settings);S(()=>{n({focus:60*b.focusMinutes,short:60*b.shortBreakMinutes,long:60*b.longBreakMinutes})},[b.focusMinutes,b.shortBreakMinutes,b.longBreakMinutes]),S(()=>{r(b.alarmSound),s(b.alarmVolume,b.alarmRepeat)},[b.alarmSound,b.alarmVolume,b.alarmRepeat]),S(()=>{i({autoStartBreaks:b.autoStartBreaks,autoStartPomodoros:b.autoStartPomodoros,longBreakInterval:b.longBreakInterval})},[b.autoStartBreaks,b.autoStartPomodoros,b.longBreakInterval]),S(()=>{l(b.focusSound,b.focusVolume)},[b.focusSound,b.focusVolume]),S(()=>{if("undefined"!=typeof Notification&&"default"===Notification.permission)try{Notification.requestPermission()}catch{}},[]);const Q=c(),z=Q.tasks,q=w(()=>/* @__PURE__ */(new Date).toISOString().slice(0,10),[]),ee=function(e,t){return w(()=>t?(e=>{const t=[],o=[];for(const a of e)(a.done?o:t).push(a);return[...t,...o]})(e):e,[e,t])}(w(()=>z.filter(e=>!!e.dueDate&&(e.dueDate===q||e.dueDate<q&&!e.done)),[z,q]),b.checkToBottom),[te,oe]=j(()=>localStorage.getItem(D)),[ae,ne]=j(!1),[re,se]=j(null),ie=B(!1);S(()=>{ie.current||(ie.current=!0,u(z,Q.setAllTasks))},[]),S(()=>{try{te?localStorage.setItem(D,te):localStorage.removeItem(D)}catch{}},[te]),S(()=>{if(!re)return;const e=()=>se(null),t=setTimeout(()=>document.addEventListener("click",e),0);return()=>{clearTimeout(t),document.removeEventListener("click",e)}},[re]);const le=B(t.streak);S(()=>{if(t.streak>le.current&&te){const e=z.find(e=>e.id===te);if(e){const t=(e.completed??0)+1,o=e.estimated??0,a=b.autoCheckTasks&&o>0&&t>=o;Q.updateTask(te,{completed:t,done:e.done||a})}}le.current=t.streak},[t.streak,te,b.autoCheckTasks,z,Q]);const ue=ee.reduce((e,t)=>e+(t.completed??0),0),de=ee.reduce((e,t)=>e+Math.max(t.estimated??0,t.completed??0),0),me=ee.reduce((e,t)=>t.done?e:e+Math.max(0,(t.estimated??0)-(t.completed??0)),0),he=t.running&&"focus"===t.mode?t.remaining:0,pe=me*b.focusMinutes*60+he,ge=new Date(Date.now()+1e3*pe).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit",hour12:!1}),ke=(pe/3600).toFixed(1),fe=te?z.find(e=>e.id===te)??null:null,be=x(Math.floor(t.remaining/60)),xe=x(t.remaining%60),[ve,ye]=j(()=>e(A)),[Ne,Ce]=j(!1),[Se,we]=j(ve),[je,Be]=j(b);v(M(()=>{we({...ve}),Be({...b}),Ce(!0)},[ve,b]));const Me="focus"!==t.mode,Te=J[t.mode],Ie=Me?(Pe=Te,Ae=ve.activeOpacity/100,`rgba(${parseInt(Pe.slice(1,3),16)}, ${parseInt(Pe.slice(3,5),16)}, ${parseInt(Pe.slice(5,7),16)}, ${Ae})`):`rgb(var(--taskbar-bg-rgb, 243 244 246) / ${ve.activeOpacity/100})`;var Pe,Ae;const De={primary:Me?"text-white":"text-gray-900",secondary:Me?"text-white/85":"text-gray-700",muted:Me?"text-white/65":"text-gray-500",tabActive:Me?"bg-white/15 text-white":"bg-gray-200 text-gray-900",tabInactive:Me?"text-white/75 hover:bg-white/10":"text-gray-500 hover:bg-gray-200",divider:Me?"border-white/30":"border-gray-200",softDivider:Me?"border-white/20":"border-gray-200",iconBtn:Me?"bg-black/15 hover:bg-black/25 text-white/85":"bg-gray-200 hover:bg-gray-300 text-gray-600",addTaskBtn:Me?"border-white/45 text-white/90 hover:bg-white/[0.06]":"border-gray-300 text-gray-500 hover:bg-gray-200/50"},Le=Me?Te:"#0f172a";/* @__PURE__ */
|
|
2
|
-
return T(I,{children:[
|
|
3
|
-
/* @__PURE__ */T("div",{className:`flex flex-col h-full select-none transition-colors duration-300 ${De.primary}`,style:{backgroundColor:Ie,backdropFilter:ve.activeBlur>0?`blur(${ve.activeBlur}px)`:void 0},children:[
|
|
4
|
-
/* @__PURE__ */P("div",{className:"px-3 pt-3 flex justify-center gap-2",children:["focus","short","long"].map(e=>/* @__PURE__ */P("button",{onClick:()=>d(e),className:`px-3 py-1 text-sm font-bold rounded transition-colors ${t.mode===e?De.tabActive:De.tabInactive}`,children:L[e]},e))}),
|
|
5
|
-
/* @__PURE__ */T("div",{className:"text-center font-bold tabular-nums leading-none tracking-tight mt-3",style:{fontSize:"4.5rem"},children:[be,":",xe]}),
|
|
6
|
-
/* @__PURE__ */P("div",{className:"flex justify-center mt-3 mb-2",children:/* @__PURE__ */P("button",{onClick:()=>t.running?m():h(),className:"bg-surface px-12 py-3 rounded-md font-bold text-base shadow-[0_4px_0_rgba(0,0,0,0.12)] hover:shadow-[0_3px_0_rgba(0,0,0,0.12)] active:translate-y-1 active:shadow-none transition-all",style:{color:Le,letterSpacing:"0.08em"},children:t.running?"PAUSE":"START"})}),
|
|
7
|
-
/* @__PURE__ */P("div",{className:"px-3 py-3 text-center",children:fe?/* @__PURE__ */T(I,{children:[
|
|
8
|
-
/* @__PURE__ */T("div",{className:`text-xs leading-tight ${De.muted}`,children:["#",(fe.completed??0)+1]}),
|
|
9
|
-
/* @__PURE__ */P("div",{className:`text-base font-medium leading-tight truncate mt-0.5 ${De.primary}`,children:fe.name})]}):/* @__PURE__ */P("div",{className:`text-xs italic ${De.muted}`,children:"No task selected"})}),
|
|
10
|
-
/* @__PURE__ */T("div",{className:"px-3 mt-1 flex items-center justify-between",children:[
|
|
11
|
-
/* @__PURE__ */P("h3",{className:`text-base font-bold tracking-tight ${De.primary}`,children:"Tasks"}),
|
|
12
|
-
/* @__PURE__ */P("button",{className:`rounded p-1 transition-colors ${De.iconBtn}`,"aria-label":"Tasks menu",tabIndex:-1,children:/* @__PURE__ */P(N,{name:"more-vertical",look:"solid",className:"h-4 w-4"})})]}),
|
|
13
|
-
/* @__PURE__ */P("div",{className:`border-t mx-3 mt-2 ${De.divider}`}),
|
|
14
|
-
/* @__PURE__ */T("div",{className:"flex-1 px-3 py-3 space-y-2 overflow-y-auto",children:[ee.map(e=>{const t=e.id===te;/* @__PURE__ */
|
|
15
|
-
return T("div",{onClick:()=>oe(e.id),className:"bg-surface text-ink-strong rounded-md flex items-center pr-2 py-3 shadow-sm cursor-pointer transition-shadow hover:shadow-(--elevation-panel) "+(t?"border-l-4 border-gray-700 pl-2":"pl-3 border-l-4 border-transparent"),children:[
|
|
16
|
-
/* @__PURE__ */P("button",{onClick:t=>{var o;t.stopPropagation(),o=e.id,Q.toggleDone(o)},className:"shrink-0",children:e.done?/* @__PURE__ */P("svg",{className:"h-5 w-5",fill:"currentColor",viewBox:"0 0 20 20",style:{color:Le},children:/* @__PURE__ */P("path",{d:"M10 0a10 10 0 100 20 10 10 0 000-20zm-1 14.5l-4.5-4.5 1.4-1.4 3.1 3.1 6.1-6.1 1.4 1.4z"})}):/* @__PURE__ */P("svg",{className:"h-5 w-5 text-gray-300",fill:"none",stroke:"currentColor",strokeWidth:2,viewBox:"0 0 24 24",children:/* @__PURE__ */P("circle",{cx:"12",cy:"12",r:"10"})})}),
|
|
17
|
-
/* @__PURE__ */P("span",{className:"ml-3 flex-1 font-semibold truncate "+(e.done?"line-through text-gray-400":"text-gray-800"),children:e.name}),
|
|
18
|
-
/* @__PURE__ */T("span",{className:"text-sm tabular-nums mr-2 shrink-0",children:[
|
|
19
|
-
/* @__PURE__ */P("span",{className:"font-bold text-gray-500",children:e.completed??0}),
|
|
20
|
-
/* @__PURE__ */P("span",{className:"text-gray-400",children:" / "}),
|
|
21
|
-
/* @__PURE__ */P("span",{className:"text-gray-400",children:e.estimated??"–"})]}),
|
|
22
|
-
/* @__PURE__ */T("div",{className:"relative",children:[
|
|
23
|
-
/* @__PURE__ */P("button",{onClick:t=>{t.stopPropagation(),se(re===e.id?null:e.id)},className:"rounded p-1 bg-gray-100 hover:bg-gray-200",children:/* @__PURE__ */P(N,{name:"more-vertical",look:"solid",className:"h-4 w-4 text-ink-faint"})}),re===e.id&&/* @__PURE__ */P("div",{className:"absolute right-0 top-full mt-1 bg-white text-gray-800 rounded shadow-lg border border-gray-200 z-10 min-w-[110px] overflow-hidden",onClick:e=>e.stopPropagation(),children:/* @__PURE__ */P("button",{onClick:t=>{var o;t.stopPropagation(),o=e.id,Q.removeTask(o),te===o&&oe(null),se(null)},className:"block w-full px-3 h-8 text-sm text-left hover:bg-red-50 text-red-600",children:"Delete"})})]})]},e.id)}),ae?/* @__PURE__ */P(ce,{onSubmit:(e,t)=>{const o=e.trim();if(!o)return;const a=Q.addTask({name:o,estimated:t,completed:0,dueDate:q});te||oe(a),ne(!1)},onCancel:()=>ne(!1),accentColor:Le}):/* @__PURE__ */T("button",{onClick:()=>ne(!0),className:`w-full border-2 border-dashed rounded-md py-3 font-semibold flex items-center justify-center gap-2 transition-colors ${De.addTaskBtn}`,children:[
|
|
24
|
-
/* @__PURE__ */P(N,{name:"add-circle",className:"h-5 w-5",strokeWidth:2}),"Add Task"]})]}),
|
|
25
|
-
/* @__PURE__ */T("div",{className:`border-t px-3 py-3 flex items-center justify-center gap-5 text-sm ${De.softDivider}`,children:[
|
|
26
|
-
/* @__PURE__ */T("span",{className:De.secondary,children:["Pomos: ",
|
|
27
|
-
/* @__PURE__ */P("span",{className:`font-bold ${De.primary}`,children:ue}),
|
|
28
|
-
/* @__PURE__ */P("span",{className:De.muted,children:" / "}),
|
|
29
|
-
/* @__PURE__ */P("span",{className:`font-bold ${De.primary}`,children:de})]}),pe>0&&/* @__PURE__ */T("span",{className:De.secondary,children:["Finish At: ",
|
|
30
|
-
/* @__PURE__ */P("span",{className:`font-bold ${De.primary}`,children:ge}),
|
|
31
|
-
/* @__PURE__ */T("span",{className:De.muted,children:[" (",ke,"h)"]})]})]})]}),
|
|
32
|
-
/* @__PURE__ */P(_,{open:Ne,onClose:()=>Ce(!1),onSave:()=>{ye(Se),localStorage.setItem(A,JSON.stringify(Se)),f({pomodoro_settings:je}),Ce(!1)},configAppearance:Se,setConfigAppearance:we,configPrefs:je,setConfigPrefs:Be})]})}function _({open:e,onClose:o,onSave:a,configAppearance:n,setConfigAppearance:r,configPrefs:s,setConfigPrefs:i}){const l=(e,t)=>i(o=>({...o,[e]:t}));/* @__PURE__ */
|
|
33
|
-
return T(t,{open:e,onClose:o,title:"Pomodoro Settings",appearance:n,onAppearanceChange:r,onSave:a,children:[
|
|
34
|
-
/* @__PURE__ */T(z,{icon:/* @__PURE__ */P(se,{}),label:"TIMER",children:[
|
|
35
|
-
/* @__PURE__ */T("div",{children:[
|
|
36
|
-
/* @__PURE__ */P("p",{className:"text-sm font-bold text-gray-800 mb-2",children:"Time (minutes)"}),
|
|
37
|
-
/* @__PURE__ */T("div",{className:"grid grid-cols-3 gap-3",children:[
|
|
38
|
-
/* @__PURE__ */P(te,{label:"Pomodoro",value:s.focusMinutes,onChange:e=>l("focusMinutes",e),max:120}),
|
|
39
|
-
/* @__PURE__ */P(te,{label:"Short Break",value:s.shortBreakMinutes,onChange:e=>l("shortBreakMinutes",e),max:120}),
|
|
40
|
-
/* @__PURE__ */P(te,{label:"Long Break",value:s.longBreakMinutes,onChange:e=>l("longBreakMinutes",e),max:120})]})]}),
|
|
41
|
-
/* @__PURE__ */P(q,{label:"Auto Start Breaks",children:/* @__PURE__ */P(ne,{checked:s.autoStartBreaks,onChange:e=>l("autoStartBreaks",e)})}),
|
|
42
|
-
/* @__PURE__ */P(q,{label:"Auto Start Pomodoros",children:/* @__PURE__ */P(ne,{checked:s.autoStartPomodoros,onChange:e=>l("autoStartPomodoros",e)})}),
|
|
43
|
-
/* @__PURE__ */P(q,{label:"Long Break interval",children:/* @__PURE__ */P(oe,{value:s.longBreakInterval,onChange:e=>l("longBreakInterval",e),min:1,max:20,className:"w-14 text-center"})})]}),
|
|
44
|
-
/* @__PURE__ */T(z,{icon:/* @__PURE__ */P(ie,{}),label:"TASK",children:[
|
|
45
|
-
/* @__PURE__ */P(q,{label:"Auto Check Tasks",info:'If you enable "Auto Check Tasks", the active task will be automatically checked when the actual pomodoro count reaches the estimated count.',children:/* @__PURE__ */P(ne,{checked:s.autoCheckTasks,onChange:e=>l("autoCheckTasks",e)})}),
|
|
46
|
-
/* @__PURE__ */P(q,{label:"Check to Bottom",info:'If you enable "Check to Bottom", the checked task will be automatically moved to the bottom of the task list.',children:/* @__PURE__ */P(ne,{checked:s.checkToBottom,onChange:e=>l("checkToBottom",e)})})]}),
|
|
47
|
-
/* @__PURE__ */T(z,{icon:/* @__PURE__ */P(le,{}),label:"SOUND",children:[
|
|
48
|
-
/* @__PURE__ */P(q,{label:"Alarm Sound",children:/* @__PURE__ */T("div",{className:"flex items-center gap-2",children:[
|
|
49
|
-
/* @__PURE__ */P(ae,{value:s.alarmSound,onChange:e=>l("alarmSound",e),options:p.map(e=>({id:e.id,label:e.label}))}),"off"!==s.alarmSound&&/* @__PURE__ */P("button",{type:"button",onClick:()=>g(s.alarmSound,{volume:s.alarmVolume,repeat:1}),className:"px-2 py-1 text-2xs rounded border border-line-strong text-gray-600 hover:bg-gray-100",children:"Play"})]})}),
|
|
50
|
-
/* @__PURE__ */P(ee,{value:s.alarmVolume,onChange:e=>l("alarmVolume",e)}),
|
|
51
|
-
/* @__PURE__ */P(q,{label:"repeat",children:/* @__PURE__ */P(oe,{value:s.alarmRepeat,onChange:e=>l("alarmRepeat",e),min:1,max:5,className:"w-14 text-center"})}),
|
|
52
|
-
/* @__PURE__ */P(q,{label:"Focus Sound",children:/* @__PURE__ */T("div",{className:"flex items-center gap-2",children:[
|
|
53
|
-
/* @__PURE__ */P(ae,{value:s.focusSound,onChange:e=>l("focusSound",e),options:k}),"none"!==s.focusSound&&/* @__PURE__ */P("button",{type:"button",onClick:()=>f(s.focusSound,s.focusVolume),className:"px-2 py-1 text-2xs rounded border border-line-strong text-gray-600 hover:bg-gray-100",children:"Play"})]})}),
|
|
54
|
-
/* @__PURE__ */P(ee,{value:s.focusVolume,onChange:e=>l("focusVolume",e)})]})]})}function z({icon:e,label:t,children:o}){/* @__PURE__ */
|
|
55
|
-
return T("div",{className:"border-t border-gray-200 pt-3 first:border-0 first:pt-0",children:[
|
|
56
|
-
/* @__PURE__ */T("div",{className:"flex items-center gap-2 mb-3 text-ink-faintest",children:[e,
|
|
57
|
-
/* @__PURE__ */P("span",{className:"text-xs font-bold tracking-[0.15em]",children:t})]}),
|
|
58
|
-
/* @__PURE__ */P("div",{className:"space-y-3",children:o})]})}function q({label:e,info:t,children:o}){/* @__PURE__ */
|
|
59
|
-
return T("div",{className:"flex items-center justify-between gap-3",children:[
|
|
60
|
-
/* @__PURE__ */T("div",{className:"flex items-center gap-2 min-w-0",children:[
|
|
61
|
-
/* @__PURE__ */P("span",{className:"text-sm font-semibold text-gray-800",children:e}),t&&/* @__PURE__ */P(re,{title:t})]}),
|
|
62
|
-
/* @__PURE__ */P("div",{className:"shrink-0",children:o})]})}function ee({value:e,onChange:t}){/* @__PURE__ */
|
|
63
|
-
return T("div",{className:"flex items-center justify-end gap-3",children:[
|
|
64
|
-
/* @__PURE__ */P("span",{className:"text-xs text-gray-400 w-7 text-right tabular-nums",children:e}),
|
|
65
|
-
/* @__PURE__ */P("input",{type:"range",min:0,max:100,value:e,onChange:e=>t(parseInt(e.target.value,10)),className:"w-40 accent-blue-500"})]})}function te({label:e,value:t,onChange:o,min:a=1,max:n=99}){/* @__PURE__ */
|
|
66
|
-
return T("label",{className:"flex flex-col",children:[
|
|
67
|
-
/* @__PURE__ */P("span",{className:"text-xs font-semibold text-gray-500 mb-1",children:e}),
|
|
68
|
-
/* @__PURE__ */P(oe,{value:t,onChange:o,min:a,max:n})]})}function oe({value:e,onChange:t,min:o=1,max:a=99,className:n=""}){/* @__PURE__ */
|
|
69
|
-
return P("input",{type:"number",min:o,max:a,value:e,onChange:e=>t(Math.max(o,Math.min(a,parseInt(e.target.value,10)||o))),className:`bg-gray-100 border-0 rounded-md px-2 h-8 text-sm font-medium text-ink-strong focus:outline-none focus:ring-2 focus:ring-blue-500 w-full ${n}`})}function ae({value:e,onChange:t,options:o}){/* @__PURE__ */
|
|
70
|
-
return T("div",{className:"relative",children:[
|
|
71
|
-
/* @__PURE__ */P("select",{value:e,onChange:e=>t(e.target.value),className:"appearance-none bg-gray-100 border-0 rounded-md pl-3 pr-8 h-8 text-sm font-medium text-ink-strong focus:outline-none focus:ring-2 focus:ring-blue-500 cursor-pointer",children:o.map(e=>/* @__PURE__ */P("option",{value:e.id,children:e.label},e.id))}),
|
|
72
|
-
/* @__PURE__ */P(N,{name:"chevron-down",className:`absolute right-2 top-1/2 -translate-y-1/2 h-3.5 w-3.5 pointer-events-none ${b}`,strokeWidth:2.5})]})}function ne({checked:e,onChange:t}){/* @__PURE__ */
|
|
73
|
-
return P("button",{type:"button",role:"switch","aria-checked":e,onClick:()=>t(!e),className:"relative inline-flex h-6 w-11 items-center rounded-full transition-colors "+(e?"bg-emerald-500":"bg-gray-300"),children:/* @__PURE__ */P("span",{className:"absolute h-5 w-5 rounded-full bg-white shadow transition-transform "+(e?"translate-x-[22px]":"translate-x-0.5")})})}function re({title:e}){/* @__PURE__ */
|
|
74
|
-
return P("span",{title:e,className:"inline-flex items-center justify-center w-4 h-4 rounded-full bg-gray-300 text-on-accent text-3xs font-bold cursor-help",children:"i"})}function se(){/* @__PURE__ */
|
|
75
|
-
return T("svg",{className:"h-3.5 w-3.5",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,children:[
|
|
76
|
-
/* @__PURE__ */P("circle",{cx:"12",cy:"12",r:"9"}),
|
|
77
|
-
/* @__PURE__ */P("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M12 7v5l3 2"})]})}function ie(){/* @__PURE__ */
|
|
78
|
-
return T("svg",{className:"h-3.5 w-3.5",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,children:[
|
|
79
|
-
/* @__PURE__ */P("rect",{x:"4",y:"4",width:"16",height:"16",rx:"2"}),
|
|
80
|
-
/* @__PURE__ */P("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M9 12l2 2 4-4"})]})}function le(){/* @__PURE__ */
|
|
81
|
-
return T("svg",{className:"h-3.5 w-3.5",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,children:[
|
|
82
|
-
/* @__PURE__ */P("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M11 5L6 9H2v6h4l5 4V5z"}),
|
|
83
|
-
/* @__PURE__ */P("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15.5 8.5a5 5 0 010 7M19 5a9 9 0 010 14"})]})}function ce({onSubmit:e,onCancel:t,accentColor:o}){const[a,n]=j(""),[r,s]=j(1),i=()=>e(a,r);/* @__PURE__ */
|
|
84
|
-
return T("div",{className:"bg-surface text-ink-strong rounded-md p-3 shadow-(--elevation-panel)",children:[
|
|
85
|
-
/* @__PURE__ */P("input",{autoFocus:!0,value:a,onChange:e=>n(e.target.value),placeholder:"What are you working on?",onKeyDown:e=>{"Enter"===e.key&&i(),"Escape"===e.key&&t()},className:"w-full text-base font-medium bg-transparent border-0 outline-none placeholder-gray-400"}),
|
|
86
|
-
/* @__PURE__ */T("div",{className:"flex items-center justify-between mt-2",children:[
|
|
87
|
-
/* @__PURE__ */P("span",{className:"text-xs font-semibold text-gray-500",children:"Est Pomodoros"}),
|
|
88
|
-
/* @__PURE__ */P("input",{type:"number",min:1,max:20,value:r,onChange:e=>s(Math.max(1,Math.min(20,parseInt(e.target.value,10)||1))),className:"w-16 bg-gray-100 rounded px-2 py-1 text-sm text-right border-0 focus:outline-none focus:ring-2 focus:ring-blue-500"})]}),
|
|
89
|
-
/* @__PURE__ */T("div",{className:"flex gap-2 mt-3 justify-end",children:[
|
|
90
|
-
/* @__PURE__ */P("button",{onClick:t,className:"px-3 py-1 text-sm text-gray-500 hover:bg-gray-100 rounded",children:"Cancel"}),
|
|
91
|
-
/* @__PURE__ */P("button",{onClick:i,className:"px-4 py-1 text-sm font-semibold text-white rounded shadow-sm",style:{backgroundColor:o},children:"Save"})]})]})}export{Q as default};
|
package/dist/chunk-EEGTFJUQ.js
DELETED
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import{Tree as e,TreeRow as n,TreeGroup as l}from"./chunk-OLCRYT3N.js";import{MarqueeBox as a}from"./chunk-IC72MGON.js";import{EmptyState as i}from"./chunk-T2TZBTSM.js";import{ImageLightbox as r}from"./chunk-436PJFHC.js";import{DescriptionList as t}from"./chunk-SACUSHVN.js";import{Drawer as o}from"./chunk-UP4HLGMZ.js";import{Breadcrumbs as d}from"./chunk-QMSINDXL.js";import{useGridSelection as s}from"./chunk-VLKDWKVR.js";import{useMarquee as c}from"./chunk-OLFYNMTD.js";import{ROOT_KEY as u,mediaLibraryMenu as m}from"./chunk-VQ4X3OBR.js";import{useMediaMoveItems as h}from"./chunk-NOGSS432.js";import{RenameField as p}from"./chunk-GEZM6ARD.js";import{NativeSelect as f}from"./chunk-TM4CRQ3W.js";import{MediaUploadGrid as g}from"./chunk-OG53D3R5.js";import{MediaUsedInList as v}from"./chunk-FQ4IRBMA.js";import{Segmented as k}from"./chunk-HNIIDDLJ.js";import{copyToClipboard as y}from"./chunk-Y7KDCC6E.js";import{Checkbox_default as b}from"./chunk-CGZBDI6C.js";import{useContextMenu as w,ContextMenu as x}from"./chunk-6FZ5JTBY.js";import{Banner as C}from"./chunk-N3R6N7LG.js";import{Input_default as N}from"./chunk-6RK6R3RY.js";import{DropdownMenu as I}from"./chunk-SFULX4E3.js";import{IconButton_default as D}from"./chunk-SV5RRBVA.js";import{useFileIntake as S,FileIntakeAlert as j}from"./chunk-V4XR4MOS.js";import{ColoredBadge as z}from"./chunk-CJHYOHMU.js";import{Button_default as T}from"./chunk-EVYD6UFQ.js";import{Icon as F}from"./chunk-XZXFUZIK.js";import{Tooltip as O}from"./chunk-SOZCWT6I.js";import{buttonClasses as L}from"./chunk-UQYNPYF4.js";import{usePlotWidth as M}from"./chunk-MAFUXCPZ.js";import{useShellStrings as R}from"./chunk-JSHMIMAJ.js";import{useRef as A,useMemo as E,useCallback as P,useState as U,useEffect as B}from"react";import{jsxs as K,Fragment as H,jsx as J}from"react/jsx-runtime";var V="application/x-efficient-media-files",G="application/x-efficient-media-folder",Y="application/x-efficient-media-file";function Z(e){if(!e||!Array.from(e.types).includes(Y))return null;try{const n=JSON.parse(e.getData(Y));if(n&&"string"==typeof n.id&&"string"==typeof n.url&&"string"==typeof n.name&&("image"===n.kind||"video"===n.kind))return{id:n.id,url:n.url,kind:n.kind,name:n.name}}catch{}return null}var Q={type:"all",use:"any",sort:"newest"},X={lock:/* @__PURE__ */J(F,{name:"lock","aria-hidden":"true",className:"h-4 w-4"}),folder:/* @__PURE__ */J(F,{name:"folder","aria-hidden":"true",className:"h-4 w-4"}),folderOpen:/* @__PURE__ */J(F,{name:"folder-open","aria-hidden":"true",className:"h-4 w-4"}),folderPlus:/* @__PURE__ */J(F,{name:"folder-plus","aria-hidden":"true",className:"h-4 w-4"}),trash:/* @__PURE__ */J(F,{name:"trash","aria-hidden":"true",className:"h-4 w-4"}),upload:/* @__PURE__ */J(F,{name:"upload","aria-hidden":"true",className:"h-4 w-4"}),search:/* @__PURE__ */J(F,{name:"search","aria-hidden":"true",className:"h-4 w-4"}),grid:/* @__PURE__ */J(F,{name:"grid","aria-hidden":"true",className:"h-4 w-4"}),list:/* @__PURE__ */J(F,{name:"list","aria-hidden":"true",className:"h-4 w-4"}),more:/* @__PURE__ */J(F,{name:"more","aria-hidden":"true",className:"h-4 w-4"}),copy:/* @__PURE__ */J(F,{name:"copy","aria-hidden":"true",className:"h-4 w-4"}),edit:/* @__PURE__ */J(F,{name:"edit","aria-hidden":"true",className:"h-4 w-4"}),swap:/* @__PURE__ */J(F,{name:"swap","aria-hidden":"true",className:"h-4 w-4"}),crop:/* @__PURE__ */J(F,{name:"crop","aria-hidden":"true",className:"h-4 w-4"}),external:/* @__PURE__ */J(F,{name:"external","aria-hidden":"true",className:"h-4 w-4"}),undo:/* @__PURE__ */J(F,{name:"undo","aria-hidden":"true",className:"h-4 w-4"})},$={link:/* @__PURE__ */J(F,{name:"link","aria-hidden":"true",className:"h-3 w-3"}),email:/* @__PURE__ */J(F,{name:"email","aria-hidden":"true",className:"h-3 w-3"}),lock:/* @__PURE__ */J(F,{name:"lock","aria-hidden":"true",className:"h-3 w-3"}),clock:/* @__PURE__ */J(F,{name:"clock","aria-hidden":"true",className:"h-3 w-3"})};function W(F){const{mode:Z="manage",layout:W="auto",location:q,onLocationChange:_,folders:ee,products:ne,allFilesCount:le,trashCount:ae,files:ie,query:re,onQueryChange:te,filters:oe=Q,onFiltersChange:de,extraFilters:se,view:ce="grid",onViewChange:ue,selectedIds:me,onSelectionChange:he,usedIn:pe,denied:fe={},accept:ge="image/*,video/*",maxSizeBytes:ve,busy:ke,progress:ye,onUpload:be,onNewFolder:we,onRename:xe,onMove:Ce,onTrash:Ne,onDeleteFolder:Ie,onRestore:De,onDeleteForever:Se,onEmptyTrash:je,onReplace:ze,onCropEdit:Te,onOpenInDesign:Fe,onChoose:Oe,onCancel:Le,pickNote:Me,onDragOut:Re,className:Ae=""}=F,Ee=R().mediaLibrary,Pe=R().media,Ue="pick"===Z,Be=!Ue,Ke=A(null),He=M(Ke,"phone"===W?343:1200),Je="phone"===W||"auto"===W&&He<640,Ve=E(()=>function(e=[]){const n=/* @__PURE__ */new Map,l=(e,a)=>{for(const i of e){const e=[...a,i];n.set(i.id,{node:i,path:e}),i.children&&l(i.children,e)}};return l(e,[]),n}(ne),[ne]),Ge=E(()=>new Map(ee.map(e=>[e.id,e])),[ee]),Ye=E(()=>{const e=/* @__PURE__ */new Map;for(const n of ee){const l=n.parentId&&Ge.has(n.parentId)?n.parentId:null;e.set(l,[...e.get(l)??[],n])}return e},[ee,Ge]),Ze=P(e=>{const n=[];for(let l=e?Ge.get(e):void 0;l&&(n.unshift(l),!(n.length>ee.length));l=l.parentId?Ge.get(l.parentId):void 0);return n},[Ge,ee.length]),Qe=P((e,n)=>Ze(e).some(e=>e.id===n),[Ze]),[Xe,$e]=U(()=>/* @__PURE__ */new Set(["@files"])),We=e=>$e(n=>{const l=new Set(n);return l.has(e)?l.delete(e):l.add(e),l}),qe=P(e=>{$e(n=>e.every(e=>n.has(e))?n:/* @__PURE__ */new Set([...n,...e]))},[]),_e="files"===(en=q).place?`files:${en.folderId??""}`:"products"===en.place?`products:${en.nodeId??""}`:"trash";var en;B(()=>{if("files"===q.place)qe(["@files",...Ze(q.folderId).slice(0,-1).map(e=>e.id)]);else if("products"===q.place){const e=q.nodeId?Ve.get(q.nodeId)?.path??[]:[];qe(["@products",...e.slice(0,-1).map(e=>`p:${e.id}`)])}},[_e]);const nn="products"===q.place,ln="trash"===q.place,an="files"===q.place,rn=an?q.folderId:null,tn=nn&&q.nodeId?Ve.get(q.nodeId)?.path[0]:void 0,on=e=>e?.sharedFrom?`${Ee.readOnly} ${Ee.editedAtHq(e.sharedFrom)}`:Ee.readOnly,dn=E(()=>ie.map(e=>e.id),[ie]),sn=E(()=>new Map(ie.map(e=>[e.id,e])),[ie]),cn=s(dn),un=E(()=>dn.filter(e=>cn.selected.has(e)),[dn,cn.selected]),mn=1===un.length?sn.get(un[0]):void 0,hn=A(!0);B(()=>{hn.current?hn.current=!1:cn.clear()},[_e]);const pn=me?.join("\0");B(()=>{me&&cn.setSelection(me)},[pn]);const fn=A(pn??""),gn=un.join("\0");B(()=>{fn.current!==gn&&(fn.current=gn,he?.(un))},[gn]);const vn=(e,n={})=>{Ue?cn.select(e):cn.select(e,{ctrl:!(!n.ctrlKey&&!n.metaKey),shift:!!n.shiftKey})},[kn,yn]=U(null),bn=e=>{const n=kn;if(yn(null),!n||null==e)return;e!==("folder"===n.kind?Ge.get(n.id)?.name:sn.get(n.id)?.name)&&xe?.(n,e)},wn=async e=>{if(!we)return;const n=await we(e);qe(["@files",...e?[e]:[]]),"string"==typeof n&&yn({kind:"folder",id:n})},xn=P(e=>{const n=[],l=n=>{if("files"===e.kind)return n===rn&&an?Ee.alreadyHere:void 0;const l=Ge.get(e.id);return n===e.id||n&&Qe(n,e.id)?Ee.notIntoItself:(l?.parentId??null)===n?Ee.folderAlreadyHere:void 0};n.push({key:u,label:Ee.allFiles,disabledReason:l(null)});const a=(e,i)=>{for(const r of Ye.get(e)??[])n.push({key:r.id,label:r.name,depth:i,disabledReason:l(r.id)}),a(r.id,i+1)};return a(null,1),n},[Ye,Ge,an,Qe,rn,Ee]),Cn=P(e=>{const n=new Set(e.map(e=>sn.get(e)?.kind??"image"));return 1===n.size?[...n][0]:"file"},[sn]),[Nn,In]=U(null),Dn={words:Ee,media:Pe,denied:fe,moveTargets:xn,kindOf:Cn,urlOf:e=>sn.get(e)?.url,newSubfolder:we&&Be?e=>{wn(e)}:void 0,rename:xe&&Be?e=>{"file"!==e.kind||cn.isSelected(e.id)||cn.select(e.id),yn(e)}:void 0,move:Ce&&Be?Ce:void 0,trash:Ne&&Be?Ne:void 0,deleteFolder:Ie&&Be?Ie:void 0,folderNotEmpty:e=>!!Ge.get(e)?.notEmpty,replace:ze&&Be?ze:void 0,copyUrl:e=>{const n=sn.get(e)?.url;n&&y(Ee.urlLabel,n)},openInDesign:Fe,restore:De,deleteForever:Se},Sn=e=>m(e,Dn),jn=w(),zn=(e,n)=>{Ue||(cn.isSelected(e)||cn.select(e),jn.open(n,(e=>{const n=cn.isSelected(e)?un:[e];return nn?{kind:"render",id:e}:ln?{kind:"trashed",ids:n}:{kind:"files",ids:n}})(e)))},[Tn,Fn]=U(null),[On,Ln]=U(null),[Mn,Rn]=U(null);B(()=>{if(!On&&!Tn)return;const e=()=>{Ln(null),Fn(null)};return window.addEventListener("dragend",e),window.addEventListener("drop",e),()=>{window.removeEventListener("dragend",e),window.removeEventListener("drop",e)}},[On,Tn]);const An=(e,n)=>Array.from(e.dataTransfer?.types??[]).includes(n),En=(e,n)=>!(!Ce||fe.move||Ue)&&(!!An(e,V)||!(!An(e,G)||!Mn)&&(n!==Mn&&!(n&&Qe(n,Mn)))),Pn=(e,n)=>({onDragEnter:l=>{En(l,n)&&(l.preventDefault(),Fn(e))},onDragOver:l=>{En(l,n)&&(l.preventDefault(),l.dataTransfer.dropEffect="move",Tn!==e&&Fn(e))},onDragLeave:n=>{const l=n.relatedTarget;l&&n.currentTarget.contains(l)||Fn(n=>n===e?null:n)},onDrop:e=>{if(En(e,n))if(e.preventDefault(),Fn(null),An(e,V)){let l;try{l=JSON.parse(e.dataTransfer.getData(V))}catch{l=null}Array.isArray(l)&&l.length&&Ce({kind:"files",ids:l.map(String)},n)}else Mn&&(Ce({kind:"folder",id:Mn},n),Rn(null))}}),Un=e=>{const n=e=>An(e,V)||An(e,G)||An(e,"Files");return{onDragEnter:l=>{n(l)&&Ln(e)},onDragOver:l=>{n(l)&&On!==e&&Ln(e)},onDragLeave:n=>{const l=n.relatedTarget;l&&n.currentTarget.contains(l)||Ln(n=>n===e?null:n)}}},Bn=(e,n,l)=>/* @__PURE__ */J(O,{side:"right",content:On===e?Ee.noDropProducts:on(l),open:On===e||!On&&void 0,children:/* @__PURE__ */J("span",{children:n})}),Kn=e=>({onContextMenu:n=>{jn.open(n,e)}}),Hn=(e,a,i)=>e.map(e=>{const r=`p:${e.id}`,t=i??e,o=Xe.has(r),d=e.children?.length?e.children:null;/* @__PURE__ */
|
|
2
|
-
return K("div",{role:"none",className:"contents",children:[
|
|
3
|
-
/* @__PURE__ */J(n,{label:Bn(r,e.name,t),level:a,icon:d&&o?X.folderOpen:X.folder,count:e.count,countLabel:null!=e.count?e.countLabel??Ee.fileCount(e.count):void 0,selected:nn&&q.nodeId===e.id,expanded:d?o:void 0,onToggle:d?()=>We(r):void 0,onSelect:()=>_({place:"products",nodeId:e.id}),rowProps:{"data-media-row":r,...Un(r),...Be?Kn({kind:"product-node",id:e.id}):{}}}),d&&o&&/* @__PURE__ */J(l,{children:Hn(d,a+1,t)})]},e.id)}),Jn=(e,a)=>(Ye.get(e)??[]).map(e=>{const i=Ye.get(e.id),r=Xe.has(e.id),t="folder"===kn?.kind&&kn.id===e.id,o=Sn({kind:"folder",id:e.id});/* @__PURE__ */
|
|
4
|
-
return K("div",{role:"none",className:"contents",children:[
|
|
5
|
-
/* @__PURE__ */J(n,{label:e.name,level:a,icon:i&&r?X.folderOpen:X.folder,count:e.count,countLabel:null!=e.count?e.countLabel??Ee.fileCount(e.count):void 0,selected:t||an&&q.folderId===e.id,expanded:i?r:void 0,onToggle:i?()=>We(e.id):void 0,onSelect:()=>_({place:"files",folderId:e.id}),drop:Tn===e.id?"into":void 0,dragging:Mn===e.id,draggable:Be&&!!Ce&&!fe.move,rename:t?/* @__PURE__ */J(p,{value:e.name,label:Ee.folderName,onDone:bn}):void 0,actions:Be&&o.length?/* @__PURE__ */J(I,{align:"end","aria-label":Ee.folderActions,trigger:X.more,items:o}):void 0,rowProps:{"data-media-row":e.id,...Pn(e.id,e.id),...Be?Kn({kind:"folder",id:e.id}):{},...Be&&Ce&&!fe.move?{draggable:!0,onDragStart:n=>{n.dataTransfer.effectAllowed="move",n.dataTransfer.setData(G,e.id),Rn(e.id)},onDragEnd:()=>{Rn(null),Fn(null)}}:{}}}),i&&r&&/* @__PURE__ */J(l,{children:Jn(e.id,a+1)})]},e.id)}),Vn=Xe.has("@files"),Gn=Xe.has("@products"),Yn=/* @__PURE__ */K(e,{"aria-label":Ee.folders,children:[ne&&/* @__PURE__ */K(H,{children:[
|
|
6
|
-
/* @__PURE__ */J(n,{label:Bn("@products",Ee.products),level:1,icon:X.lock,badge:{label:Ee.readOnlyBadge,tone:"neutral"},expanded:ne.length?Gn:void 0,onToggle:()=>We("@products"),selected:nn&&null==q.nodeId,onSelect:()=>_({place:"products",nodeId:null}),rowProps:{"data-media-row":"@products",...Un("@products")}}),Gn&&ne.length>0&&/* @__PURE__ */J(l,{children:Hn(ne,2)})]}),
|
|
7
|
-
/* @__PURE__ */J(n,{label:Ee.allFiles,level:1,icon:Vn?X.folderOpen:X.folder,count:le,countLabel:null!=le?Ee.fileCount(le):void 0,expanded:Ye.get(null)?.length?Vn:void 0,onToggle:()=>We("@files"),selected:an&&null==q.folderId,onSelect:()=>_({place:"files",folderId:null}),drop:"@files"===Tn?"into":void 0,rowProps:{"data-media-row":"@files",...Pn("@files",null)}}),Vn&&(Ye.get(null)?.length??0)>0&&/* @__PURE__ */J(l,{children:Jn(null,2)}),Be&&/* @__PURE__ */J(n,{label:Ee.trash,level:1,icon:X.trash,count:ae,countLabel:null!=ae?Ee.fileCount(ae):void 0,selected:ln,onSelect:()=>_({place:"trash"}),rowProps:{"data-media-row":"@trash"}})]}),Zn=(()=>{if(ln)return[{label:Ee.trash}];if(nn){const e=q.nodeId?Ve.get(q.nodeId)?.path??[]:[];return[{label:Ee.products,onClick:e.length?()=>_({place:"products",nodeId:null}):void 0},...e.map((n,l)=>({label:n.name,onClick:l<e.length-1?()=>_({place:"products",nodeId:n.id}):void 0}))]}const e=Ze(rn);return[{label:Ee.allFiles,onClick:e.length?()=>_({place:"files",folderId:null}):void 0},...e.map((n,l)=>({label:n.name,onClick:l<e.length-1?()=>_({place:"files",folderId:n.id}):void 0}))]})(),Qn=nn?Ee.readOnly:fe.upload,Xn=!!be&&!ln&&!Qn,$n=S({accept:ge,maxSizeBytes:ve,multiple:!0,disabled:!Xn,onAccept:e=>be?.(e,rn)}),Wn=nn?Ee.noProductFolder:fe.newFolder,qn=e=>e?{"aria-disabled":!0,disabledReason:e}:{},_n=/* @__PURE__ */K("div",{className:"flex flex-wrap items-center gap-2",children:[Be&&we&&!ln&&/* @__PURE__ */J(T,{variant:"secondary",size:"sm",leftIcon:X.folderPlus,onClick:()=>{wn(rn)},...qn(Wn),children:Ee.newFolder}),be&&!ln&&/* @__PURE__ */J(T,{variant:"primary",size:"sm",leftIcon:X.upload,onClick:()=>$n.open(),...qn(Qn),children:Ee.upload}),Be&&ln&&je&&ie.length>0&&/* @__PURE__ */J(T,{variant:"danger",size:"sm",onClick:je,...qn(fe.deleteForever),children:Ee.emptyTrash})]}),el=(e,n,l,a,i)=>/* @__PURE__ */J("div",{style:{width:Je?void 0:i,flex:Je?"1 1 120px":"0 0 auto",minWidth:0},children:/* @__PURE__ */J(f,{size:"sm","aria-label":e,value:n,onChange:a,options:l})},e),nl=e=>n=>de?.({...oe,[e]:n}),ll=/* @__PURE__ */K("div",{className:"flex flex-wrap items-center gap-2",children:[te&&/* @__PURE__ */J("div",{style:{flex:"1 1 200px",minWidth:0},children:/* @__PURE__ */J(N,{size:"sm",type:"search",leftIcon:X.search,placeholder:nn?Ee.searchProducts:Ee.search,"aria-label":nn?Ee.searchProducts:Ee.search,value:re??"",onChange:e=>te(e.target.value)})}),de&&el(Ee.mediaType,oe.type,[{value:"all",label:Ee.allTypes},{value:"image",label:Ee.images},{value:"video",label:Ee.videos},{value:"svg",label:"SVG"},{value:"gif",label:"GIF"}],nl("type"),130),de&&!nn&&!ln&&el(Ee.use,oe.use,[{value:"any",label:Ee.anyUse},{value:"email",label:Ee.emailOnly},{value:"website",label:Ee.websiteOnly},{value:"unused",label:Ee.notUsed}],nl("use"),130),de&&Be&&el(Ee.sort,oe.sort,[{value:"newest",label:Ee.newest},{value:"name",label:Ee.byName},{value:"size",label:Ee.bySize}],nl("sort"),110),se?.map(e=>el(e.label,e.value,e.options,e.onChange,120)),ue&&/* @__PURE__ */J(k,{size:"sm",label:Ee.view,value:ce,onChange:ue,options:[{value:"grid",label:Ee.grid,icon:X.grid},{value:"list",label:Ee.list,icon:X.list}]})]}),al=e=>{const n=[];return null!=e.trashedDaysAgo&&n.push({key:"t",label:Ee.daysAgo(e.trashedDaysAgo),count:e.trashedDaysAgo,icon:$.clock,tone:"neutral"}),e.usedCount&&n.push({key:"u",label:Ee.used(e.usedCount),count:e.usedCount,icon:$.link,tone:"active"}),e.email&&n.push({key:"e",label:Ee.email,icon:$.email,tone:"queued"}),e.private&&n.push({key:"p",label:Ee.private,icon:$.lock,tone:"neutral"}),n},il=e=>al(e).map(e=>/* @__PURE__ */J(z,{tone:e.tone,size:"xs",children:e.label},e.key)),rl=Be&&an&&!!Ce&&!fe.move,tl=!!Re&&!ln,ol=e=>!tl||e.private||e.pickDisabledReason?void 0:JSON.stringify({id:e.id,url:e.url,kind:"video"===e.kind?"video":"image",name:e.name}),dl=ie.map(e=>({id:e.id,url:e.thumbUrl??e.url,name:e.name,kind:e.kind,caption:e.name,badges:al(e),dragData:rl?JSON.stringify(cn.isSelected(e.id)?un:[e.id]):ol(e),...rl&&ol(e)?{dragAlso:{[Y]:ol(e)}}:{}})),sl=Je?Math.max(72,Math.floor((He-24-16-1)/3)):112,cl=A(null),ul=c({containerRef:cl,enabled:Be&&!Je&&ie.length>0,selected:cn.selected,setSelection:e=>cn.setSelection(e),clearSelection:cn.clear}),ml=e=>{if(Ue){const n=sn.get(e);return void(!n||n.private||n.pickDisabledReason||Oe?.(n))}const n=dn.indexOf(e);n>=0&&In(n)},hl=ie.length?null:re?/* @__PURE__ */J(i,{variant:"dashed",title:Ee.noMatches}):nn?/* @__PURE__ */J(i,{variant:"dashed",title:Ee.emptyProducts,description:on(tn)}):ln?/* @__PURE__ */J(i,{variant:"dashed",title:Ee.trashEmpty}):!Xn||Ue?/* @__PURE__ */J(i,{variant:"dashed",title:Ee.emptyFolder}):null,pl="list"===ce&&ie.length>0,fl=hl??(pl?/* @__PURE__ */J("ul",{role:"listbox","aria-multiselectable":Be||void 0,"aria-label":Ee.folders,className:"flex flex-col gap-1",children:ie.map(e=>/* @__PURE__ */K("li",{role:"option","aria-selected":cn.isSelected(e.id),tabIndex:0,"data-grid-item":"","data-grid-id":e.id,onClick:n=>vn(e.id,n),onDoubleClick:()=>ml(e.id),onContextMenu:n=>zn(e.id,n),draggable:!!ol(e)||void 0,onDragStart:ol(e)?n=>{n.dataTransfer.effectAllowed="link",n.dataTransfer.setData(Y,ol(e)),Re("start")}:void 0,onDragEnd:ol(e)?e=>Re("none"===e.dataTransfer.dropEffect?"cancelled":"dropped"):void 0,onKeyDown:n=>{"Enter"!==n.key&&" "!==n.key||(n.preventDefault(),vn(e.id,n))},className:"flex h-12 cursor-pointer items-center gap-3 rounded-md px-2 text-sm rosh-focus-ring focus-visible:ring-2 focus-visible:ring-[color:var(--rosh-focus-ring-solid)] "+(cn.isSelected(e.id)?"bg-accent-tint text-blue-700":"text-ink hover:bg-gray-100"),children:[
|
|
8
|
-
/* @__PURE__ */J("img",{src:e.thumbUrl??e.url,alt:"",className:"h-10 w-10 shrink-0 rounded bg-gray-100 object-contain"}),
|
|
9
|
-
/* @__PURE__ */J("span",{className:"min-w-0 flex-1 truncate",children:e.name}),
|
|
10
|
-
/* @__PURE__ */J("span",{className:"flex shrink-0 items-center gap-1",children:il(e)}),e.sizeLabel&&/* @__PURE__ */J("span",{className:"w-16 shrink-0 text-right text-xs text-ink-faint",children:e.sizeLabel})]},e.id))}):/* @__PURE__ */J(g,{items:dl,readOnly:!Xn||Ue,onFiles:Xn&&!Ue?e=>be(e,rn):void 0,accept:ge,maxSizeBytes:ve,busy:ke,progress:ye,fit:"contain",thumbSize:sl,dragType:rl?V:tl?Y:void 0,onDragOutChange:tl?e=>Re(e):void 0,selected:cn.selected,onItemClick:vn,onItemDoubleClick:ml,onItemContextMenu:Be?zn:void 0,menuOnMedia:Be})),gl=h({count:un.length,kind:Cn(un),targets:xn({kind:"files",ids:un}),onPick:e=>Ce?.({kind:"files",ids:un},e.key===u?null:e.key)}),vl=L({variant:"secondary",size:"sm"}),kl=/* @__PURE__ */J(I,{align:"start",triggerClassName:vl,trigger:/* @__PURE__ */K(H,{children:[X.folder,Ee.moveTo]}),items:gl,disabled:!!fe.move}),yl=Be&&un.length>1&&!nn?/* @__PURE__ */K("div",{"data-media-bulk":"",className:"flex flex-wrap items-center gap-2 rounded-lg border border-line px-3 py-2",children:[
|
|
11
|
-
/* @__PURE__ */J(b,{checked:un.length===ie.length,indeterminate:un.length<ie.length,onChange:e=>e?cn.selectAll():cn.clear(),label:Ee.selected(un.length)}),/* @__PURE__ */K(H,ln?{children:[De&&/* @__PURE__ */J(T,{variant:"secondary",size:"sm",leftIcon:X.undo,onClick:()=>De(un),...qn(fe.restore),children:Ee.restore}),Se&&/* @__PURE__ */J(T,{variant:"secondary-danger",size:"sm",onClick:()=>Se(un),...qn(fe.deleteForever),children:Ee.deleteForever})]}:{children:[Ce&&kl,xe&&/* @__PURE__ */J(T,{variant:"secondary",size:"sm",leftIcon:X.edit,disabled:!0,children:Ee.rename}),Ne&&/* @__PURE__ */J(T,{variant:"secondary",size:"sm",leftIcon:X.trash,onClick:()=>Ne({kind:"files",ids:un}),...qn(fe.trash),children:Ee.moveFilesToTrash(un.length)})]}),
|
|
12
|
-
/* @__PURE__ */J(T,{variant:"ghost",size:"sm",onClick:cn.clear,children:Ee.clearSelection})]}):null,bl=e=>{const n=[],l=(e,l,a)=>{null!=a&&""!==a&&n.push({key:e,label:l,value:a})},a="file"===kn?.kind&&kn.id===e.id;l("name",Ee.name,a?/* @__PURE__ */J(p,{value:e.name,label:Ee.fileName,onDone:bn}):e.name),l("type",Ee.type,e.typeLabel),l("size",Ee.size,e.sizeLabel),l("resolution",Ee.resolution,e.resolution),nn?(l("design",Ee.design,e.design),l("finish",Ee.finish,e.finish),l("angle",Ee.angleLug,e.angleLug),l("owner",Ee.owner,e.owner)):(l("added",Ee.addedBy,e.addedBy),l("folder",Ee.folder,e.folderPath)),l("used",Ee.usedIn,null!=e.usedCount?Ee.places(e.usedCount):void 0);const i=m({kind:"files",ids:[e.id]},Dn).find(e=>"submenu"===e.type);/* @__PURE__ */
|
|
13
|
-
return K("div",{"data-media-details":"",className:"flex flex-col gap-3",children:[
|
|
14
|
-
/* @__PURE__ */J("img",{src:e.url,alt:e.name,className:"aspect-square w-full rounded-lg bg-gray-100 object-contain"}),nn&&/* @__PURE__ */J(C,{tone:"neutral",title:Ee.readOnlyBadge,children:on(tn)}),
|
|
15
|
-
/* @__PURE__ */J(t,{size:"sm",columns:1,items:n}),!ln&&/* @__PURE__ */K("div",{className:"flex gap-2",children:[
|
|
16
|
-
/* @__PURE__ */J("div",{style:{flex:"1 1 0",minWidth:0},children:/* @__PURE__ */J(N,{size:"sm",readOnly:!0,value:e.url,"aria-label":Ee.fileUrl,onFocus:e=>e.currentTarget.select()})}),
|
|
17
|
-
/* @__PURE__ */J(T,{variant:"secondary",size:"sm",leftIcon:X.copy,onClick:()=>Dn.copyUrl(e.id),children:Ee.copyUrl})]}),an&&Be&&/* @__PURE__ */K("div",{className:"flex flex-wrap gap-2",children:[ze&&/* @__PURE__ */J(T,{variant:"secondary",size:"sm",leftIcon:X.swap,onClick:()=>ze(e.id),...qn(fe.replace),children:Ee.replace}),Te&&/* @__PURE__ */J(T,{variant:"secondary",size:"sm",leftIcon:X.crop,onClick:()=>Te(e.id),children:Ee.cropEdit}),Ce&&"submenu"===i?.type&&/* @__PURE__ */J(I,{align:"start",triggerClassName:vl,trigger:/* @__PURE__ */K(H,{children:[X.folder,Ee.moveTo]}),items:i.items,disabled:!!fe.move}),xe&&/* @__PURE__ */J(T,{variant:"secondary",size:"sm",leftIcon:X.edit,onClick:()=>yn({kind:"file",id:e.id}),...qn(fe.rename),children:Ee.rename}),Ne&&/* @__PURE__ */J(D,{"aria-label":Ee.moveToTrash,size:"sm",onClick:()=>Ne({kind:"files",ids:[e.id]}),disabledReason:fe.trash,"aria-disabled":!!fe.trash||void 0,children:X.trash})]}),ln&&Be&&/* @__PURE__ */K("div",{className:"flex flex-wrap gap-2",children:[De&&/* @__PURE__ */J(T,{variant:"primary",size:"sm",leftIcon:X.undo,onClick:()=>De([e.id]),...qn(fe.restore),children:Ee.restore}),Se&&/* @__PURE__ */J(T,{variant:"danger",size:"sm",onClick:()=>Se([e.id]),...qn(fe.deleteForever),children:Ee.deleteForever})]}),nn&&Fe&&/* @__PURE__ */J(T,{variant:"secondary",size:"sm",leftIcon:X.external,onClick:()=>Fe({kind:"render",id:e.id}),children:Ee.openInDesign}),pe&&/* @__PURE__ */J(v,{items:pe})]})},wl=mn?mn.private?Ee.privateNoPick:mn.pickDisabledReason:void 0,xl=Ue?/* @__PURE__ */K("div",{"data-media-picker-footer":"",className:"flex flex-wrap items-center justify-between gap-2 border-t border-line px-3 py-2",children:[
|
|
18
|
-
/* @__PURE__ */J("span",{className:"min-w-0 truncate text-sm text-ink-faint",children:mn?Ee.oneChosen(mn.name):Ee.noneChosen}),
|
|
19
|
-
/* @__PURE__ */K("div",{className:"flex gap-2",children:[Le&&/* @__PURE__ */J(T,{variant:"secondary",size:"sm",onClick:Le,children:Ee.cancel}),
|
|
20
|
-
/* @__PURE__ */J(T,{variant:"primary",size:"sm",disabled:!mn,...qn(wl),onClick:()=>{mn&&!wl&&Oe?.(mn)},children:Ee.chooseImage})]})]}):null,Cl=Be&&!!mn,Nl=/* @__PURE__ */K("div",{className:"flex min-w-0 flex-col gap-3",children:[Me&&/* @__PURE__ */J(C,{tone:"neutral",children:Me}),
|
|
21
|
-
/* @__PURE__ */K("div",{className:"flex flex-wrap items-center justify-between gap-2",children:[
|
|
22
|
-
/* @__PURE__ */J(d,{items:Zn}),_n]}),ll,yl,
|
|
23
|
-
/* @__PURE__ */K("div",{ref:cl,className:"relative",onPointerDown:ul.onPointerDown,onKeyDown:e=>{Be&&(e.ctrlKey||e.metaKey)&&"a"===e.key.toLowerCase()?(e.preventDefault(),cn.selectAll()):"Escape"===e.key&&cn.size&&cn.clear()},children:[fl,
|
|
24
|
-
/* @__PURE__ */J(a,{rect:ul.rect})]}),Xn&&/* @__PURE__ */J("input",{...$n.inputProps}),
|
|
25
|
-
/* @__PURE__ */J(j,{rejections:$n.rejections})]});/* @__PURE__ */
|
|
26
|
-
return K("div",{ref:Ke,"data-media-library":"","data-layout":Je?"phone":"wide",className:`flex h-full min-h-0 min-w-0 flex-col ${Ae}`.trim(),children:[/* @__PURE__ */K("div",Je?{className:"flex flex-col gap-3 p-3",children:[Yn,Nl]}:{className:"flex min-h-0 min-w-0 flex-1",children:[
|
|
27
|
-
/* @__PURE__ */J("div",{className:"shrink-0 overflow-y-auto border-r border-line p-3",style:{width:280,"--rosh-tree-ground":"var(--surface)"},children:Yn}),
|
|
28
|
-
/* @__PURE__ */J("div",{className:"min-w-0 flex-1 overflow-y-auto p-3",children:Nl}),Cl&&/* @__PURE__ */J("div",{className:"shrink-0 overflow-y-auto border-l border-line p-3",style:{width:300},children:bl(mn)})]}),xl,Je&&/* @__PURE__ */J(o,{open:Cl,onClose:cn.clear,side:"bottom",title:mn?.name,children:mn&&bl(mn)}),jn.state&&/* @__PURE__ */J(x,{...jn.props,items:Sn(jn.state.data)}),null!=Nn&&ie.length>0&&/* @__PURE__ */J(r,{images:ie.map(e=>({url:e.url,caption:e.name})),startIndex:Math.min(Nn,ie.length-1),onClose:()=>In(null)})]})}export{V as MEDIA_FILES_DRAG_TYPE,Y as MEDIA_FILE_DRAG_TYPE,G as MEDIA_FOLDER_DRAG_TYPE,W as MediaLibrary,Z as readMediaFileDrag};
|
package/dist/chunk-MDVABA4H.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var r="12.23.0",a=r;export{a as APP_VERSION,r as VERSION};
|