@validationcloud/fractal-ui 1.49.0 → 1.51.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/components/echarts-renderer/echarts-chart-option.d.ts +11 -0
- package/dist/components/echarts-renderer/echarts-chart-option.js +9 -0
- package/dist/components/echarts-renderer/echarts-renderer.d.ts +22 -0
- package/dist/components/echarts-renderer/echarts-renderer.js +21 -0
- package/dist/components/echarts-renderer/echarts-theme-option.d.ts +4 -0
- package/dist/components/echarts-renderer/echarts-theme-option.js +9 -0
- package/dist/components/echarts-renderer/mavrik-theme.d.ts +227 -0
- package/dist/components/echarts-renderer/mavrik-theme.js +11 -0
- package/dist/components/echarts-renderer/mavrik-theme.json.d.ts +269 -0
- package/dist/components/echarts-renderer/mavrik-theme.json.js +33 -0
- package/dist/components/echarts-renderer/use-chart-instance.d.ts +19 -0
- package/dist/components/echarts-renderer/use-chart-instance.js +46 -0
- package/dist/components/mount-svg-sprite/mount-svg-sprite.js +18 -0
- package/dist/{src/components → components}/protocol-logo/protocol-logo-ids.d.ts +1 -1
- package/dist/{src/components → components}/scroll-area/scroll-area-viewport.js +1 -1
- package/dist/index.d.ts +32 -2
- package/dist/index.js +63 -51
- package/dist/lib/render-chart-to-image.d.ts +28 -0
- package/dist/lib/render-chart-to-image.js +34 -0
- package/dist/lib/render-chart-to-image.test.d.ts +1 -0
- package/dist/server.d.ts +1 -0
- package/dist/server.js +4 -0
- package/package.json +25 -13
- package/dist/node_modules/.pnpm/@radix-ui_react-compose-refs@1.1.2_@types_react@19.2.6_react@19.2.0/node_modules/@radix-ui/react-compose-refs/dist/index.js +0 -25
- package/dist/src/components/mount-svg-sprite/mount-svg-sprite.js +0 -18
- package/dist/src/index.d.ts +0 -27
- /package/dist/{src/assets → assets}/animated-loader.svg.js +0 -0
- /package/dist/{src/assets → assets}/default-avatar.svg.js +0 -0
- /package/dist/{src/assets → assets}/not-found.svg.js +0 -0
- /package/dist/{src/components → components}/animated-loader/animated-loader.d.ts +0 -0
- /package/dist/{src/components → components}/animated-loader/animated-loader.js +0 -0
- /package/dist/{src/components → components}/badge/badge.d.ts +0 -0
- /package/dist/{src/components → components}/badge/badge.js +0 -0
- /package/dist/{src/components → components}/box/box.d.ts +0 -0
- /package/dist/{src/components → components}/box/box.js +0 -0
- /package/dist/{src/components → components}/button/button.d.ts +0 -0
- /package/dist/{src/components → components}/button/button.js +0 -0
- /package/dist/{src/components → components}/client-modal/client-modal.d.ts +0 -0
- /package/dist/{src/components → components}/client-modal/client-modal.js +0 -0
- /package/dist/{src/components → components}/copy-button/copy-button.d.ts +0 -0
- /package/dist/{src/components → components}/copy-button/copy-button.js +0 -0
- /package/dist/{src/components → components}/decorated-icon/decorated-icon.d.ts +0 -0
- /package/dist/{src/components → components}/decorated-icon/decorated-icon.js +0 -0
- /package/dist/{src/components → components}/dropdown-menu/dropdown-menu.d.ts +0 -0
- /package/dist/{src/components → components}/dropdown-menu/dropdown-menu.js +0 -0
- /package/dist/{src/components → components}/error-boundary/error-boundary.d.ts +0 -0
- /package/dist/{src/components → components}/error-boundary/error-boundary.js +0 -0
- /package/dist/{src/components → components}/icon/icon-ids.d.ts +0 -0
- /package/dist/{src/components → components}/icon/icon.d.ts +0 -0
- /package/dist/{src/components → components}/icon/icon.js +0 -0
- /package/dist/{src/components → components}/icon-button/icon-button.d.ts +0 -0
- /package/dist/{src/components → components}/icon-button/icon-button.js +0 -0
- /package/dist/{src/components → components}/input-button/input-button.d.ts +0 -0
- /package/dist/{src/components → components}/input-button/input-button.js +0 -0
- /package/dist/{src/components → components}/mount-svg-sprite/mount-svg-sprite.d.ts +0 -0
- /package/dist/{src/components → components}/not-found-component/not-found-component.d.ts +0 -0
- /package/dist/{src/components → components}/not-found-component/not-found-component.js +0 -0
- /package/dist/{src/components → components}/page-padding/page-padding.d.ts +0 -0
- /package/dist/{src/components → components}/page-padding/page-padding.js +0 -0
- /package/dist/{src/components → components}/protocol-logo/protocol-logo.d.ts +0 -0
- /package/dist/{src/components → components}/protocol-logo/protocol-logo.js +0 -0
- /package/dist/{src/components → components}/scroll-area/index.d.ts +0 -0
- /package/dist/{src/components → components}/scroll-area/index.js +0 -0
- /package/dist/{src/components → components}/scroll-area/scroll-area-viewport.d.ts +0 -0
- /package/dist/{src/components → components}/scroll-area/scroll-area.d.ts +0 -0
- /package/dist/{src/components → components}/scroll-area/scroll-area.js +0 -0
- /package/dist/{src/components → components}/skeleton/skeleton.d.ts +0 -0
- /package/dist/{src/components → components}/skeleton/skeleton.js +0 -0
- /package/dist/{src/components → components}/switch/switch.d.ts +0 -0
- /package/dist/{src/components → components}/switch/switch.js +0 -0
- /package/dist/{src/components → components}/text-input/text-input.d.ts +0 -0
- /package/dist/{src/components → components}/text-input/text-input.js +0 -0
- /package/dist/{src/components → components}/tooltip/tooltip.d.ts +0 -0
- /package/dist/{src/components → components}/tooltip/tooltip.js +0 -0
- /package/dist/{src/components → components}/tooltip-provider/tooltip-provider.d.ts +0 -0
- /package/dist/{src/components → components}/tooltip-provider/tooltip-provider.js +0 -0
- /package/dist/{src/components → components}/touch-target/touch-target.d.ts +0 -0
- /package/dist/{src/components → components}/touch-target/touch-target.js +0 -0
- /package/dist/{src/components → components}/user-dropdown/user-dropdown.d.ts +0 -0
- /package/dist/{src/components → components}/user-dropdown/user-dropdown.js +0 -0
- /package/dist/{src/components → components}/user-dropdown-mobile/user-dropdown-mobile.d.ts +0 -0
- /package/dist/{src/components → components}/user-dropdown-mobile/user-dropdown-mobile.js +0 -0
- /package/dist/{src/hooks → hooks}/use-scroll-to-bottom.d.ts +0 -0
- /package/dist/{src/hooks → hooks}/use-scroll-to-bottom.js +0 -0
- /package/dist/{src/internal → internal}/modal-header.d.ts +0 -0
- /package/dist/{src/internal → internal}/modal-header.js +0 -0
- /package/dist/{src/internal → internal}/modal.d.ts +0 -0
- /package/dist/{src/internal → internal}/modal.js +0 -0
- /package/dist/{src/internal → internal}/react-portal.d.ts +0 -0
- /package/dist/{src/internal → internal}/react-portal.js +0 -0
- /package/dist/{src/internal → internal}/round-button.d.ts +0 -0
- /package/dist/{src/internal → internal}/round-button.js +0 -0
- /package/dist/{src/lib → lib}/tailwind-merge.d.ts +0 -0
- /package/dist/{src/lib → lib}/tailwind-merge.js +0 -0
- /package/dist/{src/utils → utils}/disable-password-managers.d.ts +0 -0
- /package/dist/{src/utils → utils}/disable-password-managers.js +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const protocolLogoIds: readonly ["abs", "aleo", "ape", "apt", "arb", "astr", "avax", "axl", "b2", "babylon", "base", "bera", "bnb", "bob", "btc", "btr", "celo", "cfx", "core", "corn", "cro", "cspr", "eigenlayer", "eth", "eth_light", "fhe", "frax", "gno", "hash", "hbar", "hsk", "hype", "icp", "ink", "jovay", "kat", "lens", "linea", "lsk", "matic", "merl", "metal", "metis", "mezo", "mint", "mnt", "mode", "mon", "obol", "okb", "op", "opbnb", "optimism", "plume", "rbtc", "ron", "s", "saga", "sauce", "scr", "sei", "shibarium", "sol", "soneium", "ssv", "starknet", "stt", "supr", "taiko", "tac", "tao", "ton", "trx", "uni", "union", "wemix", "wld", "xlm", "xtz", "zk"];
|
|
1
|
+
export declare const protocolLogoIds: readonly ["abs", "aleo", "ape", "apt", "arb", "astr", "avax", "axl", "b2", "babylon", "base", "bera", "bnb", "bob", "btc", "btr", "celo", "cfx", "core", "corn", "cro", "cspr", "eigenlayer", "eth", "eth_light", "fhe", "frax", "gno", "hash", "hbar", "hsk", "hype", "icp", "ink", "jovay", "kat", "lens", "linea", "lsk", "matic", "merl", "metal", "metis", "mezo", "mint", "mnt", "mode", "mon", "obol", "okb", "op", "opbnb", "optimism", "plume", "rbtc", "ron", "s", "saga", "sauce", "scr", "sei", "shibarium", "sol", "soneium", "ssv", "stable", "starknet", "stt", "supr", "taiko", "tac", "tao", "ton", "trx", "uni", "union", "wemix", "wld", "xlm", "xtz", "zk"];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsxs as v, jsx as g } from "react/jsx-runtime";
|
|
3
|
-
import { composeRefs as H } from "
|
|
3
|
+
import { composeRefs as H } from "@radix-ui/react-compose-refs";
|
|
4
4
|
import { ScrollArea as x } from "radix-ui";
|
|
5
5
|
import { forwardRef as q, useRef as u, useEffect as i } from "react";
|
|
6
6
|
import { useScrollToBottom as F } from "../../hooks/use-scroll-to-bottom.js";
|
package/dist/index.d.ts
CHANGED
|
@@ -1,2 +1,32 @@
|
|
|
1
|
-
export
|
|
2
|
-
export {}
|
|
1
|
+
export { AnimatedLoader } from './components/animated-loader/animated-loader';
|
|
2
|
+
export { Badge } from './components/badge/badge';
|
|
3
|
+
export { Box } from './components/box/box';
|
|
4
|
+
export { Button } from './components/button/button';
|
|
5
|
+
export { EChartsRenderer, type EChartsRendererProps, type EChartsRendererRef, type EChartsOption, } from './components/echarts-renderer/echarts-renderer';
|
|
6
|
+
export { EChartsThemeOption, isEChartsThemeOption } from './components/echarts-renderer/echarts-theme-option';
|
|
7
|
+
export { EChartsChartOption, isEChartsChartOption } from './components/echarts-renderer/echarts-chart-option';
|
|
8
|
+
export { useChartInstance, type UseChartInstanceProps, type UseChartInstanceReturn, } from './components/echarts-renderer/use-chart-instance';
|
|
9
|
+
export { MAVRIK_THEME } from './components/echarts-renderer/mavrik-theme';
|
|
10
|
+
export { ClientModal } from './components/client-modal/client-modal';
|
|
11
|
+
export { CopyButton } from './components/copy-button/copy-button';
|
|
12
|
+
export { DecoratedIcon } from './components/decorated-icon/decorated-icon';
|
|
13
|
+
export { DropdownMenu, DropdownMenuItem } from './components/dropdown-menu/dropdown-menu';
|
|
14
|
+
export { ErrorBoundary } from './components/error-boundary/error-boundary';
|
|
15
|
+
export { ScrollArea } from './components/scroll-area';
|
|
16
|
+
export { Icon, type IconID } from './components/icon/icon';
|
|
17
|
+
export { IconButton } from './components/icon-button/icon-button';
|
|
18
|
+
export { InputButton } from './components/input-button/input-button';
|
|
19
|
+
export { MountSvgSprite } from './components/mount-svg-sprite/mount-svg-sprite';
|
|
20
|
+
export { NotFoundComponent } from './components/not-found-component/not-found-component';
|
|
21
|
+
export { PagePadding } from './components/page-padding/page-padding';
|
|
22
|
+
export { ProtocolLogo } from './components/protocol-logo/protocol-logo';
|
|
23
|
+
export { Skeleton } from './components/skeleton/skeleton';
|
|
24
|
+
export { Switch } from './components/switch/switch';
|
|
25
|
+
export { TextInput } from './components/text-input/text-input';
|
|
26
|
+
export { Tooltip } from './components/tooltip/tooltip';
|
|
27
|
+
export { TooltipProvider } from './components/tooltip-provider/tooltip-provider';
|
|
28
|
+
export { TouchTarget } from './components/touch-target/touch-target';
|
|
29
|
+
export { twMerge } from './lib/tailwind-merge';
|
|
30
|
+
export { UserDropdown } from './components/user-dropdown/user-dropdown';
|
|
31
|
+
export { UserDropdownMobile } from './components/user-dropdown-mobile/user-dropdown-mobile';
|
|
32
|
+
export { useScrollToBottom } from './hooks/use-scroll-to-bottom';
|
package/dist/index.js
CHANGED
|
@@ -1,57 +1,69 @@
|
|
|
1
|
-
import { AnimatedLoader as t } from "./
|
|
2
|
-
import { Badge as p } from "./
|
|
3
|
-
import { Box as x } from "./
|
|
4
|
-
import { Button as n } from "./
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
1
|
+
import { AnimatedLoader as t } from "./components/animated-loader/animated-loader.js";
|
|
2
|
+
import { Badge as p } from "./components/badge/badge.js";
|
|
3
|
+
import { Box as x } from "./components/box/box.js";
|
|
4
|
+
import { Button as n } from "./components/button/button.js";
|
|
5
|
+
import { EChartsRenderer as d } from "./components/echarts-renderer/echarts-renderer.js";
|
|
6
|
+
import { EChartsThemeOption as u, isEChartsThemeOption as h } from "./components/echarts-renderer/echarts-theme-option.js";
|
|
7
|
+
import { EChartsChartOption as l, isEChartsChartOption as C } from "./components/echarts-renderer/echarts-chart-option.js";
|
|
8
|
+
import { useChartInstance as T } from "./components/echarts-renderer/use-chart-instance.js";
|
|
9
|
+
import { MAVRIK_THEME as E } from "./components/echarts-renderer/mavrik-theme.js";
|
|
10
|
+
import { ClientModal as M } from "./components/client-modal/client-modal.js";
|
|
11
|
+
import { CopyButton as w } from "./components/copy-button/copy-button.js";
|
|
12
|
+
import { DecoratedIcon as D } from "./components/decorated-icon/decorated-icon.js";
|
|
13
|
+
import { DropdownMenu as P, DropdownMenuItem as A } from "./components/dropdown-menu/dropdown-menu.js";
|
|
14
|
+
import { ErrorBoundary as y } from "./components/error-boundary/error-boundary.js";
|
|
15
|
+
import { ScrollArea as R } from "./components/scroll-area/index.js";
|
|
16
|
+
import { Icon as b } from "./components/icon/icon.js";
|
|
17
|
+
import { IconButton as F } from "./components/icon-button/icon-button.js";
|
|
18
|
+
import { InputButton as K } from "./components/input-button/input-button.js";
|
|
19
|
+
import { MountSvgSprite as V } from "./components/mount-svg-sprite/mount-svg-sprite.js";
|
|
20
|
+
import { NotFoundComponent as j } from "./components/not-found-component/not-found-component.js";
|
|
21
|
+
import { PagePadding as z } from "./components/page-padding/page-padding.js";
|
|
22
|
+
import { ProtocolLogo as J } from "./components/protocol-logo/protocol-logo.js";
|
|
23
|
+
import { Skeleton as W } from "./components/skeleton/skeleton.js";
|
|
24
|
+
import { Switch as Y } from "./components/switch/switch.js";
|
|
25
|
+
import { TextInput as $ } from "./components/text-input/text-input.js";
|
|
26
|
+
import { Tooltip as ro } from "./components/tooltip/tooltip.js";
|
|
27
|
+
import { TooltipProvider as eo } from "./components/tooltip-provider/tooltip-provider.js";
|
|
28
|
+
import { TouchTarget as mo } from "./components/touch-target/touch-target.js";
|
|
29
|
+
import { twMerge as fo } from "./lib/tailwind-merge.js";
|
|
30
|
+
import { UserDropdown as ao } from "./components/user-dropdown/user-dropdown.js";
|
|
31
|
+
import { UserDropdownMobile as uo } from "./components/user-dropdown-mobile/user-dropdown-mobile.js";
|
|
32
|
+
import { useScrollToBottom as so } from "./hooks/use-scroll-to-bottom.js";
|
|
28
33
|
export {
|
|
29
34
|
t as AnimatedLoader,
|
|
30
35
|
p as Badge,
|
|
31
36
|
x as Box,
|
|
32
37
|
n as Button,
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
j as
|
|
48
|
-
z as
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
38
|
+
M as ClientModal,
|
|
39
|
+
w as CopyButton,
|
|
40
|
+
D as DecoratedIcon,
|
|
41
|
+
P as DropdownMenu,
|
|
42
|
+
A as DropdownMenuItem,
|
|
43
|
+
l as EChartsChartOption,
|
|
44
|
+
d as EChartsRenderer,
|
|
45
|
+
u as EChartsThemeOption,
|
|
46
|
+
y as ErrorBoundary,
|
|
47
|
+
b as Icon,
|
|
48
|
+
F as IconButton,
|
|
49
|
+
K as InputButton,
|
|
50
|
+
E as MAVRIK_THEME,
|
|
51
|
+
V as MountSvgSprite,
|
|
52
|
+
j as NotFoundComponent,
|
|
53
|
+
z as PagePadding,
|
|
54
|
+
J as ProtocolLogo,
|
|
55
|
+
R as ScrollArea,
|
|
56
|
+
W as Skeleton,
|
|
57
|
+
Y as Switch,
|
|
58
|
+
$ as TextInput,
|
|
59
|
+
ro as Tooltip,
|
|
60
|
+
eo as TooltipProvider,
|
|
61
|
+
mo as TouchTarget,
|
|
62
|
+
ao as UserDropdown,
|
|
63
|
+
uo as UserDropdownMobile,
|
|
64
|
+
C as isEChartsChartOption,
|
|
65
|
+
h as isEChartsThemeOption,
|
|
66
|
+
fo as twMerge,
|
|
67
|
+
T as useChartInstance,
|
|
68
|
+
so as useScrollToBottom
|
|
57
69
|
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
export interface RenderChartToImageOptions {
|
|
2
|
+
option: unknown;
|
|
3
|
+
theme?: Record<string, unknown>;
|
|
4
|
+
width?: number;
|
|
5
|
+
height?: number;
|
|
6
|
+
devicePixelRatio?: number;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* Renders an ECharts chart to a PNG image buffer.
|
|
10
|
+
*
|
|
11
|
+
* @param options - Chart configuration and rendering options
|
|
12
|
+
* @returns PNG image buffer
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```ts
|
|
16
|
+
* const buffer = renderChartToImage({
|
|
17
|
+
* option: {
|
|
18
|
+
* xAxis: { type: 'category', data: ['Mon', 'Tue', 'Wed'] },
|
|
19
|
+
* yAxis: { type: 'value' },
|
|
20
|
+
* series: [{ data: [120, 200, 150], type: 'line' }]
|
|
21
|
+
* },
|
|
22
|
+
* theme: { color: ['#3398DB'] },
|
|
23
|
+
* width: 800,
|
|
24
|
+
* height: 600
|
|
25
|
+
* });
|
|
26
|
+
* ```
|
|
27
|
+
*/
|
|
28
|
+
export declare function renderChartToImage({ option, theme, width, height, devicePixelRatio, }: RenderChartToImageOptions): Buffer;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { createCanvas as f } from "canvas";
|
|
2
|
+
import { randomUUID as m } from "node:crypto";
|
|
3
|
+
import { createRequire as u } from "node:module";
|
|
4
|
+
const p = u(import.meta.url), s = p("echarts");
|
|
5
|
+
function l(r) {
|
|
6
|
+
if (!r || typeof r != "object" || Array.isArray(r))
|
|
7
|
+
return { animation: !1 };
|
|
8
|
+
const e = { ...r };
|
|
9
|
+
return "aria" in e && delete e.aria, e.animation = !1, e;
|
|
10
|
+
}
|
|
11
|
+
function h({
|
|
12
|
+
option: r,
|
|
13
|
+
theme: e,
|
|
14
|
+
width: a = 800,
|
|
15
|
+
height: n = 600,
|
|
16
|
+
devicePixelRatio: c = 2
|
|
17
|
+
}) {
|
|
18
|
+
let t;
|
|
19
|
+
e && typeof e == "object" && (t = `theme-${m()}`, s.registerTheme(t, e));
|
|
20
|
+
const i = f(a, n), o = s.init(i, t, {
|
|
21
|
+
renderer: "canvas",
|
|
22
|
+
devicePixelRatio: c,
|
|
23
|
+
width: a,
|
|
24
|
+
height: n
|
|
25
|
+
});
|
|
26
|
+
try {
|
|
27
|
+
return o.setOption(l(r)), i.toBuffer("image/png");
|
|
28
|
+
} finally {
|
|
29
|
+
o.dispose();
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
export {
|
|
33
|
+
h as renderChartToImage
|
|
34
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist/server.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { renderChartToImage, type RenderChartToImageOptions } from './lib/render-chart-to-image';
|
package/dist/server.js
ADDED
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@validationcloud/fractal-ui",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.51.0",
|
|
5
5
|
"module": "./dist/index.js",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"files": [
|
|
@@ -24,23 +24,20 @@
|
|
|
24
24
|
"format": "prettier --write .",
|
|
25
25
|
"format:check": "prettier --check .",
|
|
26
26
|
"typecheck": "tsc -b --noEmit",
|
|
27
|
+
"test": "vitest run",
|
|
27
28
|
"prepublishOnly": "pnpm build"
|
|
28
29
|
},
|
|
29
30
|
"exports": {
|
|
30
31
|
".": {
|
|
32
|
+
"types": "./dist/index.d.ts",
|
|
31
33
|
"import": "./dist/index.js"
|
|
32
34
|
},
|
|
35
|
+
"./server": {
|
|
36
|
+
"types": "./dist/server.d.ts",
|
|
37
|
+
"import": "./dist/server.js"
|
|
38
|
+
},
|
|
33
39
|
"./tailwind.css": "./dist/styles/tailwind.css"
|
|
34
40
|
},
|
|
35
|
-
"types": "./dist/index.d.ts",
|
|
36
|
-
"release": {
|
|
37
|
-
"branches": [
|
|
38
|
-
"main"
|
|
39
|
-
]
|
|
40
|
-
},
|
|
41
|
-
"publishConfig": {
|
|
42
|
-
"access": "public"
|
|
43
|
-
},
|
|
44
41
|
"packageManager": "pnpm@10.24.0",
|
|
45
42
|
"engines": {
|
|
46
43
|
"node": ">=22.14.0"
|
|
@@ -50,7 +47,8 @@
|
|
|
50
47
|
"react": "^19",
|
|
51
48
|
"react-dom": "^19",
|
|
52
49
|
"react-transition-state": "^2",
|
|
53
|
-
"tailwind-merge": "^3"
|
|
50
|
+
"tailwind-merge": "^3",
|
|
51
|
+
"zod": "^4"
|
|
54
52
|
},
|
|
55
53
|
"devDependencies": {
|
|
56
54
|
"@eslint/compat": "^1.4.1",
|
|
@@ -64,6 +62,8 @@
|
|
|
64
62
|
"@types/react": "^19",
|
|
65
63
|
"@types/react-dom": "^19",
|
|
66
64
|
"@vitejs/plugin-react": "^5.1.0",
|
|
65
|
+
"canvas": "^3.2.0",
|
|
66
|
+
"echarts": "^6.0.0",
|
|
67
67
|
"eslint": "^9.39.1",
|
|
68
68
|
"eslint-config-prettier": "^10.1.8",
|
|
69
69
|
"eslint-plugin-react-hooks": "^7.0.1",
|
|
@@ -82,14 +82,26 @@
|
|
|
82
82
|
"typescript": "^5",
|
|
83
83
|
"typescript-eslint": "^8.46.3",
|
|
84
84
|
"vite": "^7.1.12",
|
|
85
|
-
"vite-plugin-dts": "^4.5.4"
|
|
85
|
+
"vite-plugin-dts": "^4.5.4",
|
|
86
|
+
"vitest": "^4.0.15"
|
|
86
87
|
},
|
|
87
88
|
"peerDependencies": {
|
|
88
89
|
"@radix-ui/react-compose-refs": "^1",
|
|
90
|
+
"canvas": "^3",
|
|
91
|
+
"echarts": "^6",
|
|
89
92
|
"radix-ui": "^1",
|
|
90
93
|
"react": "^19",
|
|
91
94
|
"react-dom": "^19",
|
|
92
95
|
"react-transition-state": "^2",
|
|
93
|
-
"tailwind-merge": "^3"
|
|
96
|
+
"tailwind-merge": "^3",
|
|
97
|
+
"zod": "^4"
|
|
98
|
+
},
|
|
99
|
+
"peerDependenciesMeta": {
|
|
100
|
+
"canvas": {
|
|
101
|
+
"optional": true
|
|
102
|
+
},
|
|
103
|
+
"echarts": {
|
|
104
|
+
"optional": true
|
|
105
|
+
}
|
|
94
106
|
}
|
|
95
107
|
}
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import "react";
|
|
2
|
-
function i(n, o) {
|
|
3
|
-
if (typeof n == "function")
|
|
4
|
-
return n(o);
|
|
5
|
-
n != null && (n.current = o);
|
|
6
|
-
}
|
|
7
|
-
function f(...n) {
|
|
8
|
-
return (o) => {
|
|
9
|
-
let u = !1;
|
|
10
|
-
const c = n.map((t) => {
|
|
11
|
-
const e = i(t, o);
|
|
12
|
-
return !u && typeof e == "function" && (u = !0), e;
|
|
13
|
-
});
|
|
14
|
-
if (u)
|
|
15
|
-
return () => {
|
|
16
|
-
for (let t = 0; t < c.length; t++) {
|
|
17
|
-
const e = c[t];
|
|
18
|
-
typeof e == "function" ? e() : i(n[t], null);
|
|
19
|
-
}
|
|
20
|
-
};
|
|
21
|
-
};
|
|
22
|
-
}
|
|
23
|
-
export {
|
|
24
|
-
f as composeRefs
|
|
25
|
-
};
|