@vireo-ai/trellis-ui 0.1.9 → 0.1.11
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/package.json +9 -5
- package/packages/client/src/components/app/styles.css +1 -30
- package/packages/client/src/components/button/styles.css +1 -122
- package/packages/client/src/components/date-picker/styles.css +47 -77
- package/packages/client/src/components/field/styles.css +10 -0
- package/packages/client/src/components/file-upload/styles.css +0 -28
- package/packages/client/src/components/panels/styles.css +43 -0
- package/packages/client/src/components/radio/styles.css +26 -21
- package/packages/client/src/components/scroll-area/styles.css +0 -4
- package/packages/client/src/components/select/styles.css +0 -30
- package/packages/client/src/components/sidebar/styles.css +8 -0
- package/packages/client/src/components/tabs/styles.css +199 -0
- package/packages/client/src/components/toast/styles.css +14 -7
- package/packages/client/src/styles/components.css +2 -0
- package/packages/client/src/styles/generated/theme-fonts.css +5 -0
- package/packages/client/src/styles/generated/theme-palette.css +2656 -0
- package/packages/client/src/styles/generated/theme-runtime.css +2966 -0
- package/packages/client/src/styles/generated-sources.css +1 -1
- package/packages/client/src/styles/static.css +1 -0
- package/packages/client/src/styles/theme.css +777 -738
- package/packages/client/types/cdn.d.ts +1 -4
- package/packages/client/types/component-api.d.ts +21 -0
- package/packages/client/types/components/accordion/contract.d.ts +3 -2
- package/packages/client/types/components/accordion/index.d.ts +28 -42
- package/packages/client/types/components/accordion/machine.d.ts +131 -0
- package/packages/client/types/components/accordion/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/action/contract.d.ts +3 -3
- package/packages/client/types/components/app/contract.d.ts +25 -12
- package/packages/client/types/components/app/index.d.ts +2 -2
- package/packages/client/types/components/badge/contract.d.ts +5 -5
- package/packages/client/types/components/box/contract.d.ts +25 -28
- package/packages/client/types/components/brand/contract.d.ts +2 -2
- package/packages/client/types/components/button/contract.d.ts +5 -5
- package/packages/client/types/components/card/contract.d.ts +28 -31
- package/packages/client/types/components/checkbox/contract.d.ts +17 -17
- package/packages/client/types/components/checkbox/index.d.ts +20 -26
- package/packages/client/types/components/checkbox/machine.d.ts +41 -0
- package/packages/client/types/components/checkbox/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/common.d.ts +53 -235
- package/packages/client/types/components/container/contract.d.ts +11 -12
- package/packages/client/types/components/date-picker/contract.d.ts +21 -16
- package/packages/client/types/components/date-picker/index.d.ts +38 -60
- package/packages/client/types/components/date-picker/machine.d.ts +529 -0
- package/packages/client/types/components/date-picker/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/date-picker/value.d.ts +28 -0
- package/packages/client/types/components/dropdown/contract.d.ts +4 -4
- package/packages/client/types/components/dropdown/index.d.ts +20 -45
- package/packages/client/types/components/dropdown/machine.d.ts +93 -0
- package/packages/client/types/components/dropdown/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/field/contract.d.ts +10 -6
- package/packages/client/types/components/field/index.d.ts +6 -6
- package/packages/client/types/components/field/machine.d.ts +13 -0
- package/packages/client/types/components/field/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/file-upload/contract.d.ts +7 -4
- package/packages/client/types/components/file-upload/index.d.ts +34 -31
- package/packages/client/types/components/file-upload/machine.d.ts +127 -0
- package/packages/client/types/components/file-upload/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/flex/contract.d.ts +16 -17
- package/packages/client/types/components/frame/contract.d.ts +41 -47
- package/packages/client/types/components/frame/index.d.ts +2 -2
- package/packages/client/types/components/grid/contract.d.ts +20 -21
- package/packages/client/types/components/heading/contract.d.ts +1 -1
- package/packages/client/types/components/image/contract.d.ts +3 -3
- package/packages/client/types/components/input/contract.d.ts +2 -2
- package/packages/client/types/components/input/index.d.ts +15 -12
- package/packages/client/types/components/input/machine.d.ts +20 -0
- package/packages/client/types/components/layout.d.ts +44 -225
- package/packages/client/types/components/menu/contract.d.ts +14 -8
- package/packages/client/types/components/modal/contract.d.ts +12 -12
- package/packages/client/types/components/modal/index.d.ts +41 -75
- package/packages/client/types/components/modal/machine.d.ts +129 -0
- package/packages/client/types/components/modal/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/overlay/contract.d.ts +3 -3
- package/packages/client/types/components/panels/contract.d.ts +39 -0
- package/packages/client/types/components/panels/index.d.ts +54 -0
- package/packages/client/types/components/panels/machine.d.ts +151 -0
- package/packages/client/types/components/panels/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/radio/contract.d.ts +11 -11
- package/packages/client/types/components/radio/index.d.ts +19 -23
- package/packages/client/types/components/radio/machine.d.ts +40 -0
- package/packages/client/types/components/radio/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/runtime.d.ts +16 -19
- package/packages/client/types/components/scroll-area/contract.d.ts +4 -7
- package/packages/client/types/components/scroll-area/index.d.ts +23 -49
- package/packages/client/types/components/scroll-area/machine.d.ts +21 -0
- package/packages/client/types/components/scroll-area/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/section/contract.d.ts +12 -13
- package/packages/client/types/components/select/contract.d.ts +19 -15
- package/packages/client/types/components/select/index.d.ts +42 -89
- package/packages/client/types/components/select/machine.d.ts +476 -0
- package/packages/client/types/components/select/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/shared/controlled-open.d.ts +11 -0
- package/packages/client/types/components/sidebar/contract.d.ts +19 -12
- package/packages/client/types/components/sidebar/index.d.ts +51 -88
- package/packages/client/types/components/sidebar/machine.d.ts +100 -0
- package/packages/client/types/components/sidebar/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/slider/contract.d.ts +3 -3
- package/packages/client/types/components/slider/index.d.ts +17 -21
- package/packages/client/types/components/slider/machine.d.ts +37 -0
- package/packages/client/types/components/slider/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/stack/contract.d.ts +16 -17
- package/packages/client/types/components/surface-manifest.d.ts +9 -0
- package/packages/client/types/components/switch/contract.d.ts +11 -11
- package/packages/client/types/components/switch/index.d.ts +13 -18
- package/packages/client/types/components/switch/machine.d.ts +19 -0
- package/packages/client/types/components/switch/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/table/contract.d.ts +18 -18
- package/packages/client/types/components/tabs/contract.d.ts +10 -5
- package/packages/client/types/components/tabs/index.d.ts +33 -51
- package/packages/client/types/components/tabs/machine.d.ts +85 -0
- package/packages/client/types/components/tabs/runtime-docs.d.ts +2 -0
- package/packages/client/types/components/text/contract.d.ts +1 -1
- package/packages/client/types/components/textarea/contract.d.ts +2 -2
- package/packages/client/types/components/toast/contract.d.ts +5 -4
- package/packages/client/types/components/toast/index.d.ts +38 -12
- package/packages/client/types/components/toast/machine.d.ts +115 -0
- package/packages/client/types/components/toast/runtime-docs.d.ts +2 -0
- package/packages/client/types/directives/index.d.ts +3 -1
- package/packages/client/types/directives/layout.d.ts +3 -0
- package/packages/client/types/directives/request.d.ts +1 -2
- package/packages/client/types/directives/transition.d.ts +3 -0
- package/packages/client/types/docs/transition-docs.d.ts +30 -0
- package/packages/client/types/index.d.ts +8 -40
- package/packages/client/types/motion/animate.d.ts +5 -44
- package/packages/client/types/motion/controller.d.ts +33 -0
- package/packages/client/types/motion/index.d.ts +43 -20
- package/packages/client/types/motion/owned.d.ts +5 -0
- package/packages/client/types/motion/plan.d.ts +46 -0
- package/packages/client/types/motion/recipe.d.ts +56 -0
- package/packages/client/types/motion/registry.d.ts +12 -0
- package/packages/client/types/motion/resize.d.ts +15 -0
- package/packages/client/types/motion/subject.d.ts +10 -0
- package/packages/client/types/motion/targets.d.ts +2 -5
- package/packages/client/types/motion/view.d.ts +7 -2
- package/packages/client/types/runtime/alpine-machine.d.ts +69 -0
- package/packages/client/types/runtime/anchored-popover.d.ts +10 -2
- package/packages/client/types/runtime/codecs.d.ts +16 -2
- package/packages/client/types/runtime/{resizable.d.ts → drag-and-drop/index.d.ts} +4 -2
- package/packages/client/types/runtime/engine/request.d.ts +2 -2
- package/packages/client/types/runtime/engine/stream.d.ts +17 -9
- package/packages/client/types/runtime/focus-scope.d.ts +7 -0
- package/packages/client/types/runtime/identity.d.ts +3 -0
- package/packages/client/types/runtime/index.d.ts +9 -75
- package/packages/client/types/runtime/merge-bindings.d.ts +1 -1
- package/packages/client/types/runtime/semantic-observer.d.ts +10 -0
- package/packages/client/types/runtime/state-machine/index.d.ts +4 -0
- package/packages/client/types/runtime/state-machine/machine.d.ts +83 -0
- package/packages/client/types/runtime/state-machine/props-change.d.ts +12 -0
- package/packages/client/types/runtime/transition-coordinator.d.ts +52 -0
- package/packages/client/types/runtime/ui.d.ts +15 -0
- package/packages/client/types/utils/index.d.ts +2 -1
- package/packages/client/types/utils/number.d.ts +2 -0
- package/packages/client/types/utils/object.d.ts +4 -1
- package/packages/server/trellis_ui/static/trellis_ui/assets/css/trellis.css +8872 -2159
- package/packages/server/trellis_ui/static/trellis_ui/assets/css/trellis.min.css +1 -1
- package/packages/server/trellis_ui/static/trellis_ui/assets/js/esm/index.js +17176 -13340
- package/packages/server/trellis_ui/static/trellis_ui/assets/js/esm/index.js.map +1 -1
- package/packages/server/trellis_ui/static/trellis_ui/assets/js/trellis.js +8 -13
- package/packages/server/trellis_ui/static/trellis_ui/assets/js/trellis.min.js +8 -13
- package/packages/client/types/bindings/disclosure.d.ts +0 -3
- package/packages/client/types/bindings/index.d.ts +0 -7
- package/packages/client/types/bindings/motion.d.ts +0 -3
- package/packages/client/types/bindings/state.d.ts +0 -3
- package/packages/client/types/bindings/types.d.ts +0 -33
- package/packages/client/types/components/combobox/contract.d.ts +0 -60
- package/packages/client/types/components/combobox/index.d.ts +0 -80
- package/packages/client/types/components/textarea/index.d.ts +0 -13
- package/packages/client/types/motion/presence.d.ts +0 -34
- package/packages/client/types/runtime/class-name.d.ts +0 -9
- package/packages/client/types/runtime/create.d.ts +0 -8
- package/packages/client/types/runtime/machine.d.ts +0 -55
- package/packages/server/trellis_ui/static/trellis_ui/assets/js/esm/chunks/cally-TZl4LpyH.js +0 -1134
- package/packages/server/trellis_ui/static/trellis_ui/assets/js/esm/chunks/cally-TZl4LpyH.js.map +0 -1
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
import { type Machine } from '../../runtime/state-machine';
|
|
2
|
+
import type { ModalProps } from './contract';
|
|
3
|
+
type ModalContext = Record<string, never>;
|
|
4
|
+
type ModalMachineEffects = {
|
|
5
|
+
prepareOpen(): void;
|
|
6
|
+
finishOpen(): void;
|
|
7
|
+
prepareClose(): void;
|
|
8
|
+
finishClose(): void;
|
|
9
|
+
syncProps(): void;
|
|
10
|
+
emitCancel(reason: 'escape' | 'outside'): void;
|
|
11
|
+
};
|
|
12
|
+
type CreateModalMachineOptions = {
|
|
13
|
+
props: ModalProps;
|
|
14
|
+
effects: ModalMachineEffects;
|
|
15
|
+
};
|
|
16
|
+
declare const modalHooks: readonly [Readonly<{
|
|
17
|
+
name: "opening";
|
|
18
|
+
state: string;
|
|
19
|
+
onDone: string;
|
|
20
|
+
onError: string;
|
|
21
|
+
required?: boolean;
|
|
22
|
+
sends?: Record<string, import("../..").TransitionEventCreator>;
|
|
23
|
+
project?: (snapshot: Readonly<{
|
|
24
|
+
value: import("../..").MachineStateValue;
|
|
25
|
+
tags: readonly string[];
|
|
26
|
+
context: Readonly<ModalContext>;
|
|
27
|
+
props: Readonly<import("../..").SchemaToProps<{
|
|
28
|
+
name: import("../../runtime/codecs").StringCodec;
|
|
29
|
+
open: import("../../runtime/codecs").BoolCodec;
|
|
30
|
+
mode: import("../../runtime/codecs").OneOfCodec<"modal" | "sheet">;
|
|
31
|
+
side: import("../../runtime/codecs").OneOfCodec<"top" | "bottom" | "left" | "right">;
|
|
32
|
+
size: import("../../runtime/codecs").OneOfCodec<"sm" | "md" | "lg" | "full" | "xl">;
|
|
33
|
+
surface: import("../../runtime/codecs").OneOfCodec<"1" | "0" | "2" | "inherit" | "3" | "4" | "5" | "6" | "7" | "8" | "+1" | "+2" | "+3" | "+4" | "+5" | "+6" | "+7" | "+8">;
|
|
34
|
+
elevation: import("../../runtime/codecs").OneOfCodec<"1" | "match" | "2" | "none" | "3" | "4" | "5" | "6" | "7" | "8">;
|
|
35
|
+
dismissible: import("../../runtime/codecs").BoolCodec;
|
|
36
|
+
closable: import("../../runtime/codecs").BoolCodec;
|
|
37
|
+
disabled: import("../../runtime/codecs").BoolCodec;
|
|
38
|
+
autofocusTitle: import("../../runtime/codecs").BoolCodec;
|
|
39
|
+
label: import("../../runtime/codecs").StringCodec;
|
|
40
|
+
descriptionId: import("../../runtime/codecs").StringCodec;
|
|
41
|
+
panelClass: import("../../runtime/codecs").StringCodec;
|
|
42
|
+
overlayClass: import("../../runtime/codecs").StringCodec;
|
|
43
|
+
class: import("../../runtime/codecs").StringCodec;
|
|
44
|
+
}>>;
|
|
45
|
+
generations: Readonly<Record<string, number>>;
|
|
46
|
+
}>) => Record<string, never>;
|
|
47
|
+
projectEach?: (snapshot: Readonly<{
|
|
48
|
+
value: import("../..").MachineStateValue;
|
|
49
|
+
tags: readonly string[];
|
|
50
|
+
context: Readonly<ModalContext>;
|
|
51
|
+
props: Readonly<import("../..").SchemaToProps<{
|
|
52
|
+
name: import("../../runtime/codecs").StringCodec;
|
|
53
|
+
open: import("../../runtime/codecs").BoolCodec;
|
|
54
|
+
mode: import("../../runtime/codecs").OneOfCodec<"modal" | "sheet">;
|
|
55
|
+
side: import("../../runtime/codecs").OneOfCodec<"top" | "bottom" | "left" | "right">;
|
|
56
|
+
size: import("../../runtime/codecs").OneOfCodec<"sm" | "md" | "lg" | "full" | "xl">;
|
|
57
|
+
surface: import("../../runtime/codecs").OneOfCodec<"1" | "0" | "2" | "inherit" | "3" | "4" | "5" | "6" | "7" | "8" | "+1" | "+2" | "+3" | "+4" | "+5" | "+6" | "+7" | "+8">;
|
|
58
|
+
elevation: import("../../runtime/codecs").OneOfCodec<"1" | "match" | "2" | "none" | "3" | "4" | "5" | "6" | "7" | "8">;
|
|
59
|
+
dismissible: import("../../runtime/codecs").BoolCodec;
|
|
60
|
+
closable: import("../../runtime/codecs").BoolCodec;
|
|
61
|
+
disabled: import("../../runtime/codecs").BoolCodec;
|
|
62
|
+
autofocusTitle: import("../../runtime/codecs").BoolCodec;
|
|
63
|
+
label: import("../../runtime/codecs").StringCodec;
|
|
64
|
+
descriptionId: import("../../runtime/codecs").StringCodec;
|
|
65
|
+
panelClass: import("../../runtime/codecs").StringCodec;
|
|
66
|
+
overlayClass: import("../../runtime/codecs").StringCodec;
|
|
67
|
+
class: import("../../runtime/codecs").StringCodec;
|
|
68
|
+
}>>;
|
|
69
|
+
generations: Readonly<Record<string, number>>;
|
|
70
|
+
}>) => readonly Record<string, never>[];
|
|
71
|
+
}>, Readonly<{
|
|
72
|
+
name: "closing";
|
|
73
|
+
state: string;
|
|
74
|
+
onDone: string;
|
|
75
|
+
onError: string;
|
|
76
|
+
required?: boolean;
|
|
77
|
+
sends?: Record<string, import("../..").TransitionEventCreator>;
|
|
78
|
+
project?: (snapshot: Readonly<{
|
|
79
|
+
value: import("../..").MachineStateValue;
|
|
80
|
+
tags: readonly string[];
|
|
81
|
+
context: Readonly<ModalContext>;
|
|
82
|
+
props: Readonly<import("../..").SchemaToProps<{
|
|
83
|
+
name: import("../../runtime/codecs").StringCodec;
|
|
84
|
+
open: import("../../runtime/codecs").BoolCodec;
|
|
85
|
+
mode: import("../../runtime/codecs").OneOfCodec<"modal" | "sheet">;
|
|
86
|
+
side: import("../../runtime/codecs").OneOfCodec<"top" | "bottom" | "left" | "right">;
|
|
87
|
+
size: import("../../runtime/codecs").OneOfCodec<"sm" | "md" | "lg" | "full" | "xl">;
|
|
88
|
+
surface: import("../../runtime/codecs").OneOfCodec<"1" | "0" | "2" | "inherit" | "3" | "4" | "5" | "6" | "7" | "8" | "+1" | "+2" | "+3" | "+4" | "+5" | "+6" | "+7" | "+8">;
|
|
89
|
+
elevation: import("../../runtime/codecs").OneOfCodec<"1" | "match" | "2" | "none" | "3" | "4" | "5" | "6" | "7" | "8">;
|
|
90
|
+
dismissible: import("../../runtime/codecs").BoolCodec;
|
|
91
|
+
closable: import("../../runtime/codecs").BoolCodec;
|
|
92
|
+
disabled: import("../../runtime/codecs").BoolCodec;
|
|
93
|
+
autofocusTitle: import("../../runtime/codecs").BoolCodec;
|
|
94
|
+
label: import("../../runtime/codecs").StringCodec;
|
|
95
|
+
descriptionId: import("../../runtime/codecs").StringCodec;
|
|
96
|
+
panelClass: import("../../runtime/codecs").StringCodec;
|
|
97
|
+
overlayClass: import("../../runtime/codecs").StringCodec;
|
|
98
|
+
class: import("../../runtime/codecs").StringCodec;
|
|
99
|
+
}>>;
|
|
100
|
+
generations: Readonly<Record<string, number>>;
|
|
101
|
+
}>) => Record<string, never>;
|
|
102
|
+
projectEach?: (snapshot: Readonly<{
|
|
103
|
+
value: import("../..").MachineStateValue;
|
|
104
|
+
tags: readonly string[];
|
|
105
|
+
context: Readonly<ModalContext>;
|
|
106
|
+
props: Readonly<import("../..").SchemaToProps<{
|
|
107
|
+
name: import("../../runtime/codecs").StringCodec;
|
|
108
|
+
open: import("../../runtime/codecs").BoolCodec;
|
|
109
|
+
mode: import("../../runtime/codecs").OneOfCodec<"modal" | "sheet">;
|
|
110
|
+
side: import("../../runtime/codecs").OneOfCodec<"top" | "bottom" | "left" | "right">;
|
|
111
|
+
size: import("../../runtime/codecs").OneOfCodec<"sm" | "md" | "lg" | "full" | "xl">;
|
|
112
|
+
surface: import("../../runtime/codecs").OneOfCodec<"1" | "0" | "2" | "inherit" | "3" | "4" | "5" | "6" | "7" | "8" | "+1" | "+2" | "+3" | "+4" | "+5" | "+6" | "+7" | "+8">;
|
|
113
|
+
elevation: import("../../runtime/codecs").OneOfCodec<"1" | "match" | "2" | "none" | "3" | "4" | "5" | "6" | "7" | "8">;
|
|
114
|
+
dismissible: import("../../runtime/codecs").BoolCodec;
|
|
115
|
+
closable: import("../../runtime/codecs").BoolCodec;
|
|
116
|
+
disabled: import("../../runtime/codecs").BoolCodec;
|
|
117
|
+
autofocusTitle: import("../../runtime/codecs").BoolCodec;
|
|
118
|
+
label: import("../../runtime/codecs").StringCodec;
|
|
119
|
+
descriptionId: import("../../runtime/codecs").StringCodec;
|
|
120
|
+
panelClass: import("../../runtime/codecs").StringCodec;
|
|
121
|
+
overlayClass: import("../../runtime/codecs").StringCodec;
|
|
122
|
+
class: import("../../runtime/codecs").StringCodec;
|
|
123
|
+
}>>;
|
|
124
|
+
generations: Readonly<Record<string, number>>;
|
|
125
|
+
}>) => readonly Record<string, never>[];
|
|
126
|
+
}>];
|
|
127
|
+
declare const createModalMachine: ({ props, effects, }: CreateModalMachineOptions) => Machine<ModalContext, ModalProps>;
|
|
128
|
+
export { createModalMachine, modalHooks };
|
|
129
|
+
export type { CreateModalMachineOptions, ModalContext, ModalMachineEffects };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type
|
|
1
|
+
import { type SchemaToProps } from '../../runtime';
|
|
2
2
|
declare const overlaySchema: {
|
|
3
3
|
href: import("../../runtime/codecs").StringCodec;
|
|
4
4
|
label: import("../../runtime/codecs").StringCodec;
|
|
@@ -7,7 +7,7 @@ declare const overlaySchema: {
|
|
|
7
7
|
declare const overlayAboveSchema: {
|
|
8
8
|
class: import("../../runtime/codecs").StringCodec;
|
|
9
9
|
};
|
|
10
|
-
type OverlayProps =
|
|
11
|
-
type OverlayAboveProps =
|
|
10
|
+
type OverlayProps = SchemaToProps<typeof overlaySchema>;
|
|
11
|
+
type OverlayAboveProps = SchemaToProps<typeof overlayAboveSchema>;
|
|
12
12
|
export { overlayAboveSchema, overlaySchema, };
|
|
13
13
|
export type { OverlayAboveProps, OverlayProps, };
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { type SchemaToProps } from '../../runtime';
|
|
2
|
+
declare const PANELS_ORIENTATIONS: readonly ["horizontal", "vertical"];
|
|
3
|
+
declare const PANEL_AS_VALUES: readonly ["div", "section", "aside", "main", "nav"];
|
|
4
|
+
declare const PANEL_SIZES: readonly ["1", "2", "3", "4", "5", "6", "fill"];
|
|
5
|
+
declare const PANEL_RESIZE_EDGES: readonly ["none", "start", "end"];
|
|
6
|
+
declare const PANEL_TOGGLE_ACTIONS: readonly ["toggle", "expand", "collapse"];
|
|
7
|
+
declare const panelsSchema: {
|
|
8
|
+
id: import("../../runtime/codecs").StringCodec;
|
|
9
|
+
orientation: import("../../runtime/codecs").OneOfCodec<"vertical" | "horizontal">;
|
|
10
|
+
persist: import("../../runtime/codecs").BoolCodec;
|
|
11
|
+
divider: import("../../runtime/codecs").BoolCodec;
|
|
12
|
+
class: import("../../runtime/codecs").StringCodec;
|
|
13
|
+
};
|
|
14
|
+
declare const panelSchema: {
|
|
15
|
+
id: import("../../runtime/codecs").StringCodec;
|
|
16
|
+
as: import("../../runtime/codecs").OneOfCodec<"aside" | "div" | "main" | "nav" | "section">;
|
|
17
|
+
size: import("../../runtime/codecs").OneOfCodec<"1" | "fill" | "2" | "3" | "4" | "5" | "6">;
|
|
18
|
+
resize: import("../../runtime/codecs").OneOfCodec<"start" | "end" | "none">;
|
|
19
|
+
collapsible: import("../../runtime/codecs").BoolCodec;
|
|
20
|
+
defaultCollapsed: import("../../runtime/codecs").BoolCodec;
|
|
21
|
+
class: import("../../runtime/codecs").StringCodec;
|
|
22
|
+
};
|
|
23
|
+
declare const panelToggleSchema: {
|
|
24
|
+
target: import("../../runtime/codecs").StringCodec;
|
|
25
|
+
action: import("../../runtime/codecs").OneOfCodec<"toggle" | "expand" | "collapse">;
|
|
26
|
+
icon: import("../../runtime/codecs").StringCodec;
|
|
27
|
+
label: import("../../runtime/codecs").StringCodec;
|
|
28
|
+
class: import("../../runtime/codecs").StringCodec;
|
|
29
|
+
};
|
|
30
|
+
type PanelsOrientation = typeof PANELS_ORIENTATIONS[number];
|
|
31
|
+
type PanelAs = typeof PANEL_AS_VALUES[number];
|
|
32
|
+
type PanelSize = typeof PANEL_SIZES[number];
|
|
33
|
+
type PanelResizeEdge = typeof PANEL_RESIZE_EDGES[number];
|
|
34
|
+
type PanelToggleAction = typeof PANEL_TOGGLE_ACTIONS[number];
|
|
35
|
+
type PanelsProps = SchemaToProps<typeof panelsSchema>;
|
|
36
|
+
type PanelProps = SchemaToProps<typeof panelSchema>;
|
|
37
|
+
type PanelToggleProps = SchemaToProps<typeof panelToggleSchema>;
|
|
38
|
+
export { PANEL_AS_VALUES, PANEL_RESIZE_EDGES, PANEL_SIZES, PANEL_TOGGLE_ACTIONS, PANELS_ORIENTATIONS, panelSchema, panelToggleSchema, panelsSchema, };
|
|
39
|
+
export type { PanelAs, PanelProps, PanelResizeEdge, PanelSize, PanelToggleAction, PanelToggleProps, PanelsOrientation, PanelsProps, };
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import type Alpine from 'alpinejs';
|
|
2
|
+
import { type AlpineMachine, type BindingObject, type TrellisAlpineComponent } from '../../runtime';
|
|
3
|
+
import { type MotionHandle, type MotionTransitionSubject } from '../../motion';
|
|
4
|
+
import { type PanelToggleAction, type PanelToggleProps, type PanelsProps } from './contract';
|
|
5
|
+
import { panelsHooks, type PanelsContext, type PanelsPersistTransitionData, type PanelTransitionData } from './machine';
|
|
6
|
+
type PanelEventDetail = {
|
|
7
|
+
panelId?: string;
|
|
8
|
+
groupId?: string;
|
|
9
|
+
action?: PanelToggleAction;
|
|
10
|
+
trigger?: HTMLElement | null;
|
|
11
|
+
__panelsNotification?: boolean;
|
|
12
|
+
};
|
|
13
|
+
type PanelMotionTransition = MotionTransitionSubject & Readonly<{
|
|
14
|
+
data: PanelTransitionData;
|
|
15
|
+
}>;
|
|
16
|
+
/** Public Alpine API for `ui.panels`. @public */
|
|
17
|
+
interface UiPanelsApi {
|
|
18
|
+
/** Stable group id used by explicit controls, named events, and persistence. */
|
|
19
|
+
readonly id: string;
|
|
20
|
+
/** Current main axis along which direct panels negotiate space. */
|
|
21
|
+
readonly orientation: 'horizontal' | 'vertical';
|
|
22
|
+
/** Stable ids of panels whose collapsed representation is active. */
|
|
23
|
+
readonly collapsed: readonly string[];
|
|
24
|
+
/** User-committed pixel measures keyed by stable panel id. */
|
|
25
|
+
readonly sizes: Readonly<Record<string, number>>;
|
|
26
|
+
/** Returns whether a named panel is currently collapsed. */
|
|
27
|
+
isCollapsed(id: string): boolean;
|
|
28
|
+
/** Collapses a named collapsible panel. */
|
|
29
|
+
collapse(id: string): void;
|
|
30
|
+
/** Expands a named collapsed panel. */
|
|
31
|
+
expand(id: string): void;
|
|
32
|
+
/** Reverses the collapsed state of a named collapsible panel. */
|
|
33
|
+
toggle(id: string): void;
|
|
34
|
+
/** Restores one panel or the whole group to its authored layout. */
|
|
35
|
+
reset(id?: string): void;
|
|
36
|
+
}
|
|
37
|
+
type PanelsData = AlpineMachine<PanelsContext, PanelsProps, typeof panelsHooks> & UiPanelsApi & {
|
|
38
|
+
readonly root: BindingObject;
|
|
39
|
+
init(): void;
|
|
40
|
+
destroy(): void;
|
|
41
|
+
perform(action: PanelToggleAction, panelId: string, trigger?: HTMLElement | null): void;
|
|
42
|
+
syncToggles(): void;
|
|
43
|
+
hasPanel(panelId: string): boolean;
|
|
44
|
+
transitionPanel(transition: PanelMotionTransition): MotionHandle;
|
|
45
|
+
};
|
|
46
|
+
declare const UiPanels: () => TrellisAlpineComponent<PanelsData>;
|
|
47
|
+
declare const UiPanelToggle: () => TrellisAlpineComponent<{
|
|
48
|
+
props: PanelToggleProps;
|
|
49
|
+
readonly root: BindingObject;
|
|
50
|
+
trigger(event?: Event): void;
|
|
51
|
+
}>;
|
|
52
|
+
declare const registerPanels: (AlpineInstance: Alpine.Alpine) => void;
|
|
53
|
+
export { registerPanels, UiPanels, UiPanelToggle };
|
|
54
|
+
export type { PanelEventDetail, PanelsData, PanelsPersistTransitionData, UiPanelsApi, };
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
import { type Machine, type MachineScope } from '../../runtime/state-machine';
|
|
2
|
+
import type { PanelsProps } from './contract';
|
|
3
|
+
type PanelsContext = {
|
|
4
|
+
collection: {
|
|
5
|
+
ids: string[];
|
|
6
|
+
collapsibleIds: string[];
|
|
7
|
+
resizableIds: string[];
|
|
8
|
+
};
|
|
9
|
+
layout: {
|
|
10
|
+
collapsedIds: string[];
|
|
11
|
+
committedSizes: Record<string, number>;
|
|
12
|
+
};
|
|
13
|
+
authored: {
|
|
14
|
+
collapsedIds: string[];
|
|
15
|
+
};
|
|
16
|
+
change: {
|
|
17
|
+
openingIds: string[];
|
|
18
|
+
closingIds: string[];
|
|
19
|
+
};
|
|
20
|
+
resize: {
|
|
21
|
+
activeId: string;
|
|
22
|
+
initialSize: number | null;
|
|
23
|
+
previewSize: number | null;
|
|
24
|
+
};
|
|
25
|
+
};
|
|
26
|
+
type PanelTransitionData = {
|
|
27
|
+
panelId: string;
|
|
28
|
+
};
|
|
29
|
+
type PanelsPersistTransitionData = {
|
|
30
|
+
groupId: string;
|
|
31
|
+
collapsed: string[];
|
|
32
|
+
sizes: Record<string, number>;
|
|
33
|
+
};
|
|
34
|
+
type PanelsMachineEffects = {
|
|
35
|
+
prepareChange(scope: MachineScope<PanelsContext, PanelsProps>): void;
|
|
36
|
+
finishChange(scope: MachineScope<PanelsContext, PanelsProps>): void;
|
|
37
|
+
sync(scope: MachineScope<PanelsContext, PanelsProps>): void;
|
|
38
|
+
beginResize(scope: MachineScope<PanelsContext, PanelsProps>): void;
|
|
39
|
+
previewResize(scope: MachineScope<PanelsContext, PanelsProps>): void;
|
|
40
|
+
commitResize(scope: MachineScope<PanelsContext, PanelsProps>): void;
|
|
41
|
+
cancelResize(scope: MachineScope<PanelsContext, PanelsProps>): void;
|
|
42
|
+
persist(scope: MachineScope<PanelsContext, PanelsProps>): void;
|
|
43
|
+
};
|
|
44
|
+
type CreatePanelsMachineOptions = {
|
|
45
|
+
props: PanelsProps;
|
|
46
|
+
context: PanelsContext;
|
|
47
|
+
effects: PanelsMachineEffects;
|
|
48
|
+
};
|
|
49
|
+
declare const panelsHooks: readonly [Readonly<{
|
|
50
|
+
name: "opening";
|
|
51
|
+
state: string;
|
|
52
|
+
onDone: string;
|
|
53
|
+
onError: string;
|
|
54
|
+
required?: boolean;
|
|
55
|
+
sends?: Record<string, import("../..").TransitionEventCreator>;
|
|
56
|
+
project?: (snapshot: Readonly<{
|
|
57
|
+
value: import("../..").MachineStateValue;
|
|
58
|
+
tags: readonly string[];
|
|
59
|
+
context: Readonly<PanelsContext>;
|
|
60
|
+
props: Readonly<import("../..").SchemaToProps<{
|
|
61
|
+
id: import("../../runtime/codecs").StringCodec;
|
|
62
|
+
orientation: import("../../runtime/codecs").OneOfCodec<"vertical" | "horizontal">;
|
|
63
|
+
persist: import("../../runtime/codecs").BoolCodec;
|
|
64
|
+
divider: import("../../runtime/codecs").BoolCodec;
|
|
65
|
+
class: import("../../runtime/codecs").StringCodec;
|
|
66
|
+
}>>;
|
|
67
|
+
generations: Readonly<Record<string, number>>;
|
|
68
|
+
}>) => PanelTransitionData;
|
|
69
|
+
projectEach?: (snapshot: Readonly<{
|
|
70
|
+
value: import("../..").MachineStateValue;
|
|
71
|
+
tags: readonly string[];
|
|
72
|
+
context: Readonly<PanelsContext>;
|
|
73
|
+
props: Readonly<import("../..").SchemaToProps<{
|
|
74
|
+
id: import("../../runtime/codecs").StringCodec;
|
|
75
|
+
orientation: import("../../runtime/codecs").OneOfCodec<"vertical" | "horizontal">;
|
|
76
|
+
persist: import("../../runtime/codecs").BoolCodec;
|
|
77
|
+
divider: import("../../runtime/codecs").BoolCodec;
|
|
78
|
+
class: import("../../runtime/codecs").StringCodec;
|
|
79
|
+
}>>;
|
|
80
|
+
generations: Readonly<Record<string, number>>;
|
|
81
|
+
}>) => readonly PanelTransitionData[];
|
|
82
|
+
}>, Readonly<{
|
|
83
|
+
name: "closing";
|
|
84
|
+
state: string;
|
|
85
|
+
onDone: string;
|
|
86
|
+
onError: string;
|
|
87
|
+
required?: boolean;
|
|
88
|
+
sends?: Record<string, import("../..").TransitionEventCreator>;
|
|
89
|
+
project?: (snapshot: Readonly<{
|
|
90
|
+
value: import("../..").MachineStateValue;
|
|
91
|
+
tags: readonly string[];
|
|
92
|
+
context: Readonly<PanelsContext>;
|
|
93
|
+
props: Readonly<import("../..").SchemaToProps<{
|
|
94
|
+
id: import("../../runtime/codecs").StringCodec;
|
|
95
|
+
orientation: import("../../runtime/codecs").OneOfCodec<"vertical" | "horizontal">;
|
|
96
|
+
persist: import("../../runtime/codecs").BoolCodec;
|
|
97
|
+
divider: import("../../runtime/codecs").BoolCodec;
|
|
98
|
+
class: import("../../runtime/codecs").StringCodec;
|
|
99
|
+
}>>;
|
|
100
|
+
generations: Readonly<Record<string, number>>;
|
|
101
|
+
}>) => PanelTransitionData;
|
|
102
|
+
projectEach?: (snapshot: Readonly<{
|
|
103
|
+
value: import("../..").MachineStateValue;
|
|
104
|
+
tags: readonly string[];
|
|
105
|
+
context: Readonly<PanelsContext>;
|
|
106
|
+
props: Readonly<import("../..").SchemaToProps<{
|
|
107
|
+
id: import("../../runtime/codecs").StringCodec;
|
|
108
|
+
orientation: import("../../runtime/codecs").OneOfCodec<"vertical" | "horizontal">;
|
|
109
|
+
persist: import("../../runtime/codecs").BoolCodec;
|
|
110
|
+
divider: import("../../runtime/codecs").BoolCodec;
|
|
111
|
+
class: import("../../runtime/codecs").StringCodec;
|
|
112
|
+
}>>;
|
|
113
|
+
generations: Readonly<Record<string, number>>;
|
|
114
|
+
}>) => readonly PanelTransitionData[];
|
|
115
|
+
}>, Readonly<{
|
|
116
|
+
name: "persisting";
|
|
117
|
+
state: string;
|
|
118
|
+
onDone: string;
|
|
119
|
+
onError: string;
|
|
120
|
+
required?: boolean;
|
|
121
|
+
sends?: Record<string, import("../..").TransitionEventCreator>;
|
|
122
|
+
project?: (snapshot: Readonly<{
|
|
123
|
+
value: import("../..").MachineStateValue;
|
|
124
|
+
tags: readonly string[];
|
|
125
|
+
context: Readonly<PanelsContext>;
|
|
126
|
+
props: Readonly<import("../..").SchemaToProps<{
|
|
127
|
+
id: import("../../runtime/codecs").StringCodec;
|
|
128
|
+
orientation: import("../../runtime/codecs").OneOfCodec<"vertical" | "horizontal">;
|
|
129
|
+
persist: import("../../runtime/codecs").BoolCodec;
|
|
130
|
+
divider: import("../../runtime/codecs").BoolCodec;
|
|
131
|
+
class: import("../../runtime/codecs").StringCodec;
|
|
132
|
+
}>>;
|
|
133
|
+
generations: Readonly<Record<string, number>>;
|
|
134
|
+
}>) => PanelsPersistTransitionData;
|
|
135
|
+
projectEach?: (snapshot: Readonly<{
|
|
136
|
+
value: import("../..").MachineStateValue;
|
|
137
|
+
tags: readonly string[];
|
|
138
|
+
context: Readonly<PanelsContext>;
|
|
139
|
+
props: Readonly<import("../..").SchemaToProps<{
|
|
140
|
+
id: import("../../runtime/codecs").StringCodec;
|
|
141
|
+
orientation: import("../../runtime/codecs").OneOfCodec<"vertical" | "horizontal">;
|
|
142
|
+
persist: import("../../runtime/codecs").BoolCodec;
|
|
143
|
+
divider: import("../../runtime/codecs").BoolCodec;
|
|
144
|
+
class: import("../../runtime/codecs").StringCodec;
|
|
145
|
+
}>>;
|
|
146
|
+
generations: Readonly<Record<string, number>>;
|
|
147
|
+
}>) => readonly PanelsPersistTransitionData[];
|
|
148
|
+
}>];
|
|
149
|
+
declare const createPanelsMachine: ({ props, context, effects, }: CreatePanelsMachineOptions) => Machine<PanelsContext, PanelsProps>;
|
|
150
|
+
export { createPanelsMachine, panelsHooks };
|
|
151
|
+
export type { CreatePanelsMachineOptions, PanelsContext, PanelsMachineEffects, PanelsPersistTransitionData, PanelTransitionData, };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type
|
|
1
|
+
import { type SchemaToProps } from '../../runtime';
|
|
2
2
|
import { type ControlSize, type IndicatorPlacement, type Orientation } from '../common';
|
|
3
3
|
declare const RADIO_GROUP_ORIENTATIONS: readonly ["vertical", "horizontal"];
|
|
4
4
|
declare const RADIO_GROUP_VARIANTS: readonly ["default", "cards", "pills"];
|
|
@@ -12,14 +12,14 @@ type RadioSize = ControlSize;
|
|
|
12
12
|
type RadioVariant = typeof RADIO_VARIANTS[number];
|
|
13
13
|
declare const radioGroupSchema: {
|
|
14
14
|
name: import("../../runtime/codecs").StringCodec;
|
|
15
|
-
value: import("
|
|
15
|
+
value: import("../..").CodecFn<string>;
|
|
16
16
|
orientation: import("../../runtime/codecs").OneOfCodec<"vertical" | "horizontal">;
|
|
17
17
|
variant: import("../../runtime/codecs").OneOfCodec<"default" | "cards" | "pills">;
|
|
18
18
|
indicator: import("../../runtime/codecs").BoolCodec;
|
|
19
19
|
placement: import("../../runtime/codecs").OneOfCodec<"center" | "leading" | "trailing" | "top-leading" | "top-trailing" | "bottom-leading" | "bottom-trailing">;
|
|
20
|
-
disabled: import("
|
|
21
|
-
required: import("
|
|
22
|
-
invalid: import("
|
|
20
|
+
disabled: import("../..").CodecFn<boolean>;
|
|
21
|
+
required: import("../..").CodecFn<boolean>;
|
|
22
|
+
invalid: import("../..").CodecFn<boolean>;
|
|
23
23
|
loop: import("../../runtime/codecs").BoolCodec;
|
|
24
24
|
class: import("../../runtime/codecs").StringCodec;
|
|
25
25
|
};
|
|
@@ -28,10 +28,10 @@ declare const radioSchema: {
|
|
|
28
28
|
name: import("../../runtime/codecs").StringCodec;
|
|
29
29
|
label: import("../../runtime/codecs").StringCodec;
|
|
30
30
|
description: import("../../runtime/codecs").StringCodec;
|
|
31
|
-
checked: import("
|
|
32
|
-
disabled: import("
|
|
33
|
-
required: import("
|
|
34
|
-
invalid: import("
|
|
31
|
+
checked: import("../..").CodecFn<boolean>;
|
|
32
|
+
disabled: import("../..").CodecFn<boolean>;
|
|
33
|
+
required: import("../..").CodecFn<boolean>;
|
|
34
|
+
invalid: import("../..").CodecFn<boolean>;
|
|
35
35
|
indicator: import("../../runtime/codecs").BoolCodec;
|
|
36
36
|
placement: import("../../runtime/codecs").OneOfCodec<"center" | "leading" | "trailing" | "top-leading" | "top-trailing" | "bottom-leading" | "bottom-trailing">;
|
|
37
37
|
icon: import("../../runtime/codecs").StringCodec;
|
|
@@ -49,7 +49,7 @@ declare const radioIndicatorSchema: {
|
|
|
49
49
|
size: import("../../runtime/codecs").OneOfCodec<"xs" | "sm" | "md" | "lg" | "xlg">;
|
|
50
50
|
class: import("../../runtime/codecs").StringCodec;
|
|
51
51
|
};
|
|
52
|
-
type RadioGroupProps =
|
|
53
|
-
type RadioProps =
|
|
52
|
+
type RadioGroupProps = SchemaToProps<typeof radioGroupSchema>;
|
|
53
|
+
type RadioProps = SchemaToProps<typeof radioSchema>;
|
|
54
54
|
export { RADIO_GROUP_ORIENTATIONS, RADIO_GROUP_VARIANTS, RADIO_PLACEMENTS, RADIO_SIZES, RADIO_VARIANTS, radioGroupSchema, radioIndicatorSchema, radioSchema, };
|
|
55
55
|
export type { RadioGroupOrientation, RadioGroupProps, RadioGroupVariant, RadioPlacement, RadioProps, RadioSize, RadioVariant };
|
|
@@ -1,28 +1,24 @@
|
|
|
1
1
|
import type Alpine from 'alpinejs';
|
|
2
|
-
import { type
|
|
3
|
-
import { type RadioGroupProps } from './contract';
|
|
4
|
-
type
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
value
|
|
10
|
-
|
|
2
|
+
import { type AlpineMachine, type TrellisAlpineComponent } from '../../runtime';
|
|
3
|
+
import { type RadioGroupProps, type RadioProps } from './contract';
|
|
4
|
+
import { radioGroupHooks, radioItemHooks, type RadioGroupContext, type RadioItemContext } from './machine';
|
|
5
|
+
/** Public Alpine API for `ui.radio.group`. @public */
|
|
6
|
+
interface UiRadioGroupApi {
|
|
7
|
+
/** Current selected value, or an empty string when the group has no selection. */
|
|
8
|
+
readonly value: string;
|
|
9
|
+
/** Select a registered enabled value, or clear an optional group with an empty string. */
|
|
10
|
+
setValue(value: string): void;
|
|
11
|
+
}
|
|
12
|
+
type RadioGroupData = AlpineMachine<RadioGroupContext, RadioGroupProps, typeof radioGroupHooks> & UiRadioGroupApi & {
|
|
13
|
+
init(): void;
|
|
14
|
+
destroy(): void;
|
|
11
15
|
};
|
|
12
|
-
type
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
listeners: CleanupStack;
|
|
16
|
-
observer: MutationObserver | null;
|
|
17
|
-
items(): RadioItem[];
|
|
18
|
-
enabledItems(): RadioItem[];
|
|
19
|
-
select(item: RadioItem, event?: Event): void;
|
|
20
|
-
move(from: RadioItem, delta: 1 | -1): void;
|
|
21
|
-
sync(): void;
|
|
22
|
-
syncItem(item: RadioItem): void;
|
|
23
|
-
handleKeydown(item: RadioItem, event: KeyboardEvent): void;
|
|
16
|
+
type RadioData = AlpineMachine<RadioItemContext, RadioProps, typeof radioItemHooks> & {
|
|
17
|
+
init(): void;
|
|
18
|
+
destroy(): void;
|
|
24
19
|
};
|
|
20
|
+
declare const UiRadio: () => TrellisAlpineComponent<RadioData>;
|
|
25
21
|
declare const UiRadioGroup: () => TrellisAlpineComponent<RadioGroupData>;
|
|
26
22
|
declare const registerRadio: (AlpineInstance: Alpine.Alpine) => void;
|
|
27
|
-
export { registerRadio, UiRadioGroup };
|
|
28
|
-
export type { RadioGroupData,
|
|
23
|
+
export { registerRadio, UiRadio, UiRadioGroup };
|
|
24
|
+
export type { RadioData, RadioGroupData, UiRadioGroupApi };
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { type Machine, type MachineScope } from '../../runtime/state-machine';
|
|
2
|
+
import type { RadioGroupProps, RadioProps } from './contract';
|
|
3
|
+
type RadioItemRecord = {
|
|
4
|
+
id: string;
|
|
5
|
+
value: string;
|
|
6
|
+
disabled: boolean;
|
|
7
|
+
checked: boolean;
|
|
8
|
+
};
|
|
9
|
+
type RadioGroupContext = {
|
|
10
|
+
selection: {
|
|
11
|
+
value: string;
|
|
12
|
+
};
|
|
13
|
+
collection: {
|
|
14
|
+
items: RadioItemRecord[];
|
|
15
|
+
};
|
|
16
|
+
};
|
|
17
|
+
type RadioItemContext = {
|
|
18
|
+
checked: boolean;
|
|
19
|
+
};
|
|
20
|
+
type RadioGroupEffects = {
|
|
21
|
+
sync(scope: MachineScope<RadioGroupContext, RadioGroupProps>): void;
|
|
22
|
+
emitInput(scope: MachineScope<RadioGroupContext, RadioGroupProps>): void;
|
|
23
|
+
emitChange(scope: MachineScope<RadioGroupContext, RadioGroupProps>): void;
|
|
24
|
+
focus(scope: MachineScope<RadioGroupContext, RadioGroupProps>): void;
|
|
25
|
+
};
|
|
26
|
+
type RadioItemEffects = {
|
|
27
|
+
sync(scope: MachineScope<RadioItemContext, RadioProps>): void;
|
|
28
|
+
};
|
|
29
|
+
declare const radioGroupHooks: readonly [];
|
|
30
|
+
declare const radioItemHooks: readonly [];
|
|
31
|
+
declare const createRadioGroupMachine: ({ props, effects }: {
|
|
32
|
+
props: RadioGroupProps;
|
|
33
|
+
effects: RadioGroupEffects;
|
|
34
|
+
}) => Machine<RadioGroupContext, RadioGroupProps>;
|
|
35
|
+
declare const createRadioItemMachine: ({ props, effects }: {
|
|
36
|
+
props: RadioProps;
|
|
37
|
+
effects: RadioItemEffects;
|
|
38
|
+
}) => Machine<RadioItemContext, RadioProps>;
|
|
39
|
+
export { createRadioGroupMachine, createRadioItemMachine, radioGroupHooks, radioItemHooks };
|
|
40
|
+
export type { RadioGroupContext, RadioGroupEffects, RadioItemContext, RadioItemEffects, RadioItemRecord };
|
|
@@ -1,37 +1,34 @@
|
|
|
1
1
|
export { registerAccordion, UiAccordion } from './accordion';
|
|
2
|
-
export type { AccordionData,
|
|
2
|
+
export type { AccordionData, UiAccordionApi } from './accordion';
|
|
3
3
|
export { registerButton, unregisterButton } from './button';
|
|
4
4
|
export { registerCheckbox, UiCheckbox, UiCheckboxGroup, } from './checkbox';
|
|
5
|
-
export type { CheckboxData, CheckboxGroupData,
|
|
6
|
-
export { registerCombobox, UiCombobox } from './combobox';
|
|
7
|
-
export type { ComboboxData, ComboboxOption } from './combobox';
|
|
5
|
+
export type { CheckboxData, CheckboxGroupData, CheckboxState, UiCheckboxApi } from './checkbox';
|
|
8
6
|
export { registerDatePicker, UiDatePicker } from './date-picker';
|
|
9
7
|
export type { DatePickerData } from './date-picker';
|
|
10
8
|
export { registerDropdown, UiDropdown } from './dropdown';
|
|
11
|
-
export type { DropdownData } from './dropdown';
|
|
9
|
+
export type { DropdownData, UiDropdownApi } from './dropdown';
|
|
12
10
|
export { registerField, UiField } from './field';
|
|
13
|
-
export type { FieldData } from './field';
|
|
14
11
|
export { registerFileUpload, UiFileUpload } from './file-upload';
|
|
15
|
-
export type { FileUploadData,
|
|
12
|
+
export type { FileTransferStatus, FileUploadData, FileUploadMetadata, FileUploadRecord, UiFileUploadApi } from './file-upload';
|
|
16
13
|
export { registerInput, UiInput } from './input';
|
|
17
|
-
export type { InputData } from './input';
|
|
14
|
+
export type { InputData, UiInputApi } from './input';
|
|
18
15
|
export { registerModal, UiModal, UiModalTrigger, } from './modal';
|
|
19
|
-
export type { ModalCancelDetail,
|
|
20
|
-
export {
|
|
21
|
-
export type {
|
|
16
|
+
export type { ModalCancelDetail, UiModalApi, UiModalTriggerApi } from './modal';
|
|
17
|
+
export { registerPanels, UiPanels, UiPanelToggle } from './panels';
|
|
18
|
+
export type { PanelsData, UiPanelsApi } from './panels';
|
|
19
|
+
export { registerRadio, UiRadio, UiRadioGroup } from './radio';
|
|
20
|
+
export type { RadioData, RadioGroupData, UiRadioGroupApi } from './radio';
|
|
22
21
|
export { registerScrollArea, UiScrollArea } from './scroll-area';
|
|
23
|
-
export type { ScrollAreaData, ScrollAreaElements } from './scroll-area';
|
|
22
|
+
export type { ScrollAreaData, ScrollAreaElements, UiScrollAreaApi } from './scroll-area';
|
|
24
23
|
export { registerSelect, UiSelect } from './select';
|
|
25
|
-
export type { SelectData,
|
|
24
|
+
export type { SelectData, UiSelectApi } from './select';
|
|
26
25
|
export { registerSidebar, UiSidebar, UiSidebarToggle, } from './sidebar';
|
|
27
26
|
export type { SidebarController, SidebarData } from './sidebar';
|
|
28
27
|
export { registerSlider, UiSlider } from './slider';
|
|
29
|
-
export type { SliderData, SliderElements, SliderThumbName, SliderValues } from './slider';
|
|
28
|
+
export type { SliderData, SliderElements, SliderThumbName, SliderValues, UiSliderApi } from './slider';
|
|
30
29
|
export { registerSwitch, UiSwitch } from './switch';
|
|
31
|
-
export type { SwitchData,
|
|
32
|
-
export { registerTabs, UiTabs } from './tabs';
|
|
33
|
-
export type { TabsActivateDetail, TabsChangeDetail
|
|
34
|
-
export { registerTextarea, UiTextarea } from './textarea';
|
|
35
|
-
export type { TextareaData } from './textarea';
|
|
30
|
+
export type { SwitchData, UiSwitchApi } from './switch';
|
|
31
|
+
export { registerTabs, UiTabs, type UiTabsApi } from './tabs';
|
|
32
|
+
export type { TabsActivateDetail, TabsChangeDetail } from './tabs';
|
|
36
33
|
export { registerToast, UiToast, UiToastOutlet, } from './toast';
|
|
37
34
|
export type { ToastData, ToastDetail, ToastOutletData } from './toast';
|
|
@@ -1,11 +1,9 @@
|
|
|
1
|
-
import { type
|
|
1
|
+
import { type SchemaToProps } from '../../runtime';
|
|
2
2
|
declare const SCROLL_AREA_ORIENTATIONS: readonly ["vertical", "horizontal", "both"];
|
|
3
3
|
declare const SCROLL_AREA_TYPES: readonly ["hover", "always", "scroll"];
|
|
4
|
-
declare const SCROLL_AREA_SIZES: readonly ["sm", "md"];
|
|
5
4
|
declare const scrollAreaSchema: {
|
|
6
5
|
orientation: import("../../runtime/codecs").OneOfCodec<"vertical" | "horizontal" | "both">;
|
|
7
6
|
type: import("../../runtime/codecs").OneOfCodec<"scroll" | "always" | "hover">;
|
|
8
|
-
size: import("../../runtime/codecs").OneOfCodec<"sm" | "md">;
|
|
9
7
|
fill: import("../../runtime/codecs").BoolCodec;
|
|
10
8
|
hideNative: import("../../runtime/codecs").BoolCodec;
|
|
11
9
|
disabled: import("../../runtime/codecs").BoolCodec;
|
|
@@ -17,7 +15,6 @@ declare const scrollAreaSchema: {
|
|
|
17
15
|
};
|
|
18
16
|
type ScrollAreaOrientation = typeof SCROLL_AREA_ORIENTATIONS[number];
|
|
19
17
|
type ScrollAreaType = typeof SCROLL_AREA_TYPES[number];
|
|
20
|
-
type
|
|
21
|
-
|
|
22
|
-
export {
|
|
23
|
-
export type { ScrollAreaOrientation, ScrollAreaProps, ScrollAreaSize, ScrollAreaType, };
|
|
18
|
+
type ScrollAreaProps = SchemaToProps<typeof scrollAreaSchema>;
|
|
19
|
+
export { SCROLL_AREA_ORIENTATIONS, SCROLL_AREA_TYPES, scrollAreaSchema, };
|
|
20
|
+
export type { ScrollAreaOrientation, ScrollAreaProps, ScrollAreaType, };
|