@luxfi/ui 7.3.2 → 7.4.2
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/alert.cjs +2 -2
- package/dist/alert.js +1 -1
- package/dist/avatar.cjs +7 -6
- package/dist/avatar.js +7 -5
- package/dist/badge.cjs +36 -38
- package/dist/badge.js +31 -33
- package/dist/bank.cjs +13 -13
- package/dist/bank.d.cts +31 -24
- package/dist/bank.d.ts +31 -24
- package/dist/bank.js +1 -1
- package/dist/button.cjs +3 -3
- package/dist/button.js +1 -1
- package/dist/checkbox.cjs +4 -4
- package/dist/checkbox.d.cts +3 -2
- package/dist/checkbox.d.ts +3 -2
- package/dist/checkbox.js +5 -4
- package/dist/chrome.cjs +950 -0
- package/dist/chrome.d.cts +93 -0
- package/dist/chrome.d.ts +93 -0
- package/dist/chrome.js +921 -0
- package/dist/close-button.cjs +2 -2
- package/dist/close-button.js +1 -1
- package/dist/dialog.cjs +13 -14
- package/dist/dialog.d.cts +58 -5
- package/dist/dialog.d.ts +58 -5
- package/dist/dialog.js +1 -2
- package/dist/drawer.cjs +87 -21
- package/dist/drawer.js +85 -19
- package/dist/expiration-selector.cjs +3 -2
- package/dist/expiration-selector.js +3 -2
- package/dist/greeks-display.cjs +6 -6
- package/dist/greeks-display.js +6 -6
- package/dist/gui.cjs +13 -0
- package/dist/gui.d.cts +2 -0
- package/dist/gui.d.ts +2 -0
- package/dist/gui.js +2 -0
- package/dist/heading.cjs +4 -2
- package/dist/heading.js +4 -2
- package/dist/iam.cjs +206 -0
- package/dist/iam.d.cts +65 -0
- package/dist/iam.d.ts +65 -0
- package/dist/iam.js +201 -0
- package/dist/icon-button.cjs +2 -2
- package/dist/icon-button.js +1 -1
- package/dist/icons.cjs +13 -0
- package/dist/icons.d.cts +1 -0
- package/dist/icons.d.ts +1 -0
- package/dist/icons.js +2 -0
- package/dist/identity.cjs +420 -0
- package/dist/identity.d.cts +64 -0
- package/dist/identity.d.ts +64 -0
- package/dist/identity.js +398 -0
- package/dist/index.cjs +1699 -860
- package/dist/index.d.cts +12 -4
- package/dist/index.d.ts +12 -4
- package/dist/index.js +1618 -802
- package/dist/input.cjs +13 -3
- package/dist/input.d.cts +6 -0
- package/dist/input.d.ts +6 -0
- package/dist/input.js +13 -3
- package/dist/lux.config.cjs +77 -0
- package/dist/lux.config.d.cts +433 -0
- package/dist/lux.config.d.ts +433 -0
- package/dist/lux.config.js +69 -0
- package/dist/menu.cjs +4 -4
- package/dist/menu.js +4 -4
- package/dist/next.cjs +99 -0
- package/dist/next.d.cts +29 -0
- package/dist/next.d.ts +29 -0
- package/dist/next.js +96 -0
- package/dist/option-chain.cjs +1 -1
- package/dist/option-chain.js +1 -1
- package/dist/option-position.cjs +2 -1
- package/dist/option-position.js +2 -1
- package/dist/pnl-diagram.cjs +8 -6
- package/dist/pnl-diagram.js +8 -6
- package/dist/popover.cjs +8 -9
- package/dist/popover.js +1 -2
- package/dist/progress.cjs +7 -6
- package/dist/progress.js +7 -5
- package/dist/provider.cjs +199 -5
- package/dist/provider.d.cts +16 -3
- package/dist/provider.d.ts +16 -3
- package/dist/provider.js +195 -6
- package/dist/radio.cjs +9 -7
- package/dist/radio.js +10 -7
- package/dist/separator.cjs +3 -1
- package/dist/separator.js +3 -1
- package/dist/slider.cjs +28 -16
- package/dist/slider.js +28 -15
- package/dist/strategy-builder.cjs +2 -1
- package/dist/strategy-builder.js +2 -1
- package/dist/switch.cjs +11 -12
- package/dist/switch.js +12 -12
- package/dist/tag.cjs +38 -41
- package/dist/tag.js +31 -34
- package/dist/textarea.cjs +13 -3
- package/dist/textarea.d.cts +2 -0
- package/dist/textarea.d.ts +2 -0
- package/dist/textarea.js +13 -3
- package/dist/tooltip.cjs +31 -33
- package/dist/tooltip.js +25 -27
- package/dist/use-narrow.cjs +46 -0
- package/dist/use-narrow.d.cts +12 -0
- package/dist/use-narrow.d.ts +12 -0
- package/dist/use-narrow.js +20 -0
- package/dist/vite.cjs +40 -0
- package/dist/vite.d.cts +29 -0
- package/dist/vite.d.ts +29 -0
- package/dist/vite.js +38 -0
- package/dist/white-label.cjs +132 -0
- package/dist/white-label.d.cts +59 -0
- package/dist/white-label.d.ts +59 -0
- package/dist/white-label.js +124 -0
- package/package.json +95 -17
- package/src/avatar.tsx +22 -16
- package/src/bank.tsx +2 -2
- package/src/button.tsx +1 -1
- package/src/checkbox.tsx +15 -10
- package/src/chrome.tsx +459 -0
- package/src/close-button.tsx +1 -1
- package/src/dialog.tsx +1 -1
- package/src/drawer.tsx +83 -10
- package/src/expiration-selector.tsx +3 -2
- package/src/greeks-display.tsx +9 -6
- package/src/gui.ts +17 -0
- package/src/heading.tsx +12 -8
- package/src/iam.ts +170 -0
- package/src/icon-button.tsx +1 -1
- package/src/icons.ts +18 -0
- package/src/identity.tsx +318 -0
- package/src/index.ts +50 -1
- package/src/input.tsx +24 -4
- package/src/lux.config.ts +82 -0
- package/src/menu.tsx +4 -4
- package/src/next.ts +142 -0
- package/src/option-chain.tsx +1 -1
- package/src/option-position.tsx +2 -1
- package/src/pnl-diagram.tsx +11 -6
- package/src/popover.tsx +1 -1
- package/src/progress.tsx +15 -8
- package/src/provider.tsx +92 -12
- package/src/radio.tsx +15 -11
- package/src/separator.tsx +8 -3
- package/src/slider.tsx +35 -19
- package/src/strategy-builder.tsx +3 -2
- package/src/switch.tsx +17 -16
- package/src/textarea.tsx +18 -4
- package/src/tooltip.tsx +4 -23
- package/src/use-narrow.ts +40 -0
- package/src/vite.ts +78 -0
- package/src/white-label.ts +240 -0
- package/tokens.css +544 -319
- package/src/tokens.css +0 -438
package/dist/bank.d.cts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import * as _hanzogui_core from '@hanzogui/core';
|
|
3
|
-
import
|
|
3
|
+
import * as _hanzogui_web from '@hanzogui/web';
|
|
4
4
|
import React__default from 'react';
|
|
5
|
+
import { GetProps } from '@hanzo/gui';
|
|
5
6
|
|
|
6
7
|
declare const bankColors: {
|
|
7
8
|
readonly bg: "#000000";
|
|
@@ -26,51 +27,57 @@ declare const bankColors: {
|
|
|
26
27
|
readonly divider: "#222222";
|
|
27
28
|
readonly disabled: "#444444";
|
|
28
29
|
};
|
|
29
|
-
declare const BankCard:
|
|
30
|
+
declare const BankCard: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiElement, _hanzogui_core.RNViewNonStyleProps, _hanzogui_web.StackStyleBase, {
|
|
30
31
|
size?: "sm" | "md" | "lg" | undefined;
|
|
31
|
-
},
|
|
32
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
32
33
|
type BankCardProps = GetProps<typeof BankCard>;
|
|
33
|
-
declare const BankInput:
|
|
34
|
+
declare const BankInput: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiTextElement, _hanzogui_core.RNTextNonStyleProps, _hanzogui_web.TextStylePropsBase, {
|
|
34
35
|
size?: "sm" | "md" | "lg" | undefined;
|
|
36
|
+
unstyled?: boolean | undefined;
|
|
35
37
|
invalid?: boolean | undefined;
|
|
36
|
-
},
|
|
38
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
37
39
|
type BankInputProps = GetProps<typeof BankInput> & {
|
|
38
40
|
placeholderTextColor?: string;
|
|
39
41
|
};
|
|
40
|
-
declare const BankButton:
|
|
41
|
-
variant?: "primary" | "secondary" | "ghost" | undefined;
|
|
42
|
+
declare const BankButton: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiElement, _hanzogui_core.RNViewNonStyleProps, _hanzogui_web.StackStyleBase, {
|
|
42
43
|
disabled?: boolean | undefined;
|
|
43
|
-
}, _hanzogui_core.StaticConfigPublic>;
|
|
44
|
-
declare const BankButtonText: _hanzogui_core.GuiComponent<_hanzogui_core.TamaDefer, _hanzogui_core.GuiTextElement, _hanzogui_core.RNGuiTextNonStyleProps, _hanzogui_core.TextStylePropsBase, {
|
|
45
44
|
variant?: "primary" | "secondary" | "ghost" | undefined;
|
|
46
|
-
},
|
|
45
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
46
|
+
declare const BankButtonText: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiTextElement, _hanzogui_core.RNTextNonStyleProps, _hanzogui_web.TextStylePropsBase, {
|
|
47
|
+
unstyled?: boolean | undefined;
|
|
48
|
+
variant?: "primary" | "secondary" | "ghost" | undefined;
|
|
49
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
47
50
|
type BankButtonProps = GetProps<typeof BankButton>;
|
|
48
|
-
declare const BankHeading:
|
|
49
|
-
size?: "
|
|
50
|
-
|
|
51
|
+
declare const BankHeading: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiTextElement, _hanzogui_core.RNTextNonStyleProps, _hanzogui_web.TextStylePropsBase, {
|
|
52
|
+
size?: "xs" | "sm" | "md" | "lg" | "xl" | undefined;
|
|
53
|
+
unstyled?: boolean | undefined;
|
|
54
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
51
55
|
type BankHeadingProps = GetProps<typeof BankHeading>;
|
|
52
|
-
declare const BankText:
|
|
53
|
-
|
|
54
|
-
|
|
56
|
+
declare const BankText: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiTextElement, _hanzogui_core.RNTextNonStyleProps, _hanzogui_web.TextStylePropsBase, {
|
|
57
|
+
unstyled?: boolean | undefined;
|
|
58
|
+
variant?: "default" | "label" | "link" | "error" | "success" | "muted" | undefined;
|
|
59
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
55
60
|
type BankTextProps = GetProps<typeof BankText>;
|
|
56
61
|
declare function BankField({ label, error, children, }: {
|
|
57
62
|
label?: string;
|
|
58
63
|
error?: string;
|
|
59
64
|
children: React__default.ReactNode;
|
|
60
65
|
}): react_jsx_runtime.JSX.Element;
|
|
61
|
-
declare const BankAlert:
|
|
66
|
+
declare const BankAlert: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiElement, _hanzogui_core.RNViewNonStyleProps, _hanzogui_web.StackStyleBase, {
|
|
62
67
|
status?: "error" | "success" | undefined;
|
|
63
|
-
},
|
|
64
|
-
declare const BankAlertText:
|
|
68
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
69
|
+
declare const BankAlertText: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiTextElement, _hanzogui_core.RNTextNonStyleProps, _hanzogui_web.TextStylePropsBase, {
|
|
65
70
|
status?: "error" | "success" | undefined;
|
|
66
|
-
|
|
71
|
+
unstyled?: boolean | undefined;
|
|
72
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
67
73
|
type BankAlertProps = GetProps<typeof BankAlert>;
|
|
68
|
-
declare const BankPinBox:
|
|
74
|
+
declare const BankPinBox: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiTextElement, _hanzogui_core.RNTextNonStyleProps, _hanzogui_web.TextStylePropsBase, {
|
|
75
|
+
unstyled?: boolean | undefined;
|
|
69
76
|
invalid?: boolean | undefined;
|
|
70
|
-
},
|
|
77
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
71
78
|
type BankPinBoxProps = GetProps<typeof BankPinBox>;
|
|
72
|
-
declare const BankDivider:
|
|
73
|
-
declare const BankPage:
|
|
79
|
+
declare const BankDivider: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiElement, _hanzogui_core.RNViewNonStyleProps, _hanzogui_web.StackStyleBase, {}, _hanzogui_web.StaticConfigPublic>;
|
|
80
|
+
declare const BankPage: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiElement, _hanzogui_core.RNViewNonStyleProps, _hanzogui_web.StackStyleBase, {}, _hanzogui_web.StaticConfigPublic>;
|
|
74
81
|
type BankPageProps = GetProps<typeof BankPage>;
|
|
75
82
|
|
|
76
83
|
export { BankAlert, type BankAlertProps, BankAlertText, BankButton, type BankButtonProps, BankButtonText, BankCard, type BankCardProps, BankDivider, BankField, BankHeading, type BankHeadingProps, BankInput, type BankInputProps, BankPage, type BankPageProps, BankPinBox, type BankPinBoxProps, BankText, type BankTextProps, bankColors };
|
package/dist/bank.d.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import * as _hanzogui_core from '@hanzogui/core';
|
|
3
|
-
import
|
|
3
|
+
import * as _hanzogui_web from '@hanzogui/web';
|
|
4
4
|
import React__default from 'react';
|
|
5
|
+
import { GetProps } from '@hanzo/gui';
|
|
5
6
|
|
|
6
7
|
declare const bankColors: {
|
|
7
8
|
readonly bg: "#000000";
|
|
@@ -26,51 +27,57 @@ declare const bankColors: {
|
|
|
26
27
|
readonly divider: "#222222";
|
|
27
28
|
readonly disabled: "#444444";
|
|
28
29
|
};
|
|
29
|
-
declare const BankCard:
|
|
30
|
+
declare const BankCard: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiElement, _hanzogui_core.RNViewNonStyleProps, _hanzogui_web.StackStyleBase, {
|
|
30
31
|
size?: "sm" | "md" | "lg" | undefined;
|
|
31
|
-
},
|
|
32
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
32
33
|
type BankCardProps = GetProps<typeof BankCard>;
|
|
33
|
-
declare const BankInput:
|
|
34
|
+
declare const BankInput: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiTextElement, _hanzogui_core.RNTextNonStyleProps, _hanzogui_web.TextStylePropsBase, {
|
|
34
35
|
size?: "sm" | "md" | "lg" | undefined;
|
|
36
|
+
unstyled?: boolean | undefined;
|
|
35
37
|
invalid?: boolean | undefined;
|
|
36
|
-
},
|
|
38
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
37
39
|
type BankInputProps = GetProps<typeof BankInput> & {
|
|
38
40
|
placeholderTextColor?: string;
|
|
39
41
|
};
|
|
40
|
-
declare const BankButton:
|
|
41
|
-
variant?: "primary" | "secondary" | "ghost" | undefined;
|
|
42
|
+
declare const BankButton: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiElement, _hanzogui_core.RNViewNonStyleProps, _hanzogui_web.StackStyleBase, {
|
|
42
43
|
disabled?: boolean | undefined;
|
|
43
|
-
}, _hanzogui_core.StaticConfigPublic>;
|
|
44
|
-
declare const BankButtonText: _hanzogui_core.GuiComponent<_hanzogui_core.TamaDefer, _hanzogui_core.GuiTextElement, _hanzogui_core.RNGuiTextNonStyleProps, _hanzogui_core.TextStylePropsBase, {
|
|
45
44
|
variant?: "primary" | "secondary" | "ghost" | undefined;
|
|
46
|
-
},
|
|
45
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
46
|
+
declare const BankButtonText: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiTextElement, _hanzogui_core.RNTextNonStyleProps, _hanzogui_web.TextStylePropsBase, {
|
|
47
|
+
unstyled?: boolean | undefined;
|
|
48
|
+
variant?: "primary" | "secondary" | "ghost" | undefined;
|
|
49
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
47
50
|
type BankButtonProps = GetProps<typeof BankButton>;
|
|
48
|
-
declare const BankHeading:
|
|
49
|
-
size?: "
|
|
50
|
-
|
|
51
|
+
declare const BankHeading: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiTextElement, _hanzogui_core.RNTextNonStyleProps, _hanzogui_web.TextStylePropsBase, {
|
|
52
|
+
size?: "xs" | "sm" | "md" | "lg" | "xl" | undefined;
|
|
53
|
+
unstyled?: boolean | undefined;
|
|
54
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
51
55
|
type BankHeadingProps = GetProps<typeof BankHeading>;
|
|
52
|
-
declare const BankText:
|
|
53
|
-
|
|
54
|
-
|
|
56
|
+
declare const BankText: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiTextElement, _hanzogui_core.RNTextNonStyleProps, _hanzogui_web.TextStylePropsBase, {
|
|
57
|
+
unstyled?: boolean | undefined;
|
|
58
|
+
variant?: "default" | "label" | "link" | "error" | "success" | "muted" | undefined;
|
|
59
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
55
60
|
type BankTextProps = GetProps<typeof BankText>;
|
|
56
61
|
declare function BankField({ label, error, children, }: {
|
|
57
62
|
label?: string;
|
|
58
63
|
error?: string;
|
|
59
64
|
children: React__default.ReactNode;
|
|
60
65
|
}): react_jsx_runtime.JSX.Element;
|
|
61
|
-
declare const BankAlert:
|
|
66
|
+
declare const BankAlert: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiElement, _hanzogui_core.RNViewNonStyleProps, _hanzogui_web.StackStyleBase, {
|
|
62
67
|
status?: "error" | "success" | undefined;
|
|
63
|
-
},
|
|
64
|
-
declare const BankAlertText:
|
|
68
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
69
|
+
declare const BankAlertText: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiTextElement, _hanzogui_core.RNTextNonStyleProps, _hanzogui_web.TextStylePropsBase, {
|
|
65
70
|
status?: "error" | "success" | undefined;
|
|
66
|
-
|
|
71
|
+
unstyled?: boolean | undefined;
|
|
72
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
67
73
|
type BankAlertProps = GetProps<typeof BankAlert>;
|
|
68
|
-
declare const BankPinBox:
|
|
74
|
+
declare const BankPinBox: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiTextElement, _hanzogui_core.RNTextNonStyleProps, _hanzogui_web.TextStylePropsBase, {
|
|
75
|
+
unstyled?: boolean | undefined;
|
|
69
76
|
invalid?: boolean | undefined;
|
|
70
|
-
},
|
|
77
|
+
}, _hanzogui_web.StaticConfigPublic>;
|
|
71
78
|
type BankPinBoxProps = GetProps<typeof BankPinBox>;
|
|
72
|
-
declare const BankDivider:
|
|
73
|
-
declare const BankPage:
|
|
79
|
+
declare const BankDivider: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiElement, _hanzogui_core.RNViewNonStyleProps, _hanzogui_web.StackStyleBase, {}, _hanzogui_web.StaticConfigPublic>;
|
|
80
|
+
declare const BankPage: _hanzogui_web.GuiComponent<_hanzogui_web.TamaDefer, _hanzogui_web.GuiElement, _hanzogui_core.RNViewNonStyleProps, _hanzogui_web.StackStyleBase, {}, _hanzogui_web.StaticConfigPublic>;
|
|
74
81
|
type BankPageProps = GetProps<typeof BankPage>;
|
|
75
82
|
|
|
76
83
|
export { BankAlert, type BankAlertProps, BankAlertText, BankButton, type BankButtonProps, BankButtonText, BankCard, type BankCardProps, BankDivider, BankField, BankHeading, type BankHeadingProps, BankInput, type BankInputProps, BankPage, type BankPageProps, BankPinBox, type BankPinBoxProps, BankText, type BankTextProps, bankColors };
|
package/dist/bank.js
CHANGED
package/dist/button.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var gui = require('@hanzo/gui');
|
|
5
5
|
var React2 = require('react');
|
|
6
6
|
var clsx = require('clsx');
|
|
7
7
|
var tailwindMerge = require('tailwind-merge');
|
|
@@ -218,7 +218,7 @@ React2__namespace.forwardRef(
|
|
|
218
218
|
)) });
|
|
219
219
|
}
|
|
220
220
|
);
|
|
221
|
-
var SpinnerFrame =
|
|
221
|
+
var SpinnerFrame = gui.styled(gui.View, {
|
|
222
222
|
name: "ButtonSpinner",
|
|
223
223
|
render: /* @__PURE__ */ jsxRuntime.jsx("span", {}),
|
|
224
224
|
width: 16,
|
|
@@ -242,7 +242,7 @@ function Spinner({ className }) {
|
|
|
242
242
|
}
|
|
243
243
|
);
|
|
244
244
|
}
|
|
245
|
-
var ButtonFrame =
|
|
245
|
+
var ButtonFrame = gui.styled(gui.View, {
|
|
246
246
|
name: "LuxButton",
|
|
247
247
|
render: /* @__PURE__ */ jsxRuntime.jsx("button", { type: "button" }),
|
|
248
248
|
role: "button",
|
package/dist/button.js
CHANGED
package/dist/checkbox.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var gui = require('@hanzo/gui');
|
|
5
5
|
var React = require('react');
|
|
6
6
|
var clsx = require('clsx');
|
|
7
7
|
var tailwindMerge = require('tailwind-merge');
|
|
@@ -25,7 +25,6 @@ function _interopNamespace(e) {
|
|
|
25
25
|
return Object.freeze(n);
|
|
26
26
|
}
|
|
27
27
|
|
|
28
|
-
var RadixCheckbox__namespace = /*#__PURE__*/_interopNamespace(RadixCheckbox);
|
|
29
28
|
var React__namespace = /*#__PURE__*/_interopNamespace(React);
|
|
30
29
|
|
|
31
30
|
// src/checkbox.tsx
|
|
@@ -214,8 +213,9 @@ var CheckboxBase = React__namespace.forwardRef(
|
|
|
214
213
|
...rest,
|
|
215
214
|
children: [
|
|
216
215
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
217
|
-
|
|
216
|
+
gui.Checkbox,
|
|
218
217
|
{
|
|
218
|
+
unstyled: true,
|
|
219
219
|
checked: checkedState,
|
|
220
220
|
onCheckedChange: handleCheckedChange,
|
|
221
221
|
disabled: disabled || readOnly,
|
|
@@ -233,7 +233,7 @@ var CheckboxBase = React__namespace.forwardRef(
|
|
|
233
233
|
"transition-colors duration-150",
|
|
234
234
|
sizeClasses.control
|
|
235
235
|
),
|
|
236
|
-
children: icon ?? /* @__PURE__ */ jsxRuntime.jsx(
|
|
236
|
+
children: icon ?? /* @__PURE__ */ jsxRuntime.jsx(gui.Checkbox.Indicator, { className: cn("flex items-center justify-center", sizeClasses.icon), children: checkedState === "indeterminate" ? /* @__PURE__ */ jsxRuntime.jsx(IndeterminateIcon, { className: sizeClasses.icon }) : /* @__PURE__ */ jsxRuntime.jsx(CheckIcon, { className: sizeClasses.icon }) })
|
|
237
237
|
}
|
|
238
238
|
),
|
|
239
239
|
/* @__PURE__ */ jsxRuntime.jsx(
|
package/dist/checkbox.d.cts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import * as RadixCheckbox from '@radix-ui/react-checkbox';
|
|
2
1
|
import * as React from 'react';
|
|
3
2
|
|
|
3
|
+
/** Tri-state, as the Chakra/Radix contract consumers already code against. */
|
|
4
|
+
type CheckedState = boolean | 'indeterminate';
|
|
4
5
|
interface CheckboxGroupProps extends React.ComponentPropsWithoutRef<'div'> {
|
|
5
6
|
value?: Array<string>;
|
|
6
7
|
defaultValue?: Array<string>;
|
|
@@ -17,7 +18,7 @@ interface CheckboxProps extends Omit<React.ComponentPropsWithoutRef<'label'>, 'o
|
|
|
17
18
|
rootRef?: React.Ref<HTMLLabelElement>;
|
|
18
19
|
checked?: boolean | 'indeterminate';
|
|
19
20
|
defaultChecked?: boolean;
|
|
20
|
-
onCheckedChange?: (checked:
|
|
21
|
+
onCheckedChange?: (checked: CheckedState) => void;
|
|
21
22
|
onChange?: React.FormEventHandler<HTMLLabelElement>;
|
|
22
23
|
disabled?: boolean;
|
|
23
24
|
readOnly?: boolean;
|
package/dist/checkbox.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import * as RadixCheckbox from '@radix-ui/react-checkbox';
|
|
2
1
|
import * as React from 'react';
|
|
3
2
|
|
|
3
|
+
/** Tri-state, as the Chakra/Radix contract consumers already code against. */
|
|
4
|
+
type CheckedState = boolean | 'indeterminate';
|
|
4
5
|
interface CheckboxGroupProps extends React.ComponentPropsWithoutRef<'div'> {
|
|
5
6
|
value?: Array<string>;
|
|
6
7
|
defaultValue?: Array<string>;
|
|
@@ -17,7 +18,7 @@ interface CheckboxProps extends Omit<React.ComponentPropsWithoutRef<'label'>, 'o
|
|
|
17
18
|
rootRef?: React.Ref<HTMLLabelElement>;
|
|
18
19
|
checked?: boolean | 'indeterminate';
|
|
19
20
|
defaultChecked?: boolean;
|
|
20
|
-
onCheckedChange?: (checked:
|
|
21
|
+
onCheckedChange?: (checked: CheckedState) => void;
|
|
21
22
|
onChange?: React.FormEventHandler<HTMLLabelElement>;
|
|
22
23
|
disabled?: boolean;
|
|
23
24
|
readOnly?: boolean;
|
package/dist/checkbox.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import
|
|
2
|
+
import { Checkbox } from '@hanzo/gui';
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import { clsx } from 'clsx';
|
|
5
5
|
import { twMerge } from 'tailwind-merge';
|
|
@@ -104,7 +104,7 @@ var IndeterminateIcon = ({ className }) => /* @__PURE__ */ jsx(
|
|
|
104
104
|
}
|
|
105
105
|
);
|
|
106
106
|
var CheckboxBase = React.forwardRef(
|
|
107
|
-
function Checkbox(props, ref) {
|
|
107
|
+
function Checkbox$1(props, ref) {
|
|
108
108
|
const {
|
|
109
109
|
icon,
|
|
110
110
|
children,
|
|
@@ -191,8 +191,9 @@ var CheckboxBase = React.forwardRef(
|
|
|
191
191
|
...rest,
|
|
192
192
|
children: [
|
|
193
193
|
/* @__PURE__ */ jsx(
|
|
194
|
-
|
|
194
|
+
Checkbox,
|
|
195
195
|
{
|
|
196
|
+
unstyled: true,
|
|
196
197
|
checked: checkedState,
|
|
197
198
|
onCheckedChange: handleCheckedChange,
|
|
198
199
|
disabled: disabled || readOnly,
|
|
@@ -210,7 +211,7 @@ var CheckboxBase = React.forwardRef(
|
|
|
210
211
|
"transition-colors duration-150",
|
|
211
212
|
sizeClasses.control
|
|
212
213
|
),
|
|
213
|
-
children: icon ?? /* @__PURE__ */ jsx(
|
|
214
|
+
children: icon ?? /* @__PURE__ */ jsx(Checkbox.Indicator, { className: cn("flex items-center justify-center", sizeClasses.icon), children: checkedState === "indeterminate" ? /* @__PURE__ */ jsx(IndeterminateIcon, { className: sizeClasses.icon }) : /* @__PURE__ */ jsx(CheckIcon, { className: sizeClasses.icon }) })
|
|
214
215
|
}
|
|
215
216
|
),
|
|
216
217
|
/* @__PURE__ */ jsx(
|