@nikala-ui/core 0.10.1 → 0.11.0-nightly.b01fa01

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 (106) hide show
  1. package/package.json +1 -1
  2. package/registry/banner.json +1 -1
  3. package/registry/bubble.json +18 -0
  4. package/registry/button-group.json +20 -0
  5. package/registry/button.json +1 -1
  6. package/registry/checkbox.json +4 -1
  7. package/registry/combobox.json +1 -1
  8. package/registry/command.json +3 -2
  9. package/registry/context-menu.json +1 -1
  10. package/registry/create-app-updater.json +13 -0
  11. package/registry/create-chat-scroll.json +13 -0
  12. package/registry/create-document-tabs.json +13 -0
  13. package/registry/create-drop-zone.json +13 -0
  14. package/registry/create-global-shortcut.json +13 -0
  15. package/registry/create-pagination.json +13 -0
  16. package/registry/create-tauri-window.json +13 -0
  17. package/registry/dialog.json +1 -1
  18. package/registry/dropdown-menu.json +3 -2
  19. package/registry/dropzone.json +21 -0
  20. package/registry/field.json +1 -1
  21. package/registry/footer.json +18 -0
  22. package/registry/forgot-password-01.json +28 -0
  23. package/registry/form-message.json +3 -2
  24. package/registry/hero-01.json +22 -0
  25. package/registry/icon-button.json +1 -1
  26. package/registry/index.json +432 -5
  27. package/registry/login-01.json +28 -0
  28. package/registry/marker.json +17 -0
  29. package/registry/marquee.json +17 -0
  30. package/registry/message.json +17 -0
  31. package/registry/navbar.json +19 -0
  32. package/registry/navigation-menu.json +22 -0
  33. package/registry/number-input.json +1 -1
  34. package/registry/otp-verification-01.json +26 -0
  35. package/registry/pagination.json +22 -0
  36. package/registry/popover.json +4 -1
  37. package/registry/rating.json +19 -0
  38. package/registry/register-01.json +31 -0
  39. package/registry/resizable.json +1 -1
  40. package/registry/review-card.json +23 -0
  41. package/registry/scroll-area.json +1 -1
  42. package/registry/select.json +3 -2
  43. package/registry/sheet.json +1 -1
  44. package/registry/sidebar.json +24 -0
  45. package/registry/spinner.json +1 -1
  46. package/registry/stat.json +19 -0
  47. package/registry/status.json +1 -1
  48. package/registry/switch.json +4 -1
  49. package/registry/table.json +17 -0
  50. package/registry/tabs.json +4 -1
  51. package/registry/theme-manager.json +4 -3
  52. package/registry/timeline.json +18 -0
  53. package/registry/titlebar-tabs.json +24 -0
  54. package/registry/titlebar.json +26 -0
  55. package/registry/toggle-group.json +21 -0
  56. package/registry/updater-modal.json +26 -0
  57. package/src/registry/blocks/forgot-password-01.tsx +141 -0
  58. package/src/registry/blocks/hero-01.tsx +28 -0
  59. package/src/registry/blocks/login-01.tsx +231 -0
  60. package/src/registry/blocks/otp-verification-01.tsx +170 -0
  61. package/src/registry/blocks/register-01.tsx +318 -0
  62. package/src/registry/components/ui/banner.tsx +0 -2
  63. package/src/registry/components/ui/bubble.tsx +142 -0
  64. package/src/registry/components/ui/button-group.tsx +42 -0
  65. package/src/registry/components/ui/button.tsx +1 -1
  66. package/src/registry/components/ui/checkbox.tsx +1 -1
  67. package/src/registry/components/ui/combobox.tsx +83 -18
  68. package/src/registry/components/ui/command.tsx +101 -105
  69. package/src/registry/components/ui/context-menu.tsx +67 -22
  70. package/src/registry/components/ui/dialog.tsx +42 -32
  71. package/src/registry/components/ui/dropdown-menu.tsx +69 -31
  72. package/src/registry/components/ui/dropzone.tsx +189 -0
  73. package/src/registry/components/ui/field.tsx +7 -3
  74. package/src/registry/components/ui/footer.tsx +247 -0
  75. package/src/registry/components/ui/form-message.tsx +2 -2
  76. package/src/registry/components/ui/icon-button.tsx +1 -1
  77. package/src/registry/components/ui/marker.tsx +102 -0
  78. package/src/registry/components/ui/marquee.tsx +118 -0
  79. package/src/registry/components/ui/message.tsx +168 -0
  80. package/src/registry/components/ui/navbar.tsx +375 -0
  81. package/src/registry/components/ui/navigation-menu.tsx +358 -0
  82. package/src/registry/components/ui/number-input.tsx +3 -3
  83. package/src/registry/components/ui/pagination.tsx +258 -0
  84. package/src/registry/components/ui/popover.tsx +1 -1
  85. package/src/registry/components/ui/rating.tsx +185 -0
  86. package/src/registry/components/ui/resizable.tsx +3 -1
  87. package/src/registry/components/ui/review-card.tsx +195 -0
  88. package/src/registry/components/ui/scroll-area.tsx +13 -3
  89. package/src/registry/components/ui/select.tsx +16 -19
  90. package/src/registry/components/ui/sheet.tsx +58 -53
  91. package/src/registry/components/ui/sidebar.tsx +692 -0
  92. package/src/registry/components/ui/spinner.tsx +1 -1
  93. package/src/registry/components/ui/stat.tsx +245 -0
  94. package/src/registry/components/ui/status.tsx +7 -5
  95. package/src/registry/components/ui/switch.tsx +1 -1
  96. package/src/registry/components/ui/table.tsx +160 -0
  97. package/src/registry/components/ui/tabs.tsx +1 -1
  98. package/src/registry/components/ui/theme-toggle.tsx +80 -79
  99. package/src/registry/components/ui/timeline.tsx +350 -0
  100. package/src/registry/components/ui/titlebar-tabs.tsx +412 -0
  101. package/src/registry/components/ui/titlebar.tsx +399 -0
  102. package/src/registry/components/ui/toggle-group.tsx +203 -0
  103. package/src/registry/components/ui/updater-modal.tsx +254 -0
  104. package/src/registry/index.ts +3 -3
  105. package/src/registry/metadata.ts +184 -5
  106. package/src/registry/providers/theme-transitions.ts +81 -50
@@ -3,7 +3,7 @@ import * as DialogPrimitive from "@kobalte/core/dialog";
3
3
  import type { PolymorphicProps } from "@kobalte/core/polymorphic";
4
4
  import { cva, type VariantProps } from "class-variance-authority";
5
5
  import { X } from "lucide-solid";
6
- import { ScrollArea } from "./scroll-area";
6
+ import { ScrollArea } from "@/components/ui/scroll-area";
7
7
  import { cn } from "@/lib/cn";
8
8
 
9
9
  // Global CSS Keyframe Animations specifically designed for Kobalte animationend DOM events
@@ -15,7 +15,7 @@ const sheetStyles = `
15
15
  @keyframes sheet-slide-in-top { from { transform: translateY(-100%); } to { transform: translateY(0); } }
16
16
  @keyframes sheet-slide-out-top { from { transform: translateY(0); } to { transform: translateY(-100%); } }
17
17
  @keyframes sheet-slide-in-bottom { from { transform: translateY(100%); } to { transform: translateY(0); } }
18
- @keyframes sheet-slide-out-bottom { from { transform: translateY(0); } to { transform: translateY(-100%); } }
18
+ @keyframes sheet-slide-out-bottom { from { transform: translateY(0); } to { transform: translateY(100%); } }
19
19
  @keyframes sheet-fade-in { from { opacity: 0; } to { opacity: 1; } }
20
20
  @keyframes sheet-fade-out { from { opacity: 1; } to { opacity: 0; } }
21
21
  `;
@@ -28,12 +28,10 @@ export const sheetVariants = cva(
28
28
  {
29
29
  variants: {
30
30
  side: {
31
- top: "inset-x-0 top-0 border-b data-[expanded]:animate-[sheet-slide-in-top_300ms_ease-in-out] data-[closed]:animate-[sheet-slide-out-top_300ms_ease-in-out]",
32
- bottom:
33
- "inset-x-0 bottom-0 border-t data-[expanded]:animate-[sheet-slide-in-bottom_300ms_ease-in-out] data-[closed]:animate-[sheet-slide-out-bottom_300ms_ease-in-out]",
34
- left: "inset-y-0 left-0 h-full w-3/4 border-r sm:max-w-sm data-[expanded]:animate-[sheet-slide-in-left_300ms_ease-in-out] data-[closed]:animate-[sheet-slide-out-left_300ms_ease-in-out]",
35
- right:
36
- "inset-y-0 right-0 h-full w-3/4 border-l sm:max-w-sm data-[expanded]:animate-[sheet-slide-in-right_300ms_ease-in-out] data-[closed]:animate-[sheet-slide-out-right_300ms_ease-in-out]",
31
+ left: "fixed top-0 bottom-0 left-0 w-3/4 border-r border-border sm:max-w-sm data-[expanded]:animate-[sheet-slide-in-left_300ms_ease-in-out] data-[closed]:animate-[sheet-slide-out-left_300ms_ease-in-out]",
32
+ right: "fixed top-0 bottom-0 right-0 w-3/4 border-l border-border sm:max-w-sm data-[expanded]:animate-[sheet-slide-in-right_300ms_ease-in-out] data-[closed]:animate-[sheet-slide-out-right_300ms_ease-in-out]",
33
+ top: "fixed top-0 left-0 right-0 border-b border-border data-[expanded]:animate-[sheet-slide-in-top_300ms_ease-in-out] data-[closed]:animate-[sheet-slide-out-top_300ms_ease-in-out]",
34
+ bottom: "fixed bottom-0 left-0 right-0 border-t border-border data-[expanded]:animate-[sheet-slide-in-bottom_300ms_ease-in-out] data-[closed]:animate-[sheet-slide-out-bottom_300ms_ease-in-out]",
37
35
  },
38
36
  },
39
37
  defaultVariants: {
@@ -42,20 +40,23 @@ export const sheetVariants = cva(
42
40
  }
43
41
  );
44
42
 
45
- export const Sheet = DialogPrimitive.Root;
43
+ export type SheetRootProps = DialogPrimitive.DialogRootProps;
44
+
45
+ export const Sheet: Component<SheetRootProps> = (props) => {
46
+ return <DialogPrimitive.Root {...props} />;
47
+ };
48
+
46
49
  export const SheetTrigger = DialogPrimitive.Trigger;
47
50
  export const SheetClose = DialogPrimitive.CloseButton;
48
- export const SheetPortal = DialogPrimitive.Portal;
49
51
 
50
- export type SheetOverlayProps<T extends ValidComponent = "div"> =
51
- DialogPrimitive.DialogOverlayProps<T> & {
52
- /** Whether to apply backdrop blur (default: true) */
53
- blur?: boolean;
54
- class?: string;
55
- };
52
+ export interface SheetOverlayProps<T extends ValidComponent = "div"> {
53
+ /** Whether to apply background blur effect or keep transparent (default: true) */
54
+ blur?: boolean;
55
+ class?: string;
56
+ }
56
57
 
57
58
  /**
58
- * Fullscreen dark backdrop with fade keyframe animation.
59
+ * Backdrop overlay wrapper with fade-in and fade-out animations.
59
60
  */
60
61
  export const SheetOverlay = <T extends ValidComponent = "div">(
61
62
  props: PolymorphicProps<T, SheetOverlayProps<T>>
@@ -65,8 +66,8 @@ export const SheetOverlay = <T extends ValidComponent = "div">(
65
66
  return (
66
67
  <DialogPrimitive.Overlay
67
68
  class={cn(
68
- "fixed inset-0 z-50 transition-all duration-200 data-[expanded]:animate-[sheet-fade-in_300ms_ease-in-out] data-[closed]:animate-[sheet-fade-out_300ms_ease-in-out]",
69
- local.blur !== false ? "bg-black/80 backdrop-blur-sm" : "bg-black/80",
69
+ "fixed inset-0 z-50 data-[expanded]:animate-[sheet-fade-in_300ms_ease-in-out] data-[closed]:animate-[sheet-fade-out_300ms_ease-in-out]",
70
+ local.blur !== false ? "bg-black/80 backdrop-blur-sm" : "bg-transparent",
70
71
  local.class
71
72
  )}
72
73
  {...(rest as any)}
@@ -76,28 +77,32 @@ export const SheetOverlay = <T extends ValidComponent = "div">(
76
77
 
77
78
  export type SheetContentProps<T extends ValidComponent = "div"> =
78
79
  DialogPrimitive.DialogContentProps<T> &
79
- VariantProps<typeof sheetVariants> & {
80
- side?: "top" | "bottom" | "left" | "right";
81
- showCloseButton?: boolean;
82
- closeOnOutsideClick?: boolean;
83
- blur?: boolean;
84
- class?: string;
85
- children?: JSX.Element;
86
- };
80
+ VariantProps<typeof sheetVariants> & {
81
+ /** Direction from which the sheet slides out: top, bottom, left, right */
82
+ side?: "top" | "bottom" | "left" | "right";
83
+ /** Whether to display the top-right close (X) button (default: true) */
84
+ showCloseButton?: boolean;
85
+ /** Whether clicking outside closes the sheet (default: true) */
86
+ closeOnOutsideClick?: boolean;
87
+ /** Whether to apply background backdrop blur (default: true) */
88
+ blur?: boolean;
89
+ class?: string;
90
+ children?: JSX.Element;
91
+ };
87
92
 
88
93
  /**
89
- * Slide-out panel container with ScrollArea and animation support.
94
+ * Main sheet container with smooth CSS keyframe slide animations.
90
95
  */
91
96
  export const SheetContent = <T extends ValidComponent = "div">(
92
97
  props: PolymorphicProps<T, SheetContentProps<T>>
93
98
  ) => {
94
99
  const [local, rest] = splitProps(props as SheetContentProps, [
95
- "class",
96
- "children",
97
100
  "side",
98
101
  "showCloseButton",
99
102
  "closeOnOutsideClick",
100
103
  "blur",
104
+ "class",
105
+ "children",
101
106
  "onPointerDownOutside",
102
107
  "onInteractOutside",
103
108
  ]);
@@ -123,7 +128,7 @@ export const SheetContent = <T extends ValidComponent = "div">(
123
128
  };
124
129
 
125
130
  return (
126
- <SheetPortal>
131
+ <DialogPrimitive.Portal>
127
132
  <style>{sheetStyles}</style>
128
133
  <SheetOverlay blur={local.blur} />
129
134
  <DialogPrimitive.Content
@@ -144,7 +149,7 @@ export const SheetContent = <T extends ValidComponent = "div">(
144
149
  </DialogPrimitive.CloseButton>
145
150
  </Show>
146
151
  </DialogPrimitive.Content>
147
- </SheetPortal>
152
+ </DialogPrimitive.Portal>
148
153
  );
149
154
  };
150
155
 
@@ -172,44 +177,44 @@ export const SheetFooter: Component<SheetFooterProps> = (props) => {
172
177
 
173
178
  return (
174
179
  <div
175
- class={cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2 pt-4", local.class)}
180
+ class={cn("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", local.class)}
176
181
  {...rest}
177
182
  />
178
183
  );
179
184
  };
180
185
 
181
- export interface SheetTitleProps {
182
- class?: string;
183
- children?: JSX.Element;
184
- }
186
+ export type SheetTitleProps<T extends ValidComponent = "h2"> =
187
+ DialogPrimitive.DialogTitleProps<T> & {
188
+ class?: string;
189
+ };
185
190
 
186
- export const SheetTitle: Component<SheetTitleProps> = (props) => {
187
- const [local, rest] = splitProps(props, ["class", "children"]);
191
+ export const SheetTitle = <T extends ValidComponent = "h2">(
192
+ props: PolymorphicProps<T, SheetTitleProps<T>>
193
+ ) => {
194
+ const [local, rest] = splitProps(props as SheetTitleProps, ["class"]);
188
195
 
189
196
  return (
190
197
  <DialogPrimitive.Title
191
198
  class={cn("text-lg font-semibold text-foreground", local.class)}
192
- {...rest}
193
- >
194
- {local.children}
195
- </DialogPrimitive.Title>
199
+ {...(rest as any)}
200
+ />
196
201
  );
197
202
  };
198
203
 
199
- export interface SheetDescriptionProps {
200
- class?: string;
201
- children?: JSX.Element;
202
- }
204
+ export type SheetDescriptionProps<T extends ValidComponent = "p"> =
205
+ DialogPrimitive.DialogDescriptionProps<T> & {
206
+ class?: string;
207
+ };
203
208
 
204
- export const SheetDescription: Component<SheetDescriptionProps> = (props) => {
205
- const [local, rest] = splitProps(props, ["class", "children"]);
209
+ export const SheetDescription = <T extends ValidComponent = "p">(
210
+ props: PolymorphicProps<T, SheetDescriptionProps<T>>
211
+ ) => {
212
+ const [local, rest] = splitProps(props as SheetDescriptionProps, ["class"]);
206
213
 
207
214
  return (
208
215
  <DialogPrimitive.Description
209
216
  class={cn("text-sm text-muted-foreground", local.class)}
210
- {...rest}
211
- >
212
- {local.children}
213
- </DialogPrimitive.Description>
217
+ {...(rest as any)}
218
+ />
214
219
  );
215
220
  };