@genispace/geniapp 0.1.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/LICENSE +21 -0
- package/README.md +153 -0
- package/dist/CrossAppRecordPicker-BXchXcK5.js +624 -0
- package/dist/CrossAppRecordPicker-BXchXcK5.js.map +1 -0
- package/dist/Page-wHZrMN17.js +24 -0
- package/dist/Page-wHZrMN17.js.map +1 -0
- package/dist/ai/adopt/AiSuggestionPanel.d.ts +30 -0
- package/dist/ai/adopt/BusinessGuidancePanel.d.ts +31 -0
- package/dist/ai/adopt/DetailPageAiLayout.d.ts +7 -0
- package/dist/ai/adopt/adoptPresets.d.ts +11 -0
- package/dist/ai/adopt/guidanceContent.d.ts +27 -0
- package/dist/ai/adopt/parseAiSummary.d.ts +7 -0
- package/dist/ai/components/AgentJobProgress.d.ts +124 -0
- package/dist/ai/components/AsyncCombobox.d.ts +44 -0
- package/dist/ai/components/BulkActionBar.d.ts +44 -0
- package/dist/ai/components/EntityRef.d.ts +39 -0
- package/dist/ai/components/JobProgress.d.ts +64 -0
- package/dist/ai/components/ServerDataTable.d.ts +89 -0
- package/dist/ai/components/Timeline.d.ts +35 -0
- package/dist/ai/components/useInfiniteRows.d.ts +25 -0
- package/dist/ai/errors/userFacingError.d.ts +14 -0
- package/dist/ai/errors/userFacingError.js +48 -0
- package/dist/ai/errors/userFacingError.js.map +1 -0
- package/dist/ai/index.d.ts +34 -0
- package/dist/ai/integrations/partner/createPartnerRecordPickerHook.d.ts +15 -0
- package/dist/ai/integrations/partner/partnerRecordPicker.d.ts +20 -0
- package/dist/ai/layout/ModalWithAiLayout.d.ts +11 -0
- package/dist/ai/layout/aiUi.d.ts +16 -0
- package/dist/ai/layout/layoutConstants.d.ts +19 -0
- package/dist/ai/layout/modalSizeForAi.d.ts +5 -0
- package/dist/ai/locales/sharedAiCopy.d.ts +6 -0
- package/dist/ai/managed-data/DatasourceReadonlyTable.d.ts +11 -0
- package/dist/ai/managed-data/createTableClient.d.ts +7 -0
- package/dist/ai/managed-data/emitManagedEvent.d.ts +18 -0
- package/dist/ai/managed-data/executeManagedDatasource.d.ts +21 -0
- package/dist/ai/managed-data/queryManagedDatasource.d.ts +28 -0
- package/dist/ai/providers/AppUiProviders.d.ts +6 -0
- package/dist/ai/types/app-ai.types.d.ts +29 -0
- package/dist/ai/types/index.d.ts +1 -0
- package/dist/ai.d.ts +1 -0
- package/dist/ai.js +1817 -0
- package/dist/ai.js.map +1 -0
- package/dist/case-workspace/domain.d.ts +41 -0
- package/dist/case-workspace/domain.js +24 -0
- package/dist/case-workspace/domain.js.map +1 -0
- package/dist/case-workspace/index.d.ts +91 -0
- package/dist/case-workspace.d.ts +1 -0
- package/dist/case-workspace.js +392 -0
- package/dist/case-workspace.js.map +1 -0
- package/dist/cn-B6yFEsav.js +9 -0
- package/dist/cn-B6yFEsav.js.map +1 -0
- package/dist/components/ui/calendar.css +7 -0
- package/dist/cookieSettings-D_v3KS02.js +97 -0
- package/dist/cookieSettings-D_v3KS02.js.map +1 -0
- package/dist/dashboard/index.d.ts +16 -0
- package/dist/dashboard/src/ChartFrame.d.ts +18 -0
- package/dist/dashboard/src/ChartTooltip.d.ts +38 -0
- package/dist/dashboard/src/FilterBar.d.ts +23 -0
- package/dist/dashboard/src/KpiStatCard.d.ts +29 -0
- package/dist/dashboard/src/StatGrid.d.ts +15 -0
- package/dist/dashboard/src/TimeRangePicker.d.ts +14 -0
- package/dist/dashboard/src/chart.d.ts +10 -0
- package/dist/dashboard/src/format.d.ts +16 -0
- package/dist/dashboard/src/links.d.ts +2 -0
- package/dist/dashboard/src/useDashboardRange.d.ts +27 -0
- package/dist/dashboard.d.ts +1 -0
- package/dist/dashboard.js +361 -0
- package/dist/dashboard.js.map +1 -0
- package/dist/fonts.css +15 -0
- package/dist/hooks/access/AppAccessGate.d.ts +20 -0
- package/dist/hooks/access/AppAccessNotice.d.ts +8 -0
- package/dist/hooks/access/useAppAccess.d.ts +26 -0
- package/dist/hooks/config/businessLocale.d.ts +12 -0
- package/dist/hooks/config/currencies.d.ts +9 -0
- package/dist/hooks/index.d.ts +17 -0
- package/dist/hooks/picker/CrossAppRecordPicker.d.ts +37 -0
- package/dist/hooks/picker/managedAppPicker.d.ts +21 -0
- package/dist/hooks/picker/partnerPayload.d.ts +6 -0
- package/dist/hooks/routing/draftEntityId.d.ts +5 -0
- package/dist/hooks/routing/useRefetchOnRouteMatch.d.ts +6 -0
- package/dist/hooks/shell/resolveApiRoot.d.ts +13 -0
- package/dist/hooks/shell/shell.d.ts +4 -0
- package/dist/hooks/shell/useGenispacePlatformClient.d.ts +7 -0
- package/dist/hooks.d.ts +1 -0
- package/dist/hooks.js +42 -0
- package/dist/hooks.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +77 -0
- package/dist/index.js.map +1 -0
- package/dist/kit.d.ts +50 -0
- package/dist/kit.js +2067 -0
- package/dist/kit.js.map +1 -0
- package/dist/page.d.ts +1 -0
- package/dist/page.js +5 -0
- package/dist/page.js.map +1 -0
- package/dist/shell-DIHnXIUb.js +6 -0
- package/dist/shell-DIHnXIUb.js.map +1 -0
- package/dist/shell.d.ts +30 -0
- package/dist/shell.js +104 -0
- package/dist/shell.js.map +1 -0
- package/dist/storage/assetPreview.d.ts +12 -0
- package/dist/storage/components/AssetThumbnail.d.ts +15 -0
- package/dist/storage/components/CopyStorageLinkButton.d.ts +13 -0
- package/dist/storage/components/StorageImage.d.ts +9 -0
- package/dist/storage/components/StoragePreviewContent.d.ts +22 -0
- package/dist/storage/components/StorageVideo.d.ts +9 -0
- package/dist/storage/copyTextToClipboard.d.ts +5 -0
- package/dist/storage/hooks/useAuthenticatedStorageBlobs.d.ts +3 -0
- package/dist/storage/hooks/useImageThumbnailBlobs.d.ts +4 -0
- package/dist/storage/hooks/useShareableStorageLink.d.ts +7 -0
- package/dist/storage/index.d.ts +12 -0
- package/dist/storage/openUrlInNewTab.d.ts +6 -0
- package/dist/storage/platformStorage.d.ts +43 -0
- package/dist/storage.d.ts +1 -0
- package/dist/storage.js +605 -0
- package/dist/storage.js.map +1 -0
- package/dist/style.css +1 -0
- package/dist/styles/base.css +616 -0
- package/dist/styles/reduced-motion.css +14 -0
- package/dist/styles/tailwind-preset.js +269 -0
- package/dist/task-workspace/domain.d.ts +35 -0
- package/dist/task-workspace/domain.js +45 -0
- package/dist/task-workspace/domain.js.map +1 -0
- package/dist/task-workspace/experience.d.ts +50 -0
- package/dist/task-workspace/index.d.ts +172 -0
- package/dist/task-workspace.d.ts +1 -0
- package/dist/task-workspace.js +626 -0
- package/dist/task-workspace.js.map +1 -0
- package/dist/ui/components/features/app/AppCheckboxInput.d.ts +9 -0
- package/dist/ui/components/features/app/AppConfirmDialog.d.ts +12 -0
- package/dist/ui/components/features/app/AppDashboardSkeleton.d.ts +9 -0
- package/dist/ui/components/features/app/AppDatePicker.d.ts +69 -0
- package/dist/ui/components/features/app/AppModal.d.ts +27 -0
- package/dist/ui/components/features/app/AppPageStates.d.ts +17 -0
- package/dist/ui/components/features/app/AppSelectInput.d.ts +10 -0
- package/dist/ui/components/features/app/AppTemporalInput.d.ts +19 -0
- package/dist/ui/components/features/app/Page.d.ts +14 -0
- package/dist/ui/components/features/app/QueryErrorAlert.d.ts +7 -0
- package/dist/ui/components/features/app/Sidebar.d.ts +47 -0
- package/dist/ui/components/features/app/index.d.ts +17 -0
- package/dist/ui/components/features/user/UserAvatar.d.ts +17 -0
- package/dist/ui/components/features/user/UserDisplay.d.ts +10 -0
- package/dist/ui/components/features/user/UserSelect.d.ts +14 -0
- package/dist/ui/components/features/user/useUserDirectory.d.ts +13 -0
- package/dist/ui/components/features/user/userDirectoryTypes.d.ts +18 -0
- package/dist/ui/components/patterns/form-section.d.ts +11 -0
- package/dist/ui/components/primitives/feedback/index.d.ts +2 -0
- package/dist/ui/components/primitives/feedback/toaster.d.ts +1 -0
- package/dist/ui/components/primitives/feedback/use-toast.d.ts +46 -0
- package/dist/ui/components/primitives/page-skeleton/ChartAreaSkeleton.d.ts +13 -0
- package/dist/ui/components/primitives/page-skeleton/ChartEmptyState.d.ts +14 -0
- package/dist/ui/components/primitives/page-skeleton/ComponentSkeletonShell.d.ts +16 -0
- package/dist/ui/components/primitives/page-skeleton/ConfigEditorSkeleton.d.ts +5 -0
- package/dist/ui/components/primitives/page-skeleton/DetailTabsSkeleton.d.ts +6 -0
- package/dist/ui/components/primitives/page-skeleton/EmptyStateBadge.d.ts +13 -0
- package/dist/ui/components/primitives/page-skeleton/FormCardSkeleton.d.ts +7 -0
- package/dist/ui/components/primitives/page-skeleton/FormFieldSkeleton.d.ts +6 -0
- package/dist/ui/components/primitives/page-skeleton/FormPageSkeleton.d.ts +6 -0
- package/dist/ui/components/primitives/page-skeleton/GridCardsSkeleton.d.ts +6 -0
- package/dist/ui/components/primitives/page-skeleton/ListSkeleton.d.ts +26 -0
- package/dist/ui/components/primitives/page-skeleton/PageHeaderSkeleton.d.ts +6 -0
- package/dist/ui/components/primitives/page-skeleton/SplitPaneSkeleton.d.ts +4 -0
- package/dist/ui/components/primitives/page-skeleton/StatsRowSkeleton.d.ts +5 -0
- package/dist/ui/components/primitives/page-skeleton/TableEmptyState.d.ts +27 -0
- package/dist/ui/components/primitives/page-skeleton/TablePageSkeleton.d.ts +8 -0
- package/dist/ui/components/primitives/page-skeleton/TabsBarSkeleton.d.ts +6 -0
- package/dist/ui/components/primitives/page-skeleton/index.d.ts +24 -0
- package/dist/ui/components/primitives/page-skeleton/skeletonMetrics.d.ts +9 -0
- package/dist/ui/components/primitives/page-skeleton/useVisibleCenter.d.ts +34 -0
- package/dist/ui/components/ui/accordion.d.ts +7 -0
- package/dist/ui/components/ui/ai-draft-banner.d.ts +21 -0
- package/dist/ui/components/ui/alert-dialog.d.ts +48 -0
- package/dist/ui/components/ui/alert.d.ts +8 -0
- package/dist/ui/components/ui/avatar.d.ts +6 -0
- package/dist/ui/components/ui/badge.d.ts +9 -0
- package/dist/ui/components/ui/breadcrumb.d.ts +19 -0
- package/dist/ui/components/ui/button.d.ts +11 -0
- package/dist/ui/components/ui/calendar.d.ts +8 -0
- package/dist/ui/components/ui/card.d.ts +8 -0
- package/dist/ui/components/ui/chart.d.ts +16 -0
- package/dist/ui/components/ui/checkbox.d.ts +4 -0
- package/dist/ui/components/ui/collapsible.d.ts +5 -0
- package/dist/ui/components/ui/column-config.d.ts +42 -0
- package/dist/ui/components/ui/date-picker.d.ts +9 -0
- package/dist/ui/components/ui/date-range-filter.d.ts +32 -0
- package/dist/ui/components/ui/date-range-picker.d.ts +11 -0
- package/dist/ui/components/ui/dialog-input.d.ts +17 -0
- package/dist/ui/components/ui/dialog-safe-select.d.ts +13 -0
- package/dist/ui/components/ui/dialog.d.ts +25 -0
- package/dist/ui/components/ui/dropdown-menu.d.ts +27 -0
- package/dist/ui/components/ui/feature-guide.d.ts +43 -0
- package/dist/ui/components/ui/form.d.ts +25 -0
- package/dist/ui/components/ui/help-tip.d.ts +29 -0
- package/dist/ui/components/ui/hint-notice.d.ts +22 -0
- package/dist/ui/components/ui/index.d.ts +6 -0
- package/dist/ui/components/ui/input.d.ts +3 -0
- package/dist/ui/components/ui/label.d.ts +5 -0
- package/dist/ui/components/ui/modal-container.d.ts +56 -0
- package/dist/ui/components/ui/modal-templates.d.ts +46 -0
- package/dist/ui/components/ui/multi-select.d.ts +20 -0
- package/dist/ui/components/ui/pagination.d.ts +28 -0
- package/dist/ui/components/ui/popover.d.ts +7 -0
- package/dist/ui/components/ui/progress.d.ts +7 -0
- package/dist/ui/components/ui/radio-button-group.d.ts +18 -0
- package/dist/ui/components/ui/radio-group.d.ts +5 -0
- package/dist/ui/components/ui/scroll-area.d.ts +5 -0
- package/dist/ui/components/ui/select.d.ts +16 -0
- package/dist/ui/components/ui/separator.d.ts +7 -0
- package/dist/ui/components/ui/sheet.d.ts +25 -0
- package/dist/ui/components/ui/sidebar-rail.d.ts +9 -0
- package/dist/ui/components/ui/skeleton.d.ts +2 -0
- package/dist/ui/components/ui/slider.d.ts +13 -0
- package/dist/ui/components/ui/switch.d.ts +4 -0
- package/dist/ui/components/ui/table.d.ts +10 -0
- package/dist/ui/components/ui/tabs.d.ts +10 -0
- package/dist/ui/components/ui/textarea.d.ts +3 -0
- package/dist/ui/components/ui/toast.d.ts +21 -0
- package/dist/ui/components/ui/toggle-group.d.ts +12 -0
- package/dist/ui/components/ui/toggle.d.ts +12 -0
- package/dist/ui/components/ui/tooltip.d.ts +7 -0
- package/dist/ui/components/ui/typography.d.ts +15 -0
- package/dist/ui/components/ui/underline-tabs.d.ts +13 -0
- package/dist/ui/components/ui/view-mode-toggle.d.ts +9 -0
- package/dist/ui/hooks/useIsMobile.d.ts +16 -0
- package/dist/ui/styles/design-tokens.d.ts +189 -0
- package/dist/ui/styles/z-index-layers.d.ts +46 -0
- package/dist/ui.d.ts +2 -0
- package/dist/ui.js +35 -0
- package/dist/ui.js.map +1 -0
- package/dist/useUserDirectory-CqkyCQoR.js +2377 -0
- package/dist/useUserDirectory-CqkyCQoR.js.map +1 -0
- package/dist/utils/cookieSettings.d.ts +12 -0
- package/dist/utils/data/countryCodes.d.ts +26 -0
- package/dist/utils/index.d.ts +18 -0
- package/dist/utils/utils/appPath.d.ts +5 -0
- package/dist/utils/utils/chunkLoadRecovery.d.ts +7 -0
- package/dist/utils/utils/cn.d.ts +3 -0
- package/dist/utils/utils/crossApp.d.ts +71 -0
- package/dist/utils/utils/debounce.d.ts +1 -0
- package/dist/utils/utils/formatUserLabel.d.ts +8 -0
- package/dist/utils/utils/formatting.d.ts +18 -0
- package/dist/utils/utils/logoutNotification.d.ts +28 -0
- package/dist/utils/utils/operatorLocale.d.ts +32 -0
- package/dist/utils/utils/routeLocalePrefetch.d.ts +5 -0
- package/dist/utils/utils/shellIframeUrl.d.ts +20 -0
- package/dist/utils/utils/spaceSettings.d.ts +20 -0
- package/dist/utils/utils/sso.d.ts +42 -0
- package/dist/utils/utils/throttle.d.ts +1 -0
- package/dist/utils/utils/timezones.d.ts +14 -0
- package/dist/utils/utils/toDateInputValue.d.ts +5 -0
- package/dist/utils/utils/watermark.d.ts +1 -0
- package/dist/utils.d.ts +1 -0
- package/dist/utils.js +1334 -0
- package/dist/utils.js.map +1 -0
- package/dist/vite.d.ts +22 -0
- package/dist/vite.js +74 -0
- package/dist/vite.js.map +1 -0
- package/package.json +191 -0
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { ToastActionElement, ToastProps } from '../../ui/toast';
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
type ToasterToast = ToastProps & {
|
|
4
|
+
id: string;
|
|
5
|
+
title?: React.ReactNode;
|
|
6
|
+
description?: React.ReactNode;
|
|
7
|
+
action?: ToastActionElement;
|
|
8
|
+
duration?: number;
|
|
9
|
+
};
|
|
10
|
+
declare const actionTypes: {
|
|
11
|
+
readonly ADD_TOAST: "ADD_TOAST";
|
|
12
|
+
readonly UPDATE_TOAST: "UPDATE_TOAST";
|
|
13
|
+
readonly DISMISS_TOAST: "DISMISS_TOAST";
|
|
14
|
+
readonly REMOVE_TOAST: "REMOVE_TOAST";
|
|
15
|
+
};
|
|
16
|
+
export { actionTypes };
|
|
17
|
+
type ActionType = typeof actionTypes;
|
|
18
|
+
type Action = {
|
|
19
|
+
type: ActionType["ADD_TOAST"];
|
|
20
|
+
toast: ToasterToast;
|
|
21
|
+
} | {
|
|
22
|
+
type: ActionType["UPDATE_TOAST"];
|
|
23
|
+
toast: Partial<ToasterToast>;
|
|
24
|
+
} | {
|
|
25
|
+
type: ActionType["DISMISS_TOAST"];
|
|
26
|
+
toastId?: ToasterToast["id"];
|
|
27
|
+
} | {
|
|
28
|
+
type: ActionType["REMOVE_TOAST"];
|
|
29
|
+
toastId?: ToasterToast["id"];
|
|
30
|
+
};
|
|
31
|
+
interface State {
|
|
32
|
+
toasts: ToasterToast[];
|
|
33
|
+
}
|
|
34
|
+
export declare const reducer: (state: State, action: Action) => State;
|
|
35
|
+
type Toast = Omit<ToasterToast, "id">;
|
|
36
|
+
declare function toast({ duration, ...props }: Toast): {
|
|
37
|
+
id: string;
|
|
38
|
+
dismiss: () => void;
|
|
39
|
+
update: (props: ToasterToast) => void;
|
|
40
|
+
};
|
|
41
|
+
declare function useToast(): {
|
|
42
|
+
toast: typeof toast;
|
|
43
|
+
dismiss: (toastId?: string) => void;
|
|
44
|
+
toasts: ToasterToast[];
|
|
45
|
+
};
|
|
46
|
+
export { useToast, toast };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export type ChartSkeletonType = 'line' | 'column' | 'bar' | 'area' | 'pie' | 'radar' | 'heatmap' | 'composedBar' | 'overlapBar';
|
|
2
|
+
export interface ChartAreaSkeletonProps {
|
|
3
|
+
/** 绘图区高度(px),与真实图高对齐以避免跳动 */
|
|
4
|
+
height: number;
|
|
5
|
+
chartType?: ChartSkeletonType;
|
|
6
|
+
className?: string;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* 图表区骨架屏:替换居中 spinner。
|
|
10
|
+
* - pie / radar:环形占位 + legend 条。
|
|
11
|
+
* - 其余笛卡尔图:y 轴刻度 + 柱形占位 + x 轴刻度。
|
|
12
|
+
*/
|
|
13
|
+
export declare function ChartAreaSkeleton({ height, chartType, className }: ChartAreaSkeletonProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { ChartSkeletonType } from './ChartAreaSkeleton';
|
|
3
|
+
|
|
4
|
+
export interface ChartEmptyStateProps {
|
|
5
|
+
/** 绘图区高度(px),与真实图高对齐避免跳动 */
|
|
6
|
+
height: number;
|
|
7
|
+
chartType?: ChartSkeletonType;
|
|
8
|
+
title?: string;
|
|
9
|
+
description?: string;
|
|
10
|
+
/** 操作按钮(如"重置筛选");不传则不渲染 */
|
|
11
|
+
action?: ReactNode;
|
|
12
|
+
className?: string;
|
|
13
|
+
}
|
|
14
|
+
export declare function ChartEmptyState({ height, chartType, title, description, action, className, }: ChartEmptyStateProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { CSSProperties } from 'react';
|
|
2
|
+
|
|
3
|
+
export interface ComponentSkeletonShellProps {
|
|
4
|
+
/** 是否展示卡片标题骨架条 */
|
|
5
|
+
showHeader?: boolean;
|
|
6
|
+
/** 内容区骨架行数 */
|
|
7
|
+
lines?: number;
|
|
8
|
+
/** 最小高度(px),与 loaded 态对齐避免跳动 */
|
|
9
|
+
height?: number;
|
|
10
|
+
className?: string;
|
|
11
|
+
style?: CSSProperties;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* 通用组件骨架壳:无专用骨架的组件类型的兜底占位(卡片标题条 + 若干内容行)。
|
|
15
|
+
*/
|
|
16
|
+
export declare function ComponentSkeletonShell({ showHeader, lines, height, className, style, }: ComponentSkeletonShellProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { CSSProperties, ReactNode } from 'react';
|
|
2
|
+
|
|
3
|
+
export declare function EmptyTrayIcon(): import("react").JSX.Element;
|
|
4
|
+
export interface EmptyStateBadgeProps {
|
|
5
|
+
title?: string;
|
|
6
|
+
description?: string;
|
|
7
|
+
/** 操作按钮(如"重置筛选");不传则不渲染 */
|
|
8
|
+
action?: ReactNode;
|
|
9
|
+
className?: string;
|
|
10
|
+
/** 行内样式(如浮动模式下用 maxWidth 覆盖基础的 max-w-[88%],避免 shrink-to-fit 反馈环导致文字折行) */
|
|
11
|
+
style?: CSSProperties;
|
|
12
|
+
}
|
|
13
|
+
export declare function EmptyStateBadge({ title, description, action, className, style }: EmptyStateBadgeProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export interface FormCardSkeletonProps {
|
|
2
|
+
titleWidth?: string;
|
|
3
|
+
fieldCount?: number;
|
|
4
|
+
showTextarea?: boolean;
|
|
5
|
+
className?: string;
|
|
6
|
+
}
|
|
7
|
+
export declare function FormCardSkeleton({ titleWidth, fieldCount, showTextarea, className, }: FormCardSkeletonProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { CSSProperties, ReactNode } from 'react';
|
|
2
|
+
|
|
3
|
+
export type ListSkeletonTemplate = 'default' | 'ranking' | 'progress-task' | 'product-card';
|
|
4
|
+
export interface ListSkeletonProps {
|
|
5
|
+
template?: ListSkeletonTemplate;
|
|
6
|
+
/** 骨架项数,默认夹在 [3,6] */
|
|
7
|
+
count?: number;
|
|
8
|
+
/** 是否展示卡片头部(标题区) */
|
|
9
|
+
showHeader?: boolean;
|
|
10
|
+
/** 已配置的真实标题:loading 时保留文案;缺省时渲染标题骨架条 */
|
|
11
|
+
title?: ReactNode;
|
|
12
|
+
/** 行间分隔线 */
|
|
13
|
+
split?: boolean;
|
|
14
|
+
/** 是否带边框/阴影 */
|
|
15
|
+
bordered?: boolean;
|
|
16
|
+
/** 圆角(dashboard 模板) */
|
|
17
|
+
rounded?: boolean;
|
|
18
|
+
/** 内容区尺寸类 */
|
|
19
|
+
sizeClassName?: string;
|
|
20
|
+
className?: string;
|
|
21
|
+
style?: CSSProperties;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* 列表骨架屏:按模板生成与真实列表项同构的占位(排名 / 进度任务 / 商品卡 / 默认)。
|
|
25
|
+
*/
|
|
26
|
+
export declare function ListSkeleton({ template, count, showHeader, title, split, bordered, rounded, sizeClassName, className, style, }: ListSkeletonProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
|
|
3
|
+
export interface TableEmptyStateProps {
|
|
4
|
+
/** ghost 列数(与真实列数对齐更自然) */
|
|
5
|
+
columns?: number;
|
|
6
|
+
/** ghost 行数 */
|
|
7
|
+
rows?: number;
|
|
8
|
+
/** 是否画 ghost 表头 */
|
|
9
|
+
showHeader?: boolean;
|
|
10
|
+
/** 最小高度(px) */
|
|
11
|
+
minHeight?: number;
|
|
12
|
+
title?: string;
|
|
13
|
+
description?: string;
|
|
14
|
+
action?: ReactNode;
|
|
15
|
+
className?: string;
|
|
16
|
+
/**
|
|
17
|
+
* 浮动徽章:把「暂无数据」徽章 portal 到 body 用 fixed 定位,
|
|
18
|
+
* 始终居中于表格**当前在屏幕上可见的那一块区域**(跟随横/纵滚动、侧边栏折叠)。
|
|
19
|
+
* 表格滚出视野时徽章随之消失。默认 false(沿用原 absolute 居中行为)。
|
|
20
|
+
*/
|
|
21
|
+
floatBadge?: boolean;
|
|
22
|
+
/** floatBadge 模式下,从视口顶部排除的固定/吸顶 chrome 高度(px),避免徽章浮到吸顶筛选栏之上。 */
|
|
23
|
+
topInset?: number;
|
|
24
|
+
/** floatBadge 模式下,从视口底部排除的固定 chrome 高度(px),避免徽章浮到底部导航之上。 */
|
|
25
|
+
bottomInset?: number;
|
|
26
|
+
}
|
|
27
|
+
export declare function TableEmptyState({ columns, rows, showHeader, minHeight, title, description, action, className, floatBadge, topInset, bottomInset, }: TableEmptyStateProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export interface TablePageSkeletonProps {
|
|
2
|
+
rowCount?: number;
|
|
3
|
+
columnCount?: number;
|
|
4
|
+
showSearch?: boolean;
|
|
5
|
+
showFilters?: boolean;
|
|
6
|
+
className?: string;
|
|
7
|
+
}
|
|
8
|
+
export declare function TablePageSkeleton({ rowCount, columnCount, showSearch, showFilters, className, }: TablePageSkeletonProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export { FormFieldSkeleton, type FormFieldSkeletonProps } from './FormFieldSkeleton';
|
|
2
|
+
export { FormPageSkeleton, type FormPageSkeletonProps } from './FormPageSkeleton';
|
|
3
|
+
export { PageHeaderSkeleton, type PageHeaderSkeletonProps } from './PageHeaderSkeleton';
|
|
4
|
+
export { TabsBarSkeleton, type TabsBarSkeletonProps } from './TabsBarSkeleton';
|
|
5
|
+
export { FormCardSkeleton, type FormCardSkeletonProps } from './FormCardSkeleton';
|
|
6
|
+
export { TablePageSkeleton, type TablePageSkeletonProps } from './TablePageSkeleton';
|
|
7
|
+
export { GridCardsSkeleton, type GridCardsSkeletonProps } from './GridCardsSkeleton';
|
|
8
|
+
export { SplitPaneSkeleton, type SplitPaneSkeletonProps } from './SplitPaneSkeleton';
|
|
9
|
+
export { ConfigEditorSkeleton, type ConfigEditorSkeletonProps } from './ConfigEditorSkeleton';
|
|
10
|
+
export { DetailTabsSkeleton, type DetailTabsSkeletonProps } from './DetailTabsSkeleton';
|
|
11
|
+
export { StatsRowSkeleton, type StatsRowSkeletonProps } from './StatsRowSkeleton';
|
|
12
|
+
export { ChartAreaSkeleton, type ChartAreaSkeletonProps, type ChartSkeletonType, } from './ChartAreaSkeleton';
|
|
13
|
+
export { ChartEmptyState, type ChartEmptyStateProps } from './ChartEmptyState';
|
|
14
|
+
export { TableEmptyState, type TableEmptyStateProps } from './TableEmptyState';
|
|
15
|
+
export { EmptyStateBadge, EmptyTrayIcon, type EmptyStateBadgeProps } from './EmptyStateBadge';
|
|
16
|
+
export { ListSkeleton, type ListSkeletonProps, type ListSkeletonTemplate, } from './ListSkeleton';
|
|
17
|
+
export { ComponentSkeletonShell, type ComponentSkeletonShellProps, } from './ComponentSkeletonShell';
|
|
18
|
+
export { skeletonBarWidth, skeletonItemCount } from './skeletonMetrics';
|
|
19
|
+
export type PageSkeletonPreset = 'config-editor' | 'detail-tabs' | 'table-page' | 'grid-cards' | 'split-pane' | 'profile' | 'dashboard' | 'form-page';
|
|
20
|
+
export interface PageLoadingSkeletonProps {
|
|
21
|
+
preset: PageSkeletonPreset;
|
|
22
|
+
className?: string;
|
|
23
|
+
}
|
|
24
|
+
export declare function PageLoadingSkeleton({ preset, className }: PageLoadingSkeletonProps): import("react").JSX.Element | null;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 错落的骨架条宽度(百分比字符串),避免同列每行等宽显得呆板。
|
|
3
|
+
* row/col 为稳定输入。
|
|
4
|
+
*/
|
|
5
|
+
export declare function skeletonBarWidth(row: number, col?: number): string;
|
|
6
|
+
/**
|
|
7
|
+
* 默认骨架项数:取分页大小并夹在 [3, 6],避免渲染过多占位节点。
|
|
8
|
+
*/
|
|
9
|
+
export declare function skeletonItemCount(pageSize?: number, fallback?: number): number;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { RefObject } from 'react';
|
|
2
|
+
|
|
3
|
+
export interface VisibleCenter {
|
|
4
|
+
/** 视口坐标系下,可见交集矩形的水平中心(px) */
|
|
5
|
+
x: number;
|
|
6
|
+
/** 视口坐标系下,可见交集矩形的垂直中心(px) */
|
|
7
|
+
y: number;
|
|
8
|
+
/** 元素在屏幕上是否有有效可见区域 */
|
|
9
|
+
visible: boolean;
|
|
10
|
+
/**
|
|
11
|
+
* Scale (0..1] to apply to a `reserveHeight`-sized box so it fits the clean band (element ∩ safe
|
|
12
|
+
* area) without spilling onto the chrome or the element's own header. 1 when it fits as-is, or
|
|
13
|
+
* when reserveHeight is not provided.
|
|
14
|
+
*/
|
|
15
|
+
scale: number;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* 返回 ref 元素与「所有裁剪祖先 + 视口」求交后那块可见区域的中心点(视口坐标)。
|
|
19
|
+
* 用于把空态徽章浮动居中到组件**当前在屏幕上可见的那一块**,而非元素自身的完整几何尺寸。
|
|
20
|
+
* 横向(如表格 overflow-auto 容器)与纵向(如页面滚动容器)会被各自的裁剪祖先正确收窄。
|
|
21
|
+
*/
|
|
22
|
+
export interface VisibleCenterOptions {
|
|
23
|
+
/** Inset (px) from the viewport TOP — excludes fixed/sticky top chrome (e.g. a pinned header). */
|
|
24
|
+
topInset?: number;
|
|
25
|
+
/** Inset (px) from the viewport BOTTOM — excludes a fixed bottom bar (e.g. mobile tab nav). */
|
|
26
|
+
bottomInset?: number;
|
|
27
|
+
/**
|
|
28
|
+
* Natural height (px) of the element that will be centered at the returned point. When set, the
|
|
29
|
+
* returned `scale` shrinks it to fit the clean band (element ∩ safe area) and the centre y keeps the
|
|
30
|
+
* scaled box inside that band, so it never spills onto the chrome or the element's own header.
|
|
31
|
+
*/
|
|
32
|
+
reserveHeight?: number;
|
|
33
|
+
}
|
|
34
|
+
export declare function useVisibleCenter(ref: RefObject<HTMLElement>, { topInset, bottomInset, reserveHeight }?: VisibleCenterOptions): VisibleCenter;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as AccordionPrimitive from "@radix-ui/react-accordion";
|
|
3
|
+
declare const Accordion: React.ForwardRefExoticComponent<(AccordionPrimitive.AccordionSingleProps | AccordionPrimitive.AccordionMultipleProps) & React.RefAttributes<HTMLDivElement>>;
|
|
4
|
+
declare const AccordionItem: React.ForwardRefExoticComponent<Omit<AccordionPrimitive.AccordionItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
5
|
+
declare const AccordionTrigger: React.ForwardRefExoticComponent<Omit<AccordionPrimitive.AccordionTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
6
|
+
declare const AccordionContent: React.ForwardRefExoticComponent<Omit<AccordionPrimitive.AccordionContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
7
|
+
export { Accordion, AccordionItem, AccordionTrigger, AccordionContent };
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export type AiDraftBannerTone = 'info' | 'warning';
|
|
3
|
+
export interface AiDraftBannerProps extends Omit<React.HTMLAttributes<HTMLDivElement>, 'title'> {
|
|
4
|
+
/** Banner heading, e.g. "AI draft applied" */
|
|
5
|
+
title: React.ReactNode;
|
|
6
|
+
/** Secondary line under the title */
|
|
7
|
+
description?: React.ReactNode;
|
|
8
|
+
/** When provided, renders a dismiss button */
|
|
9
|
+
onDismiss?: () => void;
|
|
10
|
+
/** Accessible label for the dismiss button (i18n) */
|
|
11
|
+
dismissLabel: string;
|
|
12
|
+
/** Visual tone — maps to the platform status tokens */
|
|
13
|
+
tone?: AiDraftBannerTone;
|
|
14
|
+
/** Extra rows below the header (e.g. collapsible reasons, actions) */
|
|
15
|
+
children?: React.ReactNode;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* AiDraftBanner — canonical presentation for "AI draft applied" surfaces.
|
|
19
|
+
* Built on the platform status tokens, so it is dark-mode correct by construction.
|
|
20
|
+
*/
|
|
21
|
+
export declare const AiDraftBanner: React.ForwardRefExoticComponent<AiDraftBannerProps & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
export type AlertType = 'success' | 'error' | 'warning' | 'info';
|
|
3
|
+
interface AlertDialogProps {
|
|
4
|
+
isOpen: boolean;
|
|
5
|
+
onClose: () => void;
|
|
6
|
+
type?: AlertType;
|
|
7
|
+
title?: string;
|
|
8
|
+
message: string;
|
|
9
|
+
confirmText?: string;
|
|
10
|
+
onConfirm?: () => void;
|
|
11
|
+
showCancel?: boolean;
|
|
12
|
+
cancelText?: string;
|
|
13
|
+
onCancel?: () => void;
|
|
14
|
+
loading?: boolean;
|
|
15
|
+
}
|
|
16
|
+
export declare const AlertDialog: React.FC<AlertDialogProps>;
|
|
17
|
+
interface AlertState {
|
|
18
|
+
isOpen: boolean;
|
|
19
|
+
type: AlertType;
|
|
20
|
+
title?: string;
|
|
21
|
+
message: string;
|
|
22
|
+
confirmText?: string;
|
|
23
|
+
onConfirm?: () => void | Promise<void>;
|
|
24
|
+
showCancel?: boolean;
|
|
25
|
+
cancelText?: string;
|
|
26
|
+
onCancel?: () => void;
|
|
27
|
+
loading?: boolean;
|
|
28
|
+
}
|
|
29
|
+
interface AlertContextType {
|
|
30
|
+
showAlert: (options: Omit<AlertState, 'isOpen'>) => void;
|
|
31
|
+
hideAlert: () => void;
|
|
32
|
+
setLoading: (loading: boolean) => void;
|
|
33
|
+
state: AlertState;
|
|
34
|
+
}
|
|
35
|
+
export declare const AlertProvider: React.FC<{
|
|
36
|
+
children: React.ReactNode;
|
|
37
|
+
}>;
|
|
38
|
+
export declare const useAlert: () => AlertContextType;
|
|
39
|
+
export declare const useAlertDialog: () => {
|
|
40
|
+
success: (message: string, options?: Partial<Omit<AlertState, "isOpen" | "type" | "message">>) => void;
|
|
41
|
+
error: (message: string, options?: Partial<Omit<AlertState, "isOpen" | "type" | "message">>) => void;
|
|
42
|
+
warning: (message: string, options?: Partial<Omit<AlertState, "isOpen" | "type" | "message">>) => void;
|
|
43
|
+
info: (message: string, options?: Partial<Omit<AlertState, "isOpen" | "type" | "message">>) => void;
|
|
44
|
+
confirm: (message: string, onConfirm: () => void | Promise<void>, options?: Partial<Omit<AlertState, "isOpen" | "message" | "onConfirm" | "showCancel">>) => void;
|
|
45
|
+
confirmDelete: (message: string, onConfirm: () => Promise<void>, options?: Partial<Omit<AlertState, "isOpen" | "message" | "onConfirm" | "showCancel" | "type">>) => void;
|
|
46
|
+
hide: () => void;
|
|
47
|
+
};
|
|
48
|
+
export default AlertDialog;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { VariantProps } from 'class-variance-authority';
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
declare const Alert: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & VariantProps<(props?: ({
|
|
4
|
+
variant?: "default" | "destructive" | null | undefined;
|
|
5
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string> & React.RefAttributes<HTMLDivElement>>;
|
|
6
|
+
declare const AlertTitle: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLHeadingElement> & React.RefAttributes<HTMLParagraphElement>>;
|
|
7
|
+
declare const AlertDescription: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLParagraphElement> & React.RefAttributes<HTMLParagraphElement>>;
|
|
8
|
+
export { Alert, AlertTitle, AlertDescription };
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as AvatarPrimitive from "@radix-ui/react-avatar";
|
|
3
|
+
declare const Avatar: React.ForwardRefExoticComponent<Omit<AvatarPrimitive.AvatarProps & React.RefAttributes<HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
|
|
4
|
+
declare const AvatarImage: React.ForwardRefExoticComponent<Omit<AvatarPrimitive.AvatarImageProps & React.RefAttributes<HTMLImageElement>, "ref"> & React.RefAttributes<HTMLImageElement>>;
|
|
5
|
+
declare const AvatarFallback: React.ForwardRefExoticComponent<Omit<AvatarPrimitive.AvatarFallbackProps & React.RefAttributes<HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
|
|
6
|
+
export { Avatar, AvatarImage, AvatarFallback };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { VariantProps } from 'class-variance-authority';
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
declare const badgeVariants: (props?: ({
|
|
4
|
+
variant?: "default" | "destructive" | "outline" | "secondary" | null | undefined;
|
|
5
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
6
|
+
export interface BadgeProps extends React.HTMLAttributes<HTMLDivElement>, VariantProps<typeof badgeVariants> {
|
|
7
|
+
}
|
|
8
|
+
declare function Badge({ className, variant, ...props }: BadgeProps): React.JSX.Element;
|
|
9
|
+
export { Badge, badgeVariants };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
declare const Breadcrumb: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
|
|
3
|
+
separator?: React.ReactNode;
|
|
4
|
+
} & React.RefAttributes<HTMLElement>>;
|
|
5
|
+
declare const BreadcrumbList: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.OlHTMLAttributes<HTMLOListElement>, HTMLOListElement>, "ref"> & React.RefAttributes<HTMLOListElement>>;
|
|
6
|
+
declare const BreadcrumbItem: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & React.RefAttributes<HTMLLIElement>>;
|
|
7
|
+
declare const BreadcrumbLink: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, "ref"> & {
|
|
8
|
+
asChild?: boolean;
|
|
9
|
+
} & React.RefAttributes<HTMLAnchorElement>>;
|
|
10
|
+
declare const BreadcrumbPage: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & React.RefAttributes<HTMLSpanElement>>;
|
|
11
|
+
declare const BreadcrumbSeparator: {
|
|
12
|
+
({ children, className, ...props }: React.ComponentProps<"li">): React.JSX.Element;
|
|
13
|
+
displayName: string;
|
|
14
|
+
};
|
|
15
|
+
declare const BreadcrumbEllipsis: {
|
|
16
|
+
({ className, ...props }: React.ComponentProps<"span">): React.JSX.Element;
|
|
17
|
+
displayName: string;
|
|
18
|
+
};
|
|
19
|
+
export { Breadcrumb, BreadcrumbList, BreadcrumbItem, BreadcrumbLink, BreadcrumbPage, BreadcrumbSeparator, BreadcrumbEllipsis, };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { VariantProps } from 'class-variance-authority';
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
declare const buttonVariants: (props?: ({
|
|
4
|
+
variant?: "link" | "default" | "destructive" | "outline" | "secondary" | "ghost" | "subtle" | null | undefined;
|
|
5
|
+
size?: "default" | "icon" | "sm" | "lg" | null | undefined;
|
|
6
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
7
|
+
export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
|
|
8
|
+
asChild?: boolean;
|
|
9
|
+
}
|
|
10
|
+
declare const Button: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLButtonElement>>;
|
|
11
|
+
export { Button, buttonVariants };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { DayPicker } from 'react-day-picker';
|
|
2
|
+
import * as React from "react";
|
|
3
|
+
export type CalendarProps = React.ComponentProps<typeof DayPicker>;
|
|
4
|
+
declare function Calendar({ className, classNames, showOutsideDays, components, ...props }: CalendarProps): React.JSX.Element;
|
|
5
|
+
declare namespace Calendar {
|
|
6
|
+
var displayName: string;
|
|
7
|
+
}
|
|
8
|
+
export { Calendar };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
declare const Card: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
3
|
+
declare const CardHeader: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
4
|
+
declare const CardTitle: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
5
|
+
declare const CardDescription: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
6
|
+
declare const CardContent: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
7
|
+
declare const CardFooter: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
8
|
+
export { Card, CardHeader, CardFooter, CardTitle, CardDescription, CardContent };
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import * as RechartsPrimitive from 'recharts';
|
|
3
|
+
export type ChartConfig = Record<string, {
|
|
4
|
+
label?: React.ReactNode;
|
|
5
|
+
icon?: React.ComponentType;
|
|
6
|
+
color?: string;
|
|
7
|
+
}>;
|
|
8
|
+
export declare function ChartContainer({ id, className, children, config, ...props }: React.ComponentProps<'div'> & {
|
|
9
|
+
config: ChartConfig;
|
|
10
|
+
children: React.ComponentProps<typeof RechartsPrimitive.ResponsiveContainer>['children'];
|
|
11
|
+
}): React.JSX.Element;
|
|
12
|
+
export declare const ChartTooltip: typeof RechartsPrimitive.Tooltip;
|
|
13
|
+
export declare function ChartTooltipContent({ active, payload, label, className, hideLabel, }: React.ComponentProps<typeof RechartsPrimitive.Tooltip> & React.ComponentProps<'div'> & {
|
|
14
|
+
hideLabel?: boolean;
|
|
15
|
+
}): React.JSX.Element | null;
|
|
16
|
+
export declare const ChartLegend: typeof RechartsPrimitive.Legend;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
import * as CheckboxPrimitive from "@radix-ui/react-checkbox";
|
|
3
|
+
declare const Checkbox: React.ForwardRefExoticComponent<Omit<CheckboxPrimitive.CheckboxProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
4
|
+
export { Checkbox };
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import * as CollapsiblePrimitive from "@radix-ui/react-collapsible";
|
|
2
|
+
declare const Collapsible: import('react').ForwardRefExoticComponent<CollapsiblePrimitive.CollapsibleProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
3
|
+
declare const CollapsibleTrigger: import('react').ForwardRefExoticComponent<CollapsiblePrimitive.CollapsibleTriggerProps & import('react').RefAttributes<HTMLButtonElement>>;
|
|
4
|
+
declare const CollapsibleContent: import('react').ForwardRefExoticComponent<CollapsiblePrimitive.CollapsibleContentProps & import('react').RefAttributes<HTMLDivElement>>;
|
|
5
|
+
export { Collapsible, CollapsibleTrigger, CollapsibleContent };
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
export interface ColumnConfigColumn {
|
|
3
|
+
/** Stable column identifier persisted to localStorage */
|
|
4
|
+
key: string;
|
|
5
|
+
/** Human-readable label shown in the menu */
|
|
6
|
+
label: React.ReactNode;
|
|
7
|
+
}
|
|
8
|
+
export interface UseColumnConfigResult {
|
|
9
|
+
/** Keys of currently visible columns, in `allColumns` order */
|
|
10
|
+
visibleKeys: string[];
|
|
11
|
+
/** Whether a given column key is visible */
|
|
12
|
+
isVisible: (key: string) => boolean;
|
|
13
|
+
/** Toggle visibility of a column */
|
|
14
|
+
toggle: (key: string) => void;
|
|
15
|
+
/** Restore the default visibility (clears persisted state) */
|
|
16
|
+
reset: () => void;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* useColumnConfig — client-side column visibility state persisted to localStorage.
|
|
20
|
+
* Tables consume `isVisible(key)` to filter their column arrays; pair with
|
|
21
|
+
* `ColumnConfigMenu` for the standard configuration dropdown.
|
|
22
|
+
*/
|
|
23
|
+
export declare function useColumnConfig(storageKey: string, allColumns: ColumnConfigColumn[], defaultHidden?: string[]): UseColumnConfigResult;
|
|
24
|
+
export interface ColumnConfigMenuProps {
|
|
25
|
+
/** Column definitions to list in the menu */
|
|
26
|
+
columns: ColumnConfigColumn[];
|
|
27
|
+
/** Result of `useColumnConfig` */
|
|
28
|
+
hook: UseColumnConfigResult;
|
|
29
|
+
/** Accessible label for the trigger button (i18n override) */
|
|
30
|
+
label?: string;
|
|
31
|
+
/** Menu heading (i18n override) */
|
|
32
|
+
menuLabel?: string;
|
|
33
|
+
/** Reset item label (i18n override) */
|
|
34
|
+
resetLabel?: string;
|
|
35
|
+
/** Extra classes for the trigger button */
|
|
36
|
+
className?: string;
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* ColumnConfigMenu — standard "configure columns" dropdown (Settings2 ghost icon
|
|
40
|
+
* button) with a checkbox item per column and a reset item.
|
|
41
|
+
*/
|
|
42
|
+
export declare function ColumnConfigMenu({ columns, hook, label, menuLabel, resetLabel, className, }: ColumnConfigMenuProps): React.JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export interface DatePickerProps {
|
|
2
|
+
selected?: Date;
|
|
3
|
+
onChange?: (date: Date | undefined) => void;
|
|
4
|
+
placeholderText?: string;
|
|
5
|
+
className?: string;
|
|
6
|
+
compact?: boolean;
|
|
7
|
+
locale?: string;
|
|
8
|
+
}
|
|
9
|
+
export declare function DatePicker({ selected, onChange, placeholderText, className, compact, locale }: DatePickerProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { DateRange } from 'react-day-picker';
|
|
3
|
+
|
|
4
|
+
export type { DateRange };
|
|
5
|
+
export type DateRangeQuickSelectPresetKey = 'today' | 'yesterday' | 'yesterdayToToday' | 'last7days' | 'last30days';
|
|
6
|
+
export interface DateRangeFilterProps {
|
|
7
|
+
value?: DateRange;
|
|
8
|
+
onChange?: (dateRange: DateRange | undefined) => void;
|
|
9
|
+
label?: string;
|
|
10
|
+
inline?: boolean;
|
|
11
|
+
showQuickSelect?: boolean;
|
|
12
|
+
placeholder?: string;
|
|
13
|
+
style?: React.CSSProperties;
|
|
14
|
+
className?: string;
|
|
15
|
+
triggerClassName?: string;
|
|
16
|
+
quickSelectLabels?: {
|
|
17
|
+
today?: string;
|
|
18
|
+
yesterday?: string;
|
|
19
|
+
yesterdayToToday?: string;
|
|
20
|
+
last7days?: string;
|
|
21
|
+
last30days?: string;
|
|
22
|
+
};
|
|
23
|
+
actionLabels?: {
|
|
24
|
+
confirm?: string;
|
|
25
|
+
cancel?: string;
|
|
26
|
+
};
|
|
27
|
+
showTimePicker?: boolean;
|
|
28
|
+
quickSelectItems?: Partial<Record<DateRangeQuickSelectPresetKey, boolean>>;
|
|
29
|
+
/** Merged into `PopoverContent` (e.g. theme-scoped styles for portaled calendar/actions). */
|
|
30
|
+
popoverContentClassName?: string;
|
|
31
|
+
}
|
|
32
|
+
export declare const DateRangeFilter: React.FC<DateRangeFilterProps>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { DateRange } from 'react-day-picker';
|
|
2
|
+
|
|
3
|
+
export type { DateRange };
|
|
4
|
+
export interface DateRangePickerProps {
|
|
5
|
+
dateRange?: DateRange;
|
|
6
|
+
onChange?: (dateRange: DateRange | undefined) => void;
|
|
7
|
+
placeholderText?: string;
|
|
8
|
+
className?: string;
|
|
9
|
+
compact?: boolean;
|
|
10
|
+
}
|
|
11
|
+
export declare function DateRangePicker({ dateRange, onChange, placeholderText, className, compact }: DateRangePickerProps): import("react").JSX.Element;
|