@opencode-ai/ui 0.0.0-dev-202606260805 → 0.0.0-dev-202606260844

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 (119) hide show
  1. package/dist/components/accordion.d.ts +24 -0
  2. package/dist/components/animated-number.d.ts +4 -0
  3. package/dist/components/app-icon.d.ts +6 -0
  4. package/dist/components/app-icons/types.d.ts +2 -0
  5. package/dist/components/avatar.d.ts +9 -0
  6. package/dist/components/button.d.ts +9 -0
  7. package/dist/components/card.d.ts +22 -0
  8. package/dist/components/checkbox.d.ts +8 -0
  9. package/dist/components/collapsible.d.ts +17 -0
  10. package/dist/components/context-menu.d.ts +80 -0
  11. package/dist/components/dialog.d.ts +12 -0
  12. package/dist/components/diff-changes.d.ts +11 -0
  13. package/dist/components/dock-surface.d.ts +7 -0
  14. package/dist/components/dropdown-menu.d.ts +80 -0
  15. package/dist/components/favicon.d.ts +1 -0
  16. package/dist/components/file-icon.d.ts +12 -0
  17. package/dist/components/file-icons/types.d.ts +2 -0
  18. package/dist/components/font.d.ts +1 -0
  19. package/dist/components/hover-card.d.ts +9 -0
  20. package/dist/components/icon-button.d.ts +10 -0
  21. package/dist/components/icon.d.ts +104 -0
  22. package/dist/components/image-preview.d.ts +5 -0
  23. package/dist/components/inline-input.d.ts +5 -0
  24. package/dist/components/keybind.d.ts +6 -0
  25. package/dist/components/list.d.ts +45 -0
  26. package/dist/components/logo.d.ts +8 -0
  27. package/dist/components/motion-spring.d.ts +4 -0
  28. package/dist/components/popover.d.ts +14 -0
  29. package/dist/components/progress-circle.d.ts +7 -0
  30. package/dist/components/progress.d.ts +7 -0
  31. package/dist/components/provider-icon.d.ts +5 -0
  32. package/dist/components/provider-icons/types.d.ts +2 -0
  33. package/dist/components/radio-group.d.ts +16 -0
  34. package/dist/components/resize-handle.d.ts +12 -0
  35. package/dist/components/scroll-view.d.ts +15 -0
  36. package/dist/components/select.d.ts +21 -0
  37. package/dist/components/spinner.d.ts +6 -0
  38. package/dist/components/sticky-accordion-header.d.ts +5 -0
  39. package/dist/components/switch.d.ts +7 -0
  40. package/dist/components/tabs.d.ts +32 -0
  41. package/dist/components/tag.d.ts +5 -0
  42. package/dist/components/text-field.d.ts +13 -0
  43. package/dist/components/text-reveal.d.ts +13 -0
  44. package/dist/components/text-shimmer.d.ts +8 -0
  45. package/dist/components/text-strikethrough.d.ts +11 -0
  46. package/dist/components/toast.d.ts +56 -0
  47. package/dist/components/tooltip.d.ts +17 -0
  48. package/dist/components/typewriter.d.ts +6 -0
  49. package/dist/context/dialog.d.ts +18 -0
  50. package/dist/context/file.d.ts +5 -0
  51. package/dist/context/helper.d.ts +14 -0
  52. package/dist/context/i18n.d.ts +12 -0
  53. package/dist/context/index.d.ts +4 -0
  54. package/dist/context/marked.d.ts +9 -0
  55. package/dist/context/worker-pool.d.ts +9 -0
  56. package/dist/hooks/create-auto-scroll.d.ts +17 -0
  57. package/dist/hooks/index.d.ts +2 -0
  58. package/dist/hooks/use-filtered-list.d.ts +39 -0
  59. package/dist/i18n/ar.d.ts +148 -0
  60. package/dist/i18n/br.d.ts +148 -0
  61. package/dist/i18n/bs.d.ts +148 -0
  62. package/dist/i18n/da.d.ts +148 -0
  63. package/dist/i18n/de.d.ts +148 -0
  64. package/dist/i18n/en.d.ts +1 -0
  65. package/dist/i18n/es.d.ts +148 -0
  66. package/dist/i18n/fr.d.ts +148 -0
  67. package/dist/i18n/ja.d.ts +148 -0
  68. package/dist/i18n/ko.d.ts +148 -0
  69. package/dist/i18n/no.d.ts +4 -0
  70. package/dist/i18n/pl.d.ts +148 -0
  71. package/dist/i18n/ru.d.ts +148 -0
  72. package/dist/i18n/th.d.ts +148 -0
  73. package/dist/i18n/tr.d.ts +148 -0
  74. package/dist/i18n/uk.d.ts +1 -0
  75. package/dist/i18n/zh.d.ts +148 -0
  76. package/dist/i18n/zht.d.ts +148 -0
  77. package/dist/storybook/fixtures.d.ts +19 -0
  78. package/dist/storybook/scaffold.d.ts +16 -0
  79. package/dist/theme/color.d.ts +30 -0
  80. package/dist/theme/context.d.ts +21 -0
  81. package/dist/theme/default-themes.d.ts +39 -0
  82. package/dist/theme/index.d.ts +7 -0
  83. package/dist/theme/loader.d.ts +6 -0
  84. package/dist/theme/resolve.d.ts +7 -0
  85. package/dist/theme/types.d.ts +56 -0
  86. package/dist/theme/v2/avatar.d.ts +5 -0
  87. package/dist/theme/v2/default-primitives.d.ts +3 -0
  88. package/dist/theme/v2/foreground.d.ts +2 -0
  89. package/dist/theme/v2/mapping.d.ts +3 -0
  90. package/dist/theme/v2/resolve.d.ts +9 -0
  91. package/dist/v2/components/accordion-v2.d.ts +26 -0
  92. package/dist/v2/components/avatar-v2.d.ts +11 -0
  93. package/dist/v2/components/badge-v2.d.ts +5 -0
  94. package/dist/v2/components/button-v2.d.ts +10 -0
  95. package/dist/v2/components/checkbox-v2.d.ts +10 -0
  96. package/dist/v2/components/dialog-v2.d.ts +14 -0
  97. package/dist/v2/components/diff-changes-v2.d.ts +11 -0
  98. package/dist/v2/components/field-v2.d.ts +28 -0
  99. package/dist/v2/components/icon-button-v2.d.ts +11 -0
  100. package/dist/v2/components/icon.d.ts +81 -0
  101. package/dist/v2/components/inline-input-v2.d.ts +21 -0
  102. package/dist/v2/components/keybind-v2.d.ts +7 -0
  103. package/dist/v2/components/line-comment-v2.d.ts +28 -0
  104. package/dist/v2/components/menu-v2.d.ts +52 -0
  105. package/dist/v2/components/project-avatar-v2.d.ts +11 -0
  106. package/dist/v2/components/radio-v2.d.ts +16 -0
  107. package/dist/v2/components/segmented-control-v2.d.ts +21 -0
  108. package/dist/v2/components/select-v2.d.ts +24 -0
  109. package/dist/v2/components/switch-v2.d.ts +7 -0
  110. package/dist/v2/components/tab-state-indicator.d.ts +2 -0
  111. package/dist/v2/components/tabs-v2.d.ts +34 -0
  112. package/dist/v2/components/text-input-v2.d.ts +17 -0
  113. package/dist/v2/components/text-shimmer-v2.d.ts +9 -0
  114. package/dist/v2/components/textarea-v2.d.ts +7 -0
  115. package/dist/v2/components/toast-v2.d.ts +48 -0
  116. package/dist/v2/components/tooltip-v2.d.ts +13 -0
  117. package/dist/v2/components/wordmark-v2.d.ts +2 -0
  118. package/package.json +59 -15
  119. package/src/styles/tailwind/colors.css +1 -1
@@ -0,0 +1,28 @@
1
+ import { type ComponentProps, type ParentProps } from "solid-js";
2
+ import "./field-v2.css";
3
+ export interface FieldV2Props extends ComponentProps<"div"> {
4
+ invalid?: boolean;
5
+ }
6
+ declare function FieldV2Root(props: ParentProps<FieldV2Props>): import("solid-js").JSX.Element;
7
+ export interface FieldLabelProps extends ComponentProps<"label"> {
8
+ /** When set, shows the info icon with a tooltip containing this text. */
9
+ tooltip?: string;
10
+ }
11
+ declare function FieldLabel(props: ParentProps<FieldLabelProps>): import("solid-js").JSX.Element;
12
+ declare function FieldPrefix(props: ParentProps<ComponentProps<"div">>): import("solid-js").JSX.Element;
13
+ declare function FieldSuffix(props: ParentProps<ComponentProps<"div">>): import("solid-js").JSX.Element;
14
+ /** Optional layout wrapper around the control. */
15
+ declare function FieldControl(props: ParentProps<ComponentProps<"div">>): import("solid-js").JSX.Element;
16
+ export declare const FieldV2: typeof FieldV2Root & {
17
+ Label: typeof FieldLabel;
18
+ Prefix: typeof FieldPrefix;
19
+ Suffix: typeof FieldSuffix;
20
+ Control: typeof FieldControl;
21
+ };
22
+ export declare const Field: typeof FieldV2Root & {
23
+ Label: typeof FieldLabel;
24
+ Prefix: typeof FieldPrefix;
25
+ Suffix: typeof FieldSuffix;
26
+ Control: typeof FieldControl;
27
+ };
28
+ export {};
@@ -0,0 +1,11 @@
1
+ import { Button as Kobalte } from "@kobalte/core/button";
2
+ import { type ComponentProps } from "solid-js";
3
+ import { JSX } from "solid-js";
4
+ import "./icon-button-v2.css";
5
+ export interface IconButtonV2Props extends ComponentProps<typeof Kobalte>, Pick<ComponentProps<"button">, "class" | "classList"> {
6
+ icon?: JSX.Element;
7
+ size?: "small" | "normal" | "large";
8
+ variant?: "neutral" | "contrast" | "ghost" | "ghost-muted";
9
+ state?: "rest" | "hover" | "pressed";
10
+ }
11
+ export declare function IconButtonV2(props: ComponentProps<"button"> & IconButtonV2Props): JSX.Element;
@@ -0,0 +1,81 @@
1
+ import { type ComponentProps } from "solid-js";
2
+ declare const icons: {
3
+ edit: {
4
+ viewBox: string;
5
+ body: string;
6
+ };
7
+ "folder-add-left": {
8
+ viewBox: string;
9
+ body: string;
10
+ };
11
+ "grid-plus": {
12
+ viewBox: string;
13
+ body: string;
14
+ };
15
+ help: {
16
+ viewBox: string;
17
+ body: string;
18
+ };
19
+ "sidebar-right": {
20
+ viewBox: string;
21
+ body: string;
22
+ };
23
+ status: {
24
+ viewBox: string;
25
+ body: string;
26
+ };
27
+ "status-active": {
28
+ viewBox: string;
29
+ body: string;
30
+ };
31
+ "magnifying-glass": {
32
+ viewBox: string;
33
+ body: string;
34
+ };
35
+ menu: {
36
+ viewBox: string;
37
+ body: string;
38
+ };
39
+ plus: {
40
+ viewBox: string;
41
+ body: string;
42
+ };
43
+ "settings-gear": {
44
+ viewBox: string;
45
+ body: string;
46
+ };
47
+ "chevron-down": {
48
+ viewBox: string;
49
+ body: string;
50
+ };
51
+ check: {
52
+ viewBox: string;
53
+ body: string;
54
+ };
55
+ close: {
56
+ viewBox: string;
57
+ body: string;
58
+ };
59
+ "xmark-small": {
60
+ viewBox: string;
61
+ body: string;
62
+ };
63
+ "outline-chevron-down": {
64
+ viewBox: string;
65
+ body: string;
66
+ };
67
+ "outline-dots": {
68
+ viewBox: string;
69
+ body: string;
70
+ };
71
+ archive: {
72
+ viewBox: string;
73
+ body: string;
74
+ };
75
+ };
76
+ export interface IconProps extends ComponentProps<"svg"> {
77
+ name: keyof typeof icons | (string & {});
78
+ size?: "small" | "normal" | "large";
79
+ }
80
+ export declare function Icon(props: IconProps): import("solid-js").JSX.Element;
81
+ export {};
@@ -0,0 +1,21 @@
1
+ import { type ComponentProps, type JSX } from "solid-js";
2
+ import "./inline-input-v2.css";
3
+ export interface InlineInputV2Props extends Omit<ComponentProps<"input">, "type" | "prefix"> {
4
+ /** Inline label shown before the field (prefix segment). */
5
+ prefix: JSX.Element;
6
+ /** Fixed width for the prefix segment (px number or CSS length). Omit for fit-content. */
7
+ labelWidth?: number | string;
8
+ /** Show the trailing copy action. */
9
+ showCopyButton?: boolean;
10
+ /** Accessible label for the copy button. */
11
+ copyLabel?: string;
12
+ onCopyClick?: (event: MouseEvent) => void;
13
+ /** Apply tabular numerals to the prefix and field value. */
14
+ numeric?: boolean;
15
+ /** Error styling for the field and value text. */
16
+ invalid?: boolean;
17
+ /** `base` is 28px tall; `large` is 32px tall. */
18
+ appearance?: "base" | "large";
19
+ type?: ComponentProps<"input">["type"];
20
+ }
21
+ export declare function InlineInputV2(props: InlineInputV2Props): JSX.Element;
@@ -0,0 +1,7 @@
1
+ import { type ComponentProps } from "solid-js";
2
+ import "./keybind-v2.css";
3
+ export interface KeybindV2Props extends ComponentProps<"div"> {
4
+ keys: string[];
5
+ variant?: "neutral" | "ghost";
6
+ }
7
+ export declare function KeybindV2(props: KeybindV2Props): import("solid-js").JSX.Element;
@@ -0,0 +1,28 @@
1
+ import { type ComponentProps, type JSX } from "solid-js";
2
+ import "./line-comment-v2.css";
3
+ /** Horizontal “more” glyph for the display-card overflow control (Figma outline-dots). */
4
+ export declare function LineCommentV2OverflowIcon(props: ComponentProps<"svg">): JSX.Element;
5
+ export interface LineCommentV2Props extends ComponentProps<"div"> {
6
+ /** Main comment body (text or rich content). */
7
+ comment: JSX.Element;
8
+ /** Line / selection context (e.g. “Comment on line 40”). */
9
+ selection: JSX.Element;
10
+ /** Typically an overflow menu trigger; use `LineCommentV2OverflowIcon` inside `line-comment-v2-overflow`. */
11
+ actions?: JSX.Element;
12
+ }
13
+ export declare function LineCommentV2(props: LineCommentV2Props): JSX.Element;
14
+ export interface LineCommentEditorV2Props extends Omit<ComponentProps<"div">, "children" | "onInput" | "onSubmit"> {
15
+ /** Visible field label above the textarea (default: “Comment”). */
16
+ heading?: JSX.Element | string;
17
+ value: string;
18
+ onInput: (value: string) => void;
19
+ onCancel: () => void;
20
+ onSubmit: (value: string) => void;
21
+ selection: JSX.Element;
22
+ placeholder?: string;
23
+ rows?: number;
24
+ cancelLabel?: string;
25
+ submitLabel?: string;
26
+ autofocus?: boolean;
27
+ }
28
+ export declare function LineCommentEditorV2(props: LineCommentEditorV2Props): JSX.Element;
@@ -0,0 +1,52 @@
1
+ import { DropdownMenu } from "@kobalte/core/dropdown-menu";
2
+ import { ContextMenu } from "@kobalte/core/context-menu";
3
+ import { type ComponentProps, type JSX, type ParentProps } from "solid-js";
4
+ import "./menu-v2.css";
5
+ export interface MenuV2ItemProps extends ComponentProps<typeof DropdownMenu.Item> {
6
+ shortcut?: JSX.Element | string;
7
+ badge?: JSX.Element | string;
8
+ }
9
+ declare function MenuV2Item(props: ParentProps<MenuV2ItemProps>): JSX.Element;
10
+ export interface MenuV2CheckboxItemProps extends ComponentProps<typeof DropdownMenu.CheckboxItem> {
11
+ shortcut?: JSX.Element | string;
12
+ badge?: JSX.Element | string;
13
+ }
14
+ declare function MenuV2CheckboxItem(props: ParentProps<MenuV2CheckboxItemProps>): JSX.Element;
15
+ export interface MenuV2RadioItemProps extends ComponentProps<typeof DropdownMenu.RadioItem> {
16
+ shortcut?: JSX.Element | string;
17
+ badge?: JSX.Element | string;
18
+ }
19
+ declare function MenuV2RadioItem(props: ParentProps<MenuV2RadioItemProps>): JSX.Element;
20
+ export interface MenuV2SubTriggerProps extends ComponentProps<typeof DropdownMenu.SubTrigger> {
21
+ shortcut?: JSX.Element | string;
22
+ badge?: JSX.Element | string;
23
+ }
24
+ declare function MenuV2SubTrigger(props: ParentProps<MenuV2SubTriggerProps>): JSX.Element;
25
+ declare function MenuV2SubContent(props: ComponentProps<typeof DropdownMenu.SubContent>): JSX.Element;
26
+ declare function MenuV2GroupLabel(props: ComponentProps<typeof DropdownMenu.GroupLabel>): JSX.Element;
27
+ declare function MenuV2Separator(props: ComponentProps<typeof DropdownMenu.Separator>): JSX.Element;
28
+ declare function MenuV2Content(props: ComponentProps<typeof DropdownMenu.Content>): JSX.Element;
29
+ declare function MenuV2Root(props: ComponentProps<typeof DropdownMenu>): JSX.Element;
30
+ declare function MenuV2ContextRoot(props: ComponentProps<typeof ContextMenu>): JSX.Element;
31
+ declare function MenuV2ContextContent(props: ComponentProps<typeof ContextMenu.Content>): JSX.Element;
32
+ export declare const MenuV2: typeof MenuV2Root & {
33
+ Trigger: typeof import("@kobalte/core/dropdown-menu").Trigger;
34
+ Portal: typeof import("@kobalte/core/context-menu").Portal;
35
+ Content: typeof MenuV2Content;
36
+ Item: typeof MenuV2Item;
37
+ CheckboxItem: typeof MenuV2CheckboxItem;
38
+ RadioGroup: typeof import("@kobalte/core/context-menu").RadioGroup;
39
+ RadioItem: typeof MenuV2RadioItem;
40
+ Group: typeof import("@kobalte/core/context-menu").Group;
41
+ GroupLabel: typeof MenuV2GroupLabel;
42
+ Separator: typeof MenuV2Separator;
43
+ Sub: typeof import("@kobalte/core/context-menu").Sub;
44
+ SubTrigger: typeof MenuV2SubTrigger;
45
+ SubContent: typeof MenuV2SubContent;
46
+ Context: typeof MenuV2ContextRoot & {
47
+ Trigger: typeof import("@kobalte/core/context-menu").Trigger;
48
+ Portal: typeof import("@kobalte/core/context-menu").Portal;
49
+ Content: typeof MenuV2ContextContent;
50
+ };
51
+ };
52
+ export {};
@@ -0,0 +1,11 @@
1
+ import { type ComponentProps } from "solid-js";
2
+ import "./project-avatar-v2.css";
3
+ export declare const PROJECT_AVATAR_VARIANTS: readonly ["orange", "yellow", "cyan", "green", "red", "pink", "blue", "purple", "gray"];
4
+ export type ProjectAvatarVariant = (typeof PROJECT_AVATAR_VARIANTS)[number];
5
+ export interface ProjectAvatarProps extends ComponentProps<"div"> {
6
+ fallback: string;
7
+ src?: string;
8
+ variant?: ProjectAvatarVariant;
9
+ unread?: boolean;
10
+ }
11
+ export declare function ProjectAvatar(props: ProjectAvatarProps): import("solid-js").JSX.Element;
@@ -0,0 +1,16 @@
1
+ import { RadioGroup as Kobalte } from "@kobalte/core/radio-group";
2
+ import { type JSX } from "solid-js";
3
+ import type { ComponentProps, ParentProps } from "solid-js";
4
+ import "./radio-v2.css";
5
+ export interface RadioGroupV2Props extends ParentProps<ComponentProps<typeof Kobalte>> {
6
+ label?: JSX.Element;
7
+ description?: JSX.Element;
8
+ hideLabel?: boolean;
9
+ }
10
+ export declare function RadioGroupV2(props: RadioGroupV2Props): JSX.Element;
11
+ export interface RadioItemV2Props extends ComponentProps<typeof Kobalte.Item> {
12
+ label: JSX.Element;
13
+ description?: JSX.Element;
14
+ hideLabel?: boolean;
15
+ }
16
+ export declare function RadioItemV2(props: RadioItemV2Props): JSX.Element;
@@ -0,0 +1,21 @@
1
+ import { type JSX, type ParentProps } from "solid-js";
2
+ import type { ComponentProps } from "solid-js";
3
+ import "./segmented-control-v2.css";
4
+ type OnChange = (value: string | null) => void;
5
+ export type SegmentedControlV2Props = Omit<ComponentProps<"div">, "onChange"> & ParentProps<{
6
+ /** Selected value when controlled (including `null` when empty). Omit key for uncontrolled. */
7
+ value?: string | null;
8
+ /** Initial value when uncontrolled. */
9
+ defaultValue?: string;
10
+ onChange?: OnChange;
11
+ /** When true, clicking the active segment clears selection (`onChange(null)`). Default false. */
12
+ allowDeselect?: boolean;
13
+ disabled?: boolean;
14
+ }>;
15
+ export declare function SegmentedControlV2(props: SegmentedControlV2Props): JSX.Element;
16
+ export type SegmentedControlItemV2Props = Omit<ComponentProps<"button">, "type" | "children"> & ParentProps<{
17
+ value: string;
18
+ children: JSX.Element;
19
+ }>;
20
+ export declare function SegmentedControlItemV2(props: SegmentedControlItemV2Props): JSX.Element;
21
+ export {};
@@ -0,0 +1,24 @@
1
+ import { Select as Kobalte } from "@kobalte/core/select";
2
+ import { type ComponentProps, type JSX } from "solid-js";
3
+ import "./select-v2.css";
4
+ export type SelectV2Props<T> = Omit<ComponentProps<typeof Kobalte<T, {
5
+ category: string;
6
+ options: T[];
7
+ }>>, "value" | "onSelect" | "children" | "options" | "itemComponent" | "sectionComponent" | "defaultValue" | "multiple"> & {
8
+ placeholder?: string;
9
+ options: T[];
10
+ /** Selected option (single selection). */
11
+ current?: T;
12
+ value?: (x: T) => string;
13
+ label?: (x: T) => string;
14
+ groupBy?: (x: T) => string;
15
+ onSelect?: (value: T | null) => void;
16
+ onHighlight?: (value: T | undefined) => void | (() => void);
17
+ /** `base` / `large` match text-input-v2; `inline` is a compact settings-row trigger. */
18
+ appearance?: "base" | "large" | "inline";
19
+ invalid?: boolean;
20
+ numeric?: boolean;
21
+ children?: (item: T) => JSX.Element;
22
+ valueClass?: string;
23
+ };
24
+ export declare function SelectV2<T>(props: SelectV2Props<T>): JSX.Element;
@@ -0,0 +1,7 @@
1
+ import { Switch as Kobalte } from "@kobalte/core/switch";
2
+ import type { ComponentProps, ParentProps } from "solid-js";
3
+ import "./switch-v2.css";
4
+ export interface SwitchProps extends ParentProps<ComponentProps<typeof Kobalte>> {
5
+ hideLabel?: boolean;
6
+ }
7
+ export declare function Switch(props: SwitchProps): import("solid-js").JSX.Element;
@@ -0,0 +1,2 @@
1
+ import { type ComponentProps } from "solid-js";
2
+ export declare function TabStateIndicator(props: ComponentProps<"svg">): import("solid-js").JSX.Element;
@@ -0,0 +1,34 @@
1
+ import { Tabs as Kobalte } from "@kobalte/core/tabs";
2
+ import { type JSX } from "solid-js";
3
+ import type { ComponentProps, ParentProps, Component } from "solid-js";
4
+ import "./tabs-v2.css";
5
+ export interface TabsV2Props extends ComponentProps<typeof Kobalte> {
6
+ variant?: "normal" | "pill" | "settings";
7
+ orientation?: "horizontal" | "vertical";
8
+ }
9
+ export interface TabsV2ListProps extends ComponentProps<typeof Kobalte.List> {
10
+ }
11
+ export interface TabsV2TriggerProps extends ComponentProps<typeof Kobalte.Trigger> {
12
+ onMiddleClick?: () => void;
13
+ /** Optional subtext shown beside the primary content (muted style) */
14
+ subtext?: JSX.Element | string;
15
+ }
16
+ export interface TabsV2CloseButtonProps extends ComponentProps<"div"> {
17
+ }
18
+ export interface TabsV2ContentProps extends ComponentProps<typeof Kobalte.Content> {
19
+ }
20
+ declare function TabsV2Root(props: TabsV2Props): JSX.Element;
21
+ declare function TabsV2List(props: TabsV2ListProps): JSX.Element;
22
+ declare function TabsV2Trigger(props: ParentProps<TabsV2TriggerProps>): JSX.Element;
23
+ declare function TabsV2CloseButton(props: TabsV2CloseButtonProps): JSX.Element;
24
+ declare function TabsV2Content(props: ParentProps<TabsV2ContentProps>): JSX.Element;
25
+ export declare const TabsV2: typeof TabsV2Root & {
26
+ List: typeof TabsV2List;
27
+ Trigger: typeof TabsV2Trigger;
28
+ CloseButton: typeof TabsV2CloseButton;
29
+ Content: typeof TabsV2Content;
30
+ SectionTitle: Component<{
31
+ children?: JSX.Element;
32
+ }>;
33
+ };
34
+ export {};
@@ -0,0 +1,17 @@
1
+ import { type ComponentProps } from "solid-js";
2
+ import "./text-input-v2.css";
3
+ export interface TextInputV2Props extends Omit<ComponentProps<"input">, "type"> {
4
+ /** Show the trailing copy action. */
5
+ showCopyButton?: boolean;
6
+ /** Accessible label for the copy button. */
7
+ copyLabel?: string;
8
+ onCopyClick?: (event: MouseEvent) => void;
9
+ /** Apply tabular numerals to the field value. */
10
+ numeric?: boolean;
11
+ /** Error styling for the field and value text. */
12
+ invalid?: boolean;
13
+ /** `base` is 28px tall; `large` is 32px tall. */
14
+ appearance?: "base" | "large";
15
+ type?: ComponentProps<"input">["type"];
16
+ }
17
+ export declare function TextInputV2(props: TextInputV2Props): import("solid-js").JSX.Element;
@@ -0,0 +1,9 @@
1
+ import { type ValidComponent } from "solid-js";
2
+ import "./text-shimmer-v2.css";
3
+ export declare const TextShimmerV2: <T extends ValidComponent = "span">(props: {
4
+ text: string;
5
+ class?: string;
6
+ as?: T;
7
+ active?: boolean;
8
+ offset?: number;
9
+ }) => import("solid-js").JSX.Element;
@@ -0,0 +1,7 @@
1
+ import { type ComponentProps } from "solid-js";
2
+ import "./textarea-v2.css";
3
+ export interface TextareaV2Props extends ComponentProps<"textarea"> {
4
+ /** Error styling for the field and value text. */
5
+ invalid?: boolean;
6
+ }
7
+ export declare function TextareaV2(props: TextareaV2Props): import("solid-js").JSX.Element;
@@ -0,0 +1,48 @@
1
+ import { Toast as Kobalte, toaster } from "@kobalte/core/toast";
2
+ import type { ToastRootProps, ToastCloseButtonProps, ToastTitleProps, ToastDescriptionProps } from "@kobalte/core/toast";
3
+ import type { ComponentProps, JSX } from "solid-js";
4
+ import "./toast-v2.css";
5
+ export interface ToastV2RegionProps extends ComponentProps<typeof Kobalte.Region> {
6
+ }
7
+ declare function ToastV2Region(props: ToastV2RegionProps): JSX.Element;
8
+ export interface ToastV2RootComponentProps extends ToastRootProps {
9
+ class?: string;
10
+ classList?: ComponentProps<"li">["classList"];
11
+ children?: JSX.Element;
12
+ }
13
+ declare function ToastV2Root(props: ToastV2RootComponentProps): JSX.Element;
14
+ declare function ToastV2Icon(props: ComponentProps<"div">): JSX.Element;
15
+ declare function ToastV2Content(props: ComponentProps<"div">): JSX.Element;
16
+ declare function ToastV2Title(props: ToastTitleProps & ComponentProps<"div">): JSX.Element;
17
+ declare function ToastV2Description(props: ToastDescriptionProps & ComponentProps<"div">): JSX.Element;
18
+ declare function ToastV2Actions(props: ComponentProps<"div">): JSX.Element;
19
+ declare function ToastV2CloseButton(props: ToastCloseButtonProps & ComponentProps<"button">): JSX.Element;
20
+ export declare const ToastV2: typeof ToastV2Root & {
21
+ Region: typeof ToastV2Region;
22
+ Icon: typeof ToastV2Icon;
23
+ Content: typeof ToastV2Content;
24
+ Title: typeof ToastV2Title;
25
+ Description: typeof ToastV2Description;
26
+ Actions: typeof ToastV2Actions;
27
+ CloseButton: typeof ToastV2CloseButton;
28
+ };
29
+ export { toaster as toasterV2 };
30
+ export interface ToastV2Action {
31
+ label: string;
32
+ variant?: "primary" | "secondary";
33
+ onClick: "dismiss" | (() => void);
34
+ }
35
+ export interface ToastV2Options {
36
+ title?: string;
37
+ description?: string;
38
+ icon?: JSX.Element;
39
+ duration?: number;
40
+ persistent?: boolean;
41
+ actions?: ToastV2Action[];
42
+ }
43
+ export declare function showToastV2(options: ToastV2Options | string): number;
44
+ export interface ToastV2PromiseOptions<T, U = unknown> {
45
+ loading?: JSX.Element;
46
+ success?: (data: T) => JSX.Element;
47
+ error?: (error: U) => JSX.Element;
48
+ }
@@ -0,0 +1,13 @@
1
+ import { Tooltip as KobalteTooltip } from "@kobalte/core/tooltip";
2
+ import { type JSX } from "solid-js";
3
+ import type { ComponentProps } from "solid-js";
4
+ import "./tooltip-v2.css";
5
+ export interface TooltipV2Props extends ComponentProps<typeof KobalteTooltip> {
6
+ value: JSX.Element;
7
+ class?: string;
8
+ contentClass?: string;
9
+ contentStyle?: JSX.CSSProperties;
10
+ inactive?: boolean;
11
+ forceOpen?: boolean;
12
+ }
13
+ export declare function TooltipV2(props: TooltipV2Props): JSX.Element;
@@ -0,0 +1,2 @@
1
+ import { type ComponentProps } from "solid-js";
2
+ export declare function WordmarkV2(props: Pick<ComponentProps<"svg">, "class">): import("solid-js").JSX.Element;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opencode-ai/ui",
3
- "version": "0.0.0-dev-202606260805",
3
+ "version": "0.0.0-dev-202606260844",
4
4
  "type": "module",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -15,6 +15,7 @@
15
15
  "**/*.css"
16
16
  ],
17
17
  "files": [
18
+ "dist/**/*.d.ts",
18
19
  "src/**/*.ts",
19
20
  "src/**/*.tsx",
20
21
  "!src/**/*.test.ts",
@@ -33,28 +34,71 @@
33
34
  ],
34
35
  "exports": {
35
36
  "./package.json": "./package.json",
36
- "./*": "./src/components/*.tsx",
37
- "./i18n/*": "./src/i18n/*.ts",
38
- "./hooks": "./src/hooks/index.ts",
39
- "./context": "./src/context/index.ts",
40
- "./context/*": "./src/context/*.tsx",
41
- "./storybook/scaffold": "./src/storybook/scaffold.tsx",
42
- "./storybook/fixtures": "./src/storybook/fixtures.ts",
37
+ "./*": {
38
+ "types": "./dist/components/*.d.ts",
39
+ "import": "./src/components/*.tsx"
40
+ },
41
+ "./i18n/*": {
42
+ "types": "./dist/i18n/*.d.ts",
43
+ "import": "./src/i18n/*.ts"
44
+ },
45
+ "./hooks": {
46
+ "types": "./dist/hooks/index.d.ts",
47
+ "import": "./src/hooks/index.ts"
48
+ },
49
+ "./context": {
50
+ "types": "./dist/context/index.d.ts",
51
+ "import": "./src/context/index.ts"
52
+ },
53
+ "./context/*": {
54
+ "types": "./dist/context/*.d.ts",
55
+ "import": "./src/context/*.tsx"
56
+ },
57
+ "./storybook/scaffold": {
58
+ "types": "./dist/storybook/scaffold.d.ts",
59
+ "import": "./src/storybook/scaffold.tsx"
60
+ },
61
+ "./storybook/fixtures": {
62
+ "types": "./dist/storybook/fixtures.d.ts",
63
+ "import": "./src/storybook/fixtures.ts"
64
+ },
43
65
  "./styles": "./src/styles/index.css",
44
66
  "./styles/tailwind": "./src/styles/tailwind/index.css",
45
- "./theme": "./src/theme/index.ts",
46
- "./theme/*": "./src/theme/*.ts",
47
- "./theme/context": "./src/theme/context.tsx",
48
- "./icons/provider": "./src/components/provider-icons/types.ts",
49
- "./icons/file-type": "./src/components/file-icons/types.ts",
50
- "./icons/app": "./src/components/app-icons/types.ts",
67
+ "./theme": {
68
+ "types": "./dist/theme/index.d.ts",
69
+ "import": "./src/theme/index.ts"
70
+ },
71
+ "./theme/*": {
72
+ "types": "./dist/theme/*.d.ts",
73
+ "import": "./src/theme/*.ts"
74
+ },
75
+ "./theme/context": {
76
+ "types": "./dist/theme/context.d.ts",
77
+ "import": "./src/theme/context.tsx"
78
+ },
79
+ "./icons/provider": {
80
+ "types": "./dist/components/provider-icons/types.d.ts",
81
+ "import": "./src/components/provider-icons/types.ts"
82
+ },
83
+ "./icons/file-type": {
84
+ "types": "./dist/components/file-icons/types.d.ts",
85
+ "import": "./src/components/file-icons/types.ts"
86
+ },
87
+ "./icons/app": {
88
+ "types": "./dist/components/app-icons/types.d.ts",
89
+ "import": "./src/components/app-icons/types.ts"
90
+ },
51
91
  "./fonts/*": "./src/assets/fonts/*",
52
92
  "./audio/*": "./src/assets/audio/*",
53
93
  "./v2/*.css": "./src/v2/components/*.css",
54
- "./v2/*": "./src/v2/components/*.tsx",
94
+ "./v2/*": {
95
+ "types": "./dist/v2/components/*.d.ts",
96
+ "import": "./src/v2/components/*.tsx"
97
+ },
55
98
  "./v2/styles/*": "./src/v2/styles/*"
56
99
  },
57
100
  "scripts": {
101
+ "build": "rm -rf dist && tsc -p tsconfig.build.json",
58
102
  "typecheck": "tsgo --noEmit",
59
103
  "test": "bun test src --only-failures",
60
104
  "dev": "vite",
@@ -283,4 +283,4 @@
283
283
  --color-v2-state-bg-info: var(--v2-state-bg-info);
284
284
  --color-v2-state-fg-info: var(--v2-state-fg-info);
285
285
  --color-v2-state-border-info: var(--v2-state-border-info);
286
- }
286
+ }