efficient-shell 13.9.0 → 13.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{Browser-ATL2PGT2.js → Browser-RQMICFVJ.js} +13 -13
- package/dist/Files-MJBEQENM.js +141 -0
- package/dist/{Notepad-QL5GJZNS.js → Notepad-KE3Q7TEM.js} +8 -8
- package/dist/{Preview-PP3XS7E7.js → Preview-J54KUTIR.js} +19 -19
- package/dist/apps/index.d.ts +7 -2
- package/dist/apps/index.js +1 -1
- package/dist/bin/browser-check.js +1 -1
- package/dist/bin/media-host-check.js +1 -1
- package/dist/bin/ui-check.js +1 -1
- package/dist/chunk-7APOZZ72.js +1 -0
- package/dist/{chunk-4EFIUJ7X.js → chunk-CUNYWXUT.js} +1 -1
- package/dist/{chunk-RK6X56ZC.js → chunk-HQSJSPQB.js} +1 -1
- package/dist/chunk-KGRJSTPM.js +13 -0
- package/dist/{chunk-E6PDAYBR.js → chunk-O5UD3ZWM.js} +4 -4
- package/dist/{chunk-767USLF5.js → chunk-R3R6ZJNW.js} +6 -6
- package/dist/{chunk-AEOCSYKL.js → chunk-VKRJVHYA.js} +1 -1
- package/dist/{chunk-SQ4ZFG2B.js → chunk-ZAL72BPF.js} +1 -1
- package/dist/forms/BrandAssetEditor.js +1 -1
- package/dist/forms/MediaLibrary.js +1 -1
- package/dist/icons/index.js +1 -1
- package/dist/index.js +46 -46
- package/dist/shell/LanguageSelect.js +1 -1
- package/dist/shell/SettingRow.js +1 -1
- package/dist/telemetry/index.js +1 -1
- package/dist/ui/index.js +1 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
- package/dist/Files-RHEICXXW.js +0 -141
- package/dist/chunk-AJMQ5SHI.js +0 -1
- package/dist/chunk-WBAWJIVM.js +0 -13
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
export{LanguagePanel,LanguageSelect,languageSelectWidth}from"../chunk-65JCQLM4.js";import"../chunk-NUDL6UO3.js";import"../chunk-PLD54WSR.js";import"../chunk-
|
|
2
|
+
export{LanguagePanel,LanguageSelect,languageSelectWidth}from"../chunk-65JCQLM4.js";import"../chunk-NUDL6UO3.js";import"../chunk-PLD54WSR.js";import"../chunk-VQCKMT5F.js";import"../chunk-RQGLDRRF.js";import"../chunk-64ACCUNN.js";import"../chunk-32VV2J22.js";import"../chunk-NI5FXWK5.js";import"../chunk-KITSIQCV.js";import"../chunk-EO5RLFRX.js";import"../chunk-K5YT5PMJ.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-ISVODSRP.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-DEJIH3ZQ.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-O5UD3ZWM.js";import"../chunk-F3MO56N4.js";import"../chunk-HCP7WOAL.js";import"../chunk-2NMW66P5.js";import"../chunk-DEJIH3ZQ.js";import"../chunk-C3QOHMR6.js";
|
package/dist/telemetry/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{startClientTelemetry}from"../chunk-
|
|
1
|
+
export{startClientTelemetry}from"../chunk-VKRJVHYA.js";import"../chunk-KNUR2UEG.js";import"../chunk-7APOZZ72.js";
|
package/dist/ui/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import"../chunk-CLEMKDRO.js";export{FormLayoutPage}from"../chunk-BSEQJM7X.js";export{GalleryTemplate}from"../chunk-BRFUQAVC.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{AuthScreen}from"../chunk-7WMFHPKS.js";export{ChatTemplate}from"../chunk-ROPVIMIR.js";export{CheckoutTemplate}from"../chunk-PGATHOTX.js";export{DashboardTemplate}from"../chunk-LPAOHDUE.js";export{DataTablePage}from"../chunk-QDEQHT2T.js";export{EmailTemplate}from"../chunk-YW6BODBX.js";export{ErrorBoundary}from"../chunk-H4GOJ26X.js";export{ErrorPage}from"../chunk-AEMTJGD4.js";export{useTransferProgress}from"../chunk-QHOEMRR7.js";export{Tabs,tabButtonId,tabPanelId}from"../chunk-I5EVMLPB.js";export{Paragraph,Text,Title}from"../chunk-5KUE6IHF.js";export{TimeAgo}from"../chunk-IOZSLFGR.js";export{TopNav}from"../chunk-N2FX4O3H.js";export{Skeleton}from"../chunk-4Z62SEA5.js";export{ListRow,SortableList}from"../chunk-R5TSUJTK.js";export{Grid,Inline,Stack}from"../chunk-3RPER7VH.js";export{Statistic}from"../chunk-6SOS6OBB.js";export{Stepper}from"../chunk-KTO427N3.js";export{SettingReset}from"../chunk-4HJX2M4W.js";export{SettingRow}from"../chunk-E6PDAYBR.js";export{SidebarActionButton}from"../chunk-KMTCYDJH.js";export{SidebarLayout}from"../chunk-6D6Q3ZCG.js";export{SidebarGroupLabel,SidebarNavGroup,SidebarNavItem,SidebarSection}from"../chunk-VUM6BYAX.js";import"../chunk-QWK6DRSN.js";export{MetricBar}from"../chunk-AJ5GLMGD.js";export{isSeverityTone,severityOf}from"../chunk-TZFNWAED.js";export{MetricBarLegend}from"../chunk-DU7TJVX5.js";import"../chunk-URBCGEXG.js";export{MilestoneTimeline}from"../chunk-YJGA4LPG.js";export{PageHeader}from"../chunk-AKKDFFUO.js";export{POST_PRODUCTION_STATUSES,ProductionTimeline,STAGES,calcOverall,calcReportOverall,useProductionTimeline}from"../chunk-H7CIK74N.js";import"../chunk-S4Z657L6.js";export{TimelineTrack}from"../chunk-F3G7S5HO.js";export{fmtSliderDate,toDayMs}from"../chunk-5CFERCYW.js";export{ResizeHandle}from"../chunk-PC3MYH2K.js";export{HelpCenter}from"../chunk-IRCASURW.js";export{IconRail,IconRailButton}from"../chunk-Q6GECV4J.js";import"../chunk-FQEALPZJ.js";export{LanguagePanel,LanguageSelect,languageSelectWidth}from"../chunk-65JCQLM4.js";export{EditableGrid}from"../chunk-6XPS3H5Z.js";export{EmptyValue}from"../chunk-HNQPF5QZ.js";export{FloatingBar}from"../chunk-7KWYVQMX.js";export{GlobalSearch,openGlobalSearch}from"../chunk-PZNF2TEB.js";export{pushRecent as pushRecentSearch,sanitizeRecent as sanitizeRecentSearches}from"../chunk-HGOWQO63.js";export{Card,StatCard}from"../chunk-CVXJKHPD.js";export{ContainerFillChart}from"../chunk-X22SFR5F.js";export{CountBadge}from"../chunk-F3MO56N4.js";export{ENGLISH,SHELL_LANGUAGE_STORAGE_KEY,ShellLanguageProvider,matchShellLanguage,readSavedShellLanguage,resolveShellLanguage,saveShellLanguage,useShellLanguage}from"../chunk-NUDL6UO3.js";export{Accordion,AccordionBody,AccordionHeading}from"../chunk-TDG5WGLR.js";export{APP_UPDATE_POLL_MS,AppUpdateBanner,useAppUpdate}from"../chunk-4RSBPRCQ.js";export{BudgetBar,budgetState}from"../chunk-3DV5YLAI.js";export{ICON_NAMES,isIconName}from"../chunk-PLD54WSR.js";export{BRAND_ICON_NAMES,isBrandIconName}from"../chunk-RQGLDRRF.js";export{BRAND_MAX_HEIGHT,BRAND_MIN_HEIGHT_PX,brandBox}from"../chunk-64ACCUNN.js";export{TimePicker_default as TimePicker}from"../chunk-FVORTWUY.js";export{WidthsBar}from"../chunk-VMKTA5HL.js";export{COLUMN_COUNT_MAX,COLUMN_COUNT_WIDTHS,COLUMN_SHARES_EQUAL,COLUMN_SHARE_MIN,columnSharesWidths,resolveColumnShares,resolveColumnWidths}from"../chunk-PLGJOHEG.js";export{Slider,SliderGroup}from"../chunk-2LRSUDGN.js";export{Snippet}from"../chunk-B3KQELHS.js";export{SplitButton_default as SplitButton}from"../chunk-ASDYAASN.js";export{Switch_default as Switch}from"../chunk-M3R4C3A6.js";export{TagInput}from"../chunk-V3KQIY6T.js";export{TextToolbar,textToolbarRows,textToolbarWindowColumns}from"../chunk-2FQBY4ED.js";export{TEXT_ALIGNS,TEXT_ALIGN_FIT,TEXT_ALIGN_ICONS,textAlignFit,textAlignOptions,textAlignWords}from"../chunk-4HJNHI4A.js";export{Textarea_default as Textarea}from"../chunk-PB7G6CJ7.js";export{TileButton_default as TileButton}from"../chunk-H2R4SNNO.js";export{PositionInput}from"../chunk-BLXHT72M.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-4YWQE67T.js";export{LinkPicker,TextLinkField}from"../chunk-WUEH6DLJ.js";export{SearchableSelect}from"../chunk-P62QGXRW.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-767USLF5.js";export{Tree,TreeEmptySlot,TreeGroup,TreeGroupLabel,TreeRow,TreeSeam}from"../chunk-FCWBO7I3.js";import"../chunk-FXG7TOZN.js";export{ImageLightbox,lightboxKind}from"../chunk-HWJQLLJA.js";export{LIGHTBOX_PICTURE_FIT,ZoomableImage}from"../chunk-CGUMJZUB.js";export{MarqueeBox}from"../chunk-IC72MGON.js";export{Drawer}from"../chunk-3RX5KCUH.js";export{EmptyState}from"../chunk-3TCGXYUC.js";export{DescriptionList}from"../chunk-SACUSHVN.js";export{Breadcrumbs}from"../chunk-YM7AWNMY.js";export{mediaLibraryMenu}from"../chunk-3YCU6V3U.js";export{mediaMoveItems,mediaMoveSubmenu,useMediaMoveItems}from"../chunk-JWUNK2PW.js";export{RenameField}from"../chunk-QIPO4EVJ.js";export{NativeSelect,Select_default as Select}from"../chunk-KITSIQCV.js";import"../chunk-EO5RLFRX.js";import"../chunk-K5YT5PMJ.js";export{FULL_BADGE_TILE_PX,MediaUploadGrid}from"../chunk-BNPJHOAC.js";export{MediaUsedInList}from"../chunk-ZDDMFFQK.js";export{NumericKeypad}from"../chunk-TAEO2JC6.js";export{MAX_FRACTION_DIGITS,appendKey,backspace}from"../chunk-VEPVOHCV.js";export{PICTURE_TILES_COLUMNS_VAR,PictureTiles}from"../chunk-OBZZLLMQ.js";export{FilePicker_default as FilePicker}from"../chunk-JOYGSKWG.js";export{FormErrorSummary}from"../chunk-BXZLSY2S.js";export{CornersInput}from"../chunk-R5SVNFUG.js";export{DatePicker_default as DatePicker}from"../chunk-SC3AQXJY.js";export{DateRangePicker,toISODate}from"../chunk-BKZOTBDP.js";export{DateTimePicker_default as DateTimePicker}from"../chunk-NZKR3JPM.js";export{DisplayChips}from"../chunk-XCY7A5UM.js";export{useRootIsDark}from"../chunk-UPXDDO3U.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-O32GIVYD.js";export{IconPicker}from"../chunk-KGBB6REQ.js";export{ColorPicker,ColorPickerPanel,ColorSwatch,HexInput,colorFill,colorSwatchClasses}from"../chunk-Y43S6YS5.js";export{Popover}from"../chunk-64RHGJXK.js";export{InputNumber_default as InputNumber}from"../chunk-ZDCCYRFF.js";export{UnitMenu}from"../chunk-QOYKBINM.js";export{useSettingAuto,useSettingRowName}from"../chunk-2NMW66P5.js";export{BrandAssetEditor}from"../chunk-QO7UHTUE.js";export{MediaUploadField}from"../chunk-UHQBHSWL.js";export{FormField}from"../chunk-6KBDNYRW.js";export{ImageFocusPoint}from"../chunk-YMUHIJDJ.js";export{BrandMark,resolveBrandMarkTreatment}from"../chunk-MI67DI3H.js";export{Calendar}from"../chunk-LOFFHXZ4.js";export{useSort}from"../chunk-E6FDUFPH.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{gridColumnCount}from"../chunk-VNNVG4NR.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{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{Gantt}from"../chunk-Z62HFEFS.js";export{Segmented}from"../chunk-HNIIDDLJ.js";import"../chunk-EFKJLUYP.js";export{Kanban}from"../chunk-RJ24VXBZ.js";export{PortalBrandingProvider,resolvePortalBrandAsset,usePortalBranding}from"../chunk-ACYYVK6G.js";export{DataTable}from"../chunk-ZHR2HNT2.js";export{Pagination}from"../chunk-MZCYB2MW.js";export{EntityList}from"../chunk-FOE2QHDE.js";import"../chunk-HTHNDX32.js";export{useTableNav}from"../chunk-ATMJ5ZPK.js";export{escapeHtml}from"../chunk-G6DKCCWH.js";export{ListFooter}from"../chunk-IODIQ77P.js";export{ListLoadError}from"../chunk-IYTOOV7Q.js";export{ResizableTable}from"../chunk-5UPLN44S.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-V5VAKDLS.js";export{squarify}from"../chunk-46BYGPGD.js";export{WaterfallChart}from"../chunk-YEEMRWBS.js";export{RangeChart}from"../chunk-G5U7IRH4.js";export{RankedBars}from"../chunk-ARBS2EZ6.js";export{SankeyChart}from"../chunk-HTHD7STJ.js";export{SCATTER_SERIES_CAP,ScatterChart}from"../chunk-RMEYKJEH.js";export{StatTile}from"../chunk-75TPMXA7.js";export{Sparkline}from"../chunk-CKCDGSTC.js";export{SunburstChart}from"../chunk-VVXBBU6R.js";export{FunnelChart}from"../chunk-WEZ2RO72.js";export{HeatmapChart}from"../chunk-FBMYLCCE.js";export{HistogramChart}from"../chunk-QXXMRV4E.js";export{Meter}from"../chunk-IEW5JTIR.js";export{PieChart}from"../chunk-DYOFTZOC.js";export{RADAR_SERIES_CAP,RadarChart}from"../chunk-DGFFDZCY.js";export{RadialBarChart}from"../chunk-KZQRUVII.js";export{ChordChart}from"../chunk-BLXEDMZM.js";import"../chunk-HY6CBG4M.js";export{StepChain,StepChainItem}from"../chunk-Z2Z653OO.js";export{Markdown,Markdown as MarkdownLite,plainCell,tableToCsv}from"../chunk-E44RNULN.js";export{Divider}from"../chunk-DFOFEBYX.js";export{Avatar,AvatarGroup}from"../chunk-YAM3L5N4.js";import"../chunk-UJUTS6LJ.js";export{isSafeLinkHref}from"../chunk-Z5TE3MEG.js";export{ContextMenu,useContextMenu}from"../chunk-QMBMK6PP.js";export{Banner}from"../chunk-ID35S5Y6.js";export{AttachButton,AttachmentDropZone,AttachmentList,ComposerAttachments,PaperclipGlyph}from"../chunk-DFOKJAIS.js";export{Input_default as Input}from"../chunk-PT4GMPUB.js";export{DropdownMenu}from"../chunk-3DSGJIC7.js";import"../chunk-UZFFSZFI.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-CCPUNN4F.js";export{TransferProgress}from"../chunk-ROKUEMAK.js";export{FileIntakeAlert,acceptsFile,useFileIntake}from"../chunk-ITEOA45V.js";export{CHART_SPEC_LIMITS,parseChartSpec}from"../chunk-CR7T435F.js";export{SpecChart}from"../chunk-ZJ34FNRC.js";export{currencyDecimals,currencySymbol,formatBytes,formatMoney,setCurrencyFormats,timeAgo}from"../chunk-OJI4ROSD.js";export{DATE_FORMAT_OPTIONS,TZ_AUTO,dayKeyInZone,firstDayOfWeek,formatDate,formatDateTime,formatTime,getUserDateFormat,getUserTimezone,instantOnDayKey,knownZone,setUserDateFormat,setUserTimezone,syncTimezoneFromProfile,userToday,userZone}from"../chunk-NHKT5IH6.js";export{EMPTY_VALUE}from"../chunk-36BRD5J3.js";export{DAY_MS,fromDateKey,toDateKey}from"../chunk-JRQMX4PK.js";import"../chunk-LF27WIN2.js";export{TimeSeriesChart}from"../chunk-EEFUXXYJ.js";export{DEFAULT_FLOW_CHART_LABELS,FlowChart}from"../chunk-7NO4IENQ.js";export{FLOW_LAYOUT,FLOW_SPEC_LIMITS,layoutFlow,parseFlowSpec}from"../chunk-FAERBT6Y.js";export{ChartBrush}from"../chunk-FEQQMRHJ.js";export{ChartDot}from"../chunk-CK2YOGUS.js";export{ChartFrame}from"../chunk-VWYICGVA.js";export{arcPath,areaBetween,areaFrom,bumpPath,curvePath,linearPath,monotonePath,polygonPoints,splinePath,stepPath}from"../chunk-VFC6QUEN.js";export{ColumnChart}from"../chunk-PA3OU3Y7.js";export{ChartDefs,MOTION,dashFor,fillFor,fillId,glowId,groundId,maskId,stagger}from"../chunk-465RRWBY.js";export{ChartSkeleton}from"../chunk-NLHGFQ54.js";export{ChartHighlightProvider,autoHighlightIndex,highlightOpacity,useHighlight}from"../chunk-CNYAHYE6.js";export{ImageAnnotator_default as ImageAnnotator}from"../chunk-EQFWFQOZ.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-DASRJ26L.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-KV6XCHAG.js";export{Dialog}from"../chunk-B447IHIL.js";import"../chunk-EIFNESXS.js";export{ItemCount}from"../chunk-PR6FNBKR.js";import"../chunk-RIG5FEVS.js";import"../chunk-NDWX5Z4D.js";import"../chunk-VWGWZY7A.js";import"../chunk-7QSDPSXP.js";export{ColoredBadge}from"../chunk-ZGIAMYTI.js";import"../chunk-5LHEPE4B.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-AJMQ5SHI.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-GOAFMGUI.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-ISVODSRP.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-TMSSR5UH.js";export{buttonClasses,iconButtonClasses}from"../chunk-UQYNPYF4.js";import"../chunk-MRJKZWWV.js";export{BoxPlotChart}from"../chunk-GAGCE2ML.js";export{CandlestickChart}from"../chunk-XPSWZQR4.js";export{CartesianPlot}from"../chunk-D53FU245.js";import"../chunk-2UBR4YUF.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-DEJIH3ZQ.js";import"../chunk-C3QOHMR6.js";
|
|
2
|
+
import"../chunk-CLEMKDRO.js";export{FormLayoutPage}from"../chunk-BSEQJM7X.js";export{GalleryTemplate}from"../chunk-BRFUQAVC.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{AuthScreen}from"../chunk-7WMFHPKS.js";export{ChatTemplate}from"../chunk-ROPVIMIR.js";export{CheckoutTemplate}from"../chunk-PGATHOTX.js";export{DashboardTemplate}from"../chunk-LPAOHDUE.js";export{DataTablePage}from"../chunk-QDEQHT2T.js";export{EmailTemplate}from"../chunk-YW6BODBX.js";export{ErrorBoundary}from"../chunk-H4GOJ26X.js";export{ErrorPage}from"../chunk-AEMTJGD4.js";export{useTransferProgress}from"../chunk-QHOEMRR7.js";export{Tabs,tabButtonId,tabPanelId}from"../chunk-I5EVMLPB.js";export{Paragraph,Text,Title}from"../chunk-5KUE6IHF.js";export{TimeAgo}from"../chunk-IOZSLFGR.js";export{TopNav}from"../chunk-N2FX4O3H.js";export{Skeleton}from"../chunk-4Z62SEA5.js";export{ListRow,SortableList}from"../chunk-R5TSUJTK.js";export{Grid,Inline,Stack}from"../chunk-3RPER7VH.js";export{Statistic}from"../chunk-6SOS6OBB.js";export{Stepper}from"../chunk-KTO427N3.js";export{SettingReset}from"../chunk-4HJX2M4W.js";export{SettingRow}from"../chunk-O5UD3ZWM.js";export{SidebarActionButton}from"../chunk-KMTCYDJH.js";export{SidebarLayout}from"../chunk-6D6Q3ZCG.js";export{SidebarGroupLabel,SidebarNavGroup,SidebarNavItem,SidebarSection}from"../chunk-VUM6BYAX.js";import"../chunk-QWK6DRSN.js";export{MetricBar}from"../chunk-AJ5GLMGD.js";export{isSeverityTone,severityOf}from"../chunk-TZFNWAED.js";export{MetricBarLegend}from"../chunk-DU7TJVX5.js";import"../chunk-URBCGEXG.js";export{MilestoneTimeline}from"../chunk-YJGA4LPG.js";export{PageHeader}from"../chunk-AKKDFFUO.js";export{POST_PRODUCTION_STATUSES,ProductionTimeline,STAGES,calcOverall,calcReportOverall,useProductionTimeline}from"../chunk-H7CIK74N.js";import"../chunk-S4Z657L6.js";export{TimelineTrack}from"../chunk-F3G7S5HO.js";export{fmtSliderDate,toDayMs}from"../chunk-5CFERCYW.js";export{ResizeHandle}from"../chunk-PC3MYH2K.js";export{HelpCenter}from"../chunk-IRCASURW.js";export{IconRail,IconRailButton}from"../chunk-Q6GECV4J.js";import"../chunk-FQEALPZJ.js";export{LanguagePanel,LanguageSelect,languageSelectWidth}from"../chunk-65JCQLM4.js";export{EditableGrid}from"../chunk-6XPS3H5Z.js";export{EmptyValue}from"../chunk-HNQPF5QZ.js";export{FloatingBar}from"../chunk-7KWYVQMX.js";export{GlobalSearch,openGlobalSearch}from"../chunk-PZNF2TEB.js";export{pushRecent as pushRecentSearch,sanitizeRecent as sanitizeRecentSearches}from"../chunk-HGOWQO63.js";export{Card,StatCard}from"../chunk-CVXJKHPD.js";export{ContainerFillChart}from"../chunk-X22SFR5F.js";export{CountBadge}from"../chunk-F3MO56N4.js";export{ENGLISH,SHELL_LANGUAGE_STORAGE_KEY,ShellLanguageProvider,matchShellLanguage,readSavedShellLanguage,resolveShellLanguage,saveShellLanguage,useShellLanguage}from"../chunk-NUDL6UO3.js";export{Accordion,AccordionBody,AccordionHeading}from"../chunk-TDG5WGLR.js";export{APP_UPDATE_POLL_MS,AppUpdateBanner,useAppUpdate}from"../chunk-4RSBPRCQ.js";export{BudgetBar,budgetState}from"../chunk-3DV5YLAI.js";export{ICON_NAMES,isIconName}from"../chunk-PLD54WSR.js";export{useRootIsDark}from"../chunk-UPXDDO3U.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{BRAND_ICON_NAMES,isBrandIconName}from"../chunk-RQGLDRRF.js";export{BRAND_MAX_HEIGHT,BRAND_MIN_HEIGHT_PX,brandBox}from"../chunk-64ACCUNN.js";export{useDebouncedValue}from"../chunk-SLGT5WPJ.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-FVORTWUY.js";export{WidthsBar}from"../chunk-VMKTA5HL.js";export{COLUMN_COUNT_MAX,COLUMN_COUNT_WIDTHS,COLUMN_SHARES_EQUAL,COLUMN_SHARE_MIN,columnSharesWidths,resolveColumnShares,resolveColumnWidths}from"../chunk-PLGJOHEG.js";export{ShowWhen}from"../chunk-YEM4KYCW.js";export{SidesEachToggle,SidesInput,sidesStartEach}from"../chunk-4YWQE67T.js";export{Slider,SliderGroup}from"../chunk-2LRSUDGN.js";export{Snippet}from"../chunk-B3KQELHS.js";export{SplitButton_default as SplitButton}from"../chunk-ASDYAASN.js";export{Switch_default as Switch}from"../chunk-M3R4C3A6.js";export{TagInput}from"../chunk-V3KQIY6T.js";export{TextToolbar,textToolbarRows,textToolbarWindowColumns}from"../chunk-2FQBY4ED.js";export{TEXT_ALIGNS,TEXT_ALIGN_FIT,TEXT_ALIGN_ICONS,textAlignFit,textAlignOptions,textAlignWords}from"../chunk-4HJNHI4A.js";export{NumericKeypad}from"../chunk-TAEO2JC6.js";export{MAX_FRACTION_DIGITS,appendKey,backspace}from"../chunk-VEPVOHCV.js";export{PICTURE_TILES_COLUMNS_VAR,PictureTiles}from"../chunk-OBZZLLMQ.js";export{PositionInput}from"../chunk-BLXHT72M.js";export{RadioGroup}from"../chunk-32VV2J22.js";export{Radio_default as Radio}from"../chunk-NI5FXWK5.js";export{LinkPicker,TextLinkField}from"../chunk-WUEH6DLJ.js";export{SearchableSelect}from"../chunk-P62QGXRW.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-R3R6ZJNW.js";export{Tree,TreeEmptySlot,TreeGroup,TreeGroupLabel,TreeRow,TreeSeam}from"../chunk-FCWBO7I3.js";import"../chunk-FXG7TOZN.js";export{ImageLightbox,lightboxKind}from"../chunk-HWJQLLJA.js";export{LIGHTBOX_PICTURE_FIT,ZoomableImage}from"../chunk-CGUMJZUB.js";export{MarqueeBox}from"../chunk-IC72MGON.js";export{Drawer}from"../chunk-3RX5KCUH.js";export{EmptyState}from"../chunk-3TCGXYUC.js";export{DescriptionList}from"../chunk-SACUSHVN.js";export{Breadcrumbs}from"../chunk-YM7AWNMY.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-3YCU6V3U.js";export{mediaMoveItems,mediaMoveSubmenu,useMediaMoveItems}from"../chunk-JWUNK2PW.js";export{RenameField}from"../chunk-QIPO4EVJ.js";export{NativeSelect,Select_default as Select}from"../chunk-KITSIQCV.js";import"../chunk-EO5RLFRX.js";import"../chunk-K5YT5PMJ.js";export{FULL_BADGE_TILE_PX,MediaUploadGrid}from"../chunk-BNPJHOAC.js";export{MediaUsedInList}from"../chunk-ZDDMFFQK.js";export{DateTimePicker_default as DateTimePicker}from"../chunk-NZKR3JPM.js";export{DisplayChips}from"../chunk-XCY7A5UM.js";export{FilePicker_default as FilePicker}from"../chunk-JOYGSKWG.js";export{FormErrorSummary}from"../chunk-BXZLSY2S.js";export{CornersInput}from"../chunk-R5SVNFUG.js";export{DatePicker_default as DatePicker}from"../chunk-SC3AQXJY.js";export{DateRangePicker,toISODate}from"../chunk-BKZOTBDP.js";export{Calendar}from"../chunk-LOFFHXZ4.js";export{useSort}from"../chunk-E6FDUFPH.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{gridColumnCount}from"../chunk-VNNVG4NR.js";export{AlignmentGrid}from"../chunk-3DWVSQIJ.js";export{BorderInput,borderSides,borderStartEach}from"../chunk-O32GIVYD.js";export{IconPicker}from"../chunk-KGBB6REQ.js";export{ColorPicker,ColorPickerPanel,ColorSwatch,HexInput,colorFill,colorSwatchClasses}from"../chunk-Y43S6YS5.js";export{Popover}from"../chunk-64RHGJXK.js";export{InputNumber_default as InputNumber}from"../chunk-ZDCCYRFF.js";export{UnitMenu}from"../chunk-QOYKBINM.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-QO7UHTUE.js";export{MediaUploadField}from"../chunk-UHQBHSWL.js";export{FormField}from"../chunk-6KBDNYRW.js";export{ImageFocusPoint}from"../chunk-YMUHIJDJ.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{Gantt}from"../chunk-Z62HFEFS.js";export{Segmented}from"../chunk-HNIIDDLJ.js";import"../chunk-EFKJLUYP.js";export{Kanban}from"../chunk-RJ24VXBZ.js";export{PortalBrandingProvider,resolvePortalBrandAsset,usePortalBranding}from"../chunk-ACYYVK6G.js";export{DataTable}from"../chunk-ZHR2HNT2.js";export{Pagination}from"../chunk-MZCYB2MW.js";export{EntityList}from"../chunk-FOE2QHDE.js";import"../chunk-HTHNDX32.js";export{useTableNav}from"../chunk-ATMJ5ZPK.js";export{escapeHtml}from"../chunk-G6DKCCWH.js";export{ListFooter}from"../chunk-IODIQ77P.js";export{ListLoadError}from"../chunk-IYTOOV7Q.js";export{ResizableTable}from"../chunk-5UPLN44S.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-V5VAKDLS.js";export{squarify}from"../chunk-46BYGPGD.js";export{WaterfallChart}from"../chunk-YEEMRWBS.js";export{RangeChart}from"../chunk-G5U7IRH4.js";export{RankedBars}from"../chunk-ARBS2EZ6.js";export{SankeyChart}from"../chunk-HTHD7STJ.js";export{SCATTER_SERIES_CAP,ScatterChart}from"../chunk-RMEYKJEH.js";export{StatTile}from"../chunk-75TPMXA7.js";export{Sparkline}from"../chunk-CKCDGSTC.js";export{SunburstChart}from"../chunk-VVXBBU6R.js";export{FunnelChart}from"../chunk-WEZ2RO72.js";export{HeatmapChart}from"../chunk-FBMYLCCE.js";export{HistogramChart}from"../chunk-QXXMRV4E.js";export{Meter}from"../chunk-IEW5JTIR.js";export{PieChart}from"../chunk-DYOFTZOC.js";export{RADAR_SERIES_CAP,RadarChart}from"../chunk-DGFFDZCY.js";export{RadialBarChart}from"../chunk-KZQRUVII.js";export{ChordChart}from"../chunk-BLXEDMZM.js";import"../chunk-HY6CBG4M.js";export{StepChain,StepChainItem}from"../chunk-Z2Z653OO.js";export{Markdown,Markdown as MarkdownLite,plainCell,tableToCsv}from"../chunk-E44RNULN.js";export{Divider}from"../chunk-DFOFEBYX.js";export{Avatar,AvatarGroup}from"../chunk-YAM3L5N4.js";import"../chunk-UJUTS6LJ.js";export{isSafeLinkHref}from"../chunk-Z5TE3MEG.js";export{ContextMenu,useContextMenu}from"../chunk-QMBMK6PP.js";export{Banner}from"../chunk-ID35S5Y6.js";export{AttachButton,AttachmentDropZone,AttachmentList,ComposerAttachments,PaperclipGlyph}from"../chunk-DFOKJAIS.js";export{Input_default as Input}from"../chunk-PT4GMPUB.js";export{DropdownMenu}from"../chunk-3DSGJIC7.js";import"../chunk-UZFFSZFI.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-CCPUNN4F.js";export{TransferProgress}from"../chunk-ROKUEMAK.js";export{FileIntakeAlert,acceptsFile,useFileIntake}from"../chunk-ITEOA45V.js";export{CHART_SPEC_LIMITS,parseChartSpec}from"../chunk-CR7T435F.js";export{SpecChart}from"../chunk-ZJ34FNRC.js";export{currencyDecimals,currencySymbol,formatBytes,formatMoney,setCurrencyFormats,timeAgo}from"../chunk-OJI4ROSD.js";export{DATE_FORMAT_OPTIONS,TZ_AUTO,dayKeyInZone,firstDayOfWeek,formatDate,formatDateTime,formatTime,getUserDateFormat,getUserTimezone,instantOnDayKey,knownZone,setUserDateFormat,setUserTimezone,syncTimezoneFromProfile,userToday,userZone}from"../chunk-NHKT5IH6.js";export{EMPTY_VALUE}from"../chunk-36BRD5J3.js";export{DAY_MS,fromDateKey,toDateKey}from"../chunk-JRQMX4PK.js";import"../chunk-LF27WIN2.js";export{TimeSeriesChart}from"../chunk-EEFUXXYJ.js";export{DEFAULT_FLOW_CHART_LABELS,FlowChart}from"../chunk-7NO4IENQ.js";export{FLOW_LAYOUT,FLOW_SPEC_LIMITS,layoutFlow,parseFlowSpec}from"../chunk-FAERBT6Y.js";export{ChartBrush}from"../chunk-FEQQMRHJ.js";export{ChartDot}from"../chunk-CK2YOGUS.js";export{ChartFrame}from"../chunk-VWYICGVA.js";export{arcPath,areaBetween,areaFrom,bumpPath,curvePath,linearPath,monotonePath,polygonPoints,splinePath,stepPath}from"../chunk-VFC6QUEN.js";export{ColumnChart}from"../chunk-PA3OU3Y7.js";export{ChartDefs,MOTION,dashFor,fillFor,fillId,glowId,groundId,maskId,stagger}from"../chunk-465RRWBY.js";export{ChartSkeleton}from"../chunk-NLHGFQ54.js";export{ChartHighlightProvider,autoHighlightIndex,highlightOpacity,useHighlight}from"../chunk-CNYAHYE6.js";export{ImageAnnotator_default as ImageAnnotator}from"../chunk-EQFWFQOZ.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-DASRJ26L.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-KV6XCHAG.js";export{Dialog}from"../chunk-B447IHIL.js";import"../chunk-EIFNESXS.js";export{ItemCount}from"../chunk-PR6FNBKR.js";import"../chunk-RIG5FEVS.js";import"../chunk-NDWX5Z4D.js";import"../chunk-VWGWZY7A.js";import"../chunk-7QSDPSXP.js";export{ColoredBadge}from"../chunk-ZGIAMYTI.js";import"../chunk-5LHEPE4B.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-7APOZZ72.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-GOAFMGUI.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-ISVODSRP.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-TMSSR5UH.js";export{buttonClasses,iconButtonClasses}from"../chunk-UQYNPYF4.js";import"../chunk-MRJKZWWV.js";export{BoxPlotChart}from"../chunk-GAGCE2ML.js";export{CandlestickChart}from"../chunk-XPSWZQR4.js";export{CartesianPlot}from"../chunk-D53FU245.js";import"../chunk-2UBR4YUF.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-DEJIH3ZQ.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-7APOZZ72.js";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "efficient-shell",
|
|
3
|
-
"version": "13.
|
|
3
|
+
"version": "13.10.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",
|
package/dist/Files-RHEICXXW.js
DELETED
|
@@ -1,141 +0,0 @@
|
|
|
1
|
-
import{openPreviewFile as e}from"./chunk-SQ4ZFG2B.js";import{SidebarLayout as t}from"./chunk-6D6Q3ZCG.js";import"./chunk-QWK6DRSN.js";import"./chunk-PC3MYH2K.js";import{SearchableSelect as n}from"./chunk-P62QGXRW.js";import{Breadcrumbs as a}from"./chunk-YM7AWNMY.js";import{Select_default as r}from"./chunk-KITSIQCV.js";import"./chunk-EO5RLFRX.js";import"./chunk-K5YT5PMJ.js";import"./chunk-2NMW66P5.js";import{useContextMenu as i,ContextMenu as s}from"./chunk-QMBMK6PP.js";import{Input_default as l}from"./chunk-PT4GMPUB.js";import{DropdownMenu as o}from"./chunk-3DSGJIC7.js";import"./chunk-UZFFSZFI.js";import{IconButton_default as c}from"./chunk-SV5RRBVA.js";import"./chunk-AYZY3YNC.js";import{formatBytes as d}from"./chunk-OJI4ROSD.js";import{dayKeyInZone as m,formatTime as h,formatDateTime as u,userToday as f,instantOnDayKey as p}from"./chunk-NHKT5IH6.js";import{EMPTY_VALUE as k}from"./chunk-36BRD5J3.js";import{fromDateKey as g,toDateKey as w}from"./chunk-JRQMX4PK.js";import"./chunk-LF27WIN2.js";import{getFilesDemoTree as y,subscribeFilesChoice as b,getFilesChoice as v,holdFilesChoice as x,answerFilesChoice as N,choiceTakes as C}from"./chunk-4EFIUJ7X.js";import{AboutApp as S}from"./chunk-RK6X56ZC.js";import{getFilesStore as j,peekFilesViewRequest as D,consumeFilesViewRequest as M,FILES_SHOW_TRASH_EVENT as $,FILES_OPEN_DESKTOP_FOLDER_EVENT as T,subscribeDesktopFolders as L,getDesktopFoldersSnapshot as R,hasHostFilesStore as A,FolderGlyph as I,DesktopItemMiniIcon as P,desktopItemTypeLabel as E,FilesQuotaError as F,FILES_OFFICE_EXTENSIONS as z}from"./chunk-WBAWJIVM.js";import"./chunk-I4RJAMLJ.js";import{useWindowManager as W,WindowTitle as K}from"./chunk-H4LUHKUJ.js";import"./chunk-4LXCCZDM.js";import"./chunk-AW7TOB6N.js";import"./chunk-KNUR2UEG.js";import"./chunk-JDCM2VHG.js";import"./chunk-DASRJ26L.js";import"./chunk-ZDMZM7HD.js";import"./chunk-5A7MWTXX.js";import"./chunk-GHLXZDLU.js";import{confirm as O,prompt as U}from"./chunk-KV6XCHAG.js";import{Dialog as J}from"./chunk-B447IHIL.js";import"./chunk-EIFNESXS.js";import{ItemCount as G}from"./chunk-PR6FNBKR.js";import"./chunk-RIG5FEVS.js";import"./chunk-NDWX5Z4D.js";import"./chunk-VWGWZY7A.js";import"./chunk-7QSDPSXP.js";import"./chunk-ZGIAMYTI.js";import"./chunk-5LHEPE4B.js";import"./chunk-F3ZOO23R.js";import"./chunk-2QY5BJLA.js";import"./chunk-UGTRSRIW.js";import"./chunk-KC3EX26K.js";import"./chunk-AJMQ5SHI.js";import"./chunk-DWGYC7OD.js";import"./chunk-JMGDGNM7.js";import"./chunk-GOAFMGUI.js";import"./chunk-URHGHXDN.js";import"./chunk-5QFPTDQF.js";import{Button_default as V}from"./chunk-EVYD6UFQ.js";import"./chunk-M5K4AX4E.js";import{Icon as Y}from"./chunk-ISVODSRP.js";import"./chunk-J75ZT2JQ.js";import{LoadingSpinner as H}from"./chunk-R2VKEMZH.js";import{TH_ONE_LINE as B}from"./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 Q}from"./chunk-TMSSR5UH.js";import"./chunk-UQYNPYF4.js";import"./chunk-MRJKZWWV.js";import"./chunk-TWVUQUUD.js";import"./chunk-5FYDNH4Y.js";import"./chunk-LNXBTK7Q.js";import"./chunk-DEJIH3ZQ.js";import"./chunk-C3QOHMR6.js";import{useState as Z,useRef as X,useEffect as q,useCallback as _,useSyncExternalStore as ee,useMemo as te}from"react";import{jsxs as ne,jsx as ae,Fragment as re}from"react/jsx-runtime";var ie={doc:"document",docx:"document",odt:"document",rtf:"document",txt:"document",md:"document",xls:"spreadsheet",xlsx:"spreadsheet",ods:"spreadsheet",csv:"spreadsheet",sheet:"spreadsheet",ppt:"slides",pptx:"slides",odp:"slides",key:"slides",slides:"slides",pdf:"pdf",jpg:"image",jpeg:"image",png:"image",gif:"image",webp:"image",svg:"image",avif:"image",bmp:"image",heic:"image",tif:"image",tiff:"image",mp4:"video",mov:"video",webm:"video",avi:"video",mkv:"video",mp3:"audio",wav:"audio",m4a:"audio",ogg:"audio",flac:"audio",zip:"archive",rar:"archive","7z":"archive",gz:"archive",tar:"archive",dxf:"drawing",dwg:"drawing",stp:"drawing",step:"drawing",stl:"drawing",obj:"drawing",iges:"drawing",igs:"drawing","3mf":"drawing",glb:"drawing",gltf:"drawing"};function se(e){const t=e.lastIndexOf(".");return t>0?e.slice(t+1).toLowerCase():""}function le(e){if("folder"===e.kind)return"folder";if("document"===e.officeKind)return"document";if("spreadsheet"===e.officeKind)return"spreadsheet";if("deck"===e.officeKind)return"slides";const t=e.contentType??"";return"application/pdf"===t?"pdf":t.startsWith("image/")?"image":t.startsWith("video/")?"video":t.startsWith("audio/")?"audio":ie[se(e.name)]??"other"}var oe={folder:"Folder",document:"Document",spreadsheet:"Spreadsheet",slides:"Slides",pdf:"PDF",image:"Image",video:"Video",audio:"Audio",archive:"Archive",drawing:"Drawing",other:"File"},ce={folder:{name:"folder",tone:"muted"},document:{name:"document",tone:"accent"},spreadsheet:{name:"table",tone:"success"},slides:{name:"presentation-chart-bar",tone:"warning"},pdf:{name:"document",tone:"danger"},image:{name:"image",tone:"muted"},video:{name:"play",tone:"muted"},audio:{name:"speaker-wave",tone:"muted"},archive:{name:"archive-box",tone:"muted"},drawing:{name:"cube-transparent",tone:"muted"},other:{name:"page",tone:"muted"}};function de(e){const t=e.officeKind?z[e.officeKind]:"";return t&&e.name.toLowerCase().endsWith(t)&&e.name.length>t.length?e.name.slice(0,-t.length):e.name}function me(e){return"folder"===e.kind||e.officeKind&&e.size<=2?"—":d(e.size)}function he(e,t=/* @__PURE__ */new Date){const n=m(e),a=m(t.toISOString());return n&&a?n===a?h(e,{clock:{hour:"numeric",minute:"2-digit"}}):n.slice(0,4)===a.slice(0,4)?u(e,{clock:{day:"numeric",month:"short"}}):u(e,{clock:{day:"numeric",month:"short",year:"numeric"}}):k}function ue(e){return h(e,{clock:{dateStyle:"short",timeStyle:"short"}})}function fe(e){return"owner"===(e.role??"owner")?"me":e.owner?.name??"—"}var pe=new Intl.Collator(void 0,{numeric:!0,sensitivity:"base"});function ke(e,t){const n="asc"===t.dir?1:-1;return[...e].sort((e,a)=>e.kind!==a.kind?"folder"===e.kind?-1:1:n*((e,n)=>{switch(t.key){case"owner":return pe.compare(fe(e),fe(n));case"size":return e.size-n.size;case"modified":return(Date.parse(e.modifiedAt)||0)-(Date.parse(n.modifiedAt)||0);default:return pe.compare(de(e),de(n))}})(e,a)||pe.compare(e.name,a.name))}var ge=["folder","document","spreadsheet","slides","pdf","image","video"],we={today:"Today",week:"Last 7 days",month:"Last 30 days",year:"This year"};function ye(e,t,n=/* @__PURE__ */new Date){const a=t.modified?function(e,t){const n=f(t),a=g(n);if(!n||!a)return Number.NEGATIVE_INFINITY;"week"===e&&a.setDate(a.getDate()-6),"month"===e&&a.setDate(a.getDate()-29),"year"===e&&a.setMonth(0,1);const r=p(w(a),{hour:0,minute:0});return r?Date.parse(r):Number.NEGATIVE_INFINITY}(t.modified,n):null;return e.filter(e=>{if(t.type&&le(e)!==t.type)return!1;if(t.person){const n="owner"===(e.role??"owner");if("me"===t.person?!n:n||e.owner?.id!==t.person)return!1}return null===a||(Date.parse(e.modifiedAt)||0)>=a})}var be=[{value:"viewer",label:"Viewer"},{value:"editor",label:"Editor"}];function ve({store:e,entry:t,onClose:a,onChanged:i}){const[s,l]=Z(null),[o,d]=Z(""),[m,h]=Z([]),[u,f]=Z(!1),[p,k]=Z(""),[g,w]=Z("viewer"),[y,b]=Z(!1),v=X(/* @__PURE__ */new Map),x=t?.id??null;if(q(()=>{if(l(null),k(""),d(""),!x||!e.shares)return;let t=!0;return e.shares(x).then(e=>{t&&l(e)}).catch(e=>{t&&(Q.error(e.message),l([]))}),()=>{t=!1}},[x,e]),q(()=>{if(!e.searchPeople||!x)return;let t=!0;f(!0);const n=setTimeout(()=>{e.searchPeople(o).then(e=>{if(t){for(const t of e)v.current.set(t.id,t);h(e)}}).catch(()=>{t&&h([])}).finally(()=>{t&&f(!1)})},250);return()=>{t=!1,clearTimeout(n)}},[o,x,e]),!t)return null;const N=new Set((s??[]).map(e=>e.person.id)),C=m.filter(e=>!N.has(e.id)).map(e=>({value:e.id,label:e.name})),S=async n=>{b(!0);try{await n(),l(await e.shares(t.id)),i()}catch(e){Q.error(e.message)}finally{b(!1)}};/* @__PURE__ */
|
|
2
|
-
return ne(J,{open:!0,onClose:a,size:"md",title:`Share “${t.name}”`,description:"folder"===t.kind?"Everything inside this folder is shared too. Editors’ uploads count toward your quota.":"Viewers can open and download it. Editors can also replace, rename and delete it.",footer:/* @__PURE__ */ae(V,{variant:"secondary",onClick:a,children:"Done"}),children:[
|
|
3
|
-
/* @__PURE__ */ne("div",{className:"flex items-center gap-2",children:[
|
|
4
|
-
/* @__PURE__ */ae("div",{className:"min-w-0 flex-1",children:/* @__PURE__ */ae(n,{value:p,onChange:k,onSearchChange:d,loading:u&&0===m.length,options:C,placeholder:"Search colleagues by name","aria-label":"Colleague to share with"})}),
|
|
5
|
-
/* @__PURE__ */ae("div",{className:"w-28 shrink-0",children:/* @__PURE__ */ae(r,{value:g,onChange:e=>w(e),options:be,"aria-label":"Access"})}),
|
|
6
|
-
/* @__PURE__ */ae(V,{variant:"primary",onClick:()=>{if(!p||!e.share)return;const n=v.current.get(p);S(async()=>{await e.share(t.id,p,g),k(""),d(""),n&&Q.success(`Shared with ${n.name}`)})},disabled:!p||y,children:"Add"})]}),
|
|
7
|
-
/* @__PURE__ */ae("div",{className:"mt-4 mb-1 text-2xs font-semibold uppercase tracking-wide text-ink-faintest",children:"Who has access"}),null===s?/* @__PURE__ */ae(H,{size:"sm",padding:"p-4",label:"Loading"}):/* @__PURE__ */ne("ul",{className:"divide-y divide-line-subtle text-sm",children:[
|
|
8
|
-
/* @__PURE__ */ne("li",{className:"flex items-center gap-2 h-10",children:[
|
|
9
|
-
/* @__PURE__ */ae("span",{className:"flex-1 truncate",children:"You"}),
|
|
10
|
-
/* @__PURE__ */ae("span",{className:"text-xs text-ink-faint",children:"Owner"})]}),s.map(n=>/* @__PURE__ */ne("li",{className:"flex items-center gap-2 h-10",children:[
|
|
11
|
-
/* @__PURE__ */ae("span",{className:"flex-1 truncate",title:n.person.name,children:n.person.name}),
|
|
12
|
-
/* @__PURE__ */ae("div",{className:"w-28 shrink-0",children:/* @__PURE__ */ae(r,{value:n.role,onChange:a=>S(()=>e.share(t.id,n.person.id,a)),options:be,"aria-label":`Access for ${n.person.name}`,disabled:y})}),
|
|
13
|
-
/* @__PURE__ */ae(c,{"aria-label":`Remove ${n.person.name}`,variant:"ghost",size:"sm",disabled:y,onClick:()=>S(()=>e.unshare(t.id,n.person.id)),children:/* @__PURE__ */ae(Y,{name:"close",className:"h-4 w-4",strokeWidth:1.8})})]},n.person.id))]})]})}function xe({store:e,items:t,from:n,onClose:a,onMove:r}){const[i,s]=Z(n??null),[l,o]=Z(null),[d,m]=Z(!1);q(()=>{t&&s(n??null)},[t,n]),q(()=>{if(!t)return;let n=!0;return m(!0),e.list(i).then(e=>{n&&o(e)}).catch(()=>{n&&o(null)}).finally(()=>{n&&m(!1)}),()=>{n=!1}},[e,i,t]);const h=new Set((t??[]).map(e=>e.id)),u=(l?.entries??[]).filter(e=>"folder"===e.kind&&!h.has(e.id)),f=(l?.folder.path??[]).filter(e=>null!==e.id),p=f.length>1?f[f.length-2].id:null,k=l?.folder,g="viewer"!==(k?.role??"owner"),w=void 0!==n&&i===n,y=t?.length??0,b=1===y?`"${t[0].name}"`:`${y} items`;/* @__PURE__ */
|
|
14
|
-
return ne(J,{open:!!t,onClose:a,title:`Move ${b}`,size:"sm",footer:/* @__PURE__ */ne(re,{children:[
|
|
15
|
-
/* @__PURE__ */ae(V,{variant:"secondary",onClick:a,children:"Cancel"}),
|
|
16
|
-
/* @__PURE__ */ae(V,{variant:"primary",onClick:()=>r(i),disabled:d||!g||w,children:"Move here"})]}),children:[
|
|
17
|
-
/* @__PURE__ */ne("div",{className:"flex items-center gap-1 mb-2 min-h-8",children:[null!==i&&/* @__PURE__ */ae(c,{"aria-label":"Back",size:"sm",onClick:()=>s(p),children:/* @__PURE__ */ae(Y,{name:"arrow-left",className:"h-4 w-4"})}),
|
|
18
|
-
/* @__PURE__ */ae("span",{className:"text-sm font-medium text-ink-strong truncate",children:null===i?"My files":k?.name??""})]}),
|
|
19
|
-
/* @__PURE__ */ae("div",{className:"border border-line rounded-(--radius-control) h-64 overflow-auto",children:d?/* @__PURE__ */ae(H,{size:"sm",padding:"p-6",label:"Loading"}):0===u.length?/* @__PURE__ */ae("div",{className:"p-6 text-center text-sm text-ink-faintest",children:"No folders here."}):/* @__PURE__ */ae("ul",{children:u.map(e=>/* @__PURE__ */ae("li",{children:/* @__PURE__ */ne("button",{type:"button",onClick:()=>s(e.id),className:"flex w-full items-center gap-2 px-3 h-9 text-left text-sm hover:bg-row-hover",children:[
|
|
20
|
-
/* @__PURE__ */ae(Y,{name:"folder",look:"solid",tone:"muted",className:"h-4 w-4 shrink-0"}),
|
|
21
|
-
/* @__PURE__ */ae("span",{className:"truncate flex-1",children:e.name}),
|
|
22
|
-
/* @__PURE__ */ae(Y,{name:"chevron-right",tone:"muted",className:"h-4 w-4 shrink-0"})]})},e.id))})}),!g&&/* @__PURE__ */ae("p",{className:"mt-2 text-xs text-ink-faint",children:"You can view this folder but not move things into it."})]})}function Ne({store:e,entry:t,selectedCount:n,onClose:a}){const[r,i]=Z(null),[s,l]=Z(null);q(()=>{if(i(null),l(null),!t)return;let n=!0;return e.info?.(t.id).then(e=>{n&&i(e)}).catch(()=>{}),e.shares?.(t.id).then(e=>{n&&l(e)}).catch(()=>{}),()=>{n=!1}},[e,t]);const o=t?le(t):null,d=o?ce[o]:null,m=r?.path.slice(0,-1).map(e=>e.name||"My files").join(" / "),h=(e,t)=>t?/* @__PURE__ */ne("div",{className:"py-2",children:[
|
|
23
|
-
/* @__PURE__ */ae("dt",{className:"text-2xs text-ink-faint",children:e}),
|
|
24
|
-
/* @__PURE__ */ae("dd",{className:"text-sm text-ink break-words",children:t})]}):null;/* @__PURE__ */
|
|
25
|
-
return ne("aside",{className:"w-72 shrink-0 border-l border-line flex flex-col min-h-0 bg-surface","aria-label":"Details",children:[
|
|
26
|
-
/* @__PURE__ */ne("div",{className:"flex items-center gap-2 px-3 h-12 shrink-0",children:[d&&/* @__PURE__ */ae(Y,{name:d.name,tone:d.tone,className:"h-5 w-5 shrink-0"}),
|
|
27
|
-
/* @__PURE__ */ae("span",{className:"flex-1 truncate text-sm font-medium text-ink-strong",children:t?de(t):n>1?`${n} items selected`:"Details"}),
|
|
28
|
-
/* @__PURE__ */ae(c,{"aria-label":"Close details",size:"sm",onClick:a,children:/* @__PURE__ */ae(Y,{name:"close",className:"h-4 w-4"})})]}),
|
|
29
|
-
/* @__PURE__ */ae("div",{className:"flex-1 overflow-auto px-4 pb-4",children:t?/* @__PURE__ */ne(re,{children:[
|
|
30
|
-
/* @__PURE__ */ae("div",{className:"h-32 rounded-(--radius-control) bg-surface-sunken flex items-center justify-center mb-3",children:d&&/* @__PURE__ */ae(Y,{name:d.name,tone:d.tone,className:"h-12 w-12"})}),s&&/* @__PURE__ */ne("div",{className:"mb-3",children:[
|
|
31
|
-
/* @__PURE__ */ae("div",{className:"text-xs font-medium text-ink-strong mb-1",children:"Who has access"}),0===s.length?/* @__PURE__ */ne("p",{className:"text-sm text-ink-faint",children:["Only ","owner"!==t.role&&t.role?t.owner?.name??"its owner":"you"]}):/* @__PURE__ */ae("ul",{className:"text-sm text-ink",children:s.map(e=>/* @__PURE__ */ne("li",{className:"flex justify-between py-0.5",children:[
|
|
32
|
-
/* @__PURE__ */ae("span",{className:"truncate",children:e.person.name}),
|
|
33
|
-
/* @__PURE__ */ae("span",{className:"text-ink-faint text-xs",children:"editor"===e.role?"Editor":"Viewer"})]},e.person.id))})]}),
|
|
34
|
-
/* @__PURE__ */ne("dl",{className:"border-t border-line pt-2",children:[h("Type",o?oe[o]:null),"file"===t.kind&&h("Size",me(t)),h("Location",m),h("Owner","me"===fe(t)?"me":fe(t)),h("Modified",t.modifiedAt?`${he(t.modifiedAt)}${t.modifiedBy?` by ${t.modifiedBy.name}`:""}`:null),h("Created",r?.createdAt?he(r.createdAt):null)]})]}):/* @__PURE__ */ae("p",{className:"pt-6 text-center text-sm text-ink-faintest",children:n>1?"Select one item to see its details.":"Select a file or folder to see its details."})})]})}var Ce=e=>"recent"===e||"starred"===e||"shared"===e||"search"===e,Se="files.layout",je={pdf:"pdf",dxf:"dxf",csv:"csv",jpg:"image",jpeg:"image",png:"image",gif:"image",webp:"image",svg:"image",avif:"image",bmp:"image",stp:"3d",step:"3d",stl:"3d",obj:"3d",gltf:"3d",glb:"3d","3mf":"3d",iges:"3d",igs:"3d",ply:"3d",fbx:"3d"},De=[{kind:"document",label:"Document"},{kind:"spreadsheet",label:"Spreadsheet"},{kind:"deck",label:"Slides"}],Me="application/x-efficient-files";function $e(){try{return"grid"===localStorage.getItem(Se)?"grid":"list"}catch{return"list"}}function Te(e){const t=e??"/",n=t.split("/").filter(Boolean);let a=y()??[];for(const e of n){const t=a.find(t=>"folder"===t.kind&&t.name===e);a=t?.children??[]}return{folder:{id:e,name:n[n.length-1]??"",role:"owner",path:[{id:null,name:""},...n.map((e,t)=>({id:"/"+n.slice(0,t+1).join("/"),name:e}))]},entries:a.map(e=>({id:("/"===t?"":t)+"/"+e.name,name:e.name,kind:e.kind,size:e.size??0,modifiedAt:e.modifiedAt??""}))}}function Le(e,t){return`Not enough space for “${e}” (${d(t.attempted)}). You've used ${d(t.used)} of ${d(t.limit)}. Empty Trash or ask an administrator for more space.`}var Re=(e,t)=>e instanceof Error&&e.message||t;function Ae(e){const t=[];for(const n of e)("divider"!==n.type||0!==t.length&&"divider"!==t[t.length-1].type)&&t.push(n);for(;t.length&&"divider"===t[t.length-1].type;)t.pop();return t}function Ie({entry:e,className:t="h-5 w-5"}){const{name:n,tone:a}=ce[le(e)];/* @__PURE__ */
|
|
35
|
-
return ae(Y,{name:n,tone:a,look:"folder"===e.kind?"solid":void 0,className:`${t} shrink-0`})}function Pe({entry:e,read:t}){const[n,a]=Z(null),r="image"===le(e)&&e.size<=5242880;return q(()=>{if(!r||!t||"function"!=typeof URL.createObjectURL)return;let n=!0,i=null;return t(e.id).then(e=>{n&&(i=URL.createObjectURL(e),a(i))}).catch(()=>{}),()=>{n=!1,i&&URL.revokeObjectURL(i)}},[e.id,e.modifiedAt,r,t]),n?/* @__PURE__ */ae("img",{src:n,alt:"",className:"h-full w-full object-cover",draggable:!1}):/* @__PURE__ */ae(Ie,{entry:e,className:"h-10 w-10"})}function Ee(){const n=j(),r=n.title??"Files",m=null!==y(),h=!m&&!!n.shares&&!!n.sharedWithMe,[u,f]=Z(null),[p,k]=Z(null),[g,w]=Z([]),[J,ie]=Z(()=>/* @__PURE__ */new Set),le=X(null),[be,Ee]=Z(!0),[Fe,ze]=Z(!1),[We,Ke]=Z(null),[Oe,Ue]=Z(!1),[Je,Ge]=Z(null),[Ve,Ye]=Z(null),[He,Be]=Z(null),[Qe,Ze]=Z($e),[Xe,qe]=Z(!1),[_e,et]=Z(""),[tt,nt]=Z(""),[at,rt]=Z({}),[it,st]=Z({key:"name",dir:"asc"}),[lt,ot]=Z(()=>{const e=D();return"trash"===e?"trash":e?{desktopFolderId:e.folderId}:"files"}),ct=X("files"),dt=X(lt);dt.current=lt,q(()=>{M()},[]);const[mt,ht]=Z([]),ut=e=>{Ze(e);try{localStorage.setItem(Se,e)}catch{}},ft=_(e=>{ot(e),rt({}),st("recent"===e?{key:"modified",dir:"desc"}:{key:"name",dir:"asc"}),"search"!==e&&(et(""),nt(""))},[]);q(()=>{const e=()=>{M(),ft("trash")},t=e=>{M();const t=e.detail?.folderId;t&&ft({desktopFolderId:t})};return window.addEventListener($,e),window.addEventListener(T,t),()=>{window.removeEventListener($,e),window.removeEventListener(T,t)}},[ft]);const pt=ee(L,R,R),kt="object"==typeof lt?lt.desktopFolderId:null,gt=kt?pt?.folders.find(e=>e.id===kt)??null:null,wt=kt&&pt?.itemsByFolder[kt]||[];q(()=>{kt&&pt&&!pt.folders.some(e=>e.id===kt)&&ft("files")},[kt,pt,ft]);const yt=X(0),bt=X(null),vt=X(null),{openPage:xt,openEntity:Nt}=W(),Ct=i(),St=i(),jt=i(),Dt=ee(b,v,v);q(()=>x(),[]),q(()=>{!Dt||"trash"!==lt&&"object"!=typeof lt||ft("files")},[Dt,lt,ft]);const Mt=t=>{"preview-file"===t.entityType&&t.filePath&&t.fileKind?e({filePath:t.filePath,filename:t.label,kind:t.fileKind,onStaged:e=>xt(e)}):"page"===t.entityType?xt(t.entityId):Nt(t.entityType,t.entityId,null,t.label)},$t=_(async()=>{if(!m)try{Ke(await n.quota())}catch{}},[n,m]),Tt=_(async(e,t)=>{Ee(!0);try{await e(),ze(!1)}catch(e){e instanceof TypeError?ze(!0):Q.error(Re(e,t))}finally{Ee(!1)}},[]),Lt=_(async e=>{if(m)return k(Te(e)),ze(!1),void Ee(!1);await Tt(async()=>{k(await n.list(e))},"Failed to list"),$t()},[n,$t,m,Tt]),Rt=_(async(e,t)=>{if("search"===e&&!n.search){const e=t.toLowerCase(),a=m?Te(u):await n.list(u).catch(()=>null);return w((a?.entries??[]).filter(t=>t.name.toLowerCase().includes(e))),void Ee(!1)}const a={recent:()=>n.recent?.()??Promise.resolve([]),starred:()=>n.starred?.()??Promise.resolve([]),shared:()=>n.sharedWithMe?.()??Promise.resolve([]),search:()=>n.search?.(t)??Promise.resolve([])}[e];await Tt(async()=>{w(await a())},"Failed to list files")},[n,m,u,Tt]),At=_(async()=>{if(m)return ht([]),void Ee(!1);await Tt(async()=>{ht(await n.trash())},"Failed to list trash"),$t()},[n,$t,m,Tt]),It=()=>{"files"===lt?Lt(u):Ce(lt)?Rt(lt,tt):"trash"===lt&&At()};q(()=>{ie(/* @__PURE__ */new Set),le.current=null,It()},[u,lt,tt]),q(()=>{const e=_e.trim();if(!e)return;const t=setTimeout(()=>{e===tt&&"search"===dt.current||("search"!==dt.current&&(ct.current=dt.current),ot("search"),rt({}),nt(e))},300);return()=>clearTimeout(t)},[_e]);const Pt=()=>{et(""),"search"===dt.current&&ft(ct.current)},Et=e=>{ft("files"),f(e)},Ft=async(e,t)=>{try{await e()}catch(e){Q.error(Re(e,t))}It()},zt=e=>Ft(async()=>{await n.restore(e.id),Q.success(`Restored "${e.name}"`)},"Restore failed"),Wt=async e=>{await O({title:"Permanently delete",message:`"${e.name}" will be permanently removed. This can't be undone.`,confirmLabel:"Delete forever",variant:"danger"})&&Ft(()=>n.purge(e.id),"Delete failed")},Kt=async e=>{try{const t=await n.read(e.id),a=URL.createObjectURL(t),r=document.createElement("a");r.href=a,r.download=e.name,r.click(),setTimeout(()=>URL.revokeObjectURL(a),1e3)}catch(e){Q.error(Re(e,"Download failed"))}},Ot="files"===lt?p?.folder??null:null,Ut=Ot?.role??"owner",Jt="owner"!==Ut,Gt="files"===lt?u:null,Vt=!m&&("files"!==lt||"viewer"!==Ut),Yt=!m&&"files"===lt&&"viewer"!==Ut,Ht=async(e,{withFolders:t=!1}={})=>{let a=0;for(const r of Array.from(e)){const e=r.webkitRelativePath??"",i=t?e.split("/").slice(0,-1).join("/"):"";try{await n.upload(Gt,r,i?{folderPath:i}:void 0),a++}catch(e){e instanceof F?Q.error(Le(r.name,e)):Q.error(`Upload ${r.name}: ${Re(e,"failed")}`)}}a>1&&Q.success(`Uploaded ${a} files`),"files"===lt?Lt(u):Et(null)},Bt=async e=>{const t=de(e),a=await U({title:`Rename ${e.kind}`,defaultValue:t,confirmLabel:"Rename"});a&&a!==t&&(/[\\/]/.test(a)?Q.error("Names cannot contain slashes"):Ft(()=>n.rename(e.id,function(e,t){const n=e.officeKind?z[e.officeKind]:"";return n&&!t.toLowerCase().endsWith(n)?t+n:t}(e,a)),"Rename failed"))},Qt=async e=>{if(0===e.length)return;const t=1===e.length?e[0]:null,a=e.some(e=>"owner"!==(e.role??"owner")),r=t?(t.owner??p?.folder.owner)?.name??"its owner":"their owners";await O({title:t?`Move ${t.kind} to trash`:`Move ${e.length} items to trash`,message:(t?`"${de(t)}"${"folder"===t.kind?" and everything inside":""}`:`${e.length} items`)+" will move to "+(a?`${r}'s Trash.`:"Trash. You can restore it from there."),confirmLabel:"Move to trash",variant:"danger"})&&(await Ft(async()=>{for(const t of e)await n.remove(t.id)},"Delete failed"),Q.success(t?`"${de(t)}" moved to trash`:`${e.length} items moved to trash`))},Zt=(e,t)=>Ft(async()=>{for(const a of e)await n.setStarred(a.id,t)},t?"Star failed":"Unstar failed"),Xt=async(e,t)=>{Be(null);const a=e.filter(e=>e.id!==t);0!==a.length&&(await Ft(async()=>{for(const e of a)await n.move(e.id,t)},"Move failed"),Q.success(1===a.length?`Moved "${de(a[0])}"`:`Moved ${a.length} items`))},qt=()=>{yt.current=0,Ue(!1),Ge(null)};q(()=>{const e=()=>qt();return window.addEventListener("dragend",e),window.addEventListener("drop",e),()=>{window.removeEventListener("dragend",e),window.removeEventListener("drop",e)}},[]);const _t="files"===lt?p?.entries??[]:Ce(lt)?g:[],en=te(()=>ke(ye(_t,at),it),[_t,at,it]),tn=te(()=>new Map(en.map(e=>[e.id,e])),[en]),nn=[...J].map(e=>tn.get(e)).filter(e=>!!e),an=1===nn.length?nn[0]:null,rn=e=>e.role??("files"===lt?Ut:"owner"),sn=e=>!m&&"viewer"!==rn(e),ln=e=>h&&"owner"===rn(e),on=e=>!!n.move&&sn(e),cn=(e,t)=>{if(Dt){const t=tn.get(e);if(t&&"file"===t.kind&&!mn(t))return;return void ie(/* @__PURE__ */new Set([e]))}if(t.shiftKey&&le.current){const t=en.map(e=>e.id),n=t.indexOf(le.current),a=t.indexOf(e);if(n>=0&&a>=0)return void ie(new Set(t.slice(Math.min(n,a),Math.max(n,a)+1)))}le.current=e,t.metaKey||t.ctrlKey?ie(t=>{const n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n}):ie(/* @__PURE__ */new Set([e]))},dn=()=>{ie(/* @__PURE__ */new Set),le.current=null},mn=e=>!!Dt&&"file"===e.kind&&C(Dt.request,e.name),hn=e=>Dt&&"file"===e.kind&&!mn(e)?"text-ink-faintest":"",un=e=>{if(!Dt||!mn(e))return;const t="files"===lt?p?.folder:null,n=t?["owner"===t.role?"My files":"Shared with me",...t.path.filter(e=>null!==e.id).map(e=>e.name)].join(" › "):"shared"===lt?"Shared with me":"My files";N(Dt.id,{entry:e,folderId:"files"===lt?u:null,location:n})},fn=Dt&&an&&mn(an)?an:null,pn=t=>{"folder"===t.kind?Et(t.id):Dt?un(t):(async t=>{if(m)return;if(n.open?.(t))return;const a=je[se(t.name)];a?await e({filePath:n.shortcutPath?.(t.id)??t.id,filename:t.name,kind:a,load:()=>n.read(t.id),onStaged:e=>xt(e)}):Kt(t)})(t)},kn=e=>{if(0===e.length)return[];const t=1===e.length?e[0]:null;if(Dt)return t&&("folder"===t.kind||mn(t))?[{key:"open",label:"Open",icon:/* @__PURE__ */ae(Y,{name:"external",className:"h-4 w-4"}),onSelect:()=>pn(t)}]:[];const a=t&&"file"===t.kind&&n.openLabel?.(t)||"Open",r=e.every(e=>"file"===e.kind),i=e.every(sn);if(m)return t?[{key:"open",label:"Open",icon:/* @__PURE__ */ae(Y,{name:"external",className:"h-4 w-4"}),onSelect:()=>pn(t)}]:[];const s=e.some(e=>!e.starred);return Ae([...t?[{key:"open",label:a,icon:/* @__PURE__ */ae(Y,{name:"external",className:"h-4 w-4"}),onSelect:()=>pn(t)}]:[],{type:"divider",key:"d1"},...r?[{key:"download",label:"Download",icon:/* @__PURE__ */ae(Y,{name:"download",className:"h-4 w-4"}),onSelect:()=>{e.forEach(Kt)}}]:[],...t&&i?[{key:"rename",label:"Rename",icon:/* @__PURE__ */ae(Y,{name:"edit",className:"h-4 w-4"}),onSelect:()=>Bt(t)}]:[],...r&&n.copy?[{key:"copy",label:"Make a copy",icon:/* @__PURE__ */ae(Y,{name:"copy",className:"h-4 w-4"}),onSelect:()=>(e=>Ft(async()=>{for(const t of e)await n.copy(t.id);Q.success(1===e.length?`Copied "${de(e[0])}"`:`Copied ${e.length} files`)},"Copy failed"))(e)}]:[],{type:"divider",key:"d2"},...t&&ln(t)?[{key:"share",label:"Share",icon:/* @__PURE__ */ae(Y,{name:"add-person",className:"h-4 w-4"}),onSelect:()=>Ye(t)}]:[],...e.every(on)?[{key:"move",label:"Move",icon:/* @__PURE__ */ae(Y,{name:"forward",className:"h-4 w-4"}),onSelect:()=>Be(e)}]:[],...n.setStarred?[{key:"star",label:s?"Add to starred":"Remove from starred",icon:/* @__PURE__ */ae(Y,{name:"star",className:"h-4 w-4"}),onSelect:()=>Zt(e,s)}]:[],...t?[{key:"info",label:"File information",icon:/* @__PURE__ */ae(Y,{name:"info",className:"h-4 w-4"}),onSelect:()=>{ie(/* @__PURE__ */new Set([t.id])),qe(!0)}}]:[],{type:"divider",key:"d3"},...i?[{key:"trash",label:"Move to trash",danger:!0,icon:/* @__PURE__ */ae(Y,{name:"trash",className:"h-4 w-4"}),onSelect:()=>Qt(e)}]:[]])},gn=(e,t)=>{const n=J.has(t.id)?nn:[t];Ct.open(e,n)&&!J.has(t.id)&&(ie(/* @__PURE__ */new Set([t.id])),le.current=t.id)},wn=e=>on(e)?{draggable:!0,onDragStart:t=>{const n=J.has(e.id)?nn:[e];t.dataTransfer.setData(Me,JSON.stringify(n.map(e=>e.id))),t.dataTransfer.effectAllowed="move"}}:{},yn=e=>"folder"===e.kind&&sn(e)&&n.move?{onDragOver:t=>{t.dataTransfer.types.includes(Me)&&(t.preventDefault(),t.stopPropagation(),Je!==e.id&&Ge(e.id))},onDragLeave:()=>{Je===e.id&&Ge(null)},onDrop:t=>{if(!t.dataTransfer.types.includes(Me))return;t.preventDefault(),t.stopPropagation(),Ge(null);const n=JSON.parse(t.dataTransfer.getData(Me)||"[]").map(e=>tn.get(e)).filter(t=>!!t&&t.id!==e.id);Xt(n,e.id)}}:{};if(Fe)/* @__PURE__ */
|
|
36
|
-
return ne("div",{className:"flex flex-col h-full bg-surface",children:[
|
|
37
|
-
/* @__PURE__ */ae(K,{title:`${r} - offline`}),
|
|
38
|
-
/* @__PURE__ */ae("div",{className:"flex-1 flex items-center justify-center p-8 text-center",children:/* @__PURE__ */ne("div",{className:"max-w-md",children:[
|
|
39
|
-
/* @__PURE__ */ae(Y,{name:"close-circle",tone:"muted",className:"h-12 w-12 mx-auto mb-3",strokeWidth:1.4}),A()?/* @__PURE__ */ne(re,{children:[
|
|
40
|
-
/* @__PURE__ */ae("h3",{className:"text-base font-semibold text-ink-strong mb-1",children:"Can't reach your files"}),
|
|
41
|
-
/* @__PURE__ */ae("p",{className:"text-sm text-ink-faint mb-3",children:"Check your connection and try again."})]}):/* @__PURE__ */ne(re,{children:[
|
|
42
|
-
/* @__PURE__ */ae("h3",{className:"text-base font-semibold text-ink-strong mb-1",children:"Can't reach the file server"}),
|
|
43
|
-
/* @__PURE__ */ne("p",{className:"text-sm text-ink-faint mb-3",children:["No response from the file server. Make sure the server is running — see ",
|
|
44
|
-
/* @__PURE__ */ae("span",{className:"font-mono",children:"examples/file-server/README.md"}),"."]})]}),
|
|
45
|
-
/* @__PURE__ */ae(V,{variant:"primary",onClick:It,children:"Retry"})]})})]});const bn=We&&We.limit>0?Math.min(100,Math.round(We.used/We.limit*100)):0,vn=bn>90?"bg-danger":bn>75?"bg-warning":"bg-accent-fill",xn=[Jt?{label:"Shared with me",onClick:()=>ft("shared")}:{label:"My files",onClick:()=>Et(null)},...(Ot?.path??[]).filter(e=>null!==e.id).map(e=>({label:e.name,onClick:()=>Et(e.id)}))],Nn="recent"===lt?"Recent":"starred"===lt?"Starred":"shared"===lt?"Shared with me":"search"===lt?`Results for “${tt}”`:"trash"===lt?"Trash":gt?gt.name:null,Cn=Dt?`${r} - Choosing`:Nn?`${r} - ${"search"===lt?"Search":Nn}`:Ot&&null!==Ot.id?`${r} - ${Ot.name}`:r,Sn=e=>"flex w-full items-center gap-3 rounded-full px-3 min-h-(--row-height-menu) py-2 text-left text-sm transition-colors "+(e?"bg-accent-tint font-medium text-accent-text":"text-ink hover:bg-row-hover"),jn=Ae([{key:"folder",label:"New folder",icon:/* @__PURE__ */ae(Y,{name:"folder-plus",className:"h-4 w-4"}),onSelect:async()=>{const e=await U({title:"New folder",placeholder:"Folder name",defaultValue:"Untitled folder",confirmLabel:"Create"});e&&(/[\\/]/.test(e)?Q.error("Folder names cannot contain slashes"):(await Ft(()=>n.createFolder(Gt,e),"Create folder failed"),"files"!==lt&&Et(null)))}},{type:"divider",key:"d1"},{key:"upload",label:"File upload",icon:/* @__PURE__ */ae(Y,{name:"upload",className:"h-4 w-4"}),onSelect:()=>bt.current?.click()},...n.folderUpload?[{key:"upload-folder",label:"Folder upload",icon:/* @__PURE__ */ae(Y,{name:"cloud-arrow-up",className:"h-4 w-4"}),onSelect:()=>vt.current?.click()}]:[],{type:"divider",key:"d2"},...n.createOfficeFile?De.filter(e=>!n.officeKinds||n.officeKinds.includes(e.kind)).map(e=>{const t=ce["deck"===e.kind?"slides":e.kind];return{key:e.kind,label:e.label,icon:/* @__PURE__ */ae(Y,{name:t.name,tone:t.tone,className:"h-4 w-4"}),onSelect:()=>{Promise.resolve(n.createOfficeFile(e.kind,Gt)).catch(e=>Q.error(Re(e,"Could not create it")))}}}):[]]),Dn=/* @__PURE__ */ne("div",{className:"flex h-full flex-col",children:[
|
|
46
|
-
/* @__PURE__ */ae("div",{className:"p-3 pb-2",children:/* @__PURE__ */ae(o,{trigger:/* @__PURE__ */ne(re,{children:[
|
|
47
|
-
/* @__PURE__ */ae(Y,{name:"add",className:"h-5 w-5"}),
|
|
48
|
-
/* @__PURE__ */ae("span",{children:"New"})]}),items:jn,align:"start","aria-label":"New",disabled:!Vt,triggerClassName:"inline-flex items-center gap-2 h-11 pl-4 pr-5 rounded-2xl bg-surface-raised border border-line shadow-sm text-sm font-medium text-ink-strong hover:bg-row-hover disabled:opacity-50 rosh-focus-ring focus-visible:ring-2"})}),
|
|
49
|
-
/* @__PURE__ */ne("nav",{className:"px-2 flex-1 overflow-auto","aria-label":"Locations",children:[
|
|
50
|
-
/* @__PURE__ */ne("button",{onClick:()=>Et(null),className:Sn("files"===lt&&!Jt),children:[
|
|
51
|
-
/* @__PURE__ */ae(Y,{name:"home",className:"h-4 w-4 shrink-0",strokeWidth:1.6}),"My files"]}),n.recent&&!m&&/* @__PURE__ */ne("button",{onClick:()=>ft("recent"),className:Sn("recent"===lt),children:[
|
|
52
|
-
/* @__PURE__ */ae(Y,{name:"clock",className:"h-4 w-4 shrink-0",strokeWidth:1.6}),"Recent"]}),n.starred&&!m&&/* @__PURE__ */ne("button",{onClick:()=>ft("starred"),className:Sn("starred"===lt),children:[
|
|
53
|
-
/* @__PURE__ */ae(Y,{name:"star",className:"h-4 w-4 shrink-0",strokeWidth:1.6}),"Starred"]}),h&&/* @__PURE__ */ne("button",{onClick:()=>ft("shared"),className:Sn("shared"===lt||"files"===lt&&Jt),children:[
|
|
54
|
-
/* @__PURE__ */ae(Y,{name:"team",className:"h-4 w-4 shrink-0",strokeWidth:1.6}),"Shared with me"]}),!m&&/* @__PURE__ */ne("button",{onClick:()=>ft("trash"),className:Sn("trash"===lt),children:[
|
|
55
|
-
/* @__PURE__ */ae(Y,{name:"trash",className:"h-4 w-4 shrink-0",strokeWidth:1.6}),"Trash"]}),pt&&pt.folders.length>0&&/* @__PURE__ */ne(re,{children:[
|
|
56
|
-
/* @__PURE__ */ae("div",{className:"px-3 pt-4 pb-1 text-2xs font-semibold uppercase tracking-wide text-ink-faintest",children:"Desktop"}),pt.folders.map(e=>/* @__PURE__ */ne("button",{onClick:()=>ft({desktopFolderId:e.id}),className:Sn(kt===e.id),children:[
|
|
57
|
-
/* @__PURE__ */ae(I,{className:"h-4 w-4 shrink-0 text-amber-500"}),
|
|
58
|
-
/* @__PURE__ */ae("span",{className:"truncate",children:e.name}),
|
|
59
|
-
/* @__PURE__ */ae(G,{count:e.itemCount,active:kt===e.id,className:"ml-auto"})]},e.id))]})]}),We&&/* @__PURE__ */ne("div",{className:"px-5 py-3 shrink-0",title:`${d(We.used)} of ${d(We.limit)} used`,children:[
|
|
60
|
-
/* @__PURE__ */ae("div",{className:"h-1 rounded-full bg-line overflow-hidden",children:/* @__PURE__ */ae("div",{className:`h-full ${vn} transition-all`,style:{width:`${bn}%`}})}),
|
|
61
|
-
/* @__PURE__ */ne("div",{className:"mt-2 text-2xs text-ink-faint tabular-nums",children:[d(We.used)," of ",d(We.limit)," used"]})]})]}),Mn=(e,t)=>/* @__PURE__ */ne("span",{className:"inline-flex items-center gap-1",children:[e,
|
|
62
|
-
/* @__PURE__ */ae(Y,{name:"chevron-down",className:"h-3.5 w-3.5"}),t?"":null]}),$n=e=>"inline-flex items-center h-7 px-3 rounded-(--radius-control) border text-xs whitespace-nowrap rosh-focus-ring focus-visible:ring-2 "+(e?"border-accent-border bg-accent-tint text-accent-text":"border-line-strong text-ink-muted hover:bg-row-hover"),Tn=Ce(lt)||"files"===lt,Ln=function(e){const t=/* @__PURE__ */new Map;for(const n of e)"owner"!==(n.role??"owner")&&n.owner&&t.set(n.owner.id,n.owner.name);return[...t].map(([e,t])=>({id:e,name:t})).sort((e,t)=>pe.compare(e.name,t.name))}(_t),Rn=Tn&&_t.length>0?/* @__PURE__ */ne("div",{className:"flex items-center gap-2 shrink-0",children:[
|
|
63
|
-
/* @__PURE__ */ae(o,{trigger:Mn(at.type?oe[at.type]:"Type",!!at.type),"aria-label":"Type",triggerClassName:$n(!!at.type),items:[...ge.map(e=>({type:"radio",key:e,label:oe[e],checked:at.type===e,onSelect:()=>rt(t=>({...t,type:t.type===e?null:e}))})),...at.type?[{type:"divider",key:"d"},{key:"clear",label:"Clear",onSelect:()=>rt(e=>({...e,type:null}))}]:[]]}),h&&/* @__PURE__ */ae(o,{trigger:Mn(at.person?"me"===at.person?"Owned by me":Ln.find(e=>e.id===at.person)?.name??"People":"People",!!at.person),"aria-label":"People",triggerClassName:$n(!!at.person),items:[{type:"radio",key:"me",label:"Owned by me",checked:"me"===at.person,onSelect:()=>rt(e=>({...e,person:"me"===e.person?null:"me"}))},...Ln.map(e=>({type:"radio",key:e.id,label:e.name,checked:at.person===e.id,onSelect:()=>rt(t=>({...t,person:t.person===e.id?null:e.id}))})),...at.person?[{type:"divider",key:"d"},{key:"clear",label:"Clear",onSelect:()=>rt(e=>({...e,person:null}))}]:[]]}),
|
|
64
|
-
/* @__PURE__ */ae(o,{trigger:Mn(at.modified?we[at.modified]:"Modified",!!at.modified),"aria-label":"Modified",triggerClassName:$n(!!at.modified),items:[...Object.keys(we).map(e=>({type:"radio",key:e,label:we[e],checked:at.modified===e,onSelect:()=>rt(t=>({...t,modified:t.modified===e?null:e}))})),...at.modified?[{type:"divider",key:"d"},{key:"clear",label:"Clear",onSelect:()=>rt(e=>({...e,modified:null}))}]:[]]})]}):null,An=Tn&&nn.length>0&&!Dt?/* @__PURE__ */ne("div",{className:"flex items-center gap-0.5 h-10 px-2 rounded-full bg-surface-sunken",role:"toolbar","aria-label":"Selection",children:[
|
|
65
|
-
/* @__PURE__ */ae(c,{"aria-label":"Clear selection",size:"sm",onClick:dn,children:/* @__PURE__ */ae(Y,{name:"close",className:"h-4 w-4"})}),
|
|
66
|
-
/* @__PURE__ */ne("span",{className:"text-sm text-ink mr-2 whitespace-nowrap",children:[nn.length," selected"]}),an&&ln(an)&&/* @__PURE__ */ae(c,{"aria-label":"Share",size:"sm",onClick:()=>Ye(an),children:/* @__PURE__ */ae(Y,{name:"add-person",className:"h-4 w-4"})}),!m&&nn.every(e=>"file"===e.kind)&&/* @__PURE__ */ae(c,{"aria-label":"Download",size:"sm",onClick:()=>nn.forEach(Kt),children:/* @__PURE__ */ae(Y,{name:"download",className:"h-4 w-4"})}),nn.every(on)&&/* @__PURE__ */ae(c,{"aria-label":"Move",size:"sm",onClick:()=>Be(nn),children:/* @__PURE__ */ae(Y,{name:"forward",className:"h-4 w-4"})}),!m&&nn.every(sn)&&/* @__PURE__ */ae(c,{"aria-label":"Move to trash",size:"sm",onClick:()=>Qt(nn),children:/* @__PURE__ */ae(Y,{name:"trash",className:"h-4 w-4"})}),
|
|
67
|
-
/* @__PURE__ */ae(o,{trigger:/* @__PURE__ */ae(Y,{name:"more-vertical",className:"h-4 w-4"}),"aria-label":"More actions",items:kn(nn)})]}):null,In=/* @__PURE__ */ae("div",{className:"flex items-center gap-2 px-4 pb-2 min-h-12 shrink-0",children:An??/* @__PURE__ */ne(re,{children:[
|
|
68
|
-
/* @__PURE__ */ne("div",{className:"min-w-0 flex-1 flex items-center gap-2",children:["files"===lt?/* @__PURE__ */ae("div",{className:"min-w-0 text-base [&_*]:text-base",children:/* @__PURE__ */ae(a,{items:xn,maxItems:5})}):"trash"===lt?/* @__PURE__ */ae("span",{className:"text-base font-medium text-ink-strong",children:"Trash"}):"object"==typeof lt?/* @__PURE__ */ne(re,{children:[
|
|
69
|
-
/* @__PURE__ */ae(I,{className:"h-4 w-4 text-amber-500 shrink-0"}),
|
|
70
|
-
/* @__PURE__ */ae("span",{className:"text-base font-medium text-ink-strong truncate",children:gt?.name??"Desktop folder"}),
|
|
71
|
-
/* @__PURE__ */ae("span",{className:"text-2xs text-ink-faintest whitespace-nowrap",children:"Desktop shortcuts"})]}):/* @__PURE__ */ae("span",{className:"text-base font-medium text-ink-strong truncate",children:Nn}),"files"===lt&&Jt&&"viewer"===Ut&&/* @__PURE__ */ne("span",{className:"shrink-0 inline-flex items-center gap-1 rounded-full bg-surface-sunken px-2 py-0.5 text-2xs text-ink-faint whitespace-nowrap",children:[
|
|
72
|
-
/* @__PURE__ */ae(Y,{name:"eye",className:"h-3 w-3",strokeWidth:1.8}),"View only"]}),"files"===lt&&Jt&&Ot?.owner&&/* @__PURE__ */ne("span",{className:"shrink-0 text-2xs text-ink-faint whitespace-nowrap",children:["Shared by ",Ot.owner.name]})]}),Rn,"trash"===lt&&/* @__PURE__ */ae(V,{variant:"secondary-danger",size:"sm",onClick:async()=>{if(0===mt.length)return;await O({title:"Empty trash",message:`${mt.length} item${1===mt.length?"":"s"} will be permanently removed. This can't be undone.`,confirmLabel:"Empty trash",variant:"danger"})&&Ft(()=>n.emptyTrash(),"Empty trash failed")},disabled:0===mt.length,children:"Empty trash"})]})}),Pn=(e,t)=>Dt?null:/* @__PURE__ */ne("div",{className:"flex items-center justify-end "+(t?"":"opacity-0 group-hover:opacity-100 group-focus-within:opacity-100"),children:[ln(e)&&/* @__PURE__ */ae(c,{"aria-label":"Share",size:"sm",onClick:t=>{t.stopPropagation(),Ye(e)},children:/* @__PURE__ */ae(Y,{name:"add-person",className:"h-4 w-4"})}),!m&&"file"===e.kind&&/* @__PURE__ */ae(c,{"aria-label":"Download",size:"sm",onClick:t=>{t.stopPropagation(),Kt(e)},children:/* @__PURE__ */ae(Y,{name:"download",className:"h-4 w-4"})}),n.setStarred&&!m&&/* @__PURE__ */ae(c,{"aria-label":e.starred?"Remove from starred":"Add to starred","aria-pressed":!!e.starred,size:"sm",onClick:t=>{t.stopPropagation(),Zt([e],!e.starred)},children:/* @__PURE__ */ae(Y,{name:"star",look:e.starred?"solid":void 0,tone:e.starred?"warning":void 0,className:"h-4 w-4"})}),
|
|
73
|
-
/* @__PURE__ */ae("span",{onClick:e=>e.stopPropagation(),onDoubleClick:e=>e.stopPropagation(),children:/* @__PURE__ */ae(o,{trigger:/* @__PURE__ */ae(Y,{name:"more-vertical",className:"h-4 w-4"}),"aria-label":"More actions",items:kn(J.has(e.id)&&nn.length>1?nn:[e])})})]}),En=e=>/* @__PURE__ */ne("span",{className:"flex items-center gap-3 min-w-0",children:[
|
|
74
|
-
/* @__PURE__ */ae(Ie,{entry:e}),
|
|
75
|
-
/* @__PURE__ */ae("span",{className:"truncate",title:e.name,children:de(e)}),!!e.shareCount&&/* @__PURE__ */ae("span",{className:"shrink-0",role:"img","aria-label":"Shared with "+(1===e.shareCount?"1 person":`${e.shareCount} people`),title:"Shared with "+(1===e.shareCount?"1 person":`${e.shareCount} people`),children:/* @__PURE__ */ae(Y,{name:"team",tone:"muted",className:"h-3.5 w-3.5"})}),e.starred&&/* @__PURE__ */ae("span",{className:"shrink-0",role:"img","aria-label":"Starred",title:"Starred",children:/* @__PURE__ */ae(Y,{name:"star",look:"solid",tone:"warning",className:"h-3.5 w-3.5"})})]}),Fn=(e,t,n)=>{const a=it.key===e;/* @__PURE__ */
|
|
76
|
-
return ae("th",{className:`${B} font-medium px-3 h-9 ${n}`,"aria-sort":a?"asc"===it.dir?"ascending":"descending":void 0,children:/* @__PURE__ */ne("button",{type:"button",className:"inline-flex items-center gap-1 rounded hover:text-ink "+(a?"text-ink":""),onClick:()=>st(t=>({key:e,dir:t.key===e&&"asc"===t.dir?"desc":"asc"})),children:[t,a&&("asc"===it.dir?/* @__PURE__ */ae(Y,{name:"arrow-up",className:"h-3 w-3"}):/* @__PURE__ */ae(Y,{name:"arrow-down",className:"h-3 w-3"}))]})})},zn="recent"===lt?"Files you and your colleagues change show here.":"starred"===lt?"Star the files and folders you want to find quickly.":"shared"===lt?"Nothing has been shared with you yet. Files and folders colleagues share with you show here.":"search"===lt?`Nothing matches “${tt}”.`:null,Wn=0===en.length?be?/* @__PURE__ */ae(H,{size:"sm",padding:"p-6",label:"Loading"}):/* @__PURE__ */ae("div",{className:"p-10 text-center text-sm text-ink-faintest",children:_t.length>0?"Nothing matches these filters.":zn??/* @__PURE__ */ne(re,{children:["This folder is empty.",Yt&&/* @__PURE__ */ne(re,{children:[" Drop files here or choose ",
|
|
77
|
-
/* @__PURE__ */ae("span",{className:"font-medium",children:"New"}),"."]})]})}):"grid"===Qe?/* @__PURE__ */ae("div",{className:"px-4 pb-4",children:["folder","file"].map(e=>{const t=en.filter(t=>t.kind===e);return 0===t.length?null:/* @__PURE__ */ne("section",{className:"mb-4",children:[
|
|
78
|
-
/* @__PURE__ */ae("h3",{className:"text-xs font-medium text-ink-faint mb-2",children:"folder"===e?"Folders":"Files"}),
|
|
79
|
-
/* @__PURE__ */ae("div",{className:"grid gap-3",style:{gridTemplateColumns:"repeat(auto-fill, minmax(180px, 1fr))"},children:t.map(t=>{const a=J.has(t.id);/* @__PURE__ */
|
|
80
|
-
return ne("div",{role:"button",tabIndex:0,"aria-pressed":a,"aria-label":de(t),onClick:e=>cn(t.id,e),onDoubleClick:()=>pn(t),onContextMenu:e=>gn(e,t),...wn(t),...yn(t),className:"group rounded-xl border cursor-default select-none outline-none focus-visible:ring-2 focus-visible:ring-accent-border "+(a||Je===t.id?"border-accent-border bg-accent-tint":"border-line bg-surface-sunken hover:bg-row-hover"),children:[
|
|
81
|
-
/* @__PURE__ */ne("div",{className:"flex items-center gap-2 pl-3 pr-1 h-11",children:[
|
|
82
|
-
/* @__PURE__ */ae(Ie,{entry:t,className:"h-4 w-4"}),
|
|
83
|
-
/* @__PURE__ */ae("span",{className:"flex-1 truncate text-sm",title:t.name,children:de(t)}),
|
|
84
|
-
/* @__PURE__ */ae("span",{onClick:e=>e.stopPropagation(),onDoubleClick:e=>e.stopPropagation(),children:/* @__PURE__ */ae(o,{trigger:/* @__PURE__ */ae(Y,{name:"more-vertical",className:"h-4 w-4"}),"aria-label":"More actions",items:kn(a&&nn.length>1?nn:[t])})})]}),"file"===e&&/* @__PURE__ */ne(re,{children:[
|
|
85
|
-
/* @__PURE__ */ae("div",{className:"mx-2 h-28 rounded-lg bg-surface flex items-center justify-center overflow-hidden",children:/* @__PURE__ */ae(Pe,{entry:t,read:m?void 0:n.read})}),
|
|
86
|
-
/* @__PURE__ */ne("div",{className:"px-3 py-2 text-2xs text-ink-faint truncate",children:["me"===fe(t)?"You":fe(t)," · ",he(t.modifiedAt)]})]})]},t.id)})})]},e)})}):/* @__PURE__ */ne("table",{className:"w-full text-sm table-fixed",children:[
|
|
87
|
-
/* @__PURE__ */ae("thead",{className:"text-xs text-ink-faint border-b border-line",children:/* @__PURE__ */ne("tr",{children:[Fn("name","Name","text-left"),h&&Fn("owner","Owner","text-left w-32"),Fn("modified","Modified","text-left w-28"),Fn("size","Size","text-right w-20"),
|
|
88
|
-
/* @__PURE__ */ae("th",{className:`${B} w-32`,children:/* @__PURE__ */ae("span",{className:"sr-only",children:"Actions"})})]})}),
|
|
89
|
-
/* @__PURE__ */ae("tbody",{children:en.map(e=>{const t=J.has(e.id);/* @__PURE__ */
|
|
90
|
-
return ne("tr",{"aria-selected":t,onClick:t=>cn(e.id,t),onDoubleClick:()=>pn(e),onContextMenu:t=>gn(t,e),...wn(e),...yn(e),className:`group cursor-default select-none border-b border-line-subtle ${hn(e)} ${t||Je===e.id?"bg-accent-tint":"hover:bg-row-hover"}`,children:[
|
|
91
|
-
/* @__PURE__ */ae("td",{className:"px-3 h-11",children:En(e)}),h&&/* @__PURE__ */ae("td",{className:"px-3 h-11 text-ink-faint truncate",children:fe(e)}),
|
|
92
|
-
/* @__PURE__ */ae("td",{className:"px-3 h-11 text-ink-faint whitespace-nowrap",title:ue(e.modifiedAt),children:he(e.modifiedAt)}),
|
|
93
|
-
/* @__PURE__ */ae("td",{className:"px-3 h-11 text-right tabular-nums text-ink-faint whitespace-nowrap",children:Dt&&"file"===e.kind&&!mn(e)&&Dt.request.otherLabel?Dt.request.otherLabel:me(e)}),
|
|
94
|
-
/* @__PURE__ */ae("td",{className:"px-2 h-11",children:Pn(e,t)})]},e.id)})})]}),Kn=be&&0===mt.length?/* @__PURE__ */ae(H,{size:"sm",padding:"p-6",label:"Loading"}):0===mt.length?/* @__PURE__ */ae("div",{className:"p-10 text-center text-sm text-ink-faintest",children:"Trash is empty. What you delete stays here for 30 days."}):/* @__PURE__ */ne("table",{className:"w-full text-sm table-fixed",children:[
|
|
95
|
-
/* @__PURE__ */ae("thead",{className:"text-xs text-ink-faint border-b border-line",children:/* @__PURE__ */ne("tr",{children:[
|
|
96
|
-
/* @__PURE__ */ae("th",{className:`${B} text-left font-medium px-3 h-9`,children:"Name"}),
|
|
97
|
-
/* @__PURE__ */ae("th",{className:`${B} text-left font-medium px-3 h-9 w-48`,children:"Original location"}),
|
|
98
|
-
/* @__PURE__ */ae("th",{className:`${B} text-left font-medium px-3 h-9 w-32`,children:"Deleted"}),
|
|
99
|
-
/* @__PURE__ */ae("th",{className:`${B} text-right font-medium px-3 h-9 w-24`,children:"Size"}),
|
|
100
|
-
/* @__PURE__ */ae("th",{className:`${B} w-28`,children:/* @__PURE__ */ae("span",{className:"sr-only",children:"Actions"})})]})}),
|
|
101
|
-
/* @__PURE__ */ae("tbody",{children:mt.map(e=>/* @__PURE__ */ne("tr",{className:"group border-b border-line-subtle hover:bg-row-hover",onContextMenu:t=>St.open(t,e),children:[
|
|
102
|
-
/* @__PURE__ */ae("td",{className:"px-3 h-11",children:/* @__PURE__ */ne("span",{className:"flex items-center gap-3 min-w-0",children:[
|
|
103
|
-
/* @__PURE__ */ae(Ie,{entry:e}),
|
|
104
|
-
/* @__PURE__ */ae("span",{className:"truncate",title:e.name,children:e.name})]})}),
|
|
105
|
-
/* @__PURE__ */ae("td",{className:"px-3 h-11 text-ink-faint text-xs truncate",title:e.originalPath,children:e.originalPath||"—"}),
|
|
106
|
-
/* @__PURE__ */ae("td",{className:"px-3 h-11 text-ink-faint whitespace-nowrap",title:e.deletedAt?ue(e.deletedAt):void 0,children:e.deletedAt?he(e.deletedAt):"—"}),
|
|
107
|
-
/* @__PURE__ */ae("td",{className:"px-3 h-11 text-right tabular-nums text-ink-faint",children:"folder"===e.kind?"—":d(e.size)}),
|
|
108
|
-
/* @__PURE__ */ae("td",{className:"px-2 h-11",children:/* @__PURE__ */ne("div",{className:"flex justify-end opacity-0 group-hover:opacity-100 group-focus-within:opacity-100",children:[
|
|
109
|
-
/* @__PURE__ */ae(c,{"aria-label":"Restore",size:"sm",onClick:()=>zt(e),children:/* @__PURE__ */ae(Y,{name:"revert",className:"h-4 w-4"})}),
|
|
110
|
-
/* @__PURE__ */ae(c,{"aria-label":"Delete forever",size:"sm",variant:"ghost-danger",onClick:()=>Wt(e),children:/* @__PURE__ */ae(Y,{name:"trash",className:"h-4 w-4"})})]})})]},e.id))})]}),On=0===wt.length?/* @__PURE__ */ae("div",{className:"p-10 text-center text-sm text-ink-faintest",children:"This desktop folder is empty. Drag shortcuts onto it on the desktop."}):/* @__PURE__ */ne("table",{className:"w-full text-sm table-fixed",children:[
|
|
111
|
-
/* @__PURE__ */ae("thead",{className:"text-xs text-ink-faint border-b border-line",children:/* @__PURE__ */ne("tr",{children:[
|
|
112
|
-
/* @__PURE__ */ae("th",{className:`${B} text-left font-medium px-3 h-9`,children:"Name"}),
|
|
113
|
-
/* @__PURE__ */ae("th",{className:`${B} text-left font-medium px-3 h-9 w-32`,children:"Type"}),
|
|
114
|
-
/* @__PURE__ */ae("th",{className:`${B} w-32`,children:/* @__PURE__ */ae("span",{className:"sr-only",children:"Actions"})})]})}),
|
|
115
|
-
/* @__PURE__ */ae("tbody",{children:wt.map(e=>/* @__PURE__ */ne("tr",{onDoubleClick:()=>Mt(e),onContextMenu:t=>jt.open(t,e),className:"group cursor-default border-b border-line-subtle hover:bg-row-hover",children:[
|
|
116
|
-
/* @__PURE__ */ae("td",{className:"px-3 h-11",children:/* @__PURE__ */ne("span",{className:"flex items-center gap-3 min-w-0",children:[
|
|
117
|
-
/* @__PURE__ */ae(P,{item:e}),
|
|
118
|
-
/* @__PURE__ */ae("span",{className:"truncate",title:e.label,children:e.label})]})}),
|
|
119
|
-
/* @__PURE__ */ae("td",{className:"px-3 h-11 text-xs text-ink-faint",children:E(e)}),
|
|
120
|
-
/* @__PURE__ */ae("td",{className:"px-2 h-11",children:/* @__PURE__ */ne("div",{className:"flex justify-end opacity-0 group-hover:opacity-100 group-focus-within:opacity-100",children:[
|
|
121
|
-
/* @__PURE__ */ae(c,{"aria-label":"Open",size:"sm",onClick:()=>Mt(e),children:/* @__PURE__ */ae(Y,{name:"external",className:"h-4 w-4"})}),
|
|
122
|
-
/* @__PURE__ */ae(c,{"aria-label":"Move to desktop",size:"sm",onClick:()=>pt?.moveToDesktop([e]),children:/* @__PURE__ */ae(Y,{name:"desktop",className:"h-4 w-4"})}),
|
|
123
|
-
/* @__PURE__ */ae(c,{"aria-label":"Remove",size:"sm",variant:"ghost-danger",onClick:()=>pt?.removeShortcuts([e]),children:/* @__PURE__ */ae(Y,{name:"close",className:"h-4 w-4"})})]})})]},`${e.entityType}|${e.entityId}`))})]});/* @__PURE__ */
|
|
124
|
-
return ne("div",{className:"relative flex flex-col h-full bg-surface",onDragEnter:e=>{Yt&&e.dataTransfer?.types?.includes?.("Files")&&(e.preventDefault(),yt.current++,Oe||Ue(!0))},onDragOver:e=>{e.dataTransfer?.types?.includes?.("Files")&&e.preventDefault()},onDragLeave:()=>{yt.current>0&&yt.current--,0===yt.current&&Ue(!1)},onDrop:e=>{e.dataTransfer?.types?.includes?.("Files")&&(e.preventDefault(),qt(),Yt&&e.dataTransfer.files?.length&&Ht(e.dataTransfer.files))},children:[
|
|
125
|
-
/* @__PURE__ */ae(K,{title:Cn}),
|
|
126
|
-
/* @__PURE__ */ae(S,{app:"files"}),
|
|
127
|
-
/* @__PURE__ */ae("input",{ref:bt,type:"file",multiple:!0,className:"hidden",onChange:e=>{e.target.files?.length&&Ht(e.target.files),bt.current&&(bt.current.value="")}}),
|
|
128
|
-
/* @__PURE__ */ae("input",{ref:e=>{vt.current=e,e?.setAttribute("webkitdirectory","")},type:"file",multiple:!0,className:"hidden",onChange:e=>{e.target.files?.length&&Ht(e.target.files,{withFolders:!0}),vt.current&&(vt.current.value="")}}),
|
|
129
|
-
/* @__PURE__ */ae("div",{className:"flex-1 min-h-0",children:/* @__PURE__ */ae(t,{sidebar:Dn,storageKey:"files.sidebarWidth",defaultWidth:220,minWidth:170,maxWidth:320,children:/* @__PURE__ */ne("div",{className:"flex h-full min-w-0",children:[
|
|
130
|
-
/* @__PURE__ */ne("div",{className:"flex flex-1 min-w-0 flex-col",children:[Dt&&/* @__PURE__ */ne("div",{className:"flex items-center gap-2 px-4 py-2 border-b border-line bg-accent-tint text-accent-text text-sm shrink-0",role:"status",children:[
|
|
131
|
-
/* @__PURE__ */ae(Y,{name:"cursor",className:"h-4 w-4 shrink-0",strokeWidth:1.6}),
|
|
132
|
-
/* @__PURE__ */ae("span",{className:"flex-1 min-w-0 truncate",children:Dt.request.title}),
|
|
133
|
-
/* @__PURE__ */ae(V,{variant:"secondary",size:"sm",onClick:()=>N(Dt.id,null),children:"Cancel"}),
|
|
134
|
-
/* @__PURE__ */ae(V,{variant:"primary",size:"sm",disabled:!fn,onClick:()=>{fn&&un(fn)},children:"Open"})]}),
|
|
135
|
-
/* @__PURE__ */ne("div",{className:"flex items-center gap-1 px-4 py-2 shrink-0",children:[
|
|
136
|
-
/* @__PURE__ */ae("div",{className:"flex-1 min-w-48 max-w-2xl",role:"search",children:/* @__PURE__ */ae(l,{type:"text",enterKeyHint:"search",value:_e,onChange:e=>{et(e.target.value),e.target.value.trim()||Pt()},onKeyDown:e=>{"Escape"===e.key&&_e&&(e.stopPropagation(),Pt())},placeholder:`Search in ${r}`,"aria-label":`Search in ${r}`,leftIcon:/* @__PURE__ */ae(Y,{name:"search",className:"h-4 w-4"}),endAction:_e?{label:"Clear search",icon:/* @__PURE__ */ae(Y,{name:"close",className:"h-4 w-4"}),onClick:Pt}:void 0})}),
|
|
137
|
-
/* @__PURE__ */ae("div",{className:"flex-1"}),"object"!=typeof lt&&"trash"!==lt&&/* @__PURE__ */ne(re,{children:[
|
|
138
|
-
/* @__PURE__ */ae(c,{"aria-label":"List view","aria-pressed":"list"===Qe,onClick:()=>ut("list"),children:/* @__PURE__ */ae(Y,{name:"list",className:"h-4 w-4"})}),
|
|
139
|
-
/* @__PURE__ */ae(c,{"aria-label":"Grid view","aria-pressed":"grid"===Qe,onClick:()=>ut("grid"),children:/* @__PURE__ */ae(Y,{name:"grid",className:"h-4 w-4"})})]}),
|
|
140
|
-
/* @__PURE__ */ae(c,{"aria-label":"Details","aria-pressed":Xe,onClick:()=>qe(e=>!e),children:/* @__PURE__ */ae(Y,{name:"info",className:"h-4 w-4"})})]}),In,
|
|
141
|
-
/* @__PURE__ */ae("div",{className:"flex-1 overflow-auto outline-none",tabIndex:-1,onKeyDown:e=>{e.target instanceof HTMLInputElement||(Dt?"Enter"===e.key&&fn&&(e.preventDefault(),un(fn)):("Delete"===e.key||"Backspace"===e.key)&&nn.length&&nn.every(sn)?(e.preventDefault(),Qt(nn)):"Enter"===e.key&&an?(e.preventDefault(),pn(an)):(e.metaKey||e.ctrlKey)&&"a"===e.key.toLowerCase()&&en.length&&(e.preventDefault(),ie(new Set(en.map(e=>e.id)))))},onClick:e=>{e.target===e.currentTarget&&dn()},children:"object"==typeof lt?On:"trash"===lt?Kn:Wn})]}),Xe&&Tn&&/* @__PURE__ */ae(Ne,{store:n,entry:an,selectedCount:nn.length,onClose:()=>qe(!1)})]})})}),Ct.state&&/* @__PURE__ */ae(s,{...Ct.props,items:kn(Ct.state.data),"aria-label":"File actions"}),St.state&&/* @__PURE__ */ae(s,{...St.props,"aria-label":"Trash actions",items:[{key:"restore",label:"Restore",icon:/* @__PURE__ */ae(Y,{name:"revert",className:"h-4 w-4"}),onSelect:()=>zt(St.state.data)},{type:"divider",key:"d"},{key:"purge",label:"Delete forever",danger:!0,icon:/* @__PURE__ */ae(Y,{name:"trash",className:"h-4 w-4"}),onSelect:()=>Wt(St.state.data)}]}),jt.state&&/* @__PURE__ */ae(s,{...jt.props,"aria-label":"Shortcut actions",items:[{key:"open",label:"Open",icon:/* @__PURE__ */ae(Y,{name:"external",className:"h-4 w-4"}),onSelect:()=>Mt(jt.state.data)},{key:"desktop",label:"Move to desktop",icon:/* @__PURE__ */ae(Y,{name:"desktop",className:"h-4 w-4"}),onSelect:()=>pt?.moveToDesktop([jt.state.data])},{type:"divider",key:"d"},{key:"remove",label:"Remove",danger:!0,icon:/* @__PURE__ */ae(Y,{name:"close",className:"h-4 w-4"}),onSelect:()=>pt?.removeShortcuts([jt.state.data])}]}),h&&/* @__PURE__ */ae(ve,{store:n,entry:Ve,onClose:()=>Ye(null),onChanged:It}),n.move&&/* @__PURE__ */ae(xe,{store:n,items:He,from:"files"===lt?u:void 0,onClose:()=>Be(null),onMove:e=>He&&Xt(He,e)}),Oe&&/* @__PURE__ */ae("div",{className:"absolute inset-0 bg-accent-tint border-4 border-dashed border-accent-border pointer-events-none flex items-center justify-center z-20",children:/* @__PURE__ */ae("div",{className:"px-4 py-2 rounded-md bg-accent-fill text-on-accent text-sm font-medium shadow-lg",children:"Drop to upload"})})]})}export{Ee as default,Le as quotaExceededMessage};
|
package/dist/chunk-AJMQ5SHI.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
var r="13.9.0",a=r;export{a as APP_VERSION,r as VERSION};
|
package/dist/chunk-WBAWJIVM.js
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import{navIcons as e}from"./chunk-4LXCCZDM.js";import{Icon as t}from"./chunk-ISVODSRP.js";import{isValidElement as n,cloneElement as r}from"react";import{jsx as o,jsxs as i}from"react/jsx-runtime";var a="react-os-shell:spreadsheet-preview-update",s=null,l=0;function d(e){const t=++l,n={token:t,data:e};return s=n,{update(e){s===n&&(n.data=e),"undefined"!=typeof window&&window.dispatchEvent(new CustomEvent(a,{detail:{token:t,data:e}}))}}}function c(){return s}function p(e){s===e&&(s=null)}var u={document:".docx",spreadsheet:".sheet",deck:".slides"},f=class extends Error{limit;used;attempted;constructor(e,t,n){super("Not enough space"),this.name="FilesQuotaError",this.limit=e,this.used=t,this.attempted=n}};function h(e,t){return e&&"/"!==e?e.replace(/\/$/,"")+"/"+t:"/"+t}async function m(e,t){const n=await e.json().catch(()=>({}));return new Error(n.error||`${t} failed (${e.status})`)}function w(e){const t=()=>(e??(("undefined"!=typeof window?window.__REACT_OS_SHELL_FILE_SERVER__:void 0)||"http://localhost:4000").replace(/\/$/,"")).replace(/\/$/,""),n=(e,n={})=>fetch(`${t()}${e}`,{...n,credentials:"include"}),r=e=>({method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)});return{async quota(){const e=await n("/api/quota");if(!e.ok)throw await m(e,"Quota");const t=await e.json();return{used:t.used,limit:t.limit}},async list(e){const t=e??"/",r=await n(`/api/files?path=${encodeURIComponent(t)}`);if(!r.ok)throw await m(r,"Listing");const o=await r.json(),i=o.path||t,a=i.split("/").filter(Boolean);return{folder:{id:"/"===i?null:i,name:a[a.length-1]??"",role:"owner",path:[{id:null,name:""},...a.map((e,t)=>({id:"/"+a.slice(0,t+1).join("/"),name:e}))]},entries:(o.entries||[]).map(e=>({id:h(i,e.name),name:e.name,kind:e.kind,size:e.size,modifiedAt:e.modifiedAt}))}},async upload(e,t){const r=new FormData;r.append("file",t);const o=await n(`/api/upload?path=${encodeURIComponent(e??"/")}`,{method:"POST",body:r});if(413===o.status){const e=await o.json().catch(()=>({}));throw new f(e.limit||0,e.used||0,e.attempted||t.size)}if(!o.ok)throw await m(o,"Upload")},async createFolder(e,t){const o=await n("/api/folder",r({path:h(e,t)}));if(!o.ok)throw await m(o,"Create folder")},async rename(e,t){const o=e.replace(/\/[^/]*$/,"")||"/",i=await n("/api/rename",r({from:e,to:h(o,t)}));if(!i.ok)throw await m(i,"Rename")},async remove(e){const t=await n(`/api/files?path=${encodeURIComponent(e)}`,{method:"DELETE"});if(!t.ok)throw await m(t,"Delete")},async read(e){const t=await n(`/api/file?path=${encodeURIComponent(e)}`);if(!t.ok)throw await m(t,"Download");return t.blob()},async trash(){const e=await n("/api/trash");if(!e.ok)throw await m(e,"Listing trash");return(await e.json()).entries||[]},async restore(e){const t=await n("/api/trash/restore",r({id:e}));if(!t.ok)throw await m(t,"Restore")},async purge(e){const t=await n(`/api/trash/${encodeURIComponent(e)}`,{method:"DELETE"});if(!t.ok)throw await m(t,"Delete")},async emptyTrash(){const e=await n("/api/trash",{method:"DELETE"});if(!e.ok)throw await m(e,"Empty trash")}}}var y=null;function g(e){y=e}function x(){return y??w()}function b(){return null!==y}var v=["from-blue-500 to-blue-700","from-indigo-500 to-purple-600","from-purple-500 to-pink-600","from-pink-500 to-rose-600","from-red-500 to-rose-600","from-orange-500 to-red-600","from-amber-500 to-orange-600","from-yellow-500 to-amber-500","from-lime-500 to-green-600","from-green-500 to-emerald-600","from-emerald-500 to-teal-600","from-teal-500 to-cyan-600","from-cyan-500 to-sky-600","from-sky-500 to-blue-600","from-violet-500 to-fuchsia-600"];function _(e){let t=0;for(let n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n);return v[Math.abs(t)%v.length]}var k={order:"text-blue-600",purchase_order:"text-purple-600",invoice:"text-green-600",client:"text-indigo-600",manufacturer:"text-orange-600",shipment:"text-teal-600",part_number:"text-gray-600",project:"text-pink-600",mould:"text-red-600",design:"text-cyan-600",brand:"text-amber-600",price_sheet:"text-emerald-600",folder:"text-yellow-600",page:"text-blue-500"},E={order:"SO",purchase_order:"PO",invoice:"INV",client:"CLI",manufacturer:"MFR",shipment:"DN",part_number:"PN",project:"PRJ",mould:"MLD",design:"DSN",brand:"BRD",price_sheet:"PS",vendor_invoice:"VI",vendor_payment:"VP",warranty_claim:"WC",qc_report:"QC",vendor_shipment:"GRN",bank_account:"BA",wheel_finish:"WF",weight_log:"WL",production_progress:"PP",vendor_price_sheet:"VPS",proposal:"PR",folder:"FLD"},C={pdf:"PDF",dxf:"DXF","3d":"STP",image:"IMG",csv:"CSV"},N={pdf:"text-red-600",dxf:"text-blue-600","3d":"text-purple-600",image:"text-emerald-600",csv:"text-green-600"};function j({className:e}){/* @__PURE__ */
|
|
2
|
-
return o(t,{name:"folder",look:"solid",className:e})}function T(t,n){return n&&e[n]||(t?e[t]:void 0)}var I=/* @__PURE__ */o("svg",{className:"h-7 w-7",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:/* @__PURE__ */o("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3.75 6A2.25 2.25 0 016 3.75h2.25A2.25 2.25 0 0110.5 6v2.25a2.25 2.25 0 01-2.25 2.25H6a2.25 2.25 0 01-2.25-2.25V6z"})});function S({entityType:e,isSelected:t,entityId:a,label:s,fileKind:l}){const d="preview-file"===e&&l,c=d?N[l]:null,p=d?C[l]:null;if("folder"===e)/* @__PURE__ */
|
|
3
|
-
return o("div",{className:"w-12 h-12 flex items-center justify-center "+(t?"rounded-lg bg-blue-400/30 ring-2 ring-blue-500":""),children:/* @__PURE__ */o(j,{className:"h-12 w-12 text-amber-500 drop-shadow-[0_2px_3px_rgba(0,0,0,0.3)]"})});if("page"===e){const e=T(a,s),i=_(a||s||"page");/* @__PURE__ */
|
|
4
|
-
return o("div",{className:"w-12 h-12 flex items-center justify-center "+(t?"rounded-lg bg-blue-400/30 ring-2 ring-blue-500":""),children:/* @__PURE__ */o("span",{className:`h-11 w-11 rounded-xl bg-gradient-to-br ${i} flex items-center justify-center text-white border border-white/30 drop-shadow-[0_2px_3px_rgba(0,0,0,0.3)]`,children:e&&n(e)?r(e,{className:"h-7 w-7 text-white"}):I})})}/* @__PURE__ */
|
|
5
|
-
return i("div",{className:"w-12 h-12 relative flex items-center justify-center "+(t?"rounded-lg bg-blue-400/30 ring-2 ring-blue-500":""),children:[
|
|
6
|
-
/* @__PURE__ */i("svg",{className:`w-10 h-12 drop-shadow-[0_2px_3px_rgba(0,0,0,0.3)] ${c??k[e]??"text-gray-500"}`,viewBox:"0 0 40 48",fill:"none",children:[
|
|
7
|
-
/* @__PURE__ */o("path",{d:"M4 0h22l10 10v34a4 4 0 01-4 4H4a4 4 0 01-4-4V4a4 4 0 014-4z",fill:"white",fillOpacity:"0.92"}),
|
|
8
|
-
/* @__PURE__ */o("path",{d:"M26 0l10 10H30a4 4 0 01-4-4V0z",fill:"currentColor",fillOpacity:"0.2"}),
|
|
9
|
-
/* @__PURE__ */o("path",{d:"M4 0h22l10 10v34a4 4 0 01-4 4H4a4 4 0 01-4-4V4a4 4 0 014-4z",stroke:"currentColor",strokeWidth:"1.5",strokeOpacity:"0.5"})]}),
|
|
10
|
-
/* @__PURE__ */o("span",{className:`absolute inset-0 flex items-center justify-center text-3xs font-bold pt-2 ${c??k[e]??"text-gray-600"}`,children:p??E[e]??e.slice(0,3).toUpperCase()})]})}function L({item:e}){if("folder"===e.entityType)/* @__PURE__ */
|
|
11
|
-
return o(j,{className:"h-4 w-4 shrink-0 text-amber-500"});if("page"===e.entityType){const t=T(e.entityId,e.label);/* @__PURE__ */
|
|
12
|
-
return o("span",{className:`h-4 w-4 rounded bg-gradient-to-br ${_(e.entityId||e.label||"page")} flex items-center justify-center text-white shrink-0`,children:t&&n(t)?r(t,{className:"h-3 w-3 text-white"}):/* @__PURE__ */o("span",{className:"h-1.5 w-1.5 rounded-[2px] border border-white/80"})})}const i=("preview-file"===e.entityType&&e.fileKind?N[e.fileKind]:k[e.entityType])??"text-gray-400";/* @__PURE__ */
|
|
13
|
-
return o(t,{name:"page",className:`h-4 w-4 shrink-0 ${i}`,strokeWidth:1.5})}function $(e){return"preview-file"===e.entityType&&e.fileKind?C[e.fileKind]:"page"===e.entityType?"App":"folder"===e.entityType?"Folder":E[e.entityType]??e.entityType.slice(0,3).toUpperCase()}var R=null,D=/* @__PURE__ */new Set;function P(e){R=e,D.forEach(e=>e())}function V(e){return D.add(e),()=>{D.delete(e)}}function F(){return R}var O="__REACT_OS_SHELL_FILES_VIEW__",A="react-os-shell:files-show-trash",M="react-os-shell:files-open-desktop-folder";function U(){"undefined"!=typeof window&&(window[O]="trash",window.dispatchEvent(new CustomEvent(A)))}function z(e){"undefined"!=typeof window&&(window[O]={view:"desktop-folder",folderId:e},window.dispatchEvent(new CustomEvent(M,{detail:{folderId:e}})))}function W(){if("undefined"==typeof window)return null;const e=window[O];return"trash"===e?"trash":e&&"object"==typeof e&&"desktop-folder"===e.view&&"string"==typeof e.folderId?e:null}function H(){const e=W();return"undefined"!=typeof window&&(window[O]=null),e}export{L as DesktopItemMiniIcon,u as FILES_OFFICE_EXTENSIONS,M as FILES_OPEN_DESKTOP_FOLDER_EVENT,A as FILES_SHOW_TRASH_EVENT,S as FileIconTile,f as FilesQuotaError,j as FolderGlyph,a as SPREADSHEET_PREVIEW_UPDATE_EVENT,p as claimSpreadsheetPreviewStage,H as consumeFilesViewRequest,w as createFileServerStore,$ as desktopItemTypeLabel,F as getDesktopFoldersSnapshot,x as getFilesStore,b as hasHostFilesStore,W as peekFilesViewRequest,c as peekSpreadsheetPreviewStage,P as publishDesktopFolders,z as requestFilesDesktopFolderView,U as requestFilesTrashView,g as setFilesStore,d as setSpreadsheetPreview,V as subscribeDesktopFolders};
|