@almadar/ui 5.69.0 → 5.71.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/avl/index.cjs +2034 -1854
- package/dist/avl/index.d.cts +93 -56
- package/dist/avl/index.js +758 -578
- package/dist/components/avl/molecules/AvlEventWireEdge.d.ts +2 -1
- package/dist/components/avl/molecules/AvlTransitionEdge.d.ts +2 -1
- package/dist/components/avl/molecules/avl-behavior-compose-converter.d.ts +7 -5
- package/dist/components/avl/molecules/avl-behavior-compose-types.d.ts +41 -21
- package/dist/components/avl/molecules/avl-canvas-types.d.ts +10 -7
- package/dist/components/avl/molecules/avl-preview-converter.d.ts +5 -5
- package/dist/components/avl/molecules/avl-preview-types.d.ts +15 -4
- package/dist/components/avl/organisms/FlowCanvas.d.ts +2 -2
- package/dist/components/avl/organisms/avl-schema-parser.d.ts +18 -16
- package/dist/components/core/atoms/Button.d.ts +2 -0
- package/dist/components/core/atoms/ConditionalWrapper.d.ts +5 -4
- package/dist/components/core/molecules/Carousel.d.ts +2 -2
- package/dist/components/core/molecules/OrbitalVisualization.d.ts +4 -3
- package/dist/components/core/molecules/PageHeader.d.ts +3 -3
- package/dist/components/core/molecules/RepeatableFormSection.d.ts +4 -3
- package/dist/components/core/molecules/ViolationAlert.d.ts +2 -0
- package/dist/components/core/molecules/WizardContainer.d.ts +23 -22
- package/dist/components/core/organisms/CardGrid.d.ts +2 -2
- package/dist/components/core/organisms/CustomPattern.d.ts +3 -4
- package/dist/components/core/organisms/DataTable.d.ts +2 -2
- package/dist/components/core/organisms/DetailPanel.d.ts +1 -1
- package/dist/components/core/organisms/Form.d.ts +11 -11
- package/dist/components/core/organisms/List.d.ts +3 -5
- package/dist/components/core/organisms/StatCard.d.ts +2 -2
- package/dist/components/core/organisms/book/types.d.ts +1 -1
- package/dist/components/core/organisms/debug/RuntimeDebugger.d.ts +2 -1
- package/dist/components/core/organisms/debug/tabs/EventDispatcherTab.d.ts +2 -1
- package/dist/components/core/organisms/layout/DashboardGrid.d.ts +0 -2
- package/dist/components/core/organisms/types.d.ts +3 -2
- package/dist/components/game/atoms/ScoreDisplay.d.ts +3 -1
- package/dist/components/game/molecules/three/hooks/useSceneGraph.d.ts +2 -1
- package/dist/components/game/molecules/three/index.cjs +37 -24
- package/dist/components/game/molecules/three/index.js +37 -24
- package/dist/components/game/organisms/HolidayRunnerBoard.d.ts +19 -17
- package/dist/components/game/organisms/PinballBoard.d.ts +4 -4
- package/dist/components/game/organisms/RacingBoard.d.ts +25 -17
- package/dist/components/game/organisms/SpaceShmupBoard.d.ts +28 -11
- package/dist/components/game/organisms/boardEntity.d.ts +6 -6
- package/dist/components/game/organisms/puzzles/debugger/DebuggerBoard.d.ts +16 -2
- package/dist/components/game/organisms/puzzles/event-handler/puzzleObject.d.ts +21 -10
- package/dist/components/game/organisms/puzzles/state-architect/StateJsonView.d.ts +2 -1
- package/dist/components/index.cjs +1771 -1614
- package/dist/components/index.js +650 -493
- package/dist/docs/index.cjs +107 -104
- package/dist/docs/index.d.cts +2 -0
- package/dist/docs/index.js +38 -35
- package/dist/lib/getNestedValue.d.ts +2 -13
- package/dist/marketing/index.cjs +97 -98
- package/dist/marketing/index.d.cts +2 -0
- package/dist/marketing/index.js +54 -55
- package/dist/providers/index.cjs +1744 -1587
- package/dist/providers/index.js +635 -478
- package/dist/runtime/index.cjs +1802 -1645
- package/dist/runtime/index.js +641 -484
- package/package.json +1 -1
- package/themes/almadar-website.css +2 -2
- package/themes/almadar.css +2 -2
- package/themes/arctic.css +2 -2
- package/themes/kiosk.css +2 -2
- package/themes/lavender.css +3 -3
- package/themes/midnight.css +2 -2
- package/themes/neon.css +2 -2
- package/themes/notion-editorial.css +2 -2
- package/themes/sunset.css +2 -2
- package/themes/trait-wars.css +2 -2
package/dist/marketing/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var React11 = require('react');
|
|
4
4
|
var logger = require('@almadar/logger');
|
|
5
5
|
var jsxRuntime = require('react/jsx-runtime');
|
|
6
6
|
var LucideIcons2 = require('lucide-react');
|
|
@@ -25,7 +25,7 @@ function _interopNamespace(e) {
|
|
|
25
25
|
return Object.freeze(n);
|
|
26
26
|
}
|
|
27
27
|
|
|
28
|
-
var
|
|
28
|
+
var React11__default = /*#__PURE__*/_interopDefault(React11);
|
|
29
29
|
var LucideIcons2__namespace = /*#__PURE__*/_interopNamespace(LucideIcons2);
|
|
30
30
|
|
|
31
31
|
// node_modules/clsx/dist/clsx.mjs
|
|
@@ -2509,10 +2509,10 @@ function cn(...inputs) {
|
|
|
2509
2509
|
}
|
|
2510
2510
|
logger.createLogger("almadar:eventbus");
|
|
2511
2511
|
logger.createLogger("almadar:eventbus:subscribe");
|
|
2512
|
-
var EventBusContext =
|
|
2513
|
-
var TraitScopeContext =
|
|
2512
|
+
var EventBusContext = React11.createContext(null);
|
|
2513
|
+
var TraitScopeContext = React11.createContext(null);
|
|
2514
2514
|
function useTraitScope() {
|
|
2515
|
-
return
|
|
2515
|
+
return React11.useContext(TraitScopeContext);
|
|
2516
2516
|
}
|
|
2517
2517
|
var log = logger.createLogger("almadar:eventbus");
|
|
2518
2518
|
var subLog2 = logger.createLogger("almadar:eventbus:subscribe");
|
|
@@ -2588,10 +2588,10 @@ var fallbackEventBus = {
|
|
|
2588
2588
|
}
|
|
2589
2589
|
};
|
|
2590
2590
|
function useEventBus() {
|
|
2591
|
-
const context =
|
|
2591
|
+
const context = React11.useContext(EventBusContext);
|
|
2592
2592
|
const baseBus = context ?? getGlobalEventBus() ?? fallbackEventBus;
|
|
2593
2593
|
const scope = useTraitScope();
|
|
2594
|
-
return
|
|
2594
|
+
return React11.useMemo(() => {
|
|
2595
2595
|
if (!scope) {
|
|
2596
2596
|
return {
|
|
2597
2597
|
...baseBus,
|
|
@@ -2627,24 +2627,24 @@ function useEventBus() {
|
|
|
2627
2627
|
}
|
|
2628
2628
|
function useTapReveal(options = {}) {
|
|
2629
2629
|
const { onReveal, onDismiss, refs, enabled = true } = options;
|
|
2630
|
-
const [revealed, setRevealed] =
|
|
2631
|
-
const onRevealRef =
|
|
2632
|
-
const onDismissRef =
|
|
2630
|
+
const [revealed, setRevealed] = React11.useState(false);
|
|
2631
|
+
const onRevealRef = React11.useRef(onReveal);
|
|
2632
|
+
const onDismissRef = React11.useRef(onDismiss);
|
|
2633
2633
|
onRevealRef.current = onReveal;
|
|
2634
2634
|
onDismissRef.current = onDismiss;
|
|
2635
|
-
const reveal =
|
|
2635
|
+
const reveal = React11.useCallback(() => {
|
|
2636
2636
|
setRevealed((wasRevealed) => {
|
|
2637
2637
|
if (!wasRevealed) onRevealRef.current?.();
|
|
2638
2638
|
return true;
|
|
2639
2639
|
});
|
|
2640
2640
|
}, []);
|
|
2641
|
-
const dismiss =
|
|
2641
|
+
const dismiss = React11.useCallback(() => {
|
|
2642
2642
|
setRevealed((wasRevealed) => {
|
|
2643
2643
|
if (wasRevealed) onDismissRef.current?.();
|
|
2644
2644
|
return false;
|
|
2645
2645
|
});
|
|
2646
2646
|
}, []);
|
|
2647
|
-
const onPointerDown =
|
|
2647
|
+
const onPointerDown = React11.useCallback(
|
|
2648
2648
|
(e) => {
|
|
2649
2649
|
if (!enabled || e.pointerType === "mouse") return;
|
|
2650
2650
|
if (revealed) dismiss();
|
|
@@ -2652,7 +2652,7 @@ function useTapReveal(options = {}) {
|
|
|
2652
2652
|
},
|
|
2653
2653
|
[enabled, revealed, reveal, dismiss]
|
|
2654
2654
|
);
|
|
2655
|
-
|
|
2655
|
+
React11.useEffect(() => {
|
|
2656
2656
|
if (!revealed || typeof document === "undefined") return;
|
|
2657
2657
|
const onDocDown = (ev) => {
|
|
2658
2658
|
const target = ev.target;
|
|
@@ -2772,7 +2772,7 @@ var positionStyles = {
|
|
|
2772
2772
|
fixed: "fixed",
|
|
2773
2773
|
sticky: "sticky"
|
|
2774
2774
|
};
|
|
2775
|
-
var Box =
|
|
2775
|
+
var Box = React11__default.default.forwardRef(
|
|
2776
2776
|
({
|
|
2777
2777
|
padding,
|
|
2778
2778
|
paddingX,
|
|
@@ -2804,20 +2804,20 @@ var Box = React9__default.default.forwardRef(
|
|
|
2804
2804
|
...rest
|
|
2805
2805
|
}, ref) => {
|
|
2806
2806
|
const eventBus = useEventBus();
|
|
2807
|
-
const handleClick =
|
|
2807
|
+
const handleClick = React11.useCallback((e) => {
|
|
2808
2808
|
if (action) {
|
|
2809
2809
|
e.stopPropagation();
|
|
2810
2810
|
eventBus.emit(`UI:${action}`, actionPayload ?? {});
|
|
2811
2811
|
}
|
|
2812
2812
|
onClick?.(e);
|
|
2813
2813
|
}, [action, actionPayload, eventBus, onClick]);
|
|
2814
|
-
const handleMouseEnter =
|
|
2814
|
+
const handleMouseEnter = React11.useCallback((e) => {
|
|
2815
2815
|
if (hoverEvent) {
|
|
2816
2816
|
eventBus.emit(`UI:${hoverEvent}`, { hovered: true });
|
|
2817
2817
|
}
|
|
2818
2818
|
onMouseEnter?.(e);
|
|
2819
2819
|
}, [hoverEvent, eventBus, onMouseEnter]);
|
|
2820
|
-
const handleMouseLeave =
|
|
2820
|
+
const handleMouseLeave = React11.useCallback((e) => {
|
|
2821
2821
|
if (hoverEvent) {
|
|
2822
2822
|
eventBus.emit(`UI:${hoverEvent}`, { hovered: false });
|
|
2823
2823
|
}
|
|
@@ -2825,19 +2825,19 @@ var Box = React9__default.default.forwardRef(
|
|
|
2825
2825
|
}, [hoverEvent, eventBus, onMouseLeave]);
|
|
2826
2826
|
const { triggerProps } = useTapReveal({
|
|
2827
2827
|
enabled: tapReveal && !!hoverEvent,
|
|
2828
|
-
onReveal:
|
|
2828
|
+
onReveal: React11.useCallback(() => {
|
|
2829
2829
|
if (hoverEvent) eventBus.emit(`UI:${hoverEvent}`, { hovered: true });
|
|
2830
2830
|
}, [hoverEvent, eventBus]),
|
|
2831
|
-
onDismiss:
|
|
2831
|
+
onDismiss: React11.useCallback(() => {
|
|
2832
2832
|
if (hoverEvent) eventBus.emit(`UI:${hoverEvent}`, { hovered: false });
|
|
2833
2833
|
}, [hoverEvent, eventBus])
|
|
2834
2834
|
});
|
|
2835
|
-
const handlePointerDown =
|
|
2835
|
+
const handlePointerDown = React11.useCallback((e) => {
|
|
2836
2836
|
if (hoverEvent && tapReveal) triggerProps.onPointerDown(e);
|
|
2837
2837
|
onPointerDown?.(e);
|
|
2838
2838
|
}, [hoverEvent, tapReveal, triggerProps, onPointerDown]);
|
|
2839
2839
|
const isClickable = action || onClick;
|
|
2840
|
-
return
|
|
2840
|
+
return React11__default.default.createElement(
|
|
2841
2841
|
Component,
|
|
2842
2842
|
{
|
|
2843
2843
|
ref,
|
|
@@ -2925,9 +2925,8 @@ var Stack = ({
|
|
|
2925
2925
|
};
|
|
2926
2926
|
const isHorizontal = direction === "horizontal";
|
|
2927
2927
|
const directionClass = responsive && isHorizontal ? reverse ? "flex-col-reverse md:flex-row-reverse" : "flex-col md:flex-row" : isHorizontal ? reverse ? "flex-row-reverse" : "flex-row" : reverse ? "flex-col-reverse" : "flex-col";
|
|
2928
|
-
|
|
2929
|
-
|
|
2930
|
-
Comp,
|
|
2928
|
+
return React11__default.default.createElement(
|
|
2929
|
+
Component,
|
|
2931
2930
|
{
|
|
2932
2931
|
className: cn(
|
|
2933
2932
|
"flex",
|
|
@@ -2943,9 +2942,9 @@ var Stack = ({
|
|
|
2943
2942
|
onClick: action || onClick ? handleClick : void 0,
|
|
2944
2943
|
onKeyDown,
|
|
2945
2944
|
role,
|
|
2946
|
-
tabIndex
|
|
2947
|
-
|
|
2948
|
-
|
|
2945
|
+
tabIndex
|
|
2946
|
+
},
|
|
2947
|
+
children
|
|
2949
2948
|
);
|
|
2950
2949
|
};
|
|
2951
2950
|
var VStack = (props) => /* @__PURE__ */ jsxRuntime.jsx(Stack, { direction: "vertical", ...props });
|
|
@@ -3036,9 +3035,8 @@ var Typography = ({
|
|
|
3036
3035
|
}) => {
|
|
3037
3036
|
const variant = variantProp ?? (level ? `h${level}` : "body1");
|
|
3038
3037
|
const Component = as || defaultElements[variant];
|
|
3039
|
-
|
|
3040
|
-
|
|
3041
|
-
Comp,
|
|
3038
|
+
return React11__default.default.createElement(
|
|
3039
|
+
Component,
|
|
3042
3040
|
{
|
|
3043
3041
|
id,
|
|
3044
3042
|
className: cn(
|
|
@@ -3051,9 +3049,9 @@ var Typography = ({
|
|
|
3051
3049
|
overflow && overflowStyles2[overflow],
|
|
3052
3050
|
className
|
|
3053
3051
|
),
|
|
3054
|
-
style
|
|
3055
|
-
|
|
3056
|
-
|
|
3052
|
+
style
|
|
3053
|
+
},
|
|
3054
|
+
children ?? content
|
|
3057
3055
|
);
|
|
3058
3056
|
};
|
|
3059
3057
|
Typography.displayName = "Typography";
|
|
@@ -3107,7 +3105,7 @@ function getIconFamilyServerSnapshot() {
|
|
|
3107
3105
|
return DEFAULT_FAMILY;
|
|
3108
3106
|
}
|
|
3109
3107
|
function useIconFamily() {
|
|
3110
|
-
return
|
|
3108
|
+
return React11.useSyncExternalStore(
|
|
3111
3109
|
subscribeIconFamily,
|
|
3112
3110
|
getIconFamilySnapshot,
|
|
3113
3111
|
getIconFamilyServerSnapshot
|
|
@@ -3129,7 +3127,7 @@ function loadLib(key, importer) {
|
|
|
3129
3127
|
return p;
|
|
3130
3128
|
}
|
|
3131
3129
|
function lazyFamilyIcon(libKey, importer, pick, fallbackName, family) {
|
|
3132
|
-
const Lazy =
|
|
3130
|
+
const Lazy = React11__default.default.lazy(async () => {
|
|
3133
3131
|
const lib = await loadLib(libKey, importer);
|
|
3134
3132
|
const Comp = pick(lib);
|
|
3135
3133
|
if (!Comp) {
|
|
@@ -3139,7 +3137,7 @@ function lazyFamilyIcon(libKey, importer, pick, fallbackName, family) {
|
|
|
3139
3137
|
return { default: Comp };
|
|
3140
3138
|
});
|
|
3141
3139
|
const Wrapped = (props) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
3142
|
-
|
|
3140
|
+
React11__default.default.Suspense,
|
|
3143
3141
|
{
|
|
3144
3142
|
fallback: /* @__PURE__ */ jsxRuntime.jsx(
|
|
3145
3143
|
"span",
|
|
@@ -3809,9 +3807,10 @@ function resolveIcon(name) {
|
|
|
3809
3807
|
function doResolve(name) {
|
|
3810
3808
|
if (iconAliases[name]) return iconAliases[name];
|
|
3811
3809
|
const pascalName = kebabToPascal2(name);
|
|
3812
|
-
const
|
|
3810
|
+
const lucideMap = LucideIcons2__namespace;
|
|
3811
|
+
const directLookup = lucideMap[pascalName];
|
|
3813
3812
|
if (directLookup && typeof directLookup === "object") return directLookup;
|
|
3814
|
-
const asIs =
|
|
3813
|
+
const asIs = lucideMap[name];
|
|
3815
3814
|
if (asIs && typeof asIs === "object") return asIs;
|
|
3816
3815
|
return LucideIcons2__namespace.HelpCircle;
|
|
3817
3816
|
}
|
|
@@ -3840,7 +3839,7 @@ var Icon = ({
|
|
|
3840
3839
|
const directIcon = typeof icon === "string" ? void 0 : icon;
|
|
3841
3840
|
const effectiveName = typeof icon === "string" ? icon : name;
|
|
3842
3841
|
const family = useIconFamily();
|
|
3843
|
-
const RenderedComponent =
|
|
3842
|
+
const RenderedComponent = React11__default.default.useMemo(() => {
|
|
3844
3843
|
if (directIcon) return null;
|
|
3845
3844
|
return effectiveName ? resolveIconForFamily(effectiveName, family) : null;
|
|
3846
3845
|
}, [directIcon, effectiveName, family]);
|
|
@@ -3948,6 +3947,9 @@ var iconSizeStyles = {
|
|
|
3948
3947
|
md: "h-icon-default w-icon-default",
|
|
3949
3948
|
lg: "h-icon-default w-icon-default"
|
|
3950
3949
|
};
|
|
3950
|
+
function isIconLike(v) {
|
|
3951
|
+
return typeof v.render === "function";
|
|
3952
|
+
}
|
|
3951
3953
|
function resolveIconProp(value, sizeClass) {
|
|
3952
3954
|
if (!value) return null;
|
|
3953
3955
|
if (typeof value === "string") {
|
|
@@ -3957,16 +3959,16 @@ function resolveIconProp(value, sizeClass) {
|
|
|
3957
3959
|
const IconComp = value;
|
|
3958
3960
|
return /* @__PURE__ */ jsxRuntime.jsx(IconComp, { className: sizeClass });
|
|
3959
3961
|
}
|
|
3960
|
-
if (
|
|
3962
|
+
if (React11__default.default.isValidElement(value)) {
|
|
3961
3963
|
return value;
|
|
3962
3964
|
}
|
|
3963
|
-
if (typeof value === "object" && value !== null &&
|
|
3965
|
+
if (typeof value === "object" && value !== null && isIconLike(value)) {
|
|
3964
3966
|
const IconComp = value;
|
|
3965
3967
|
return /* @__PURE__ */ jsxRuntime.jsx(IconComp, { className: sizeClass });
|
|
3966
3968
|
}
|
|
3967
3969
|
return value;
|
|
3968
3970
|
}
|
|
3969
|
-
var Button =
|
|
3971
|
+
var Button = React11__default.default.forwardRef(
|
|
3970
3972
|
({
|
|
3971
3973
|
className,
|
|
3972
3974
|
variant = "primary",
|
|
@@ -3982,6 +3984,7 @@ var Button = React9__default.default.forwardRef(
|
|
|
3982
3984
|
label,
|
|
3983
3985
|
children,
|
|
3984
3986
|
onClick,
|
|
3987
|
+
"data-testid": dataTestId,
|
|
3985
3988
|
...props
|
|
3986
3989
|
}, ref) => {
|
|
3987
3990
|
const eventBus = useEventBus();
|
|
@@ -4014,7 +4017,7 @@ var Button = React9__default.default.forwardRef(
|
|
|
4014
4017
|
),
|
|
4015
4018
|
onClick: handleClick,
|
|
4016
4019
|
...props,
|
|
4017
|
-
"data-testid":
|
|
4020
|
+
"data-testid": dataTestId ?? (action ? `action-${action}` : void 0),
|
|
4018
4021
|
children: [
|
|
4019
4022
|
isLoading ? /* @__PURE__ */ jsxRuntime.jsx(LucideIcons2.Loader2, { className: "h-icon-default w-icon-default animate-spin" }) : resolvedLeftIcon && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "flex-shrink-0", children: resolvedLeftIcon }),
|
|
4020
4023
|
children || label,
|
|
@@ -4062,7 +4065,7 @@ var sizeStyles2 = {
|
|
|
4062
4065
|
md: "px-2.5 py-1 text-sm",
|
|
4063
4066
|
lg: "px-3 py-1.5 text-base"
|
|
4064
4067
|
};
|
|
4065
|
-
var Badge =
|
|
4068
|
+
var Badge = React11__default.default.forwardRef(
|
|
4066
4069
|
({ className, variant = "default", size = "sm", amount, label, icon, children, onRemove, removeLabel, ...props }, ref) => {
|
|
4067
4070
|
const iconSizes = {
|
|
4068
4071
|
sm: "h-icon-default w-icon-default",
|
|
@@ -4115,7 +4118,7 @@ var sizeStyles3 = {
|
|
|
4115
4118
|
md: "h-6 w-6",
|
|
4116
4119
|
lg: "h-8 w-8"
|
|
4117
4120
|
};
|
|
4118
|
-
var Spinner =
|
|
4121
|
+
var Spinner = React11__default.default.forwardRef(
|
|
4119
4122
|
({ className, size = "md", overlay, ...props }, ref) => {
|
|
4120
4123
|
if (overlay) {
|
|
4121
4124
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -4197,7 +4200,7 @@ var lookStyles = {
|
|
|
4197
4200
|
chip: "shadow-none rounded-pill border-[length:var(--border-width)] border-border",
|
|
4198
4201
|
"tile-image-first": "p-0 overflow-hidden"
|
|
4199
4202
|
};
|
|
4200
|
-
var Card =
|
|
4203
|
+
var Card = React11__default.default.forwardRef(
|
|
4201
4204
|
({
|
|
4202
4205
|
className,
|
|
4203
4206
|
variant = "bordered",
|
|
@@ -4245,9 +4248,9 @@ var Card = React9__default.default.forwardRef(
|
|
|
4245
4248
|
}
|
|
4246
4249
|
);
|
|
4247
4250
|
Card.displayName = "Card";
|
|
4248
|
-
var CardHeader =
|
|
4251
|
+
var CardHeader = React11__default.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("mb-4", className), ...props }));
|
|
4249
4252
|
CardHeader.displayName = "CardHeader";
|
|
4250
|
-
var CardTitle =
|
|
4253
|
+
var CardTitle = React11__default.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
4251
4254
|
"h3",
|
|
4252
4255
|
{
|
|
4253
4256
|
ref,
|
|
@@ -4260,11 +4263,11 @@ var CardTitle = React9__default.default.forwardRef(({ className, ...props }, ref
|
|
|
4260
4263
|
}
|
|
4261
4264
|
));
|
|
4262
4265
|
CardTitle.displayName = "CardTitle";
|
|
4263
|
-
var CardContent =
|
|
4266
|
+
var CardContent = React11__default.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx("div", { ref, className: cn("", className), ...props }));
|
|
4264
4267
|
CardContent.displayName = "CardContent";
|
|
4265
4268
|
var CardBody = CardContent;
|
|
4266
4269
|
CardBody.displayName = "CardBody";
|
|
4267
|
-
var CardFooter =
|
|
4270
|
+
var CardFooter = React11__default.default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
4268
4271
|
"div",
|
|
4269
4272
|
{
|
|
4270
4273
|
ref,
|
|
@@ -4356,22 +4359,18 @@ var Center = ({
|
|
|
4356
4359
|
as: Component = "div"
|
|
4357
4360
|
}) => {
|
|
4358
4361
|
const mergedStyle = minHeight ? { minHeight, ...style } : style;
|
|
4359
|
-
|
|
4360
|
-
|
|
4361
|
-
|
|
4362
|
-
|
|
4363
|
-
|
|
4364
|
-
|
|
4365
|
-
|
|
4366
|
-
|
|
4367
|
-
|
|
4368
|
-
|
|
4369
|
-
|
|
4370
|
-
|
|
4371
|
-
style: mergedStyle,
|
|
4372
|
-
children
|
|
4373
|
-
}
|
|
4374
|
-
);
|
|
4362
|
+
return React11__default.default.createElement(Component, {
|
|
4363
|
+
className: cn(
|
|
4364
|
+
inline ? "inline-flex" : "flex",
|
|
4365
|
+
horizontal && "justify-center",
|
|
4366
|
+
vertical && "items-center",
|
|
4367
|
+
fullHeight && "h-full",
|
|
4368
|
+
fullWidth && "w-full",
|
|
4369
|
+
className
|
|
4370
|
+
),
|
|
4371
|
+
style: mergedStyle,
|
|
4372
|
+
children
|
|
4373
|
+
});
|
|
4375
4374
|
};
|
|
4376
4375
|
var horizontalSizes = {
|
|
4377
4376
|
xs: "w-1",
|
|
@@ -4421,7 +4420,7 @@ var paddingClasses = {
|
|
|
4421
4420
|
md: "py-16",
|
|
4422
4421
|
lg: "py-24"
|
|
4423
4422
|
};
|
|
4424
|
-
var ContentSection =
|
|
4423
|
+
var ContentSection = React11__default.default.forwardRef(
|
|
4425
4424
|
({ children, background = "default", padding = "lg", id, className }, ref) => {
|
|
4426
4425
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
4427
4426
|
Box,
|
|
@@ -4445,8 +4444,8 @@ var InstallBox = ({
|
|
|
4445
4444
|
label,
|
|
4446
4445
|
className
|
|
4447
4446
|
}) => {
|
|
4448
|
-
const [copied, setCopied] =
|
|
4449
|
-
const handleCopy =
|
|
4447
|
+
const [copied, setCopied] = React11.useState(false);
|
|
4448
|
+
const handleCopy = React11.useCallback(() => {
|
|
4450
4449
|
void navigator.clipboard.writeText(command);
|
|
4451
4450
|
setCopied(true);
|
|
4452
4451
|
const timer = setTimeout(() => setCopied(false), 2e3);
|
|
@@ -5023,7 +5022,7 @@ var StepFlow = ({
|
|
|
5023
5022
|
className
|
|
5024
5023
|
}) => {
|
|
5025
5024
|
if (orientation === "vertical") {
|
|
5026
|
-
return /* @__PURE__ */ jsxRuntime.jsx(VStack, { gap: "none", className: cn("w-full", className), children: steps.map((step, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
5025
|
+
return /* @__PURE__ */ jsxRuntime.jsx(VStack, { gap: "none", className: cn("w-full", className), children: steps.map((step, index) => /* @__PURE__ */ jsxRuntime.jsx(React11__default.default.Fragment, { children: /* @__PURE__ */ jsxRuntime.jsxs(HStack, { gap: "md", align: "start", className: "w-full", children: [
|
|
5027
5026
|
/* @__PURE__ */ jsxRuntime.jsxs(VStack, { gap: "none", align: "center", children: [
|
|
5028
5027
|
/* @__PURE__ */ jsxRuntime.jsx(StepCircle, { step, index }),
|
|
5029
5028
|
showConnectors && index < steps.length - 1 && /* @__PURE__ */ jsxRuntime.jsx(Box, { className: "w-px h-8 bg-border" })
|
|
@@ -5034,7 +5033,7 @@ var StepFlow = ({
|
|
|
5034
5033
|
] })
|
|
5035
5034
|
] }) }, index)) });
|
|
5036
5035
|
}
|
|
5037
|
-
return /* @__PURE__ */ jsxRuntime.jsx(Box, { className: cn("w-full flex flex-col md:flex-row items-start gap-0", className), children: steps.map((step, index) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
5036
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Box, { className: cn("w-full flex flex-col md:flex-row items-start gap-0", className), children: steps.map((step, index) => /* @__PURE__ */ jsxRuntime.jsxs(React11__default.default.Fragment, { children: [
|
|
5038
5037
|
/* @__PURE__ */ jsxRuntime.jsxs(VStack, { gap: "sm", align: "center", className: "flex-1 w-full md:w-auto", children: [
|
|
5039
5038
|
/* @__PURE__ */ jsxRuntime.jsx(StepCircle, { step, index }),
|
|
5040
5039
|
/* @__PURE__ */ jsxRuntime.jsx(Typography, { variant: "h4", className: "text-center", children: step.title }),
|
|
@@ -5242,8 +5241,8 @@ var Avatar = ({
|
|
|
5242
5241
|
actionPayload
|
|
5243
5242
|
}) => {
|
|
5244
5243
|
const eventBus = useEventBus();
|
|
5245
|
-
const [imgFailed, setImgFailed] =
|
|
5246
|
-
|
|
5244
|
+
const [imgFailed, setImgFailed] = React11__default.default.useState(false);
|
|
5245
|
+
React11__default.default.useEffect(() => {
|
|
5247
5246
|
setImgFailed(false);
|
|
5248
5247
|
}, [src]);
|
|
5249
5248
|
const initials = providedInitials ?? (name ? generateInitials(name) : void 0);
|
|
@@ -5560,10 +5559,10 @@ var AnimatedCounter = ({
|
|
|
5560
5559
|
duration = 1500,
|
|
5561
5560
|
className
|
|
5562
5561
|
}) => {
|
|
5563
|
-
const ref =
|
|
5564
|
-
const [displayValue, setDisplayValue] =
|
|
5565
|
-
const [hasAnimated, setHasAnimated] =
|
|
5566
|
-
const animate =
|
|
5562
|
+
const ref = React11.useRef(null);
|
|
5563
|
+
const [displayValue, setDisplayValue] = React11.useState("0");
|
|
5564
|
+
const [hasAnimated, setHasAnimated] = React11.useState(false);
|
|
5565
|
+
const animate = React11.useCallback(() => {
|
|
5567
5566
|
const { num, prefix, suffix, decimals } = parseValue(value);
|
|
5568
5567
|
if (num === 0) {
|
|
5569
5568
|
setDisplayValue(String(value));
|
|
@@ -5584,7 +5583,7 @@ var AnimatedCounter = ({
|
|
|
5584
5583
|
};
|
|
5585
5584
|
requestAnimationFrame(tick);
|
|
5586
5585
|
}, [value, duration]);
|
|
5587
|
-
|
|
5586
|
+
React11.useEffect(() => {
|
|
5588
5587
|
if (hasAnimated) return;
|
|
5589
5588
|
const el = ref.current;
|
|
5590
5589
|
if (!el) return;
|
|
@@ -5634,7 +5633,7 @@ var animatedStyles = {
|
|
|
5634
5633
|
"scale-up": { opacity: 1, transform: "scale(1) translateY(0)" },
|
|
5635
5634
|
"none": {}
|
|
5636
5635
|
};
|
|
5637
|
-
var AnimatedReveal =
|
|
5636
|
+
var AnimatedReveal = React11__default.default.forwardRef(
|
|
5638
5637
|
({
|
|
5639
5638
|
trigger = "scroll",
|
|
5640
5639
|
animation = "fade-up",
|
|
@@ -5649,10 +5648,10 @@ var AnimatedReveal = React9__default.default.forwardRef(
|
|
|
5649
5648
|
style,
|
|
5650
5649
|
...props
|
|
5651
5650
|
}, forwardedRef) => {
|
|
5652
|
-
const [isAnimated, setIsAnimated] =
|
|
5653
|
-
const internalRef =
|
|
5654
|
-
const hasAnimated =
|
|
5655
|
-
const setRef =
|
|
5651
|
+
const [isAnimated, setIsAnimated] = React11.useState(false);
|
|
5652
|
+
const internalRef = React11.useRef(null);
|
|
5653
|
+
const hasAnimated = React11.useRef(false);
|
|
5654
|
+
const setRef = React11.useCallback(
|
|
5656
5655
|
(node) => {
|
|
5657
5656
|
internalRef.current = node;
|
|
5658
5657
|
if (typeof forwardedRef === "function") forwardedRef(node);
|
|
@@ -5660,7 +5659,7 @@ var AnimatedReveal = React9__default.default.forwardRef(
|
|
|
5660
5659
|
},
|
|
5661
5660
|
[forwardedRef]
|
|
5662
5661
|
);
|
|
5663
|
-
|
|
5662
|
+
React11.useEffect(() => {
|
|
5664
5663
|
if (trigger !== "scroll") return;
|
|
5665
5664
|
const el = internalRef.current;
|
|
5666
5665
|
if (!el) return;
|
|
@@ -5686,7 +5685,7 @@ var AnimatedReveal = React9__default.default.forwardRef(
|
|
|
5686
5685
|
setIsAnimated(false);
|
|
5687
5686
|
}
|
|
5688
5687
|
} : void 0;
|
|
5689
|
-
|
|
5688
|
+
React11.useEffect(() => {
|
|
5690
5689
|
if (trigger === "manual" && manualAnimate !== void 0) {
|
|
5691
5690
|
setIsAnimated(manualAnimate);
|
|
5692
5691
|
}
|
|
@@ -5716,9 +5715,9 @@ var AnimatedReveal = React9__default.default.forwardRef(
|
|
|
5716
5715
|
);
|
|
5717
5716
|
AnimatedReveal.displayName = "AnimatedReveal";
|
|
5718
5717
|
function useFetchedSvg(src) {
|
|
5719
|
-
const [svg, setSvg] =
|
|
5720
|
-
const cache =
|
|
5721
|
-
|
|
5718
|
+
const [svg, setSvg] = React11.useState(null);
|
|
5719
|
+
const cache = React11.useRef({});
|
|
5720
|
+
React11.useEffect(() => {
|
|
5722
5721
|
if (!src) {
|
|
5723
5722
|
setSvg(null);
|
|
5724
5723
|
return;
|
|
@@ -5787,7 +5786,7 @@ function applyMorphAnimation(container, animate, duration, delay, easing) {
|
|
|
5787
5786
|
el.style.opacity = animate ? "1" : "0";
|
|
5788
5787
|
});
|
|
5789
5788
|
}
|
|
5790
|
-
var AnimatedGraphic =
|
|
5789
|
+
var AnimatedGraphic = React11__default.default.forwardRef(
|
|
5791
5790
|
({
|
|
5792
5791
|
src,
|
|
5793
5792
|
svgContent,
|
|
@@ -5806,11 +5805,11 @@ var AnimatedGraphic = React9__default.default.forwardRef(
|
|
|
5806
5805
|
children,
|
|
5807
5806
|
...props
|
|
5808
5807
|
}, ref) => {
|
|
5809
|
-
const containerRef =
|
|
5808
|
+
const containerRef = React11.useRef(null);
|
|
5810
5809
|
const fetchedSvg = useFetchedSvg(svgContent ? void 0 : src);
|
|
5811
5810
|
const resolvedSvg = svgContent ?? fetchedSvg;
|
|
5812
|
-
const prevAnimateRef =
|
|
5813
|
-
const setRef =
|
|
5811
|
+
const prevAnimateRef = React11.useRef(animate);
|
|
5812
|
+
const setRef = React11__default.default.useCallback(
|
|
5814
5813
|
(node) => {
|
|
5815
5814
|
containerRef.current = node;
|
|
5816
5815
|
if (typeof ref === "function") ref(node);
|
|
@@ -5818,7 +5817,7 @@ var AnimatedGraphic = React9__default.default.forwardRef(
|
|
|
5818
5817
|
},
|
|
5819
5818
|
[ref]
|
|
5820
5819
|
);
|
|
5821
|
-
|
|
5820
|
+
React11.useEffect(() => {
|
|
5822
5821
|
const el = containerRef.current;
|
|
5823
5822
|
if (!el || !strokeColor) return;
|
|
5824
5823
|
const paths = el.querySelectorAll("path, line, polyline, polygon, circle, ellipse, rect");
|
|
@@ -5826,7 +5825,7 @@ var AnimatedGraphic = React9__default.default.forwardRef(
|
|
|
5826
5825
|
p.style.stroke = strokeColor;
|
|
5827
5826
|
});
|
|
5828
5827
|
}, [resolvedSvg, strokeColor]);
|
|
5829
|
-
|
|
5828
|
+
React11.useEffect(() => {
|
|
5830
5829
|
const el = containerRef.current;
|
|
5831
5830
|
if (!el || !resolvedSvg) return;
|
|
5832
5831
|
if (animation === "draw" || animation === "fill") {
|
|
@@ -5851,7 +5850,7 @@ var AnimatedGraphic = React9__default.default.forwardRef(
|
|
|
5851
5850
|
});
|
|
5852
5851
|
}
|
|
5853
5852
|
}, [resolvedSvg, animation]);
|
|
5854
|
-
|
|
5853
|
+
React11.useEffect(() => {
|
|
5855
5854
|
const el = containerRef.current;
|
|
5856
5855
|
if (!el) return;
|
|
5857
5856
|
const id = requestAnimationFrame(() => {
|
|
@@ -6651,7 +6650,7 @@ var GeometricPattern = ({
|
|
|
6651
6650
|
children,
|
|
6652
6651
|
className
|
|
6653
6652
|
}) => {
|
|
6654
|
-
const reactId =
|
|
6653
|
+
const reactId = React11.useId();
|
|
6655
6654
|
const patternId = `gp${reactId.replace(/:/g, "")}`;
|
|
6656
6655
|
const size = 60 * scale;
|
|
6657
6656
|
const stripHeight = 40 * scale;
|
|
@@ -6886,7 +6885,7 @@ var EdgeDecoration = ({
|
|
|
6886
6885
|
width = 15,
|
|
6887
6886
|
className
|
|
6888
6887
|
}) => {
|
|
6889
|
-
const id =
|
|
6888
|
+
const id = React11.useId();
|
|
6890
6889
|
const Variant = VARIANT_MAP2[variant];
|
|
6891
6890
|
const resolvedColor = color in colorTokenVars2 ? colorTokenVars2[color] : color;
|
|
6892
6891
|
const sides = side === "both" ? ["left", "right"] : [side];
|
|
@@ -267,6 +267,8 @@ interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {
|
|
|
267
267
|
label?: string;
|
|
268
268
|
/** Disable the button (greys out, blocks click events) */
|
|
269
269
|
disabled?: boolean;
|
|
270
|
+
/** Test identifier for automated tests */
|
|
271
|
+
'data-testid'?: string;
|
|
270
272
|
}
|
|
271
273
|
declare const Button: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLButtonElement>>;
|
|
272
274
|
|