@visulima/dev-toolbar 1.0.0-alpha.12 → 1.0.0-alpha.14

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.
Files changed (123) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/LICENSE.md +21 -0
  3. package/dist/apps/a11y/index.d.ts +3 -2
  4. package/dist/apps/a11y/index.js +1 -1
  5. package/dist/apps/annotations/index.d.ts +3 -2
  6. package/dist/apps/annotations/index.js +1 -1
  7. package/dist/apps/assets/index.d.ts +3 -2
  8. package/dist/apps/assets/index.js +1 -1
  9. package/dist/apps/inspector/index.d.ts +3 -2
  10. package/dist/apps/inspector/index.js +1 -1
  11. package/dist/apps/module-graph/index.d.ts +3 -2
  12. package/dist/apps/module-graph/index.js +1 -1
  13. package/dist/apps/performance/index.d.ts +3 -2
  14. package/dist/apps/performance/index.js +1 -1
  15. package/dist/apps/seo/index.d.ts +3 -2
  16. package/dist/apps/seo/index.js +1 -1
  17. package/dist/apps/settings/index.d.ts +3 -2
  18. package/dist/apps/settings/index.js +1 -1
  19. package/dist/apps/tailwind/index.d.ts +3 -2
  20. package/dist/apps/timeline/index.d.ts +3 -2
  21. package/dist/apps/timeline/index.js +1 -1
  22. package/dist/apps/vite-config/index.d.ts +3 -2
  23. package/dist/apps/vite-config/index.js +1 -1
  24. package/dist/client/overlay.d.ts +1 -1
  25. package/dist/index.d.ts +143 -8
  26. package/dist/mcp/server.d.ts +2 -12
  27. package/dist/packem_shared/app.d-SmKEDxsI.d.ts +229 -0
  28. package/dist/packem_shared/global-api.d-BLfn-OUA.d.ts +547 -0
  29. package/dist/packem_shared/{sharedToolbarStylesheet-CaTdYhVe.js → sharedToolbarStylesheet-Bx1muJAh.js} +1 -1
  30. package/dist/toolbar/index.d.ts +152 -48
  31. package/dist/toolbar/index.js +1 -1
  32. package/dist/ui/index.d.ts +382 -18
  33. package/dist/vite-plugin.d.ts +155 -146
  34. package/package.json +4 -4
  35. package/dist/apps/a11y/a11y-app.d.ts +0 -4
  36. package/dist/apps/a11y/a11y-store.d.ts +0 -42
  37. package/dist/apps/a11y/a11y-tooltip.d.ts +0 -10
  38. package/dist/apps/annotations/annotations-app.d.ts +0 -4
  39. package/dist/apps/assets/assets-app.d.ts +0 -4
  40. package/dist/apps/inspector/a11y-capture.d.ts +0 -12
  41. package/dist/apps/inspector/annotation-overlay.d.ts +0 -55
  42. package/dist/apps/inspector/annotation-settings.d.ts +0 -33
  43. package/dist/apps/inspector/element-utils.d.ts +0 -115
  44. package/dist/apps/inspector/freeze-animations.d.ts +0 -22
  45. package/dist/apps/inspector/inspector-app.d.ts +0 -14
  46. package/dist/apps/inspector/rulers.d.ts +0 -14
  47. package/dist/apps/inspector/theme-palette.d.ts +0 -34
  48. package/dist/apps/module-graph/module-graph-app.d.ts +0 -4
  49. package/dist/apps/performance/performance-app.d.ts +0 -4
  50. package/dist/apps/performance/performance-tooltip.d.ts +0 -4
  51. package/dist/apps/seo/seo-app.d.ts +0 -4
  52. package/dist/apps/settings/settings-app.d.ts +0 -4
  53. package/dist/apps/tailwind/tailwind-app.d.ts +0 -4
  54. package/dist/apps/timeline/timeline-app.d.ts +0 -4
  55. package/dist/apps/vite-config/vite-config-app.d.ts +0 -4
  56. package/dist/hooks/create-hook.d.ts +0 -12
  57. package/dist/hooks/events.d.ts +0 -7
  58. package/dist/hooks/global-hook.d.ts +0 -15
  59. package/dist/hooks/index.d.ts +0 -6
  60. package/dist/performance/monitor.d.ts +0 -116
  61. package/dist/rpc/client.d.ts +0 -9
  62. package/dist/rpc/functions/annotations.d.ts +0 -28
  63. package/dist/rpc/functions/assets.d.ts +0 -16
  64. package/dist/rpc/functions/module-graph.d.ts +0 -17
  65. package/dist/rpc/functions/open-in-editor.d.ts +0 -16
  66. package/dist/rpc/functions/tailwind-config.d.ts +0 -15
  67. package/dist/rpc/functions/vite-config.d.ts +0 -83
  68. package/dist/rpc/server.d.ts +0 -15
  69. package/dist/store/annotation-store.d.ts +0 -41
  70. package/dist/timeline/capture.d.ts +0 -8
  71. package/dist/timeline/index.d.ts +0 -8
  72. package/dist/timeline/store.d.ts +0 -42
  73. package/dist/toolbar/app-manager.d.ts +0 -104
  74. package/dist/toolbar/components/app-button.d.ts +0 -18
  75. package/dist/toolbar/components/app-canvas.d.ts +0 -12
  76. package/dist/toolbar/components/app-tooltip-overlay.d.ts +0 -12
  77. package/dist/toolbar/components/first-visit-hint.d.ts +0 -15
  78. package/dist/toolbar/components/index.d.ts +0 -4
  79. package/dist/toolbar/components/pinned-tooltip-card.d.ts +0 -22
  80. package/dist/toolbar/components/toolbar-bar.d.ts +0 -9
  81. package/dist/toolbar/components/toolbar-container.d.ts +0 -49
  82. package/dist/toolbar/components/vite-overlay-button.d.ts +0 -14
  83. package/dist/toolbar/context/index.d.ts +0 -2
  84. package/dist/toolbar/context/toolbar-context.d.ts +0 -107
  85. package/dist/toolbar/global-api.d.ts +0 -24
  86. package/dist/toolbar/helpers.d.ts +0 -8
  87. package/dist/toolbar/hooks/index.d.ts +0 -10
  88. package/dist/toolbar/hooks/use-apps.d.ts +0 -15
  89. package/dist/toolbar/hooks/use-frame-state.d.ts +0 -110
  90. package/dist/toolbar/hooks/use-panel-visible.d.ts +0 -23
  91. package/dist/toolbar/hooks/use-position.d.ts +0 -24
  92. package/dist/toolbar/hooks/use-theme.d.ts +0 -15
  93. package/dist/toolbar/hooks/use-toolbar.d.ts +0 -16
  94. package/dist/toolbar/settings.d.ts +0 -17
  95. package/dist/toolbar/stylesheet.d.ts +0 -3
  96. package/dist/toolbar/utils/index.d.ts +0 -12
  97. package/dist/types/annotations.d.ts +0 -156
  98. package/dist/types/app.d.ts +0 -175
  99. package/dist/types/global-api.d.ts +0 -91
  100. package/dist/types/hooks.d.ts +0 -86
  101. package/dist/types/index.d.ts +0 -13
  102. package/dist/types/messaging.d.ts +0 -43
  103. package/dist/types/rpc.d.ts +0 -137
  104. package/dist/types/timeline.d.ts +0 -62
  105. package/dist/types/toolbar.d.ts +0 -56
  106. package/dist/ui/components/alert.d.ts +0 -19
  107. package/dist/ui/components/badge.d.ts +0 -9
  108. package/dist/ui/components/button.d.ts +0 -11
  109. package/dist/ui/components/card.d.ts +0 -16
  110. package/dist/ui/components/icon.d.ts +0 -19
  111. package/dist/ui/components/input.d.ts +0 -7
  112. package/dist/ui/components/label.d.ts +0 -7
  113. package/dist/ui/components/popover.d.ts +0 -27
  114. package/dist/ui/components/progress.d.ts +0 -7
  115. package/dist/ui/components/select.d.ts +0 -54
  116. package/dist/ui/components/separator.d.ts +0 -8
  117. package/dist/ui/components/skeleton.d.ts +0 -6
  118. package/dist/ui/components/switch.d.ts +0 -11
  119. package/dist/ui/components/tabs.d.ts +0 -28
  120. package/dist/ui/components/textarea.d.ts +0 -7
  121. package/dist/ui/components/tooltip.d.ts +0 -19
  122. package/dist/vite/inject-source.d.ts +0 -24
  123. package/dist/vite/matcher.d.ts +0 -6
@@ -1,137 +0,0 @@
1
- import type { ViteDevServer } from "vite";
2
- import type { StaticAsset } from "../rpc/functions/assets.d.ts";
3
- import type { SerializableModuleNode } from "../rpc/functions/module-graph.d.ts";
4
- import type { TailwindConfigResult } from "../rpc/functions/tailwind-config.d.ts";
5
- import type { Annotation, CreateAnnotationData, UpdateAnnotationData } from "./annotations.d.ts";
6
- /**
7
- * Server-side RPC functions
8
- * These can be called from the client
9
- */
10
- export interface ServerFunctions {
11
- /**
12
- * Extension point for custom server functions
13
- */
14
- [key: string]: (...args: any[]) => Promise<any>;
15
- /**
16
- * Create a new annotation
17
- * @param data Annotation data (id, timestamps, status are generated server-side)
18
- */
19
- createAnnotation: (data: CreateAnnotationData) => Promise<Annotation>;
20
- /**
21
- * Delete an annotation and its screenshot
22
- * @param id Annotation ID
23
- */
24
- deleteAnnotation: (id: string) => Promise<boolean>;
25
- /**
26
- * Get all annotations
27
- */
28
- getAnnotations: () => Promise<Annotation[]>;
29
- /**
30
- * Get module dependency graph
31
- */
32
- getModuleGraph: () => Promise<SerializableModuleNode[]>;
33
- /**
34
- * Get a screenshot as a base64 data URL
35
- * @param annotationId Annotation ID
36
- */
37
- getScreenshot: (annotationId: string) => Promise<string | null>;
38
- /**
39
- * Get all static assets from the public directory
40
- */
41
- getStaticAssets: () => Promise<StaticAsset[]>;
42
- /**
43
- * Get full Tailwind CSS theme (default + user overrides)
44
- */
45
- getTailwindConfig: () => Promise<TailwindConfigResult>;
46
- /**
47
- * Get Vite configuration
48
- */
49
- getViteConfig: () => Promise<Record<string, any>>;
50
- /**
51
- * Open file in editor
52
- * @param file File path
53
- * @param line Line number (1-based)
54
- * @param column Column number (1-based)
55
- * @param editor Editor override (e.g. "code", "webstorm") — empty string means auto-detect
56
- */
57
- openInEditor: (file: string, line?: number, column?: number, editor?: string) => Promise<void>;
58
- /**
59
- * Read file contents
60
- * @param path File path
61
- */
62
- readFile: (path: string) => Promise<string>;
63
- /**
64
- * Save a screenshot for an annotation
65
- * @param annotationId Annotation ID
66
- * @param dataUrl Base64 data URL (PNG, JPEG, WebP, or SVG)
67
- * @returns Relative path within .devtoolbar/
68
- */
69
- saveScreenshot: (annotationId: string, dataUrl: string) => Promise<string>;
70
- /**
71
- * Update an existing annotation
72
- * @param id Annotation ID
73
- * @param data Fields to update
74
- */
75
- updateAnnotation: (id: string, data: UpdateAnnotationData) => Promise<Annotation | null>;
76
- }
77
- /**
78
- * Client-side RPC functions
79
- * These can be called from the server
80
- */
81
- export interface ClientFunctions {
82
- [key: string]: (...args: any[]) => void;
83
- /**
84
- * Notify client of config change
85
- * @param config New Vite config
86
- */
87
- onConfigChange: (config: Record<string, unknown>) => void;
88
- /**
89
- * Notify client of HMR update
90
- * @param payload HMR payload
91
- */
92
- onHMRUpdate: (payload: unknown) => void;
93
- /**
94
- * Notify client of module update
95
- * @param module Updated module node
96
- */
97
- onModuleUpdate: (module: SerializableModuleNode) => void;
98
- }
99
- /**
100
- * RPC context for server-side
101
- */
102
- export interface ServerRPCContext {
103
- /**
104
- * Call a client function
105
- * @param name Function name
106
- * @param args Function arguments
107
- */
108
- callClient: <K extends keyof ClientFunctions>(name: K, ...args: Parameters<ClientFunctions[K]>) => void;
109
- /**
110
- * Register a server function
111
- * @param name Function name
112
- * @param fn Function implementation
113
- */
114
- registerFunction: <K extends keyof ServerFunctions>(name: K, function_: ServerFunctions[K]) => void;
115
- /**
116
- * Vite dev server instance
117
- */
118
- server: ViteDevServer;
119
- }
120
- /**
121
- * RPC context for client-side
122
- */
123
- export interface ClientRPCContext {
124
- /**
125
- * Call a server function
126
- * @param name Function name
127
- * @param args Function arguments
128
- */
129
- callServer: <K extends keyof ServerFunctions>(name: K, ...args: Parameters<ServerFunctions[K]>) => Promise<ReturnType<ServerFunctions[K]>>;
130
- /**
131
- * Register a client function
132
- * @param name Function name
133
- * @param function_ Function implementation
134
- */
135
- registerFunction: <K extends keyof ClientFunctions>(name: K, function_: ClientFunctions[K]) => void;
136
- }
137
- export { type StaticAsset } from "../rpc/functions/assets.d.ts";
@@ -1,62 +0,0 @@
1
- /**
2
- * Severity levels for timeline events.
3
- */
4
- export type TimelineEventLevel = "info" | "warning" | "error";
5
- /**
6
- * A single captured event displayed in the timeline panel.
7
- */
8
- export interface TimelineEvent {
9
- /**
10
- * Optional event data
11
- */
12
- data?: Record<string, any>;
13
- /**
14
- * Optional duration (milliseconds)
15
- */
16
- duration?: number;
17
- /**
18
- * Unique event ID
19
- */
20
- id: string;
21
- /**
22
- * Event level
23
- */
24
- level?: TimelineEventLevel;
25
- /**
26
- * Optional subtitle
27
- */
28
- subtitle?: string;
29
- /**
30
- * Timestamp (milliseconds since epoch)
31
- */
32
- time: number;
33
- /**
34
- * Event title
35
- */
36
- title: string;
37
- }
38
- /**
39
- * A named group that holds related timeline events.
40
- */
41
- export interface TimelineGroup {
42
- /**
43
- * Group color (hex or CSS color)
44
- */
45
- color?: string;
46
- /**
47
- * Events in this group
48
- */
49
- events: TimelineEvent[];
50
- /**
51
- * Group ID
52
- */
53
- id: string;
54
- /**
55
- * Group label
56
- */
57
- label: string;
58
- }
59
- /**
60
- * Default timeline groups
61
- */
62
- export declare const DEFAULT_TIMELINE_GROUPS: ReadonlyArray<TimelineGroup>;
@@ -1,56 +0,0 @@
1
- /**
2
- * Toolbar placement options (for backward compatibility)
3
- */
4
- export type ToolbarPlacement = "top-left" | "top-center" | "top-right" | "bottom-left" | "bottom-center" | "bottom-right";
5
- /**
6
- * Notification levels
7
- */
8
- export type NotificationLevel = "info" | "warning" | "error";
9
- /**
10
- * Position anchor (which edge the toolbar is attached to)
11
- * Matches Vue DevTools positioning
12
- */
13
- export type PositionAnchor = "top" | "bottom" | "left" | "right";
14
- /**
15
- * Frame state - matches Vue DevTools DevToolsFrameState
16
- * @see https://github.com/vuejs/devtools/blob/main/packages/overlay/src/composables/state.ts
17
- */
18
- export interface FrameState {
19
- /**
20
- * Horizontal position as percentage (0-100)
21
- */
22
- left: number;
23
- /**
24
- * Whether panel is open
25
- */
26
- open: boolean;
27
- /**
28
- * Which edge the toolbar is anchored to
29
- */
30
- position: PositionAnchor;
31
- /**
32
- * Vertical position as percentage (0-100)
33
- */
34
- top: number;
35
- }
36
- /**
37
- * Configuration options controlling the toolbar's initial appearance.
38
- */
39
- export interface ToolbarSettings {
40
- /**
41
- * Whether toolbar is visible by default
42
- */
43
- defaultVisible: boolean;
44
- /**
45
- * Toolbar placement on screen
46
- */
47
- placement: ToolbarPlacement;
48
- /**
49
- * Whether to show notifications
50
- */
51
- showNotifications: boolean;
52
- }
53
- /**
54
- * Default toolbar settings
55
- */
56
- export declare const DEFAULT_TOOLBAR_SETTINGS: ToolbarSettings;
@@ -1,19 +0,0 @@
1
- import type { ComponentChildren, JSX } from "preact";
2
- type AlertVariant = "default" | "destructive" | "info" | "success" | "warning";
3
- interface AlertProps extends JSX.HTMLAttributes<HTMLDivElement> {
4
- children?: ComponentChildren;
5
- class?: string;
6
- variant?: AlertVariant;
7
- }
8
- interface AlertTitleProps extends JSX.HTMLAttributes<HTMLHeadingElement> {
9
- children?: ComponentChildren;
10
- class?: string;
11
- }
12
- interface AlertDescriptionProps extends JSX.HTMLAttributes<HTMLDivElement> {
13
- children?: ComponentChildren;
14
- class?: string;
15
- }
16
- declare const Alert: ({ children, class: className, variant, ...rest }: AlertProps) => JSX.Element;
17
- declare const AlertTitle: ({ children, class: className, ...rest }: AlertTitleProps) => JSX.Element;
18
- declare const AlertDescription: ({ children, class: className, ...rest }: AlertDescriptionProps) => JSX.Element;
19
- export { Alert, AlertDescription, AlertTitle };
@@ -1,9 +0,0 @@
1
- import type { ComponentChildren, JSX } from "preact";
2
- type BadgeVariant = "default" | "destructive" | "info" | "outline" | "secondary" | "success" | "warning";
3
- interface BadgeProps extends JSX.HTMLAttributes<HTMLDivElement> {
4
- children?: ComponentChildren;
5
- class?: string;
6
- variant?: BadgeVariant;
7
- }
8
- declare const Badge: ({ children, class: className, variant, ...rest }: BadgeProps) => JSX.Element;
9
- export default Badge;
@@ -1,11 +0,0 @@
1
- import type { ComponentChildren, JSX } from "preact";
2
- type ButtonSize = "default" | "icon" | "lg" | "sm";
3
- type ButtonVariant = "default" | "destructive" | "ghost" | "link" | "outline" | "secondary";
4
- interface ButtonProps extends JSX.ButtonHTMLAttributes {
5
- children?: ComponentChildren;
6
- class?: string;
7
- size?: ButtonSize;
8
- variant?: ButtonVariant;
9
- }
10
- declare const Button: ({ children, class: className, size, type, variant, ...rest }: ButtonProps) => JSX.Element;
11
- export default Button;
@@ -1,16 +0,0 @@
1
- import type { ComponentChildren, JSX } from "preact";
2
- interface CardProps extends JSX.HTMLAttributes<HTMLDivElement> {
3
- children?: ComponentChildren;
4
- class?: string;
5
- }
6
- interface CardTitleProps extends JSX.HTMLAttributes<HTMLHeadingElement> {
7
- children?: ComponentChildren;
8
- class?: string;
9
- }
10
- declare const Card: ({ children, class: className, ...rest }: CardProps) => JSX.Element;
11
- declare const CardHeader: ({ children, class: className, ...rest }: CardProps) => JSX.Element;
12
- declare const CardTitle: ({ children, class: className, ...rest }: CardTitleProps) => JSX.Element;
13
- declare const CardDescription: ({ children, class: className, ...rest }: CardProps) => JSX.Element;
14
- declare const CardContent: ({ children, class: className, ...rest }: CardProps) => JSX.Element;
15
- declare const CardFooter: ({ children, class: className, ...rest }: CardProps) => JSX.Element;
16
- export { Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle };
@@ -1,19 +0,0 @@
1
- import type { ComponentChildren } from "preact";
2
- interface IconProps {
3
- class?: string;
4
- size?: number;
5
- /**
6
- * CSS data-URI from a `?data-uri&amp;encoding=css` lucide-static import.
7
- * Uses CSS mask-image so the icon inherits currentColor from the parent.
8
- */
9
- src: string;
10
- }
11
- /**
12
- * Renders a lucide-static icon using CSS mask-image.
13
- * Color is driven by the parent element's `color` property (currentColor).
14
- * @example
15
- * import xIcon from "lucide-static/icons/x.d.ts";
16
- * &lt;Icon src={xIcon} size={13} />
17
- */
18
- declare const Icon: ({ class: className, size, src }: IconProps) => ComponentChildren;
19
- export default Icon;
@@ -1,7 +0,0 @@
1
- import type { JSX } from "preact";
2
- import type { ForwardRefExoticComponent, RefAttributes } from "preact/compat";
3
- interface InputProps extends JSX.InputHTMLAttributes {
4
- class?: string;
5
- }
6
- declare const Input: ForwardRefExoticComponent<InputProps & RefAttributes<HTMLInputElement>>;
7
- export default Input;
@@ -1,7 +0,0 @@
1
- import type { ComponentChildren, JSX } from "preact";
2
- interface LabelProps extends JSX.LabelHTMLAttributes {
3
- children?: ComponentChildren;
4
- class?: string;
5
- }
6
- declare const Label: ({ children, class: className, ...rest }: LabelProps) => JSX.Element;
7
- export default Label;
@@ -1,27 +0,0 @@
1
- import type { ComponentChildren, JSX } from "preact";
2
- interface PopoverProps {
3
- children: ComponentChildren;
4
- defaultOpen?: boolean;
5
- onOpenChange?: (open: boolean) => void;
6
- open?: boolean;
7
- }
8
- interface PopoverTriggerProps extends JSX.ButtonHTMLAttributes {
9
- children: ComponentChildren;
10
- class?: string;
11
- }
12
- interface PopoverContentProps extends JSX.HTMLAttributes<HTMLDivElement> {
13
- align?: "center" | "end" | "start";
14
- children: ComponentChildren;
15
- class?: string;
16
- side?: "bottom" | "left" | "right" | "top";
17
- sideOffset?: number;
18
- }
19
- interface PopoverCloseProps extends JSX.ButtonHTMLAttributes {
20
- children?: ComponentChildren;
21
- class?: string;
22
- }
23
- declare const Popover: ({ children, defaultOpen, onOpenChange, open }: PopoverProps) => JSX.Element;
24
- declare const PopoverTrigger: ({ children, class: className, ...rest }: PopoverTriggerProps) => JSX.Element;
25
- declare const PopoverContent: ({ align, children, class: className, side, sideOffset, ...rest }: PopoverContentProps) => JSX.Element | undefined;
26
- declare const PopoverClose: ({ children, class: className, ...rest }: PopoverCloseProps) => JSX.Element;
27
- export { Popover, PopoverClose, PopoverContent, PopoverTrigger };
@@ -1,7 +0,0 @@
1
- import type { JSX } from "preact";
2
- interface ProgressProps extends JSX.HTMLAttributes<HTMLDivElement> {
3
- class?: string;
4
- value?: number;
5
- }
6
- declare const Progress: ({ class: className, value, ...rest }: ProgressProps) => JSX.Element;
7
- export default Progress;
@@ -1,54 +0,0 @@
1
- import type { ComponentChildren, JSX } from "preact";
2
- interface SelectContextValue {
3
- highlightedValue: string | null;
4
- instanceId: string;
5
- onSelect: (value: string) => void;
6
- open: boolean;
7
- search: string;
8
- setHighlightedValue: (v: string | null) => void;
9
- setOpen: (v: boolean) => void;
10
- setSearch: (v: string) => void;
11
- triggerRef: {
12
- current: HTMLButtonElement | null;
13
- };
14
- value: string;
15
- }
16
- declare const useSelectContext: () => SelectContextValue;
17
- interface SelectOption {
18
- label: string;
19
- value: string;
20
- }
21
- interface SelectProps {
22
- children: ComponentChildren;
23
- onValueChange?: (value: string) => void;
24
- value?: string;
25
- }
26
- interface SelectTriggerProps extends Omit<JSX.ButtonHTMLAttributes, "children"> {
27
- children: ComponentChildren;
28
- class?: string;
29
- }
30
- interface SelectContentProps {
31
- align?: "center" | "end" | "start";
32
- children: ComponentChildren;
33
- class?: string;
34
- searchable?: boolean;
35
- side?: "bottom" | "top";
36
- sideOffset?: number;
37
- }
38
- interface SelectItemProps {
39
- children: ComponentChildren;
40
- class?: string;
41
- value: string;
42
- }
43
- interface SelectValueProps {
44
- class?: string;
45
- options: SelectOption[];
46
- placeholder?: string;
47
- }
48
- declare const Select: ({ children, onValueChange, value }: SelectProps) => JSX.Element;
49
- declare const SelectTrigger: ({ children, class: className, ...rest }: SelectTriggerProps) => JSX.Element;
50
- declare const SelectValue: ({ class: className, options, placeholder }: SelectValueProps) => JSX.Element;
51
- declare const SelectContent: ({ align, children, class: className, searchable, side, sideOffset, }: SelectContentProps) => JSX.Element | undefined;
52
- declare const SelectItem: ({ children, class: className, value: itemValue }: SelectItemProps) => JSX.Element;
53
- export { Select, SelectContent, SelectItem, SelectTrigger, SelectValue, useSelectContext };
54
- export type { SelectOption };
@@ -1,8 +0,0 @@
1
- import type { JSX } from "preact";
2
- interface SeparatorProps extends JSX.HTMLAttributes<HTMLDivElement> {
3
- class?: string;
4
- decorative?: boolean;
5
- orientation?: "horizontal" | "vertical";
6
- }
7
- declare const Separator: ({ class: className, decorative, orientation, ...rest }: SeparatorProps) => JSX.Element;
8
- export default Separator;
@@ -1,6 +0,0 @@
1
- import type { JSX } from "preact";
2
- interface SkeletonProps extends JSX.HTMLAttributes<HTMLDivElement> {
3
- class?: string;
4
- }
5
- declare const Skeleton: ({ class: className, ...rest }: SkeletonProps) => JSX.Element;
6
- export default Skeleton;
@@ -1,11 +0,0 @@
1
- import type { JSX } from "preact";
2
- interface SwitchProps extends Omit<JSX.ButtonHTMLAttributes, "onChange"> {
3
- checked?: boolean;
4
- class?: string;
5
- defaultChecked?: boolean;
6
- disabled?: boolean;
7
- id?: string;
8
- onCheckedChange?: (checked: boolean) => void;
9
- }
10
- declare const Switch: ({ checked, class: className, defaultChecked, disabled, id, onCheckedChange, ...rest }: SwitchProps) => JSX.Element;
11
- export default Switch;
@@ -1,28 +0,0 @@
1
- import type { ComponentChildren, JSX } from "preact";
2
- interface TabsProps extends JSX.HTMLAttributes<HTMLDivElement> {
3
- children?: ComponentChildren;
4
- class?: string;
5
- defaultValue?: string;
6
- onValueChange?: (value: string) => void;
7
- value?: string;
8
- }
9
- interface TabsListProps extends JSX.HTMLAttributes<HTMLDivElement> {
10
- children?: ComponentChildren;
11
- class?: string;
12
- }
13
- interface TabsTriggerProps extends JSX.ButtonHTMLAttributes {
14
- children?: ComponentChildren;
15
- class?: string;
16
- disabled?: boolean;
17
- value: string;
18
- }
19
- interface TabsContentProps extends JSX.HTMLAttributes<HTMLDivElement> {
20
- children?: ComponentChildren;
21
- class?: string;
22
- value: string;
23
- }
24
- declare const Tabs: ({ children, class: className, defaultValue, onValueChange, value, ...rest }: TabsProps) => JSX.Element;
25
- declare const TabsList: ({ children, class: className, ...rest }: TabsListProps) => JSX.Element;
26
- declare const TabsTrigger: ({ children, class: className, disabled, value, ...rest }: TabsTriggerProps) => JSX.Element;
27
- declare const TabsContent: ({ children, class: className, value, ...rest }: TabsContentProps) => JSX.Element | undefined;
28
- export { Tabs, TabsContent, TabsList, TabsTrigger };
@@ -1,7 +0,0 @@
1
- import type { JSX } from "preact";
2
- import type { ForwardRefExoticComponent, RefAttributes } from "preact/compat";
3
- interface TextareaProps extends JSX.TextareaHTMLAttributes {
4
- class?: string;
5
- }
6
- declare const Textarea: ForwardRefExoticComponent<RefAttributes<HTMLTextAreaElement> & TextareaProps>;
7
- export default Textarea;
@@ -1,19 +0,0 @@
1
- import type { ComponentChildren, JSX } from "preact";
2
- interface TooltipProps {
3
- children: ComponentChildren;
4
- delayDuration?: number;
5
- }
6
- interface TooltipTriggerProps extends JSX.HTMLAttributes<HTMLSpanElement> {
7
- children: ComponentChildren;
8
- class?: string;
9
- }
10
- interface TooltipContentProps extends JSX.HTMLAttributes<HTMLDivElement> {
11
- children: ComponentChildren;
12
- class?: string;
13
- side?: "bottom" | "left" | "right" | "top";
14
- sideOffset?: number;
15
- }
16
- declare const Tooltip: ({ children, delayDuration: _delayDuration }: TooltipProps) => JSX.Element;
17
- declare const TooltipTrigger: ({ children, class: className, ...rest }: TooltipTriggerProps) => JSX.Element;
18
- declare const TooltipContent: ({ children, class: className, side, sideOffset, ...rest }: TooltipContentProps) => JSX.Element | undefined;
19
- export { Tooltip, TooltipContent, TooltipTrigger };
@@ -1,24 +0,0 @@
1
- import generate from "@babel/generator";
2
- declare const gen: typeof generate;
3
- export declare const SOURCE_ATTR = "data-vdt-source";
4
- export interface InjectSourceIgnore {
5
- /** Component names or patterns to skip. */
6
- components?: (RegExp | string)[];
7
- /** File paths or patterns to skip. */
8
- files?: (RegExp | string)[];
9
- }
10
- /**
11
- * Inject `data-vdt-source="&lt;file>:&lt;line>:&lt;col>"` into every JSX opening element
12
- * in the given source code, enabling the inspector to resolve elements back to
13
- * their source location.
14
- *
15
- * Pass `originalCode` when the received `code` may have been pre-processed by an
16
- * SSR pipeline (e.g. Vinxi / TanStack Start) that shifts JSX line numbers relative
17
- * to the source file on disk. Positions are then read from `originalCode` but
18
- * injected into `code`'s AST, ensuring server and client produce identical
19
- * attribute values and React hydration never reports a mismatch.
20
- *
21
- * Returns `undefined` when the file was skipped or contained no JSX to transform.
22
- */
23
- export declare const addSourceToJsx: (code: string, id: string, ignore?: InjectSourceIgnore, originalCode?: string) => ReturnType<typeof gen> | undefined;
24
- export {};
@@ -1,6 +0,0 @@
1
- /**
2
- * Returns true if `value` matches any of the given patterns.
3
- * Strings are treated as glob patterns; RegExps are tested directly.
4
- */
5
- declare const matcher: (patterns: (RegExp | string)[], value: string) => boolean;
6
- export default matcher;