react-os-shell 4.0.4 → 4.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{Browser-LWZRALDQ.js → Browser-KJFSN3HT.js} +6 -6
- package/dist/{Browser-LWZRALDQ.js.map → Browser-KJFSN3HT.js.map} +1 -1
- package/dist/{Calculator-6N4ZRX4D.js → Calculator-YI4FFJNC.js} +5 -5
- package/dist/{Calculator-6N4ZRX4D.js.map → Calculator-YI4FFJNC.js.map} +1 -1
- package/dist/ConfirmDialog-774RXRGC.js +4 -0
- package/dist/{ConfirmDialog-TJHQS6QS.js.map → ConfirmDialog-774RXRGC.js.map} +1 -1
- package/dist/{CurrencyConverter-VKBPC4IE.js → CurrencyConverter-LUX2UEHY.js} +5 -5
- package/dist/{CurrencyConverter-VKBPC4IE.js.map → CurrencyConverter-LUX2UEHY.js.map} +1 -1
- package/dist/{Documents-O2ZW57XZ.js → Documents-BEY4LXP4.js} +6 -6
- package/dist/{Documents-O2ZW57XZ.js.map → Documents-BEY4LXP4.js.map} +1 -1
- package/dist/{Files-HVL6G7AJ.js → Files-OFPPAIUI.js} +8 -8
- package/dist/{Files-HVL6G7AJ.js.map → Files-OFPPAIUI.js.map} +1 -1
- package/dist/{Notepad-6MECX4SI.js → Notepad-RTB4T6D5.js} +6 -6
- package/dist/{Notepad-6MECX4SI.js.map → Notepad-RTB4T6D5.js.map} +1 -1
- package/dist/{PomodoroTimer-WN6OLUEK.js → PomodoroTimer-XPG5D63T.js} +6 -6
- package/dist/{PomodoroTimer-WN6OLUEK.js.map → PomodoroTimer-XPG5D63T.js.map} +1 -1
- package/dist/{Preview-KEKFMSPZ.js → Preview-O25VRQVF.js} +6 -6
- package/dist/{Preview-KEKFMSPZ.js.map → Preview-O25VRQVF.js.map} +1 -1
- package/dist/{Sidebar-AGFOKQ5J.js → Sidebar-VF2IOOFX.js} +7 -8
- package/dist/Sidebar-VF2IOOFX.js.map +1 -0
- package/dist/{Spreadsheet-V3QARAYP.js → Spreadsheet-QVN3YZGT.js} +6 -6
- package/dist/{Spreadsheet-V3QARAYP.js.map → Spreadsheet-QVN3YZGT.js.map} +1 -1
- package/dist/{Stock-4KHVBZST.js → Stock-7QVYY7WE.js} +5 -5
- package/dist/{Stock-4KHVBZST.js.map → Stock-7QVYY7WE.js.map} +1 -1
- package/dist/{Weather-VVS77N24.js → Weather-UESMYSNG.js} +5 -5
- package/dist/{Weather-VVS77N24.js.map → Weather-UESMYSNG.js.map} +1 -1
- package/dist/{WorldClock-GMZFC3F3.js → WorldClock-UONWHVMF.js} +5 -5
- package/dist/{WorldClock-GMZFC3F3.js.map → WorldClock-UONWHVMF.js.map} +1 -1
- package/dist/apps/index.js +18 -18
- package/dist/{chunk-QXWBHX7J.js → chunk-52RFL3OQ.js} +3 -3
- package/dist/{chunk-QXWBHX7J.js.map → chunk-52RFL3OQ.js.map} +1 -1
- package/dist/{chunk-GW3RA6IS.js → chunk-6Q4KYGMH.js} +9 -3
- package/dist/chunk-6Q4KYGMH.js.map +1 -0
- package/dist/{chunk-RFXXKB3Z.js → chunk-AT2OO6B4.js} +3 -3
- package/dist/{chunk-RFXXKB3Z.js.map → chunk-AT2OO6B4.js.map} +1 -1
- package/dist/{chunk-3JR7SZN4.js → chunk-C7AKG4RE.js} +3 -3
- package/dist/{chunk-3JR7SZN4.js.map → chunk-C7AKG4RE.js.map} +1 -1
- package/dist/{chunk-RVUMXSQE.js → chunk-CWFH34LM.js} +3 -3
- package/dist/{chunk-RVUMXSQE.js.map → chunk-CWFH34LM.js.map} +1 -1
- package/dist/{chunk-VEHYNKEN.js → chunk-D6JXZZJC.js} +5 -5
- package/dist/{chunk-VEHYNKEN.js.map → chunk-D6JXZZJC.js.map} +1 -1
- package/dist/{chunk-GJUL4R5U.js → chunk-OGL3C2T2.js} +4 -4
- package/dist/{chunk-GJUL4R5U.js.map → chunk-OGL3C2T2.js.map} +1 -1
- package/dist/chunk-WURP3XRN.js +7 -0
- package/dist/{chunk-UBVU54RM.js.map → chunk-WURP3XRN.js.map} +1 -1
- package/dist/index.d.ts +34 -1
- package/dist/index.js +346 -24
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/dist/ConfirmDialog-TJHQS6QS.js +0 -4
- package/dist/Sidebar-AGFOKQ5J.js.map +0 -1
- package/dist/chunk-GW3RA6IS.js.map +0 -1
- package/dist/chunk-UBVU54RM.js +0 -7
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/version.ts"],"names":[],"mappings":";AAIO,IAAM,OAAA,GAAwD,OAAA;AAG9D,IAAM,WAAA,GAAc","file":"chunk-
|
|
1
|
+
{"version":3,"sources":["../src/version.ts"],"names":[],"mappings":";AAIO,IAAM,OAAA,GAAwD,OAAA;AAG9D,IAAM,WAAA,GAAc","file":"chunk-WURP3XRN.js","sourcesContent":["declare const __PKG_VERSION__: string | undefined;\n\n/** Package version, injected by tsup at build time. Stays as an empty\n * string when the source is consumed without a build (e.g. tests). */\nexport const VERSION: string = typeof __PKG_VERSION__ === 'string' ? __PKG_VERSION__ : '';\n\n/** Legacy alias kept so existing consumers do not break. */\nexport const APP_VERSION = VERSION;\n"]}
|
package/dist/index.d.ts
CHANGED
|
@@ -1767,6 +1767,39 @@ interface MediaUploadGridProps {
|
|
|
1767
1767
|
}
|
|
1768
1768
|
declare function MediaUploadGrid({ items, onPick, onRemove, onReorder, label, hint, error, required, className, accept, fit, thumbSize, placeholder, cta, acceptHint, showCover, coverLabel, busy, busyLabel, disabled, readOnly, }: MediaUploadGridProps): react_jsx_runtime.JSX.Element;
|
|
1769
1769
|
|
|
1770
|
+
interface DateRangePickerProps {
|
|
1771
|
+
/** Start of the range as `YYYY-MM-DD`, or '' when unset. */
|
|
1772
|
+
from: string;
|
|
1773
|
+
/** End of the range as `YYYY-MM-DD`, or '' when unset. */
|
|
1774
|
+
to: string;
|
|
1775
|
+
/** Called with the applied range. Both values are '' when cleared. */
|
|
1776
|
+
onChange: (from: string, to: string) => void;
|
|
1777
|
+
/**
|
|
1778
|
+
* Render a `YYYY-MM-DD` for display. Defaults to `DD/MM/YYYY`; portals pass
|
|
1779
|
+
* their own so the picker agrees with every other date on screen.
|
|
1780
|
+
*/
|
|
1781
|
+
formatDisplay?: (iso: string) => string;
|
|
1782
|
+
/**
|
|
1783
|
+
* Offer the Clear affordances. Pass `false` where a range is REQUIRED — an
|
|
1784
|
+
* accounting report seeded with a period has nothing sensible to show for an
|
|
1785
|
+
* empty one, so it should not offer to empty it.
|
|
1786
|
+
*/
|
|
1787
|
+
clearable?: boolean;
|
|
1788
|
+
/** Trigger text when no range is set. */
|
|
1789
|
+
placeholder?: string;
|
|
1790
|
+
}
|
|
1791
|
+
/**
|
|
1792
|
+
* Serialise a Date to `YYYY-MM-DD`, reading its LOCAL calendar fields.
|
|
1793
|
+
*
|
|
1794
|
+
* This must not go through `toISOString()`. Every Date this component builds is
|
|
1795
|
+
* constructed at local midnight — calendar cells, the preset boundaries, and
|
|
1796
|
+
* `new Date()` — and local midnight always falls in the *previous* UTC day for
|
|
1797
|
+
* any positive UTC offset. Serialising through UTC would shift the whole picker
|
|
1798
|
+
* back one day for every user east of Greenwich.
|
|
1799
|
+
*/
|
|
1800
|
+
declare function toISODate(d: Date): string;
|
|
1801
|
+
declare function DateRangePicker({ from, to, onChange, formatDisplay, clearable, placeholder, }: DateRangePickerProps): react_jsx_runtime.JSX.Element;
|
|
1802
|
+
|
|
1770
1803
|
/**
|
|
1771
1804
|
* Shared form-control styling — the single source of truth for the kit's
|
|
1772
1805
|
* text-input look. Promoted out of SearchableSelect so every form control
|
|
@@ -2695,4 +2728,4 @@ declare function useNewHotkey(callback: () => void): void;
|
|
|
2695
2728
|
*/
|
|
2696
2729
|
declare function useEditHotkey(callback: (() => void) | null): void;
|
|
2697
2730
|
|
|
2698
|
-
export { ALT, ALT_SHIFT_D, ALT_SHIFT_E, ALT_SHIFT_N, Accordion, type AccordionItem, type AccordionProps, AuthScreen, type AuthScreenProps, Avatar, AvatarGroup, type AvatarGroupProps, type AvatarProps, type AvatarSize, type AvatarStatus, Banner, type BannerProps, type BannerTone, BarChart, type BarChartProps, BehaviorPanel, type BreadcrumbItem, Breadcrumbs, type BreadcrumbsProps, type BulkColumn, type BulkColumnKind, BulkImportGrid, type BulkImportGridProps, type BulkRow, Button, type ButtonProps, type ButtonSize, type ButtonVariant, CMD_A, CMD_DOT, CMD_ENTER, CMD_K, CMD_S, CancelButton, Card, type CardProps, type CellStyle, ChangePasswordForm, type ChangePasswordFormProps, type ChangelogEntry, ChatTemplate, Checkbox, type CheckboxProps, CheckoutTemplate, type ClockCalendarConfig, ColoredBadge, type ColoredBadgeProps, type ColumnDef, ConfirmProvider, ContainerFillChart, type ContainerFillChartProps, type ContainerFillItem, CopyButton, Customization, type CustomizationOmitSection, type CustomizationProps, type CustomizationSection, DEV_BANNER_TEXT, DashboardTemplate, DataTablePage, Desktop, type DesktopContextMenuItem, type DesktopHostConfig, DesktopHostProvider, DevIndicator, DocFavStar, DonutChart, type DonutChartProps, type DonutSegment, type DuplicateGroup, ENTER, EditableGrid, type EditableGridProps, EmailTemplate, EmptyState, type EmptyStateProps, type EntityFetcher, EntityList, type EntityListColumn, type EntityListContextAction, type EntityListProps, ErrorPage, type ErrorPageProps, FilterBar, type FilterOption, FormField, type FormFieldProps, FormLayoutPage, GLASS_DIVIDER, GLASS_INPUT_BG, GalleryTemplate, GlobalSearch, type GridColumn, type HealthCheckResult, HelpCenter, type HelpCenterDoc, type HelpCenterProps, INPUT_BASE, ImageAnnotator, type ImageAnnotatorHandle, type ImageAnnotatorProps, Input, type InputProps, Kanban, type KanbanColumn, type KanbanProps, Label, type LabelProps, Layout, type LayoutProps, ListFooter, ListLoadError, type ListLoadErrorProps, LoadingSpinner, type LoadingSpinnerProps, MOD, Markdown, type MarkdownProps, MediaUploadField, type MediaUploadFieldProps, MediaUploadGrid, type MediaUploadGridItem, type MediaUploadGridProps, type MergeBulkOptions, type MergeBulkResult, MetricBar, type MetricBarProps, type Milestone, type MilestoneKind, MilestoneTimeline, type MilestoneTimelineProps, type MobileAppConfig, Modal, ModalActions, NativeSelect, NotificationBell, type NotificationsConfig, PageHeader, type PageHeaderProps, type PaginatedResponse, Pagination, type PaginationProps, PdfActionButton, type PdfActionButtonProps, PopupMenu, PopupMenuDivider, PopupMenuItem, PopupMenuLabel, Radio, type RadioProps, ResizableTable, SHIFT, type SearchConfig, type SearchProvider, type SearchResult, type SearchableOption, SearchableSelect, type SearchableSelectProps, Select, type SelectOption, type SelectProps, type SemanticGroup, ServerStatusIndicator, type ServerStatusIndicatorProps, type ServerStatusUser, type SeverityTone, type ShellAuth, ShellAuthProvider, ShellEntityFetcherProvider, type ShellNotification, type ShellPrefsAdapter, ShellPrefsProvider, ShortcutHelp, SidebarActionButton, type SidebarActionButtonProps, SidebarGroupLabel, SidebarLayout, type SidebarLayoutProps, SidebarNavItem, type SortState, SoundsPanel, Sparkline, type SparklineProps, StartMenu, StatCard, type StatCardProps, StatusBadge, StatusBadgeProvider, type StickyEntityRef, type StickyResolver, SystemPreferences, type SystemPreferencesProps, type SystemPreferencesSection, type TabItem, Tabs, type TabsProps, Textarea, type TextareaProps, type TodoProvider, type TodoTask, Tooltip, type TooltipProps, TopNav, type TopNavItem, type TopNavProps, VERSION, WidgetManager, WindowCrashedFallback, WindowErrorBoundary, WindowManagerProvider, WindowRegistry, WindowTitle, applyDevTitle, commitExposeHighlight, confirm, confirmDestructive, createWindowRegistry, exitExposeMode, findDuplicateKeys, formatDate, getActiveWindowRoute, getExposeHighlight, getWindowPosition, glassStyle, inputClasses, isDevEnv, isMac, isSeverityTone, mediaFileName, mergeBulkItems, prompt, registerModalEscapeInterceptor, setExposeHighlight, setShellApiClient, setShellAuthBridge, setShellNavIcons, setShellTodoProvider, setWindowDefaultPosition, setWindowPosition, severityOf, subscribeExposeHighlight, toast, toggleExposeMode, useClickOutside, useColumnConfig, useDesktopHost, useEditHotkey, useFilters, useInfiniteScroll, useLocalStoragePrefs, useModalActive, useNewHotkey, useShellAuth, useShellEntityFetcher, useShellPrefs, useSort, useTableNav, useWidgetSettings, useWindowManager, useWindowMenuItem, useWindowTitle };
|
|
2731
|
+
export { ALT, ALT_SHIFT_D, ALT_SHIFT_E, ALT_SHIFT_N, Accordion, type AccordionItem, type AccordionProps, AuthScreen, type AuthScreenProps, Avatar, AvatarGroup, type AvatarGroupProps, type AvatarProps, type AvatarSize, type AvatarStatus, Banner, type BannerProps, type BannerTone, BarChart, type BarChartProps, BehaviorPanel, type BreadcrumbItem, Breadcrumbs, type BreadcrumbsProps, type BulkColumn, type BulkColumnKind, BulkImportGrid, type BulkImportGridProps, type BulkRow, Button, type ButtonProps, type ButtonSize, type ButtonVariant, CMD_A, CMD_DOT, CMD_ENTER, CMD_K, CMD_S, CancelButton, Card, type CardProps, type CellStyle, ChangePasswordForm, type ChangePasswordFormProps, type ChangelogEntry, ChatTemplate, Checkbox, type CheckboxProps, CheckoutTemplate, type ClockCalendarConfig, ColoredBadge, type ColoredBadgeProps, type ColumnDef, ConfirmProvider, ContainerFillChart, type ContainerFillChartProps, type ContainerFillItem, CopyButton, Customization, type CustomizationOmitSection, type CustomizationProps, type CustomizationSection, DEV_BANNER_TEXT, DashboardTemplate, DataTablePage, DateRangePicker, type DateRangePickerProps, Desktop, type DesktopContextMenuItem, type DesktopHostConfig, DesktopHostProvider, DevIndicator, DocFavStar, DonutChart, type DonutChartProps, type DonutSegment, type DuplicateGroup, ENTER, EditableGrid, type EditableGridProps, EmailTemplate, EmptyState, type EmptyStateProps, type EntityFetcher, EntityList, type EntityListColumn, type EntityListContextAction, type EntityListProps, ErrorPage, type ErrorPageProps, FilterBar, type FilterOption, FormField, type FormFieldProps, FormLayoutPage, GLASS_DIVIDER, GLASS_INPUT_BG, GalleryTemplate, GlobalSearch, type GridColumn, type HealthCheckResult, HelpCenter, type HelpCenterDoc, type HelpCenterProps, INPUT_BASE, ImageAnnotator, type ImageAnnotatorHandle, type ImageAnnotatorProps, Input, type InputProps, Kanban, type KanbanColumn, type KanbanProps, Label, type LabelProps, Layout, type LayoutProps, ListFooter, ListLoadError, type ListLoadErrorProps, LoadingSpinner, type LoadingSpinnerProps, MOD, Markdown, type MarkdownProps, MediaUploadField, type MediaUploadFieldProps, MediaUploadGrid, type MediaUploadGridItem, type MediaUploadGridProps, type MergeBulkOptions, type MergeBulkResult, MetricBar, type MetricBarProps, type Milestone, type MilestoneKind, MilestoneTimeline, type MilestoneTimelineProps, type MobileAppConfig, Modal, ModalActions, NativeSelect, NotificationBell, type NotificationsConfig, PageHeader, type PageHeaderProps, type PaginatedResponse, Pagination, type PaginationProps, PdfActionButton, type PdfActionButtonProps, PopupMenu, PopupMenuDivider, PopupMenuItem, PopupMenuLabel, Radio, type RadioProps, ResizableTable, SHIFT, type SearchConfig, type SearchProvider, type SearchResult, type SearchableOption, SearchableSelect, type SearchableSelectProps, Select, type SelectOption, type SelectProps, type SemanticGroup, ServerStatusIndicator, type ServerStatusIndicatorProps, type ServerStatusUser, type SeverityTone, type ShellAuth, ShellAuthProvider, ShellEntityFetcherProvider, type ShellNotification, type ShellPrefsAdapter, ShellPrefsProvider, ShortcutHelp, SidebarActionButton, type SidebarActionButtonProps, SidebarGroupLabel, SidebarLayout, type SidebarLayoutProps, SidebarNavItem, type SortState, SoundsPanel, Sparkline, type SparklineProps, StartMenu, StatCard, type StatCardProps, StatusBadge, StatusBadgeProvider, type StickyEntityRef, type StickyResolver, SystemPreferences, type SystemPreferencesProps, type SystemPreferencesSection, type TabItem, Tabs, type TabsProps, Textarea, type TextareaProps, type TodoProvider, type TodoTask, Tooltip, type TooltipProps, TopNav, type TopNavItem, type TopNavProps, VERSION, WidgetManager, WindowCrashedFallback, WindowErrorBoundary, WindowManagerProvider, WindowRegistry, WindowTitle, applyDevTitle, commitExposeHighlight, confirm, confirmDestructive, createWindowRegistry, exitExposeMode, findDuplicateKeys, formatDate, getActiveWindowRoute, getExposeHighlight, getWindowPosition, glassStyle, inputClasses, isDevEnv, isMac, isSeverityTone, mediaFileName, mergeBulkItems, prompt, registerModalEscapeInterceptor, setExposeHighlight, setShellApiClient, setShellAuthBridge, setShellNavIcons, setShellTodoProvider, setWindowDefaultPosition, setWindowPosition, severityOf, subscribeExposeHighlight, toISODate, toast, toggleExposeMode, useClickOutside, useColumnConfig, useDesktopHost, useEditHotkey, useFilters, useInfiniteScroll, useLocalStoragePrefs, useModalActive, useNewHotkey, useShellAuth, useShellEntityFetcher, useShellPrefs, useSort, useTableNav, useWidgetSettings, useWindowManager, useWindowMenuItem, useWindowTitle };
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { subscribePomo, getPomoSnapshot } from './chunk-
|
|
2
|
-
export { setShellTodoProvider } from './chunk-
|
|
1
|
+
import { subscribePomo, getPomoSnapshot } from './chunk-AT2OO6B4.js';
|
|
2
|
+
export { setShellTodoProvider } from './chunk-AT2OO6B4.js';
|
|
3
3
|
export { ImageAnnotator_default as ImageAnnotator } from './chunk-QU5L5ZYM.js';
|
|
4
4
|
import { PREVIEW_OPENED_EVENT, openPreviewFile } from './chunk-DINNWYVB.js';
|
|
5
5
|
export { Breadcrumbs } from './chunk-DINNWYVB.js';
|
|
@@ -7,7 +7,7 @@ import { SidebarLayout } from './chunk-YG45DAUT.js';
|
|
|
7
7
|
export { SidebarLayout } from './chunk-YG45DAUT.js';
|
|
8
8
|
import { toast_default } from './chunk-VENYVK3L.js';
|
|
9
9
|
export { toast_default as toast } from './chunk-VENYVK3L.js';
|
|
10
|
-
import { publishDesktopFolders, requestFilesTrashView, FolderGlyph, requestFilesDesktopFolderView, FileIconTile } from './chunk-
|
|
10
|
+
import { publishDesktopFolders, requestFilesTrashView, FolderGlyph, requestFilesDesktopFolderView, FileIconTile } from './chunk-52RFL3OQ.js';
|
|
11
11
|
import { setPdfPreview } from './chunk-BV6SQ46N.js';
|
|
12
12
|
import { playNotification, playStartup, soundsEnabled, getSoundConfig, SOUND_PACK_KEYS, SOUND_PACKS, SOUND_TYPES, SOUND_TYPE_LABELS, setSoundForType, previewSound, setAllSounds, playLogout } from './chunk-D7PYW2QS.js';
|
|
13
13
|
import { useAuth, useShellAuth } from './chunk-ADJ3CERD.js';
|
|
@@ -15,12 +15,12 @@ export { ShellAuthProvider, setShellAuthBridge, useShellAuth } from './chunk-ADJ
|
|
|
15
15
|
import { EditableGrid } from './chunk-GP4Y3VCB.js';
|
|
16
16
|
export { EditableGrid } from './chunk-GP4Y3VCB.js';
|
|
17
17
|
import './chunk-4SQU5YV6.js';
|
|
18
|
-
import { APP_VERSION, VERSION } from './chunk-
|
|
19
|
-
export { VERSION } from './chunk-
|
|
20
|
-
import { registerModalEscapeInterceptor, useIsMobile, useWindowManager, PopupMenu, PopupMenuLabel, PopupMenuDivider, PopupMenuItem, WINDOW_REGISTRY, isPageEntry, Modal, useShellPrefs, SIDEBAR_STRIP_W, forgetMaximizedWindowBoxes, ModalActions, useModalActive, client_default, LoadingSpinner, isShellApiClientConfigured, CancelButton, setWindowPosition } from './chunk-
|
|
21
|
-
export { CancelButton, ConfirmProvider, CopyButton, DocFavStar, Modal, ModalActions, PopupMenu, PopupMenuDivider, PopupMenuItem, PopupMenuLabel, ShellPrefsProvider, WindowCrashedFallback, WindowErrorBoundary, WindowManagerProvider, WindowTitle, commitExposeHighlight, confirm, confirmDestructive, exitExposeMode, getActiveWindowRoute, getExposeHighlight, getWindowPosition, isEntityEntry, isPageEntry, prompt, registerModalEscapeInterceptor, setExposeHighlight, setShellApiClient, setShellWindowRegistry, setWindowDefaultPosition, setWindowPosition, subscribeExposeHighlight, toggleExposeMode, useLocalStoragePrefs, useModalActive, useShellPrefs, useWidgetSettings, useWindowManager, useWindowMenuItem, useWindowTitle } from './chunk-
|
|
22
|
-
import { glassStyle, startMenuCategories, navSections, isSection, GLASS_INPUT_BG, navIcons, sectionIcons } from './chunk-
|
|
23
|
-
export { GLASS_DIVIDER, GLASS_INPUT_BG, glassStyle, setShellNavIcons } from './chunk-
|
|
18
|
+
import { APP_VERSION, VERSION } from './chunk-WURP3XRN.js';
|
|
19
|
+
export { VERSION } from './chunk-WURP3XRN.js';
|
|
20
|
+
import { registerModalEscapeInterceptor, useIsMobile, useWindowManager, PopupMenu, PopupMenuLabel, PopupMenuDivider, PopupMenuItem, WINDOW_REGISTRY, isPageEntry, Modal, useShellPrefs, SIDEBAR_STRIP_W, forgetMaximizedWindowBoxes, ModalActions, useModalActive, client_default, LoadingSpinner, isShellApiClientConfigured, CancelButton, setWindowPosition } from './chunk-OGL3C2T2.js';
|
|
21
|
+
export { CancelButton, ConfirmProvider, CopyButton, DocFavStar, Modal, ModalActions, PopupMenu, PopupMenuDivider, PopupMenuItem, PopupMenuLabel, ShellPrefsProvider, WindowCrashedFallback, WindowErrorBoundary, WindowManagerProvider, WindowTitle, commitExposeHighlight, confirm, confirmDestructive, exitExposeMode, getActiveWindowRoute, getExposeHighlight, getWindowPosition, isEntityEntry, isPageEntry, prompt, registerModalEscapeInterceptor, setExposeHighlight, setShellApiClient, setShellWindowRegistry, setWindowDefaultPosition, setWindowPosition, subscribeExposeHighlight, toggleExposeMode, useLocalStoragePrefs, useModalActive, useShellPrefs, useWidgetSettings, useWindowManager, useWindowMenuItem, useWindowTitle } from './chunk-OGL3C2T2.js';
|
|
22
|
+
import { glassStyle, startMenuCategories, navSections, isSection, GLASS_INPUT_BG, navIcons, isReachable, sectionIcons, visibleChildren } from './chunk-6Q4KYGMH.js';
|
|
23
|
+
export { GLASS_DIVIDER, GLASS_INPUT_BG, glassStyle, setShellNavIcons } from './chunk-6Q4KYGMH.js';
|
|
24
24
|
import { createContext, lazy, forwardRef, useCallback, useState, useRef, useId, useEffect, useLayoutEffect, useMemo, useContext, isValidElement, cloneElement, Suspense, Fragment as Fragment$1, Children, useSyncExternalStore } from 'react';
|
|
25
25
|
import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
26
26
|
import { Dialog, DialogBackdrop, DialogPanel } from '@headlessui/react';
|
|
@@ -2915,10 +2915,9 @@ function StartMenu({
|
|
|
2915
2915
|
const allItems = [];
|
|
2916
2916
|
const pushItem = (it, sectionLabel) => {
|
|
2917
2917
|
if (it.perms && !hasAnyPerm(it.perms)) return;
|
|
2918
|
+
if (!isReachable(it, hasAnyPerm)) return;
|
|
2918
2919
|
allItems.push({ item: it, sectionLabel });
|
|
2919
|
-
|
|
2920
|
-
for (const c of it.children) pushItem(c, it.label);
|
|
2921
|
-
}
|
|
2920
|
+
for (const c of visibleChildren(it, hasAnyPerm)) pushItem(c, it.label);
|
|
2922
2921
|
};
|
|
2923
2922
|
for (const entry of navSections2) {
|
|
2924
2923
|
if (isSection(entry)) {
|
|
@@ -2983,15 +2982,16 @@ function StartMenu({
|
|
|
2983
2982
|
const footerSections = navSections2.filter((item) => isSection(item) && footerLabels.has(item.label));
|
|
2984
2983
|
const hasAppsGroup = topItems.length > 0 || systemSections.length > 0 || virtualSections.length > 0;
|
|
2985
2984
|
const getVisibleItems = (section) => section.items.filter((item) => !item.perms || hasAnyPerm(item.perms));
|
|
2985
|
+
const visibleChildren2 = (item) => visibleChildren(item, hasAnyPerm);
|
|
2986
2986
|
const matchTree = (it, sectionLabel) => {
|
|
2987
2987
|
if (it.perms && !hasAnyPerm(it.perms)) return [];
|
|
2988
|
+
if (!isReachable(it, hasAnyPerm)) return [];
|
|
2989
|
+
const kids = visibleChildren2(it);
|
|
2988
2990
|
const hits = [];
|
|
2989
2991
|
if (it.label.toLowerCase().includes(search.toLowerCase())) {
|
|
2990
2992
|
hits.push({ ...it, section: sectionLabel });
|
|
2991
2993
|
}
|
|
2992
|
-
|
|
2993
|
-
for (const c of it.children) hits.push(...matchTree(c, it.label));
|
|
2994
|
-
}
|
|
2994
|
+
for (const c of kids) hits.push(...matchTree(c, it.label));
|
|
2995
2995
|
return hits;
|
|
2996
2996
|
};
|
|
2997
2997
|
const searchResults = search.length >= 2 ? [
|
|
@@ -3017,7 +3017,7 @@ function StartMenu({
|
|
|
3017
3017
|
};
|
|
3018
3018
|
const hoveredVirtual = hoveredSection ? virtualByLabel[hoveredSection] : void 0;
|
|
3019
3019
|
const hoveredData = hoveredVirtual ? null : hoveredSection ? [...erpSections, ...systemSections, ...footerSections].find((s) => s.label === hoveredSection) : null;
|
|
3020
|
-
const flyoutItems = hoveredVirtual ? hoveredVirtual.items : hoveredData ? getVisibleItems(hoveredData) : [];
|
|
3020
|
+
const flyoutItems = (hoveredVirtual ? hoveredVirtual.items : hoveredData ? getVisibleItems(hoveredData) : []).filter((item) => isReachable(item, hasAnyPerm));
|
|
3021
3021
|
const menuDensity = typeof document !== "undefined" ? getComputedStyle(document.documentElement).getPropertyValue("--menu-density")?.trim() || "normal" : "normal";
|
|
3022
3022
|
const density = menuDensity === "tight" || menuDensity === "large" ? menuDensity : "normal";
|
|
3023
3023
|
const sizeConfigByDensity = {
|
|
@@ -3255,7 +3255,7 @@ function StartMenu({
|
|
|
3255
3255
|
}, 200);
|
|
3256
3256
|
},
|
|
3257
3257
|
children: /* @__PURE__ */ jsx("div", { className: "py-1 px-1 overflow-y-auto overscroll-contain", style: { maxHeight: availH }, children: flyoutItems.map((item) => {
|
|
3258
|
-
const hasChildren =
|
|
3258
|
+
const hasChildren = visibleChildren2(item).length > 0;
|
|
3259
3259
|
const isChildHovered = hoveredChild === item.to;
|
|
3260
3260
|
return /* @__PURE__ */ jsxs(
|
|
3261
3261
|
"div",
|
|
@@ -3292,7 +3292,7 @@ function StartMenu({
|
|
|
3292
3292
|
(() => {
|
|
3293
3293
|
if (search.length >= 2 || !hoveredChild) return null;
|
|
3294
3294
|
const parent = flyoutItems.find((it) => it.to === hoveredChild);
|
|
3295
|
-
const kids =
|
|
3295
|
+
const kids = parent ? visibleChildren2(parent) : [];
|
|
3296
3296
|
if (!parent || kids.length === 0) return null;
|
|
3297
3297
|
const flyoutRect = flyoutRef.current?.getBoundingClientRect();
|
|
3298
3298
|
const subLeft = flyoutRect ? flyoutRect.right + 4 : 0;
|
|
@@ -3382,7 +3382,7 @@ function MobileAppLanding({
|
|
|
3382
3382
|
}
|
|
3383
3383
|
);
|
|
3384
3384
|
}
|
|
3385
|
-
var Sidebar = lazy(() => import('./Sidebar-
|
|
3385
|
+
var Sidebar = lazy(() => import('./Sidebar-VF2IOOFX.js'));
|
|
3386
3386
|
function useFavorites(wallpapers) {
|
|
3387
3387
|
const { prefs, save } = useShellPrefs();
|
|
3388
3388
|
const favorites = prefs.favorite_pages || [];
|
|
@@ -5915,12 +5915,12 @@ function Pagination({
|
|
|
5915
5915
|
] });
|
|
5916
5916
|
}
|
|
5917
5917
|
var Input = forwardRef(function Input2({ invalid, leftIcon, rightAdornment, className = "", ...rest }, ref) {
|
|
5918
|
-
const
|
|
5918
|
+
const pad2 = `${leftIcon ? "pl-9" : ""} ${rightAdornment ? "pr-9" : ""}`.trim();
|
|
5919
5919
|
const field = /* @__PURE__ */ jsx(
|
|
5920
5920
|
"input",
|
|
5921
5921
|
{
|
|
5922
5922
|
ref,
|
|
5923
|
-
className: inputClasses({ invalid, className: [
|
|
5923
|
+
className: inputClasses({ invalid, className: [pad2, className].filter(Boolean).join(" ") }),
|
|
5924
5924
|
...rest
|
|
5925
5925
|
}
|
|
5926
5926
|
);
|
|
@@ -6801,6 +6801,328 @@ function MediaUploadGrid({
|
|
|
6801
6801
|
}
|
|
6802
6802
|
) });
|
|
6803
6803
|
}
|
|
6804
|
+
var PRESET_LABELS = ["Last 2 Weeks", "Last Month", "Last 3 Months", "Last 6 Months", "Last 12 Months"];
|
|
6805
|
+
var MONTH_NAMES = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
|
|
6806
|
+
var YEARS_PER_PAGE = 12;
|
|
6807
|
+
var yearPageStart = (y) => Math.floor(y / YEARS_PER_PAGE) * YEARS_PER_PAGE;
|
|
6808
|
+
var pad = (n) => String(n).padStart(2, "0");
|
|
6809
|
+
function toISODate2(d) {
|
|
6810
|
+
return `${d.getFullYear()}-${pad(d.getMonth() + 1)}-${pad(d.getDate())}`;
|
|
6811
|
+
}
|
|
6812
|
+
function parseDate(s) {
|
|
6813
|
+
const [y, m, d] = s.split("-").map(Number);
|
|
6814
|
+
return new Date(y, m - 1, d);
|
|
6815
|
+
}
|
|
6816
|
+
function defaultFormatDisplay(s) {
|
|
6817
|
+
const [y, m, d] = s.split("-");
|
|
6818
|
+
return y && m && d ? `${d}/${m}/${y}` : s;
|
|
6819
|
+
}
|
|
6820
|
+
function DateRangePicker({
|
|
6821
|
+
from,
|
|
6822
|
+
to,
|
|
6823
|
+
onChange,
|
|
6824
|
+
formatDisplay = defaultFormatDisplay,
|
|
6825
|
+
clearable = true,
|
|
6826
|
+
placeholder = "Date Range"
|
|
6827
|
+
}) {
|
|
6828
|
+
const [open, setOpen] = useState(false);
|
|
6829
|
+
const [tempFrom, setTempFrom] = useState(from);
|
|
6830
|
+
const [tempTo, setTempTo] = useState(to);
|
|
6831
|
+
const [activePreset, setActivePreset] = useState(null);
|
|
6832
|
+
const ref = useRef(null);
|
|
6833
|
+
const now = /* @__PURE__ */ new Date();
|
|
6834
|
+
const [month, setMonth] = useState(from ? parseDate(from).getMonth() : now.getMonth());
|
|
6835
|
+
const [year, setYear] = useState(from ? parseDate(from).getFullYear() : now.getFullYear());
|
|
6836
|
+
const [view, setView] = useState("days");
|
|
6837
|
+
const [yearPage, setYearPage] = useState(() => yearPageStart(year));
|
|
6838
|
+
const displayDate = (s) => s ? formatDisplay(s) : "";
|
|
6839
|
+
useClickOutside(ref, useCallback(() => {
|
|
6840
|
+
if (open) setOpen(false);
|
|
6841
|
+
}, [open]));
|
|
6842
|
+
const handleOpen = () => {
|
|
6843
|
+
setTempFrom(from);
|
|
6844
|
+
setTempTo(to);
|
|
6845
|
+
setActivePreset(null);
|
|
6846
|
+
const anchor = from ? parseDate(from) : now;
|
|
6847
|
+
setMonth(anchor.getMonth());
|
|
6848
|
+
setYear(anchor.getFullYear());
|
|
6849
|
+
setYearPage(yearPageStart(anchor.getFullYear()));
|
|
6850
|
+
setView("days");
|
|
6851
|
+
setOpen(true);
|
|
6852
|
+
};
|
|
6853
|
+
const handlePreset = (label) => {
|
|
6854
|
+
let start, end;
|
|
6855
|
+
switch (label) {
|
|
6856
|
+
case "Last 2 Weeks":
|
|
6857
|
+
end = /* @__PURE__ */ new Date();
|
|
6858
|
+
start = /* @__PURE__ */ new Date();
|
|
6859
|
+
start.setDate(start.getDate() - 14);
|
|
6860
|
+
break;
|
|
6861
|
+
case "Last Month":
|
|
6862
|
+
start = new Date(now.getFullYear(), now.getMonth() - 1, 1);
|
|
6863
|
+
end = new Date(now.getFullYear(), now.getMonth(), 0);
|
|
6864
|
+
break;
|
|
6865
|
+
case "Last 3 Months":
|
|
6866
|
+
start = new Date(now.getFullYear(), now.getMonth() - 3, 1);
|
|
6867
|
+
end = new Date(now.getFullYear(), now.getMonth(), 0);
|
|
6868
|
+
break;
|
|
6869
|
+
case "Last 6 Months":
|
|
6870
|
+
start = new Date(now.getFullYear(), now.getMonth() - 6, 1);
|
|
6871
|
+
end = new Date(now.getFullYear(), now.getMonth(), 0);
|
|
6872
|
+
break;
|
|
6873
|
+
case "Last 12 Months":
|
|
6874
|
+
start = new Date(now.getFullYear(), now.getMonth() - 12, 1);
|
|
6875
|
+
end = new Date(now.getFullYear(), now.getMonth(), 0);
|
|
6876
|
+
break;
|
|
6877
|
+
default:
|
|
6878
|
+
return;
|
|
6879
|
+
}
|
|
6880
|
+
setTempFrom(toISODate2(start));
|
|
6881
|
+
setTempTo(toISODate2(end));
|
|
6882
|
+
setActivePreset(label);
|
|
6883
|
+
setMonth(start.getMonth());
|
|
6884
|
+
setYear(start.getFullYear());
|
|
6885
|
+
setYearPage(yearPageStart(start.getFullYear()));
|
|
6886
|
+
setView("days");
|
|
6887
|
+
};
|
|
6888
|
+
const handleCalendarSelect = (date) => {
|
|
6889
|
+
setActivePreset("Custom");
|
|
6890
|
+
if (!tempFrom || tempFrom && tempTo) {
|
|
6891
|
+
setTempFrom(date);
|
|
6892
|
+
setTempTo("");
|
|
6893
|
+
} else {
|
|
6894
|
+
if (date < tempFrom) {
|
|
6895
|
+
setTempTo(tempFrom);
|
|
6896
|
+
setTempFrom(date);
|
|
6897
|
+
} else {
|
|
6898
|
+
setTempTo(date);
|
|
6899
|
+
}
|
|
6900
|
+
}
|
|
6901
|
+
};
|
|
6902
|
+
const handleApply = () => {
|
|
6903
|
+
onChange(tempFrom, tempTo);
|
|
6904
|
+
setOpen(false);
|
|
6905
|
+
};
|
|
6906
|
+
const handleClear = () => {
|
|
6907
|
+
onChange("", "");
|
|
6908
|
+
setOpen(false);
|
|
6909
|
+
};
|
|
6910
|
+
const changeMonth = (delta) => {
|
|
6911
|
+
let m = month + delta, y = year;
|
|
6912
|
+
if (m < 0) {
|
|
6913
|
+
m = 11;
|
|
6914
|
+
y--;
|
|
6915
|
+
} else if (m > 11) {
|
|
6916
|
+
m = 0;
|
|
6917
|
+
y++;
|
|
6918
|
+
}
|
|
6919
|
+
setMonth(m);
|
|
6920
|
+
setYear(y);
|
|
6921
|
+
};
|
|
6922
|
+
const handleStep = (delta) => {
|
|
6923
|
+
if (view === "days") changeMonth(delta);
|
|
6924
|
+
else if (view === "months") setYear(year + delta);
|
|
6925
|
+
else setYearPage(yearPage + delta * YEARS_PER_PAGE);
|
|
6926
|
+
};
|
|
6927
|
+
const selectMonth = (m) => {
|
|
6928
|
+
setMonth(m);
|
|
6929
|
+
setView("days");
|
|
6930
|
+
};
|
|
6931
|
+
const selectYear = (y) => {
|
|
6932
|
+
setYear(y);
|
|
6933
|
+
setView("months");
|
|
6934
|
+
};
|
|
6935
|
+
const openYears = () => {
|
|
6936
|
+
setYearPage(yearPageStart(year));
|
|
6937
|
+
setView("years");
|
|
6938
|
+
};
|
|
6939
|
+
const firstDay = new Date(year, month, 1).getDay();
|
|
6940
|
+
const daysInMonth = new Date(year, month + 1, 0).getDate();
|
|
6941
|
+
const prevDays = new Date(year, month, 0).getDate();
|
|
6942
|
+
const monthName = new Date(year, month).toLocaleString("default", { month: "long" });
|
|
6943
|
+
const cells = [];
|
|
6944
|
+
for (let i = firstDay - 1; i >= 0; i--) {
|
|
6945
|
+
const d = new Date(year, month - 1, prevDays - i);
|
|
6946
|
+
cells.push({ day: prevDays - i, current: false, date: toISODate2(d) });
|
|
6947
|
+
}
|
|
6948
|
+
for (let d = 1; d <= daysInMonth; d++) {
|
|
6949
|
+
cells.push({ day: d, current: true, date: toISODate2(new Date(year, month, d)) });
|
|
6950
|
+
}
|
|
6951
|
+
const remaining = 42 - cells.length;
|
|
6952
|
+
for (let d = 1; d <= remaining; d++) {
|
|
6953
|
+
cells.push({ day: d, current: false, date: toISODate2(new Date(year, month + 1, d)) });
|
|
6954
|
+
}
|
|
6955
|
+
const isInRange = (date) => {
|
|
6956
|
+
if (!tempFrom || !tempTo) return false;
|
|
6957
|
+
const s = tempFrom < tempTo ? tempFrom : tempTo;
|
|
6958
|
+
const e = tempFrom < tempTo ? tempTo : tempFrom;
|
|
6959
|
+
return date > s && date < e;
|
|
6960
|
+
};
|
|
6961
|
+
const displayText = from && to ? `${displayDate(from)} \u2014 ${displayDate(to)}` : from ? `From ${displayDate(from)}` : to ? `To ${displayDate(to)}` : "";
|
|
6962
|
+
return /* @__PURE__ */ jsxs("div", { className: "relative", ref, children: [
|
|
6963
|
+
/* @__PURE__ */ jsxs(
|
|
6964
|
+
"div",
|
|
6965
|
+
{
|
|
6966
|
+
className: `inline-flex items-center gap-2 border rounded-lg px-2.5 py-1.5 text-sm focus-within:border-blue-500 focus-within:ring-1 focus-within:ring-blue-500 ${from || to ? "border-blue-400 bg-blue-50 text-blue-700" : "border-gray-300 text-gray-500"}`,
|
|
6967
|
+
children: [
|
|
6968
|
+
/* @__PURE__ */ jsxs(
|
|
6969
|
+
"button",
|
|
6970
|
+
{
|
|
6971
|
+
type: "button",
|
|
6972
|
+
onClick: handleOpen,
|
|
6973
|
+
"aria-haspopup": "dialog",
|
|
6974
|
+
"aria-expanded": open,
|
|
6975
|
+
className: "inline-flex items-center gap-2 focus:outline-none",
|
|
6976
|
+
children: [
|
|
6977
|
+
/* @__PURE__ */ jsx("svg", { className: "w-4 h-4 shrink-0", fill: "none", stroke: "currentColor", strokeWidth: "2", viewBox: "0 0 24 24", children: /* @__PURE__ */ jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M8 7V3m8 4V3m-9 8h10M5 21h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z" }) }),
|
|
6978
|
+
displayText || placeholder
|
|
6979
|
+
]
|
|
6980
|
+
}
|
|
6981
|
+
),
|
|
6982
|
+
clearable && (from || to) && /* @__PURE__ */ jsx(
|
|
6983
|
+
"button",
|
|
6984
|
+
{
|
|
6985
|
+
type: "button",
|
|
6986
|
+
onClick: handleClear,
|
|
6987
|
+
"aria-label": "Clear date range",
|
|
6988
|
+
className: "text-blue-400 hover:text-red-500 focus:outline-none focus-visible:ring-1 focus-visible:ring-blue-500 rounded",
|
|
6989
|
+
children: "\xD7"
|
|
6990
|
+
}
|
|
6991
|
+
)
|
|
6992
|
+
]
|
|
6993
|
+
}
|
|
6994
|
+
),
|
|
6995
|
+
open && /* @__PURE__ */ jsxs("div", { className: "absolute z-50 mt-1 rounded-2xl p-4", style: { right: 0, ...glassStyle() }, children: [
|
|
6996
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3 mb-3", children: [
|
|
6997
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
6998
|
+
/* @__PURE__ */ jsx("span", { className: "text-xs font-medium text-gray-500", children: "From" }),
|
|
6999
|
+
/* @__PURE__ */ jsx("span", { className: `text-sm px-2 py-1 rounded border min-w-[90px] ${tempFrom ? "border-blue-300 bg-blue-50 text-blue-700" : "border-gray-200 bg-gray-50 text-gray-400"}`, children: tempFrom ? displayDate(tempFrom) : "Start" })
|
|
7000
|
+
] }),
|
|
7001
|
+
/* @__PURE__ */ jsx("span", { className: "text-gray-300", children: "\u2014" }),
|
|
7002
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
7003
|
+
/* @__PURE__ */ jsx("span", { className: "text-xs font-medium text-gray-500", children: "To" }),
|
|
7004
|
+
/* @__PURE__ */ jsx("span", { className: `text-sm px-2 py-1 rounded border min-w-[90px] ${tempTo ? "border-blue-300 bg-blue-50 text-blue-700" : "border-gray-200 bg-gray-50 text-gray-400"}`, children: tempTo ? displayDate(tempTo) : "End" })
|
|
7005
|
+
] })
|
|
7006
|
+
] }),
|
|
7007
|
+
/* @__PURE__ */ jsxs("div", { className: "flex gap-4", children: [
|
|
7008
|
+
/* @__PURE__ */ jsxs("div", { className: "w-64", children: [
|
|
7009
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between mb-2 px-1", children: [
|
|
7010
|
+
/* @__PURE__ */ jsx("button", { type: "button", onClick: () => handleStep(-1), "aria-label": "Previous", className: "p-1 rounded-full hover:bg-gray-100 text-gray-600", children: /* @__PURE__ */ jsx("svg", { className: "w-4 h-4", fill: "none", stroke: "currentColor", strokeWidth: "2", viewBox: "0 0 24 24", children: /* @__PURE__ */ jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M15 19l-7-7 7-7" }) }) }),
|
|
7011
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1 text-sm font-semibold text-gray-800", children: [
|
|
7012
|
+
view === "days" && /* @__PURE__ */ jsx(
|
|
7013
|
+
"button",
|
|
7014
|
+
{
|
|
7015
|
+
type: "button",
|
|
7016
|
+
onClick: () => setView("months"),
|
|
7017
|
+
className: "px-1.5 py-0.5 rounded-md hover:bg-gray-100 transition-colors",
|
|
7018
|
+
children: monthName
|
|
7019
|
+
}
|
|
7020
|
+
),
|
|
7021
|
+
view === "years" ? /* @__PURE__ */ jsxs("span", { className: "px-1.5 py-0.5", children: [
|
|
7022
|
+
yearPage,
|
|
7023
|
+
" \u2013 ",
|
|
7024
|
+
yearPage + YEARS_PER_PAGE - 1
|
|
7025
|
+
] }) : /* @__PURE__ */ jsx(
|
|
7026
|
+
"button",
|
|
7027
|
+
{
|
|
7028
|
+
type: "button",
|
|
7029
|
+
onClick: openYears,
|
|
7030
|
+
className: "px-1.5 py-0.5 rounded-md hover:bg-gray-100 transition-colors",
|
|
7031
|
+
children: year
|
|
7032
|
+
}
|
|
7033
|
+
)
|
|
7034
|
+
] }),
|
|
7035
|
+
/* @__PURE__ */ jsx("button", { type: "button", onClick: () => handleStep(1), "aria-label": "Next", className: "p-1 rounded-full hover:bg-gray-100 text-gray-600", children: /* @__PURE__ */ jsx("svg", { className: "w-4 h-4", fill: "none", stroke: "currentColor", strokeWidth: "2", viewBox: "0 0 24 24", children: /* @__PURE__ */ jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M9 5l7 7-7 7" }) }) })
|
|
7036
|
+
] }),
|
|
7037
|
+
/* @__PURE__ */ jsxs("div", { className: "min-h-[13.75rem]", children: [
|
|
7038
|
+
view === "days" && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
7039
|
+
/* @__PURE__ */ jsx("div", { className: "grid grid-cols-7 text-center text-xs font-medium text-gray-500 mb-1", children: ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"].map((d) => /* @__PURE__ */ jsx("div", { className: "py-1", children: d }, d)) }),
|
|
7040
|
+
/* @__PURE__ */ jsx("div", { className: "grid grid-cols-7 text-center text-sm", children: cells.map((c, i) => {
|
|
7041
|
+
const isStart = c.date === tempFrom;
|
|
7042
|
+
const isEnd = c.date === tempTo;
|
|
7043
|
+
const isSelected = isStart || isEnd;
|
|
7044
|
+
const inRange = isInRange(c.date);
|
|
7045
|
+
return /* @__PURE__ */ jsx(
|
|
7046
|
+
"button",
|
|
7047
|
+
{
|
|
7048
|
+
type: "button",
|
|
7049
|
+
onClick: () => handleCalendarSelect(c.date),
|
|
7050
|
+
className: `py-1.5 rounded-md transition-colors ${!c.current ? "text-gray-300" : isSelected ? "bg-blue-600 text-white font-semibold" : inRange ? "bg-blue-100 text-blue-800" : "text-gray-700 hover:bg-gray-100"}`,
|
|
7051
|
+
children: c.day
|
|
7052
|
+
},
|
|
7053
|
+
i
|
|
7054
|
+
);
|
|
7055
|
+
}) })
|
|
7056
|
+
] }),
|
|
7057
|
+
view === "months" && /* @__PURE__ */ jsx("div", { className: "grid grid-cols-3 gap-1 text-center text-sm", children: MONTH_NAMES.map((name, m) => {
|
|
7058
|
+
const isCurrent = m === month;
|
|
7059
|
+
const isThisMonth = m === now.getMonth() && year === now.getFullYear();
|
|
7060
|
+
return /* @__PURE__ */ jsx(
|
|
7061
|
+
"button",
|
|
7062
|
+
{
|
|
7063
|
+
type: "button",
|
|
7064
|
+
onClick: () => selectMonth(m),
|
|
7065
|
+
className: `py-4 rounded-md transition-colors ${isCurrent ? "bg-blue-600 text-white font-semibold" : isThisMonth ? "text-blue-600 font-medium hover:bg-gray-100" : "text-gray-700 hover:bg-gray-100"}`,
|
|
7066
|
+
children: name
|
|
7067
|
+
},
|
|
7068
|
+
name
|
|
7069
|
+
);
|
|
7070
|
+
}) }),
|
|
7071
|
+
view === "years" && /* @__PURE__ */ jsx("div", { className: "grid grid-cols-3 gap-1 text-center text-sm", children: Array.from({ length: YEARS_PER_PAGE }, (_, i) => yearPage + i).map((y) => {
|
|
7072
|
+
const isCurrent = y === year;
|
|
7073
|
+
const isThisYear = y === now.getFullYear();
|
|
7074
|
+
return /* @__PURE__ */ jsx(
|
|
7075
|
+
"button",
|
|
7076
|
+
{
|
|
7077
|
+
type: "button",
|
|
7078
|
+
onClick: () => selectYear(y),
|
|
7079
|
+
className: `py-4 rounded-md transition-colors ${isCurrent ? "bg-blue-600 text-white font-semibold" : isThisYear ? "text-blue-600 font-medium hover:bg-gray-100" : "text-gray-700 hover:bg-gray-100"}`,
|
|
7080
|
+
children: y
|
|
7081
|
+
},
|
|
7082
|
+
y
|
|
7083
|
+
);
|
|
7084
|
+
}) })
|
|
7085
|
+
] })
|
|
7086
|
+
] }),
|
|
7087
|
+
/* @__PURE__ */ jsxs("div", { className: "border-l border-gray-200 pl-4 flex flex-col gap-1 min-w-[130px]", children: [
|
|
7088
|
+
PRESET_LABELS.map((label) => /* @__PURE__ */ jsx(
|
|
7089
|
+
"button",
|
|
7090
|
+
{
|
|
7091
|
+
type: "button",
|
|
7092
|
+
onClick: () => handlePreset(label),
|
|
7093
|
+
className: `text-left px-3 py-1.5 text-sm rounded-md transition-colors ${activePreset === label ? "bg-blue-50 text-blue-700 font-medium" : "text-gray-700 hover:bg-gray-50"}`,
|
|
7094
|
+
children: label
|
|
7095
|
+
},
|
|
7096
|
+
label
|
|
7097
|
+
)),
|
|
7098
|
+
/* @__PURE__ */ jsx(
|
|
7099
|
+
"button",
|
|
7100
|
+
{
|
|
7101
|
+
type: "button",
|
|
7102
|
+
onClick: () => setActivePreset("Custom"),
|
|
7103
|
+
className: `text-left px-3 py-1.5 text-sm rounded-md transition-colors ${activePreset === "Custom" ? "bg-blue-50 text-blue-700 font-medium" : "text-gray-700 hover:bg-gray-50"}`,
|
|
7104
|
+
children: "Custom"
|
|
7105
|
+
}
|
|
7106
|
+
)
|
|
7107
|
+
] })
|
|
7108
|
+
] }),
|
|
7109
|
+
/* @__PURE__ */ jsxs("div", { className: "flex justify-end gap-2 mt-4 pt-3 border-t border-gray-200", children: [
|
|
7110
|
+
clearable && /* @__PURE__ */ jsx("button", { type: "button", onClick: handleClear, className: "px-3 py-1.5 text-sm text-gray-500 hover:text-gray-700", children: "Clear" }),
|
|
7111
|
+
/* @__PURE__ */ jsx("button", { type: "button", onClick: () => setOpen(false), className: "px-3 py-1.5 text-sm text-gray-600 border border-gray-300 rounded-md hover:bg-gray-50", children: "Cancel" }),
|
|
7112
|
+
/* @__PURE__ */ jsx(
|
|
7113
|
+
"button",
|
|
7114
|
+
{
|
|
7115
|
+
type: "button",
|
|
7116
|
+
onClick: handleApply,
|
|
7117
|
+
disabled: !tempFrom || !tempTo,
|
|
7118
|
+
className: "px-4 py-1.5 text-sm font-medium text-white bg-blue-600 rounded-md hover:bg-blue-700 disabled:opacity-50",
|
|
7119
|
+
children: "Apply"
|
|
7120
|
+
}
|
|
7121
|
+
)
|
|
7122
|
+
] })
|
|
7123
|
+
] })
|
|
7124
|
+
] });
|
|
7125
|
+
}
|
|
6804
7126
|
function Card({ children, header, footer, padded = true, className = "" }) {
|
|
6805
7127
|
return /* @__PURE__ */ jsxs("div", { className: `rounded-lg border border-gray-200 bg-white shadow-sm ${className}`.trim(), children: [
|
|
6806
7128
|
header && /* @__PURE__ */ jsx("div", { className: "border-b border-gray-100 px-4 py-3 text-sm font-semibold text-gray-900", children: header }),
|
|
@@ -8934,8 +9256,8 @@ function Sparkline({
|
|
|
8934
9256
|
const max = Math.max(...data);
|
|
8935
9257
|
const min = Math.min(...data);
|
|
8936
9258
|
const span = max - min || 1;
|
|
8937
|
-
const
|
|
8938
|
-
const y = (v) => height -
|
|
9259
|
+
const pad2 = strokeWidth + (showDots ? 2 : 0);
|
|
9260
|
+
const y = (v) => height - pad2 - (v - min) / span * (height - pad2 * 2);
|
|
8939
9261
|
const pts = data.length === 1 ? [[0, height / 2], [width, height / 2]] : data.map((v, i) => [i * width / (data.length - 1), y(v)]);
|
|
8940
9262
|
const line = pts.map(([x, yy], i) => `${i === 0 ? "M" : "L"}${x.toFixed(2)},${yy.toFixed(2)}`).join(" ");
|
|
8941
9263
|
const area = `${line} L${width.toFixed(2)},${height} L0,${height} Z`;
|
|
@@ -9641,6 +9963,6 @@ function useEditHotkey(callback) {
|
|
|
9641
9963
|
}, [callback, isActive]);
|
|
9642
9964
|
}
|
|
9643
9965
|
|
|
9644
|
-
export { ALT, ALT_SHIFT_D, ALT_SHIFT_E, ALT_SHIFT_N, Accordion, AuthScreen, Avatar, AvatarGroup, Banner, BarChart, BehaviorPanel, BulkImportGrid, Button_default as Button, CMD_A, CMD_DOT, CMD_ENTER, CMD_K, CMD_S, Card, ChangePasswordForm, ChatTemplate, Checkbox_default as Checkbox, CheckoutTemplate, ColoredBadge, ContainerFillChart, Customization, DEV_BANNER_TEXT, DashboardTemplate, DataTablePage, Desktop, DesktopHostProvider, DevIndicator, DonutChart, ENTER, EmailTemplate, EmptyState, EntityList, ErrorPage, FilterBar, FormField, FormLayoutPage, GalleryTemplate, GlobalSearch, HelpCenter, INPUT_BASE, Input_default as Input, Kanban, Label, Layout, ListFooter, ListLoadError, LoadingSpinner2 as LoadingSpinner, MOD, Markdown, MediaUploadField, MediaUploadGrid, MetricBar, MilestoneTimeline, NativeSelect, NotificationBell, PageHeader, Pagination, PdfActionButton, Radio_default as Radio, ResizableTable, SHIFT, SearchableSelect, Select_default as Select, ServerStatusIndicator, ShellEntityFetcherProvider, ShortcutHelp, SidebarActionButton, SidebarGroupLabel, SidebarNavItem, SoundsPanel, Sparkline, StartMenu, StatCard, StatusBadge, StatusBadgeProvider, SystemPreferences, Tabs, Textarea_default as Textarea, Tooltip, TopNav, WidgetManager, applyDevTitle, createWindowRegistry, findDuplicateKeys, formatDate, inputClasses, isDevEnv, isMac, isSeverityTone, mediaFileName, mergeBulkItems, severityOf, useClickOutside, useColumnConfig, useDesktopHost, useEditHotkey, useFilters, useInfiniteScroll, useNewHotkey, useShellEntityFetcher, useSort, useTableNav };
|
|
9966
|
+
export { ALT, ALT_SHIFT_D, ALT_SHIFT_E, ALT_SHIFT_N, Accordion, AuthScreen, Avatar, AvatarGroup, Banner, BarChart, BehaviorPanel, BulkImportGrid, Button_default as Button, CMD_A, CMD_DOT, CMD_ENTER, CMD_K, CMD_S, Card, ChangePasswordForm, ChatTemplate, Checkbox_default as Checkbox, CheckoutTemplate, ColoredBadge, ContainerFillChart, Customization, DEV_BANNER_TEXT, DashboardTemplate, DataTablePage, DateRangePicker, Desktop, DesktopHostProvider, DevIndicator, DonutChart, ENTER, EmailTemplate, EmptyState, EntityList, ErrorPage, FilterBar, FormField, FormLayoutPage, GalleryTemplate, GlobalSearch, HelpCenter, INPUT_BASE, Input_default as Input, Kanban, Label, Layout, ListFooter, ListLoadError, LoadingSpinner2 as LoadingSpinner, MOD, Markdown, MediaUploadField, MediaUploadGrid, MetricBar, MilestoneTimeline, NativeSelect, NotificationBell, PageHeader, Pagination, PdfActionButton, Radio_default as Radio, ResizableTable, SHIFT, SearchableSelect, Select_default as Select, ServerStatusIndicator, ShellEntityFetcherProvider, ShortcutHelp, SidebarActionButton, SidebarGroupLabel, SidebarNavItem, SoundsPanel, Sparkline, StartMenu, StatCard, StatusBadge, StatusBadgeProvider, SystemPreferences, Tabs, Textarea_default as Textarea, Tooltip, TopNav, WidgetManager, applyDevTitle, createWindowRegistry, findDuplicateKeys, formatDate, inputClasses, isDevEnv, isMac, isSeverityTone, mediaFileName, mergeBulkItems, severityOf, toISODate2 as toISODate, useClickOutside, useColumnConfig, useDesktopHost, useEditHotkey, useFilters, useInfiniteScroll, useNewHotkey, useShellEntityFetcher, useSort, useTableNav };
|
|
9645
9967
|
//# sourceMappingURL=index.js.map
|
|
9646
9968
|
//# sourceMappingURL=index.js.map
|