@fuf-stack/pixels 0.25.1 → 0.27.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/Button/index.cjs +4 -2
- package/dist/Button/index.cjs.map +1 -1
- package/dist/Button/index.d.cts +3 -2
- package/dist/Button/index.d.ts +3 -2
- package/dist/Button/index.js +3 -1
- package/dist/{Button-8uTuwTxM.d.cts → ButtonGroup-DIL5WB0f.d.cts} +8 -1
- package/dist/{Button-8uTuwTxM.d.ts → ButtonGroup-DIL5WB0f.d.ts} +8 -1
- package/dist/Json/index.cjs +3 -3
- package/dist/Json/index.js +2 -2
- package/dist/Tooltip/index.cjs +2 -2
- package/dist/Tooltip/index.d.cts +2 -2
- package/dist/Tooltip/index.d.ts +2 -2
- package/dist/Tooltip/index.js +1 -1
- package/dist/{Tooltip-BuPzZLuE.d.cts → Tooltip-DS3pM5Cq.d.cts} +5 -1
- package/dist/{Tooltip-BuPzZLuE.d.ts → Tooltip-DS3pM5Cq.d.ts} +5 -1
- package/dist/{chunk-LOFZNVCN.cjs → chunk-7TIFKRWY.cjs} +8 -2
- package/dist/chunk-7TIFKRWY.cjs.map +1 -0
- package/dist/{chunk-HQODZ6JV.cjs → chunk-HI7Z6XY7.cjs} +3 -3
- package/dist/{chunk-HQODZ6JV.cjs.map → chunk-HI7Z6XY7.cjs.map} +1 -1
- package/dist/{chunk-ZQI3FICH.js → chunk-MJE4MLZY.js} +7 -3
- package/dist/chunk-MJE4MLZY.js.map +1 -0
- package/dist/{chunk-EVCVBDO5.js → chunk-ODLZQXBE.js} +7 -1
- package/dist/chunk-ODLZQXBE.js.map +1 -0
- package/dist/{chunk-VX2DFZDW.cjs → chunk-RMA57Q6K.cjs} +7 -3
- package/dist/chunk-RMA57Q6K.cjs.map +1 -0
- package/dist/{chunk-J3CY5HGI.js → chunk-XSHMJPBG.js} +2 -2
- package/dist/index.cjs +6 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -2
- package/dist/index.d.ts +3 -2
- package/dist/index.js +5 -3
- package/package.json +2 -2
- package/dist/chunk-EVCVBDO5.js.map +0 -1
- package/dist/chunk-LOFZNVCN.cjs.map +0 -1
- package/dist/chunk-VX2DFZDW.cjs.map +0 -1
- package/dist/chunk-ZQI3FICH.js.map +0 -1
- /package/dist/{chunk-J3CY5HGI.js.map → chunk-XSHMJPBG.js.map} +0 -0
package/dist/Button/index.cjs
CHANGED
|
@@ -2,11 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
|
|
6
|
+
var _chunk7TIFKRWYcjs = require('../chunk-7TIFKRWY.cjs');
|
|
6
7
|
require('../chunk-DZUJEN5N.cjs');
|
|
7
8
|
|
|
8
9
|
|
|
9
10
|
|
|
10
11
|
|
|
11
|
-
|
|
12
|
+
|
|
13
|
+
exports.Button = _chunk7TIFKRWYcjs.Button_default; exports.ButtonGroup = _chunk7TIFKRWYcjs.ButtonGroup_default; exports.buttonVariants = _chunk7TIFKRWYcjs.buttonVariants; exports.default = _chunk7TIFKRWYcjs.Button_default2;
|
|
12
14
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["/home/runner/work/uniform/uniform/packages/pixels/dist/Button/index.cjs"],"names":[],"mappings":"AAAA;AACE;AACA;AACA;AACF,yDAA8B;AAC9B,iCAA8B;AAC9B;AACE;AACA;AACA;AACF
|
|
1
|
+
{"version":3,"sources":["/home/runner/work/uniform/uniform/packages/pixels/dist/Button/index.cjs"],"names":[],"mappings":"AAAA;AACE;AACA;AACA;AACA;AACF,yDAA8B;AAC9B,iCAA8B;AAC9B;AACE;AACA;AACA;AACA;AACF,+NAAC","file":"/home/runner/work/uniform/uniform/packages/pixels/dist/Button/index.cjs"}
|
package/dist/Button/index.d.cts
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import { B as Button } from '../
|
|
2
|
-
export { a as ButtonProps, b as buttonVariants } from '../
|
|
1
|
+
import { B as Button } from '../ButtonGroup-DIL5WB0f.cjs';
|
|
2
|
+
export { a as ButtonGroup, c as ButtonProps, b as buttonVariants } from '../ButtonGroup-DIL5WB0f.cjs';
|
|
3
3
|
import 'react/jsx-runtime';
|
|
4
4
|
import 'tailwind-variants';
|
|
5
5
|
import 'tailwind-variants/dist/config.js';
|
|
6
6
|
import '@fuf-stack/pixel-utils';
|
|
7
7
|
import '@nextui-org/button';
|
|
8
8
|
import 'react';
|
|
9
|
+
import '@nextui-org/system';
|
|
9
10
|
|
|
10
11
|
|
|
11
12
|
|
package/dist/Button/index.d.ts
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import { B as Button } from '../
|
|
2
|
-
export { a as ButtonProps, b as buttonVariants } from '../
|
|
1
|
+
import { B as Button } from '../ButtonGroup-DIL5WB0f.js';
|
|
2
|
+
export { a as ButtonGroup, c as ButtonProps, b as buttonVariants } from '../ButtonGroup-DIL5WB0f.js';
|
|
3
3
|
import 'react/jsx-runtime';
|
|
4
4
|
import 'tailwind-variants';
|
|
5
5
|
import 'tailwind-variants/dist/config.js';
|
|
6
6
|
import '@fuf-stack/pixel-utils';
|
|
7
7
|
import '@nextui-org/button';
|
|
8
8
|
import 'react';
|
|
9
|
+
import '@nextui-org/system';
|
|
9
10
|
|
|
10
11
|
|
|
11
12
|
|
package/dist/Button/index.js
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
|
+
ButtonGroup_default,
|
|
2
3
|
Button_default,
|
|
3
4
|
Button_default2,
|
|
4
5
|
buttonVariants
|
|
5
|
-
} from "../chunk-
|
|
6
|
+
} from "../chunk-ODLZQXBE.js";
|
|
6
7
|
import "../chunk-5WRI5ZAA.js";
|
|
7
8
|
export {
|
|
8
9
|
Button_default as Button,
|
|
10
|
+
ButtonGroup_default as ButtonGroup,
|
|
9
11
|
buttonVariants,
|
|
10
12
|
Button_default2 as default
|
|
11
13
|
};
|
|
@@ -2,8 +2,10 @@ import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
|
2
2
|
import * as tailwind_variants from 'tailwind-variants';
|
|
3
3
|
import * as tailwind_variants_dist_config_js from 'tailwind-variants/dist/config.js';
|
|
4
4
|
import { TVProps } from '@fuf-stack/pixel-utils';
|
|
5
|
+
import * as _nextui_org_button from '@nextui-org/button';
|
|
5
6
|
import { ButtonProps as ButtonProps$1 } from '@nextui-org/button';
|
|
6
7
|
import { ReactNode } from 'react';
|
|
8
|
+
import * as _nextui_org_system from '@nextui-org/system';
|
|
7
9
|
|
|
8
10
|
declare const buttonVariants: tailwind_variants.TVReturnType<{
|
|
9
11
|
color: {
|
|
@@ -166,4 +168,9 @@ interface ButtonProps extends VariantProps {
|
|
|
166
168
|
*/
|
|
167
169
|
declare const Button: ({ ariaLabel, children, className, color, disabled, disableAnimation, icon, loading, onClick, size, testId, type, variant, }: ButtonProps) => react_jsx_runtime.JSX.Element;
|
|
168
170
|
|
|
169
|
-
|
|
171
|
+
/**
|
|
172
|
+
* Button Group based on [NextUI Button Group](https://nextui.org/docs/components/button#button-group)
|
|
173
|
+
*/
|
|
174
|
+
declare const ButtonGroup: _nextui_org_system.InternalForwardRefRenderFunction<"div", _nextui_org_button.ButtonGroupProps, never>;
|
|
175
|
+
|
|
176
|
+
export { Button as B, ButtonGroup as a, buttonVariants as b, type ButtonProps as c };
|
|
@@ -2,8 +2,10 @@ import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
|
2
2
|
import * as tailwind_variants from 'tailwind-variants';
|
|
3
3
|
import * as tailwind_variants_dist_config_js from 'tailwind-variants/dist/config.js';
|
|
4
4
|
import { TVProps } from '@fuf-stack/pixel-utils';
|
|
5
|
+
import * as _nextui_org_button from '@nextui-org/button';
|
|
5
6
|
import { ButtonProps as ButtonProps$1 } from '@nextui-org/button';
|
|
6
7
|
import { ReactNode } from 'react';
|
|
8
|
+
import * as _nextui_org_system from '@nextui-org/system';
|
|
7
9
|
|
|
8
10
|
declare const buttonVariants: tailwind_variants.TVReturnType<{
|
|
9
11
|
color: {
|
|
@@ -166,4 +168,9 @@ interface ButtonProps extends VariantProps {
|
|
|
166
168
|
*/
|
|
167
169
|
declare const Button: ({ ariaLabel, children, className, color, disabled, disableAnimation, icon, loading, onClick, size, testId, type, variant, }: ButtonProps) => react_jsx_runtime.JSX.Element;
|
|
168
170
|
|
|
169
|
-
|
|
171
|
+
/**
|
|
172
|
+
* Button Group based on [NextUI Button Group](https://nextui.org/docs/components/button#button-group)
|
|
173
|
+
*/
|
|
174
|
+
declare const ButtonGroup: _nextui_org_system.InternalForwardRefRenderFunction<"div", _nextui_org_button.ButtonGroupProps, never>;
|
|
175
|
+
|
|
176
|
+
export { Button as B, ButtonGroup as a, buttonVariants as b, type ButtonProps as c };
|
package/dist/Json/index.cjs
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
5
|
-
require('../chunk-
|
|
4
|
+
var _chunkHI7Z6XY7cjs = require('../chunk-HI7Z6XY7.cjs');
|
|
5
|
+
require('../chunk-7TIFKRWY.cjs');
|
|
6
6
|
require('../chunk-DZUJEN5N.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
exports.Json =
|
|
10
|
+
exports.Json = _chunkHI7Z6XY7cjs.Json_default; exports.default = _chunkHI7Z6XY7cjs.Json_default2;
|
|
11
11
|
//# sourceMappingURL=index.cjs.map
|
package/dist/Json/index.js
CHANGED
package/dist/Tooltip/index.cjs
CHANGED
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
var
|
|
5
|
+
var _chunkRMA57Q6Kcjs = require('../chunk-RMA57Q6K.cjs');
|
|
6
6
|
require('../chunk-DZUJEN5N.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
|
|
11
|
-
exports.Tooltip =
|
|
11
|
+
exports.Tooltip = _chunkRMA57Q6Kcjs.Tooltip_default; exports.default = _chunkRMA57Q6Kcjs.Tooltip_default2; exports.tooltipPlacementOptions = _chunkRMA57Q6Kcjs.tooltipPlacementOptions;
|
|
12
12
|
//# sourceMappingURL=index.cjs.map
|
package/dist/Tooltip/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { T as Tooltip } from '../Tooltip-
|
|
2
|
-
export { a as TooltipProps, t as tooltipPlacementOptions } from '../Tooltip-
|
|
1
|
+
import { T as Tooltip } from '../Tooltip-DS3pM5Cq.cjs';
|
|
2
|
+
export { a as TooltipProps, t as tooltipPlacementOptions } from '../Tooltip-DS3pM5Cq.cjs';
|
|
3
3
|
import 'react/jsx-runtime';
|
|
4
4
|
import 'tailwind-variants/dist/config.js';
|
|
5
5
|
import 'tailwind-variants';
|
package/dist/Tooltip/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { T as Tooltip } from '../Tooltip-
|
|
2
|
-
export { a as TooltipProps, t as tooltipPlacementOptions } from '../Tooltip-
|
|
1
|
+
import { T as Tooltip } from '../Tooltip-DS3pM5Cq.js';
|
|
2
|
+
export { a as TooltipProps, t as tooltipPlacementOptions } from '../Tooltip-DS3pM5Cq.js';
|
|
3
3
|
import 'react/jsx-runtime';
|
|
4
4
|
import 'tailwind-variants/dist/config.js';
|
|
5
5
|
import 'tailwind-variants';
|
package/dist/Tooltip/index.js
CHANGED
|
@@ -66,6 +66,10 @@ interface TooltipProps extends VariantProps {
|
|
|
66
66
|
children: ReactNode;
|
|
67
67
|
/** CSS class name */
|
|
68
68
|
className?: ClassName;
|
|
69
|
+
/** delay in milliseconds before the tooltip opens. */
|
|
70
|
+
closeDelay?: number;
|
|
71
|
+
/** delay in milliseconds before the tooltip opens. */
|
|
72
|
+
delay?: number;
|
|
69
73
|
/** placement padding in px */
|
|
70
74
|
containerPadding?: number;
|
|
71
75
|
/** content displayed in the tooltip */
|
|
@@ -80,6 +84,6 @@ interface TooltipProps extends VariantProps {
|
|
|
80
84
|
/**
|
|
81
85
|
* Tooltip component based on [NextUI Tooltip](https://nextui.org/docs/components/tooltip)
|
|
82
86
|
*/
|
|
83
|
-
declare const Tooltip: ({ children, className: _className,
|
|
87
|
+
declare const Tooltip: ({ children, className: _className, closeDelay, containerPadding, content, defaultOpen, delay, onOpenChange, placement, }: TooltipProps) => react_jsx_runtime.JSX.Element;
|
|
84
88
|
|
|
85
89
|
export { Tooltip as T, type TooltipProps as a, tooltipPlacementOptions as t };
|
|
@@ -66,6 +66,10 @@ interface TooltipProps extends VariantProps {
|
|
|
66
66
|
children: ReactNode;
|
|
67
67
|
/** CSS class name */
|
|
68
68
|
className?: ClassName;
|
|
69
|
+
/** delay in milliseconds before the tooltip opens. */
|
|
70
|
+
closeDelay?: number;
|
|
71
|
+
/** delay in milliseconds before the tooltip opens. */
|
|
72
|
+
delay?: number;
|
|
69
73
|
/** placement padding in px */
|
|
70
74
|
containerPadding?: number;
|
|
71
75
|
/** content displayed in the tooltip */
|
|
@@ -80,6 +84,6 @@ interface TooltipProps extends VariantProps {
|
|
|
80
84
|
/**
|
|
81
85
|
* Tooltip component based on [NextUI Tooltip](https://nextui.org/docs/components/tooltip)
|
|
82
86
|
*/
|
|
83
|
-
declare const Tooltip: ({ children, className: _className,
|
|
87
|
+
declare const Tooltip: ({ children, className: _className, closeDelay, containerPadding, content, defaultOpen, delay, onOpenChange, placement, }: TooltipProps) => react_jsx_runtime.JSX.Element;
|
|
84
88
|
|
|
85
89
|
export { Tooltip as T, type TooltipProps as a, tooltipPlacementOptions as t };
|
|
@@ -114,6 +114,11 @@ var Button = ({
|
|
|
114
114
|
};
|
|
115
115
|
var Button_default = Button;
|
|
116
116
|
|
|
117
|
+
// src/Button/ButtonGroup.tsx
|
|
118
|
+
|
|
119
|
+
var ButtonGroup = _button.ButtonGroup;
|
|
120
|
+
var ButtonGroup_default = ButtonGroup;
|
|
121
|
+
|
|
117
122
|
// src/Button/index.ts
|
|
118
123
|
var Button_default2 = Button_default;
|
|
119
124
|
|
|
@@ -121,5 +126,6 @@ var Button_default2 = Button_default;
|
|
|
121
126
|
|
|
122
127
|
|
|
123
128
|
|
|
124
|
-
|
|
125
|
-
|
|
129
|
+
|
|
130
|
+
exports.buttonVariants = buttonVariants; exports.Button_default = Button_default; exports.ButtonGroup_default = ButtonGroup_default; exports.Button_default2 = Button_default2;
|
|
131
|
+
//# sourceMappingURL=chunk-7TIFKRWY.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["/home/runner/work/uniform/uniform/packages/pixels/dist/chunk-7TIFKRWY.cjs","../src/Button/Button.tsx","../src/Button/subcomponents/LoadingSpinner.tsx","../src/Button/ButtonGroup.tsx","../src/Button/index.ts"],"names":["jsxs","jsx","Button_default"],"mappings":"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","file":"/home/runner/work/uniform/uniform/packages/pixels/dist/chunk-7TIFKRWY.cjs","sourcesContent":[null,"import type { TVProps } from '@fuf-stack/pixel-utils';\nimport type { ButtonProps as NextButtonProps } from '@nextui-org/button';\nimport type { ReactNode } from 'react';\n\nimport { Button as NextButton } from '@nextui-org/button';\n\nimport { tv } from '@fuf-stack/pixel-utils';\n\nimport LoadingSpinner from './subcomponents/LoadingSpinner';\n\nexport const buttonVariants = tv({\n base: '',\n variants: {\n color: {\n default: '',\n primary: '',\n secondary: '',\n success: '',\n warning: '',\n danger: '',\n },\n variant: {\n solid: '',\n bordered: '',\n light: '',\n flat: '',\n faded: '',\n shadow: '',\n ghost: '',\n },\n },\n compoundVariants: [\n // white text on solid / shadow success button\n {\n color: 'success',\n variant: ['solid', 'shadow'],\n class: 'text-white',\n },\n // white text on solid / shadow warning button\n {\n color: 'warning',\n variant: ['solid', 'shadow'],\n class: 'text-white',\n },\n ],\n});\n\ntype VariantProps = TVProps<typeof buttonVariants>;\n\nexport interface ButtonProps extends VariantProps {\n /** sets HTML aria-label attribute */\n ariaLabel?: string;\n /** child components */\n children?: ReactNode;\n /** CSS class name */\n className?: string;\n /** next ui button color */\n color?: NextButtonProps['color'];\n /** disables function of the button. */\n disabled?: boolean;\n /** disables all button animations */\n disableAnimation?: boolean;\n /** If set loading animation is shown */\n loading?: boolean;\n /** optional icon */\n icon?: ReactNode;\n /** on click event */\n onClick?: NextButtonProps['onPress'];\n /** 3 size options */\n size?: NextButtonProps['size'];\n /** HTML data-testid attribute used in e2e tests */\n testId?: string;\n /** sets the button type. */\n type?: 'button' | 'submit' | 'reset' | undefined;\n /** next ui button variants */\n variant?: NextButtonProps['variant'];\n}\n\n/**\n * Button component based on [NextUI Button](https://nextui.org/docs/components/button)\n */\nconst Button = ({\n ariaLabel = undefined,\n children = undefined,\n className = undefined,\n color = 'default',\n disabled = false,\n disableAnimation = false,\n icon = undefined,\n loading = false,\n onClick = undefined,\n size = undefined,\n testId = undefined,\n type = undefined,\n variant = 'solid',\n}: ButtonProps) => {\n return (\n <NextButton\n aria-label={ariaLabel}\n className={buttonVariants({ color, variant, className })}\n color={color}\n data-testid={testId}\n disableAnimation={disableAnimation}\n disableRipple={disableAnimation}\n isDisabled={disabled}\n isIconOnly={!!(icon && !children)}\n isLoading={loading}\n onPress={onClick}\n size={size}\n spinner={<LoadingSpinner />}\n type={type}\n variant={variant}\n >\n {icon}\n {children}\n </NextButton>\n );\n};\n\nexport default Button;\n","/**\n * svg loading spinner for button\n * @see https://nextui.org/docs/components/button#loading\n * */\nexport default () => (\n <svg\n className=\"animate-spin h-5 w-5 text-current\"\n fill=\"none\"\n viewBox=\"0 0 24 24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <circle\n className=\"opacity-25\"\n cx=\"12\"\n cy=\"12\"\n r=\"10\"\n stroke=\"currentColor\"\n strokeWidth=\"4\"\n />\n <path\n className=\"opacity-75\"\n d=\"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z\"\n fill=\"currentColor\"\n />\n </svg>\n);\n","import { ButtonGroup as NextButtonGroup } from '@nextui-org/button';\n\n/**\n * Button Group based on [NextUI Button Group](https://nextui.org/docs/components/button#button-group)\n */\nconst ButtonGroup = NextButtonGroup;\n\nexport default ButtonGroup;\n","import Button, { buttonVariants } from './Button';\nimport ButtonGroup from './ButtonGroup';\n\nexport type { ButtonProps } from './Button';\n\nexport { Button, ButtonGroup, buttonVariants };\n\nexport default Button;\n"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunk7TIFKRWYcjs = require('./chunk-7TIFKRWY.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
@@ -2631,7 +2631,7 @@ var Json = ({ className = null, collapsed = false, value }) => {
|
|
|
2631
2631
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", { className: "font-medium", children: "Failed to parse JSON data" })
|
|
2632
2632
|
] }),
|
|
2633
2633
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
2634
|
-
|
|
2634
|
+
_chunk7TIFKRWYcjs.Button_default,
|
|
2635
2635
|
{
|
|
2636
2636
|
color: "danger",
|
|
2637
2637
|
size: "sm",
|
|
@@ -2676,4 +2676,4 @@ var Json_default2 = Json_default;
|
|
|
2676
2676
|
|
|
2677
2677
|
|
|
2678
2678
|
exports.Json_default = Json_default; exports.Json_default2 = Json_default2;
|
|
2679
|
-
//# sourceMappingURL=chunk-
|
|
2679
|
+
//# sourceMappingURL=chunk-HI7Z6XY7.cjs.map
|