@svadmin/ui 0.119.0 → 0.121.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/app.css +139 -0
- package/dist/app.theme.css +139 -0
- package/dist/components/AboutSettings.svelte +1 -1
- package/dist/components/Barcode.svelte +219 -0
- package/dist/components/Barcode.svelte.d.ts +15 -0
- package/dist/components/ContextMenu.svelte +268 -0
- package/dist/components/ContextMenu.svelte.d.ts +22 -0
- package/dist/components/JsonViewer.svelte +323 -0
- package/dist/components/JsonViewer.svelte.d.ts +20 -0
- package/dist/components/KpiCard.svelte +250 -0
- package/dist/components/KpiCard.svelte.d.ts +44 -0
- package/dist/components/NumberRoll.svelte +149 -0
- package/dist/components/NumberRoll.svelte.d.ts +17 -0
- package/dist/components/OtpInput.svelte +209 -0
- package/dist/components/OtpInput.svelte.d.ts +17 -0
- package/dist/components/RecordCompareModal.svelte +428 -0
- package/dist/components/RecordCompareModal.svelte.d.ts +42 -0
- package/dist/components/ResultPage.svelte +166 -0
- package/dist/components/ResultPage.svelte.d.ts +28 -0
- package/dist/components/SignaturePad.svelte +230 -66
- package/dist/components/SignaturePad.svelte.d.ts +6 -5
- package/dist/components/Tour.svelte +71 -13
- package/dist/components/Tour.svelte.d.ts +1 -1
- package/dist/components/TrendIndicator.svelte +21 -13
- package/dist/components/TrendIndicator.svelte.d.ts +4 -2
- package/dist/components/UnsavedChangesGuard.svelte +138 -0
- package/dist/components/UnsavedChangesGuard.svelte.d.ts +32 -0
- package/dist/components/VirtualList.svelte +165 -0
- package/dist/components/VirtualList.svelte.d.ts +43 -0
- package/dist/components/WatermarkContainer.svelte +196 -0
- package/dist/components/WatermarkContainer.svelte.d.ts +20 -0
- package/dist/components/useUnsavedChanges.d.svelte.ts +1 -0
- package/dist/components/useUnsavedChanges.svelte.d.ts +22 -0
- package/dist/components/useUnsavedChanges.svelte.js +105 -0
- package/dist/index.d.ts +30 -35
- package/dist/index.js +18 -2
- package/package.json +1 -1
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { onMount, onDestroy, type Snippet } from 'svelte';
|
|
3
|
+
import { cn } from '../utils.js';
|
|
4
|
+
|
|
5
|
+
export interface WatermarkContainerProps {
|
|
6
|
+
content?: string | string[];
|
|
7
|
+
image?: string;
|
|
8
|
+
width?: number;
|
|
9
|
+
height?: number;
|
|
10
|
+
rotate?: number;
|
|
11
|
+
fontSize?: number;
|
|
12
|
+
fontFamily?: string;
|
|
13
|
+
color?: string;
|
|
14
|
+
gapX?: number;
|
|
15
|
+
gapY?: number;
|
|
16
|
+
zIndex?: number;
|
|
17
|
+
antiTamper?: boolean;
|
|
18
|
+
class?: string;
|
|
19
|
+
children?: Snippet;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
let {
|
|
23
|
+
content = 'CONFIDENTIAL',
|
|
24
|
+
image,
|
|
25
|
+
width = 240,
|
|
26
|
+
height = 140,
|
|
27
|
+
rotate = -22,
|
|
28
|
+
fontSize = 14,
|
|
29
|
+
fontFamily = 'sans-serif',
|
|
30
|
+
color = 'rgba(128, 128, 128, 0.18)',
|
|
31
|
+
gapX = 48,
|
|
32
|
+
gapY = 48,
|
|
33
|
+
zIndex = 9999,
|
|
34
|
+
antiTamper = true,
|
|
35
|
+
class: className = '',
|
|
36
|
+
children,
|
|
37
|
+
}: WatermarkContainerProps = $props();
|
|
38
|
+
|
|
39
|
+
let containerEl = $state<HTMLDivElement | null>(null);
|
|
40
|
+
let overlayEl = $state<HTMLDivElement | null>(null);
|
|
41
|
+
let watermarkDataUrl = $state<string>('');
|
|
42
|
+
|
|
43
|
+
let observer: MutationObserver | null = null;
|
|
44
|
+
|
|
45
|
+
function renderWatermarkCanvas(): string {
|
|
46
|
+
if (typeof document === 'undefined') return '';
|
|
47
|
+
|
|
48
|
+
try {
|
|
49
|
+
const canvas = document.createElement('canvas');
|
|
50
|
+
const totalWidth = width + gapX;
|
|
51
|
+
const totalHeight = height + gapY;
|
|
52
|
+
|
|
53
|
+
const dpr = typeof window !== 'undefined' ? (window.devicePixelRatio || 1) : 1;
|
|
54
|
+
canvas.width = totalWidth * dpr;
|
|
55
|
+
canvas.height = totalHeight * dpr;
|
|
56
|
+
|
|
57
|
+
const ctx = canvas.getContext('2d');
|
|
58
|
+
if (!ctx) return '';
|
|
59
|
+
|
|
60
|
+
ctx.scale(dpr, dpr);
|
|
61
|
+
ctx.translate(totalWidth / 2, totalHeight / 2);
|
|
62
|
+
ctx.rotate((rotate * Math.PI) / 180);
|
|
63
|
+
|
|
64
|
+
if (image) {
|
|
65
|
+
const img = new Image();
|
|
66
|
+
img.crossOrigin = 'anonymous';
|
|
67
|
+
img.src = image;
|
|
68
|
+
ctx.drawImage(img, -width / 2, -height / 2, width, height);
|
|
69
|
+
return typeof canvas.toDataURL === 'function' ? canvas.toDataURL() : '';
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
const lines = Array.isArray(content) ? content : [content];
|
|
73
|
+
ctx.font = `${fontSize}px ${fontFamily}`;
|
|
74
|
+
ctx.fillStyle = color;
|
|
75
|
+
ctx.textAlign = 'center';
|
|
76
|
+
ctx.textBaseline = 'middle';
|
|
77
|
+
|
|
78
|
+
const lineHeight = fontSize * 1.4;
|
|
79
|
+
const initialY = -((lines.length - 1) * lineHeight) / 2;
|
|
80
|
+
|
|
81
|
+
lines.forEach((line, index) => {
|
|
82
|
+
ctx.fillText(line, 0, initialY + index * lineHeight);
|
|
83
|
+
});
|
|
84
|
+
|
|
85
|
+
return typeof canvas.toDataURL === 'function' ? canvas.toDataURL() : '';
|
|
86
|
+
} catch {
|
|
87
|
+
return '';
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
function applyOverlayStyle() {
|
|
92
|
+
if (!overlayEl) return;
|
|
93
|
+
overlayEl.style.position = 'absolute';
|
|
94
|
+
overlayEl.style.top = '0';
|
|
95
|
+
overlayEl.style.left = '0';
|
|
96
|
+
overlayEl.style.width = '100%';
|
|
97
|
+
overlayEl.style.height = '100%';
|
|
98
|
+
overlayEl.style.pointerEvents = 'none';
|
|
99
|
+
overlayEl.style.zIndex = String(zIndex);
|
|
100
|
+
overlayEl.style.backgroundRepeat = 'repeat';
|
|
101
|
+
overlayEl.style.display = 'block';
|
|
102
|
+
overlayEl.style.visibility = 'visible';
|
|
103
|
+
overlayEl.style.opacity = '1';
|
|
104
|
+
if (watermarkDataUrl) {
|
|
105
|
+
overlayEl.style.backgroundImage = `url("${watermarkDataUrl}")`;
|
|
106
|
+
overlayEl.style.backgroundSize = `${width + gapX}px ${height + gapY}px`;
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
function reobserve() {
|
|
111
|
+
if (!observer || !containerEl || !overlayEl) return;
|
|
112
|
+
observer.observe(containerEl, {
|
|
113
|
+
childList: true,
|
|
114
|
+
subtree: false,
|
|
115
|
+
});
|
|
116
|
+
observer.observe(overlayEl, {
|
|
117
|
+
attributes: true,
|
|
118
|
+
attributeFilter: ['style', 'class', 'hidden'],
|
|
119
|
+
});
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
function setupAntiTamper() {
|
|
123
|
+
if (!antiTamper || typeof MutationObserver === 'undefined' || !containerEl || !overlayEl) return;
|
|
124
|
+
|
|
125
|
+
observer?.disconnect();
|
|
126
|
+
observer = new MutationObserver((mutations) => {
|
|
127
|
+
if (!containerEl || !overlayEl) return;
|
|
128
|
+
|
|
129
|
+
let needRestore = false;
|
|
130
|
+
|
|
131
|
+
for (const m of mutations) {
|
|
132
|
+
if (m.type === 'childList') {
|
|
133
|
+
if (!containerEl.contains(overlayEl)) {
|
|
134
|
+
needRestore = true;
|
|
135
|
+
break;
|
|
136
|
+
}
|
|
137
|
+
} else if (m.type === 'attributes' && m.target === overlayEl) {
|
|
138
|
+
const style = overlayEl.getAttribute('style') || '';
|
|
139
|
+
if (
|
|
140
|
+
style.includes('display: none') ||
|
|
141
|
+
style.includes('visibility: hidden') ||
|
|
142
|
+
style.includes('opacity: 0') ||
|
|
143
|
+
!style.includes('pointer-events: none')
|
|
144
|
+
) {
|
|
145
|
+
needRestore = true;
|
|
146
|
+
break;
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
if (needRestore) {
|
|
152
|
+
observer?.disconnect();
|
|
153
|
+
if (!containerEl.contains(overlayEl)) {
|
|
154
|
+
// eslint-disable-next-line svelte/no-dom-manipulating -- Anti-tamper security restores overlay when removed by client
|
|
155
|
+
containerEl.appendChild(overlayEl);
|
|
156
|
+
}
|
|
157
|
+
applyOverlayStyle();
|
|
158
|
+
reobserve();
|
|
159
|
+
}
|
|
160
|
+
});
|
|
161
|
+
|
|
162
|
+
reobserve();
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
$effect(() => {
|
|
166
|
+
// Access props to track reactivity
|
|
167
|
+
void [content, image, width, height, rotate, fontSize, fontFamily, color, gapX, gapY];
|
|
168
|
+
watermarkDataUrl = renderWatermarkCanvas();
|
|
169
|
+
applyOverlayStyle();
|
|
170
|
+
});
|
|
171
|
+
|
|
172
|
+
onMount(() => {
|
|
173
|
+
watermarkDataUrl = renderWatermarkCanvas();
|
|
174
|
+
applyOverlayStyle();
|
|
175
|
+
setupAntiTamper();
|
|
176
|
+
});
|
|
177
|
+
|
|
178
|
+
onDestroy(() => {
|
|
179
|
+
observer?.disconnect();
|
|
180
|
+
observer = null;
|
|
181
|
+
});
|
|
182
|
+
</script>
|
|
183
|
+
|
|
184
|
+
<div
|
|
185
|
+
bind:this={containerEl}
|
|
186
|
+
class={cn('relative overflow-hidden', className)}
|
|
187
|
+
data-svadmin-component="WatermarkContainer"
|
|
188
|
+
>
|
|
189
|
+
{@render children?.()}
|
|
190
|
+
<div
|
|
191
|
+
bind:this={overlayEl}
|
|
192
|
+
class="pointer-events-none absolute inset-0 select-none"
|
|
193
|
+
data-svadmin-watermark-overlay="true"
|
|
194
|
+
aria-hidden="true"
|
|
195
|
+
></div>
|
|
196
|
+
</div>
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { type Snippet } from 'svelte';
|
|
2
|
+
export interface WatermarkContainerProps {
|
|
3
|
+
content?: string | string[];
|
|
4
|
+
image?: string;
|
|
5
|
+
width?: number;
|
|
6
|
+
height?: number;
|
|
7
|
+
rotate?: number;
|
|
8
|
+
fontSize?: number;
|
|
9
|
+
fontFamily?: string;
|
|
10
|
+
color?: string;
|
|
11
|
+
gapX?: number;
|
|
12
|
+
gapY?: number;
|
|
13
|
+
zIndex?: number;
|
|
14
|
+
antiTamper?: boolean;
|
|
15
|
+
class?: string;
|
|
16
|
+
children?: Snippet;
|
|
17
|
+
}
|
|
18
|
+
declare const WatermarkContainer: import("svelte").Component<WatermarkContainerProps, {}, "">;
|
|
19
|
+
type WatermarkContainer = ReturnType<typeof WatermarkContainer>;
|
|
20
|
+
export default WatermarkContainer;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './useUnsavedChanges.svelte.js';
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export interface UseUnsavedChangesOptions {
|
|
2
|
+
/** Initial dirty state or getter function */
|
|
3
|
+
isDirty?: boolean | (() => boolean) | undefined;
|
|
4
|
+
/** Custom warning message for native browser dialog */
|
|
5
|
+
message?: string | (() => string) | undefined;
|
|
6
|
+
/** Whether the unsaved changes guard is actively enabled (default: true) */
|
|
7
|
+
enabled?: boolean | (() => boolean) | undefined;
|
|
8
|
+
/** Callback when user decides to leave/discard */
|
|
9
|
+
onLeave?: (() => void) | undefined;
|
|
10
|
+
/** Callback when user decides to stay and keep editing */
|
|
11
|
+
onStay?: (() => void) | undefined;
|
|
12
|
+
}
|
|
13
|
+
export declare function useUnsavedChanges(options?: UseUnsavedChangesOptions): {
|
|
14
|
+
readonly isDirty: boolean;
|
|
15
|
+
readonly isBlocked: boolean;
|
|
16
|
+
readonly pendingNavigationUrl: string | null;
|
|
17
|
+
setDirty: (value: boolean) => void;
|
|
18
|
+
setBlocked: (value: boolean) => void;
|
|
19
|
+
proceed: () => void;
|
|
20
|
+
cancel: () => void;
|
|
21
|
+
destroy: () => void;
|
|
22
|
+
};
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
export function useUnsavedChanges(options = {}) {
|
|
2
|
+
let dirtyState = $state(typeof options.isDirty === 'function' ? options.isDirty() : Boolean(options.isDirty));
|
|
3
|
+
let isBlocked = $state(false);
|
|
4
|
+
let pendingNavigationUrl = $state(null);
|
|
5
|
+
let allowLeave = false;
|
|
6
|
+
const isDirtyDerived = $derived(typeof options.isDirty === 'function' ? options.isDirty() : dirtyState);
|
|
7
|
+
const enabled = $derived(typeof options.enabled === 'function' ? options.enabled() : (options.enabled ?? true));
|
|
8
|
+
const warningMessage = $derived(typeof options.message === 'function'
|
|
9
|
+
? options.message()
|
|
10
|
+
: (options.message ?? 'You have unsaved changes. Are you sure you want to leave?'));
|
|
11
|
+
function handleBeforeUnload(e) {
|
|
12
|
+
if (allowLeave || !enabled || !isDirtyDerived)
|
|
13
|
+
return;
|
|
14
|
+
e.preventDefault();
|
|
15
|
+
e.returnValue = warningMessage;
|
|
16
|
+
return warningMessage;
|
|
17
|
+
}
|
|
18
|
+
function handleDocumentClick(e) {
|
|
19
|
+
if (allowLeave || !enabled || !isDirtyDerived)
|
|
20
|
+
return;
|
|
21
|
+
if (e.defaultPrevented || e.button !== 0 || e.metaKey || e.ctrlKey || e.shiftKey || e.altKey)
|
|
22
|
+
return;
|
|
23
|
+
const target = e.target?.closest?.('a');
|
|
24
|
+
if (!target || !target.href)
|
|
25
|
+
return;
|
|
26
|
+
if (target.target === '_blank' || target.hasAttribute('download'))
|
|
27
|
+
return;
|
|
28
|
+
try {
|
|
29
|
+
const url = new URL(target.href, window.location.href);
|
|
30
|
+
if (url.origin === window.location.origin &&
|
|
31
|
+
url.pathname === window.location.pathname &&
|
|
32
|
+
url.search === window.location.search) {
|
|
33
|
+
return;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
catch {
|
|
37
|
+
return;
|
|
38
|
+
}
|
|
39
|
+
e.preventDefault();
|
|
40
|
+
e.stopPropagation();
|
|
41
|
+
pendingNavigationUrl = target.href;
|
|
42
|
+
isBlocked = true;
|
|
43
|
+
}
|
|
44
|
+
function handlePopState() {
|
|
45
|
+
if (allowLeave || !enabled || !isDirtyDerived)
|
|
46
|
+
return;
|
|
47
|
+
window.history.pushState(null, '', window.location.href);
|
|
48
|
+
isBlocked = true;
|
|
49
|
+
}
|
|
50
|
+
if (typeof window !== 'undefined') {
|
|
51
|
+
window.addEventListener('beforeunload', handleBeforeUnload);
|
|
52
|
+
document.addEventListener('click', handleDocumentClick, true);
|
|
53
|
+
window.addEventListener('popstate', handlePopState);
|
|
54
|
+
}
|
|
55
|
+
function proceed() {
|
|
56
|
+
const url = pendingNavigationUrl;
|
|
57
|
+
isBlocked = false;
|
|
58
|
+
dirtyState = false;
|
|
59
|
+
allowLeave = true;
|
|
60
|
+
pendingNavigationUrl = null;
|
|
61
|
+
options.onLeave?.();
|
|
62
|
+
if (url && typeof window !== 'undefined') {
|
|
63
|
+
window.location.href = url;
|
|
64
|
+
return;
|
|
65
|
+
}
|
|
66
|
+
// Reset the bypass only if no synchronous navigation happened, so an
|
|
67
|
+
// `onLeave` callback can still navigate without a second beforeunload prompt.
|
|
68
|
+
setTimeout(() => {
|
|
69
|
+
allowLeave = false;
|
|
70
|
+
}, 0);
|
|
71
|
+
}
|
|
72
|
+
function cancel() {
|
|
73
|
+
isBlocked = false;
|
|
74
|
+
pendingNavigationUrl = null;
|
|
75
|
+
allowLeave = false;
|
|
76
|
+
options.onStay?.();
|
|
77
|
+
}
|
|
78
|
+
function destroy() {
|
|
79
|
+
if (typeof window !== 'undefined') {
|
|
80
|
+
window.removeEventListener('beforeunload', handleBeforeUnload);
|
|
81
|
+
document.removeEventListener('click', handleDocumentClick, true);
|
|
82
|
+
window.removeEventListener('popstate', handlePopState);
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
return {
|
|
86
|
+
get isDirty() {
|
|
87
|
+
return isDirtyDerived;
|
|
88
|
+
},
|
|
89
|
+
get isBlocked() {
|
|
90
|
+
return isBlocked;
|
|
91
|
+
},
|
|
92
|
+
get pendingNavigationUrl() {
|
|
93
|
+
return pendingNavigationUrl;
|
|
94
|
+
},
|
|
95
|
+
setDirty: (value) => {
|
|
96
|
+
dirtyState = value;
|
|
97
|
+
},
|
|
98
|
+
setBlocked: (value) => {
|
|
99
|
+
isBlocked = value;
|
|
100
|
+
},
|
|
101
|
+
proceed,
|
|
102
|
+
cancel,
|
|
103
|
+
destroy,
|
|
104
|
+
};
|
|
105
|
+
}
|
package/dist/index.d.ts
CHANGED
|
@@ -4,8 +4,7 @@ export { designSystemComponents, type DesignComponentContract, type DesignCompon
|
|
|
4
4
|
export { metricSurfaceClasses, tableSurfaceClasses } from "./design-system.js";
|
|
5
5
|
export { builtinIcons, getIconNames, hasIcon, getIconSourceNames, registerIconSource, registerIconSources, registerIcons, replaceIcons, resetIconRegistry, resolveIcon, resolveIconSource, setIconFallback, setIconMissHandler, } from "./icons.js";
|
|
6
6
|
export type { IconComponent, IconMissHandler, IconRegistry, IconSource, IconSourceInput } from "./icons.js";
|
|
7
|
-
export { default as AdminApp } from './components/AdminApp.svelte';
|
|
8
|
-
export type { AdminPageRoute } from './components/AdminApp.svelte';
|
|
7
|
+
export { default as AdminApp, type AdminPageRoute } from './components/AdminApp.svelte';
|
|
9
8
|
export { default as AutoTable } from './components/AutoTable.svelte';
|
|
10
9
|
export { default as SavedViewsMenu } from './components/SavedViewsMenu.svelte';
|
|
11
10
|
export { default as ListPagination } from './components/ListPagination.svelte';
|
|
@@ -15,14 +14,11 @@ export { default as ScrollableTable } from './components/ScrollableTable.svelte'
|
|
|
15
14
|
export { default as CopyButton } from './components/CopyButton.svelte';
|
|
16
15
|
export { listPaginationItems } from './components/list-pagination.js';
|
|
17
16
|
export type { ListPaginationItem } from './components/list-pagination.js';
|
|
18
|
-
export { default as SegmentedControl, default as Segmented } from './components/SegmentedControl.svelte';
|
|
19
|
-
export
|
|
20
|
-
export { default as RadioGroup, default as Radio } from './components/RadioGroup.svelte';
|
|
21
|
-
export type { RadioGroupOption } from './components/RadioGroup.svelte';
|
|
17
|
+
export { default as SegmentedControl, default as Segmented, type SegmentedControlOption, type SegmentedControlOption as SegmentedOption } from './components/SegmentedControl.svelte';
|
|
18
|
+
export { default as RadioGroup, default as Radio, type RadioGroupOption } from './components/RadioGroup.svelte';
|
|
22
19
|
export { default as TagsInput, default as InputTag } from './components/TagsInput.svelte';
|
|
23
20
|
export { default as Slider } from './components/Slider.svelte';
|
|
24
|
-
export { default as RangeSlider } from './components/RangeSlider.svelte';
|
|
25
|
-
export type { RangeSliderValue } from './components/RangeSlider.svelte';
|
|
21
|
+
export { default as RangeSlider, type RangeSliderValue } from './components/RangeSlider.svelte';
|
|
26
22
|
export { default as ColorPicker } from './components/ColorPicker.svelte';
|
|
27
23
|
export { default as Rate } from './components/Rate.svelte';
|
|
28
24
|
export { default as PivotExportButton } from './components/PivotExportButton.svelte';
|
|
@@ -173,7 +169,7 @@ export { default as GanttChart } from './components/GanttChart.svelte';
|
|
|
173
169
|
export type { GanttTask } from './components/GanttChart.svelte';
|
|
174
170
|
export { default as CanvasAnnotation } from './components/CanvasAnnotation.svelte';
|
|
175
171
|
export type { AnnotationTool } from './components/CanvasAnnotation.svelte';
|
|
176
|
-
export { default as SignaturePad } from './components/SignaturePad.svelte';
|
|
172
|
+
export { default as SignaturePad, type SignaturePadProps } from './components/SignaturePad.svelte';
|
|
177
173
|
export { default as PdfDocumentViewer } from './components/PdfDocumentViewer.svelte';
|
|
178
174
|
export type { DocumentStamp } from './components/PdfDocumentViewer.svelte';
|
|
179
175
|
export { default as SpreadsheetView } from './components/SpreadsheetView.svelte';
|
|
@@ -304,7 +300,7 @@ export * as DropdownMenu from './components/ui/dropdown-menu/index.js';
|
|
|
304
300
|
export * as Dropdown from './components/ui/dropdown-menu/index.js';
|
|
305
301
|
export * as Breadcrumb from './components/ui/breadcrumb/index.js';
|
|
306
302
|
export * as Pagination from './components/ui/pagination/index.js';
|
|
307
|
-
export * as
|
|
303
|
+
export * as ContextMenuPrimitive from './components/ui/context-menu/index.js';
|
|
308
304
|
export * as NavigationMenu from './components/ui/navigation-menu/index.js';
|
|
309
305
|
export * as Collapsible from './components/ui/collapsible/index.js';
|
|
310
306
|
export * as Popover from './components/ui/popover/index.js';
|
|
@@ -407,7 +403,7 @@ export { default as NetworkUserCard } from './components/content/NetworkUserCard
|
|
|
407
403
|
export type { NetworkUser, NetworkMetric } from './components/content/NetworkUserCard.svelte';
|
|
408
404
|
export { default as NetworkTable } from './components/content/NetworkTable.svelte';
|
|
409
405
|
export type { NetworkColumn } from './components/content/NetworkTable.types.js';
|
|
410
|
-
export { default as OtpInput, default as VerificationCode } from './components/
|
|
406
|
+
export { default as OtpInput, default as VerificationCode, type OtpInputProps } from './components/OtpInput.svelte';
|
|
411
407
|
export { default as TwoFactorStepper } from './components/content/TwoFactorStepper.svelte';
|
|
412
408
|
export { default as SystemErrorState } from './components/content/SystemErrorState.svelte';
|
|
413
409
|
export { referenceDemoData } from './reference-data.js';
|
|
@@ -549,29 +545,28 @@ export { default as ExcelExportButton } from './components/ExcelExportButton.sve
|
|
|
549
545
|
export type { ExcelExportButtonProps, ExcelExportColumn } from './components/ExcelExportButton.svelte';
|
|
550
546
|
export { default as PivotDrilldownModal } from './components/PivotDrilldownModal.svelte';
|
|
551
547
|
export type { PivotDrilldownModalProps, PivotDrilldownColumn, PivotDrilldownFilter, } from './components/PivotDrilldownModal.svelte';
|
|
552
|
-
export { default as SafeDeleteConfirm, default as DoubleCheckModal } from './components/SafeDeleteConfirm.svelte';
|
|
553
|
-
export
|
|
554
|
-
export { default as
|
|
555
|
-
export
|
|
556
|
-
export { default as
|
|
557
|
-
export
|
|
558
|
-
export { default as
|
|
559
|
-
export type { TrendIndicatorProps } from './components/TrendIndicator.svelte';
|
|
560
|
-
export { default as VirtualTreeSelect } from './components/VirtualTreeSelect.svelte';
|
|
561
|
-
export type { VirtualTreeSelectProps, VirtualTreeNode } from './components/VirtualTreeSelect.svelte';
|
|
562
|
-
export { default as CronExpressionBuilder } from './components/CronExpressionBuilder.svelte';
|
|
563
|
-
export type { CronExpressionBuilderProps, CronPreset } from './components/CronExpressionBuilder.svelte';
|
|
564
|
-
export { default as OrgChart } from './components/OrgChart.svelte';
|
|
565
|
-
export type { OrgChartProps, OrgNode } from './components/OrgChart.svelte';
|
|
548
|
+
export { default as SafeDeleteConfirm, default as DoubleCheckModal, type SafeDeleteConfirmProps, type ImpactItem } from './components/SafeDeleteConfirm.svelte';
|
|
549
|
+
export { default as SliderCaptcha, type SliderCaptchaProps, type SliderCaptchaResult } from './components/SliderCaptcha.svelte';
|
|
550
|
+
export { default as ConcurrentConflictModal, type ConcurrentConflictModalProps, type ConflictFieldDiff } from './components/ConcurrentConflictModal.svelte';
|
|
551
|
+
export { default as TrendIndicator, default as Trend, type TrendIndicatorProps } from './components/TrendIndicator.svelte';
|
|
552
|
+
export { default as VirtualTreeSelect, type VirtualTreeSelectProps, type VirtualTreeNode } from './components/VirtualTreeSelect.svelte';
|
|
553
|
+
export { default as CronExpressionBuilder, type CronExpressionBuilderProps, type CronPreset } from './components/CronExpressionBuilder.svelte';
|
|
554
|
+
export { default as OrgChart, type OrgChartProps, type OrgNode } from './components/OrgChart.svelte';
|
|
566
555
|
export { GaugeChart as SpeedometerGauge } from './components/charts/index.js';
|
|
567
556
|
export type { GaugeChartProps, GaugeThreshold, GaugeTone, GaugeType, GaugeMode } from './components/charts/GaugeChart.svelte';
|
|
568
|
-
export { default as MetricGrid, default as DashboardMetricGrid } from './components/MetricGrid.svelte';
|
|
569
|
-
export type
|
|
570
|
-
export { default as
|
|
571
|
-
export type
|
|
572
|
-
export { default as
|
|
573
|
-
export
|
|
574
|
-
export {
|
|
575
|
-
export
|
|
576
|
-
export {
|
|
577
|
-
export type
|
|
557
|
+
export { default as MetricGrid, default as DashboardMetricGrid, type MetricGridProps } from './components/MetricGrid.svelte';
|
|
558
|
+
export { default as MicroAppFrame, default as EmbeddedSandbox, type MicroAppFrameProps, type MicroAppMessage } from './components/MicroAppFrame.svelte';
|
|
559
|
+
export { default as TaskCenter, default as BackgroundTaskDrawer, type TaskCenterProps, type BackgroundTask, type BackgroundTaskStatus } from './components/TaskCenter.svelte';
|
|
560
|
+
export { useNetworkStatus, type NetworkInformationLike, type NetworkStatusState, type UseNetworkStatusOptions } from './components/useNetworkStatus.svelte.js';
|
|
561
|
+
export { default as OfflineGuard, type OfflineGuardProps } from './components/OfflineGuard.svelte';
|
|
562
|
+
export { default as Barcode, type BarcodeProps, type BarcodeFormat } from './components/Barcode.svelte';
|
|
563
|
+
export { default as NumberRoll, type NumberRollProps } from './components/NumberRoll.svelte';
|
|
564
|
+
export { default as VirtualList, type VirtualListProps } from './components/VirtualList.svelte';
|
|
565
|
+
export { useUnsavedChanges, type UseUnsavedChangesOptions } from './components/useUnsavedChanges.svelte.js';
|
|
566
|
+
export { default as UnsavedChangesGuard, default as UnsavedChangesModal, type UnsavedChangesGuardProps } from './components/UnsavedChangesGuard.svelte';
|
|
567
|
+
export { default as KpiCard, type KpiCardProps } from './components/KpiCard.svelte';
|
|
568
|
+
export { default as JsonViewer, type JsonViewerProps } from './components/JsonViewer.svelte';
|
|
569
|
+
export { default as ResultPage, type ResultPageProps, type ResultStatus } from './components/ResultPage.svelte';
|
|
570
|
+
export { default as WatermarkContainer, default as AntiTamperWatermark, type WatermarkContainerProps } from './components/WatermarkContainer.svelte';
|
|
571
|
+
export { default as ContextMenu, type ContextMenuProps, type ContextMenuItem } from './components/ContextMenu.svelte';
|
|
572
|
+
export { default as RecordCompareModal, default as EntityComparisonDrawer, type RecordCompareModalProps, type CompareFieldConfig } from './components/RecordCompareModal.svelte';
|
package/dist/index.js
CHANGED
|
@@ -244,7 +244,7 @@ export * as Dropdown from './components/ui/dropdown-menu/index.js';
|
|
|
244
244
|
// Additional shadcn components
|
|
245
245
|
export * as Breadcrumb from './components/ui/breadcrumb/index.js';
|
|
246
246
|
export * as Pagination from './components/ui/pagination/index.js';
|
|
247
|
-
export * as
|
|
247
|
+
export * as ContextMenuPrimitive from './components/ui/context-menu/index.js';
|
|
248
248
|
export * as NavigationMenu from './components/ui/navigation-menu/index.js';
|
|
249
249
|
export * as Collapsible from './components/ui/collapsible/index.js';
|
|
250
250
|
export * as Popover from './components/ui/popover/index.js';
|
|
@@ -332,7 +332,7 @@ export { default as FileUpload } from './components/FileUpload.svelte';
|
|
|
332
332
|
export { default as Upload } from './components/FileUpload.svelte';
|
|
333
333
|
export { default as NetworkUserCard } from './components/content/NetworkUserCard.svelte';
|
|
334
334
|
export { default as NetworkTable } from './components/content/NetworkTable.svelte';
|
|
335
|
-
export { default as OtpInput, default as VerificationCode } from './components/
|
|
335
|
+
export { default as OtpInput, default as VerificationCode } from './components/OtpInput.svelte';
|
|
336
336
|
export { default as TwoFactorStepper } from './components/content/TwoFactorStepper.svelte';
|
|
337
337
|
export { default as SystemErrorState } from './components/content/SystemErrorState.svelte';
|
|
338
338
|
export { referenceDemoData } from './reference-data.js';
|
|
@@ -444,3 +444,19 @@ export { default as TaskCenter, default as BackgroundTaskDrawer } from './compon
|
|
|
444
444
|
// Enterprise offline resilience & network monitoring suite
|
|
445
445
|
export { useNetworkStatus } from './components/useNetworkStatus.svelte.js';
|
|
446
446
|
export { default as OfflineGuard } from './components/OfflineGuard.svelte';
|
|
447
|
+
// Enterprise barcode, dynamic number roll & virtual list suite
|
|
448
|
+
export { default as Barcode } from './components/Barcode.svelte';
|
|
449
|
+
export { default as NumberRoll } from './components/NumberRoll.svelte';
|
|
450
|
+
export { default as VirtualList } from './components/VirtualList.svelte';
|
|
451
|
+
// Enterprise unsaved changes guard & form loss prevention suite
|
|
452
|
+
export { useUnsavedChanges } from './components/useUnsavedChanges.svelte.js';
|
|
453
|
+
export { default as UnsavedChangesGuard, default as UnsavedChangesModal } from './components/UnsavedChangesGuard.svelte';
|
|
454
|
+
// Enterprise KPI card, JSON tree viewer & business result page suite
|
|
455
|
+
export { default as KpiCard } from './components/KpiCard.svelte';
|
|
456
|
+
export { default as JsonViewer } from './components/JsonViewer.svelte';
|
|
457
|
+
export { default as ResultPage } from './components/ResultPage.svelte';
|
|
458
|
+
// Enterprise dynamic watermark, context menu & OTP authentication suite
|
|
459
|
+
export { default as WatermarkContainer, default as AntiTamperWatermark } from './components/WatermarkContainer.svelte';
|
|
460
|
+
export { default as ContextMenu } from './components/ContextMenu.svelte';
|
|
461
|
+
// Enterprise record comparison and parameter diff suite
|
|
462
|
+
export { default as RecordCompareModal, default as EntityComparisonDrawer } from './components/RecordCompareModal.svelte';
|