@stagewise/ui 0.1.0 → 0.2.0

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 (113) hide show
  1. package/README.md +9 -3
  2. package/package.json +9 -15
  3. package/src/components/ui/accordion.tsx +13 -15
  4. package/src/components/ui/alert-dialog.tsx +38 -38
  5. package/src/components/ui/alert.tsx +22 -22
  6. package/src/components/ui/aspect-ratio.tsx +6 -6
  7. package/src/components/ui/avatar.tsx +30 -30
  8. package/src/components/ui/badge.tsx +24 -22
  9. package/src/components/ui/breadcrumb.tsx +34 -37
  10. package/src/components/ui/bubble.tsx +48 -48
  11. package/src/components/ui/button-group.tsx +24 -24
  12. package/src/components/ui/button.tsx +24 -24
  13. package/src/components/ui/calendar.tsx +94 -81
  14. package/src/components/ui/card.tsx +30 -30
  15. package/src/components/ui/carousel.tsx +95 -92
  16. package/src/components/ui/chart.tsx +110 -110
  17. package/src/components/ui/checkbox.tsx +9 -10
  18. package/src/components/ui/collapsible.tsx +5 -5
  19. package/src/components/ui/combobox.tsx +51 -44
  20. package/src/components/ui/command.tsx +173 -190
  21. package/src/components/ui/context-menu.tsx +60 -50
  22. package/src/components/ui/dialog.tsx +33 -34
  23. package/src/components/ui/direction.tsx +1 -1
  24. package/src/components/ui/drawer.tsx +61 -61
  25. package/src/components/ui/dropdown-menu.tsx +54 -50
  26. package/src/components/ui/empty.tsx +30 -30
  27. package/src/components/ui/field.tsx +64 -64
  28. package/src/components/ui/hover-card.tsx +12 -12
  29. package/src/components/ui/input-group.tsx +54 -54
  30. package/src/components/ui/input-otp.tsx +24 -25
  31. package/src/components/ui/input.tsx +8 -8
  32. package/src/components/ui/item.tsx +64 -64
  33. package/src/components/ui/kbd.tsx +8 -8
  34. package/src/components/ui/klex-logo-combo.tsx +69 -0
  35. package/src/components/ui/klex-logo-text.tsx +70 -0
  36. package/src/components/ui/klex-logo.tsx +146 -0
  37. package/src/components/ui/label.tsx +8 -8
  38. package/src/components/ui/marker.tsx +25 -25
  39. package/src/components/ui/menubar.tsx +54 -50
  40. package/src/components/ui/message-scroller.tsx +130 -0
  41. package/src/components/ui/message.tsx +27 -27
  42. package/src/components/ui/native-select.tsx +22 -18
  43. package/src/components/ui/navigation-menu.tsx +37 -34
  44. package/src/components/ui/pagination.tsx +34 -31
  45. package/src/components/ui/popover.tsx +19 -19
  46. package/src/components/ui/progress.tsx +16 -16
  47. package/src/components/ui/questionnaire.tsx +72 -69
  48. package/src/components/ui/radio-group.tsx +9 -9
  49. package/src/components/ui/resizable.tsx +19 -12
  50. package/src/components/ui/scroll-area.tsx +10 -10
  51. package/src/components/ui/select.tsx +39 -34
  52. package/src/components/ui/separator.tsx +7 -7
  53. package/src/components/ui/sheet.tsx +31 -32
  54. package/src/components/ui/sidebar.tsx +244 -232
  55. package/src/components/ui/skeleton.tsx +5 -5
  56. package/src/components/ui/slider.tsx +11 -7
  57. package/src/components/ui/spinner.tsx +15 -6
  58. package/src/components/ui/stagewise-logo-combo.tsx +43 -0
  59. package/src/components/ui/stagewise-logo-text.tsx +30 -0
  60. package/src/components/ui/stagewise-logo.tsx +42 -0
  61. package/src/components/ui/switch.tsx +9 -9
  62. package/src/components/ui/table.tsx +31 -31
  63. package/src/components/ui/tabs.tsx +37 -26
  64. package/src/components/ui/textarea.tsx +7 -7
  65. package/src/components/ui/toast.tsx +70 -70
  66. package/src/components/ui/toggle-group.tsx +26 -26
  67. package/src/components/ui/toggle.tsx +15 -15
  68. package/src/components/ui/tooltip.tsx +13 -13
  69. package/src/hooks/use-mobile.ts +13 -11
  70. package/src/icons/custom/ui-outline-18/IconKlexOutline18.tsx +39 -0
  71. package/src/icons/custom/ui-outline-18/IconLaptop.tsx +35 -0
  72. package/src/icons/custom/ui-outline-18/IconSignOut.tsx +33 -0
  73. package/src/icons/custom/ui-outline-18/index.ts +4 -1
  74. package/src/icons/index.ts +42 -20
  75. package/src/icons/nucleo/social-media/IconMicrosoftEntraId.tsx +56 -0
  76. package/src/icons/nucleo/social-media/index.ts +1 -0
  77. package/src/icons/nucleo/ui-outline-18/IconArrowDownOutline18.tsx +4 -3
  78. package/src/icons/nucleo/ui-outline-18/IconArrowTurnRightOutline18.tsx +32 -0
  79. package/src/icons/nucleo/ui-outline-18/IconArrowUpOutline18.tsx +35 -0
  80. package/src/icons/nucleo/ui-outline-18/IconChartPieOutline18.tsx +4 -3
  81. package/src/icons/nucleo/ui-outline-18/IconChevronMaximizeDiagonal2Outline18.tsx +33 -0
  82. package/src/icons/nucleo/ui-outline-18/IconChevronUpOutline18.tsx +4 -3
  83. package/src/icons/nucleo/ui-outline-18/IconEmptyOutline18.tsx +41 -0
  84. package/src/icons/nucleo/ui-outline-18/IconEyeOffOutline18.tsx +18 -0
  85. package/src/icons/nucleo/ui-outline-18/IconLinkBrokenOutline18.tsx +66 -0
  86. package/src/icons/nucleo/ui-outline-18/IconLock18Outline.tsx +48 -0
  87. package/src/icons/nucleo/ui-outline-18/IconMinusOutline18.tsx +4 -3
  88. package/src/icons/nucleo/ui-outline-18/IconMsgs2Outline18.tsx +32 -0
  89. package/src/icons/nucleo/ui-outline-18/IconPanelLeftOutline18.tsx +4 -3
  90. package/src/icons/nucleo/ui-outline-18/IconSidebarLeft2HideOutline18.tsx +63 -0
  91. package/src/icons/nucleo/ui-outline-18/IconSidebarRight2HideOutline18.tsx +63 -0
  92. package/src/icons/nucleo/ui-outline-18/index.ts +11 -1
  93. package/src/icons/provider/IconAnthropic.tsx +15 -0
  94. package/src/icons/provider/IconCodex.tsx +18 -0
  95. package/src/icons/provider/IconDiscord.tsx +17 -0
  96. package/src/icons/provider/IconGemini.tsx +152 -0
  97. package/src/icons/provider/IconLinear.tsx +9 -0
  98. package/src/icons/provider/IconOpenAI.tsx +15 -0
  99. package/src/icons/provider/IconOpenRouter.tsx +24 -0
  100. package/src/icons/provider/IconSlack.tsx +24 -0
  101. package/src/icons/provider/IconTelegram.tsx +29 -0
  102. package/src/icons/provider/IconWhatsapp.tsx +14 -0
  103. package/src/icons/provider/LICENSE +21 -0
  104. package/src/icons/provider/index.ts +10 -0
  105. package/src/index.ts +68 -61
  106. package/src/lib/utils.ts +3 -3
  107. package/src/styles/bridge.css +7 -3
  108. package/src/styles/derived-utilities.css +129 -50
  109. package/src/styles/index.css +17 -2
  110. package/src/styles/palette.css +266 -105
  111. package/src/styles/scroll-fade.css +116 -0
  112. package/src/styles/tailwind-tokens.css +3 -0
  113. package/src/styles/theme.css +57 -43
@@ -1,20 +1,27 @@
1
- "use client"
1
+ 'use client';
2
2
 
3
- import * as React from "react"
4
- import { Toast as ToastPrimitive } from "@base-ui/react/toast"
3
+ import * as React from 'react';
4
+ import { Toast as ToastPrimitive } from '@base-ui/react/toast';
5
5
 
6
- import { cn } from "../../lib/utils"
7
- import { Button } from "./button"
8
- import { IconOctagonWarningOutline18, IconCircleCheckOutline18, IconXmarkOutline18, IconCircleInfoOutline18, IconTriangleWarningOutline18, IconLoader6Outline18 } from "../../icons"
6
+ import { cn } from '../../lib/utils';
7
+ import { Button } from './button';
8
+ import {
9
+ IconOctagonWarningOutline18,
10
+ IconCircleCheckOutline18,
11
+ IconXmarkOutline18,
12
+ IconCircleInfoOutline18,
13
+ IconTriangleWarningOutline18,
14
+ IconLoader6Outline18,
15
+ } from '../../icons';
9
16
 
10
- const toast = ToastPrimitive.createToastManager()
17
+ const toast = ToastPrimitive.createToastManager();
11
18
 
12
19
  function ToastProvider({ ...props }: ToastPrimitive.Provider.Props) {
13
- return <ToastPrimitive.Provider {...props} />
20
+ return <ToastPrimitive.Provider {...props} />;
14
21
  }
15
22
 
16
23
  function ToastPortal({ ...props }: ToastPrimitive.Portal.Props) {
17
- return <ToastPrimitive.Portal data-slot="toast-portal" {...props} />
24
+ return <ToastPrimitive.Portal data-slot="toast-portal" {...props} />;
18
25
  }
19
26
 
20
27
  function ToastViewport({ className, ...props }: ToastPrimitive.Viewport.Props) {
@@ -22,12 +29,12 @@ function ToastViewport({ className, ...props }: ToastPrimitive.Viewport.Props) {
22
29
  <ToastPrimitive.Viewport
23
30
  data-slot="toast-viewport"
24
31
  className={cn(
25
- "pointer-events-none fixed inset-x-4 bottom-4 z-50 mx-auto w-auto max-w-sm outline-none sm:right-4 sm:left-auto sm:mx-0 sm:w-full",
26
- className
32
+ 'pointer-events-none fixed inset-x-4 bottom-4 z-50 mx-auto w-auto max-w-sm outline-none sm:right-4 sm:left-auto sm:mx-0 sm:w-full',
33
+ className,
27
34
  )}
28
35
  {...props}
29
36
  />
30
- )
37
+ );
31
38
  }
32
39
 
33
40
  function Toast({ className, ...props }: ToastPrimitive.Root.Props) {
@@ -35,26 +42,26 @@ function Toast({ className, ...props }: ToastPrimitive.Root.Props) {
35
42
  <ToastPrimitive.Root
36
43
  data-slot="toast"
37
44
  className={cn(
38
- "group/toast pointer-events-auto absolute right-0 bottom-0 z-[calc(1000-var(--toast-index))] w-full origin-bottom rounded-2xl border bg-popover text-popover-foreground shadow-lg will-change-transform outline-none select-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50",
39
- "[--gap:0.75rem] [--height:var(--toast-frontmost-height,var(--toast-height))] [--offset-y:calc(var(--toast-offset-y)*-1+calc(var(--toast-index)*var(--gap)*-1)+var(--toast-swipe-movement-y))] [--peek:0.75rem] [--scale:calc(max(0,1-(var(--toast-index)*0.1)))] [--shrink:calc(1-var(--scale))]",
40
- "h-(--height) [transform:translateX(var(--toast-swipe-movement-x))_translateY(calc(var(--toast-swipe-movement-y)-(var(--toast-index)*var(--peek))-(var(--shrink)*var(--height))))_scale(var(--scale))] [transition:transform_500ms_cubic-bezier(0.22,1,0.36,1),opacity_500ms,height_150ms]",
45
+ 'group/toast pointer-events-auto absolute right-0 bottom-0 z-[calc(1000-var(--toast-index))] w-full origin-bottom rounded-2xl border bg-popover text-popover-foreground shadow-lg will-change-transform outline-none select-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50',
46
+ '[--gap:0.75rem] [--height:var(--toast-frontmost-height,var(--toast-height))] [--offset-y:calc(var(--toast-offset-y)*-1+calc(var(--toast-index)*var(--gap)*-1)+var(--toast-swipe-movement-y))] [--peek:0.75rem] [--scale:calc(max(0,1-(var(--toast-index)*0.1)))] [--shrink:calc(1-var(--scale))]',
47
+ 'h-(--height) [transform:translateX(var(--toast-swipe-movement-x))_translateY(calc(var(--toast-swipe-movement-y)-(var(--toast-index)*var(--peek))-(var(--shrink)*var(--height))))_scale(var(--scale))] [transition:transform_500ms_cubic-bezier(0.22,1,0.36,1),opacity_500ms,height_150ms]',
41
48
  "after:absolute after:top-full after:left-0 after:h-[calc(var(--gap)+1px)] after:w-full after:content-['']",
42
- "data-expanded:h-(--toast-height) data-expanded:[transform:translateX(var(--toast-swipe-movement-x))_translateY(var(--offset-y))]",
43
- "data-limited:opacity-0 data-starting-style:[transform:translateY(150%)]",
44
- "[&[data-ending-style]:not([data-limited]):not([data-swipe-direction])]:[transform:translateY(150%)]",
45
- "data-ending-style:data-[swipe-direction=down]:[transform:translateY(calc(var(--toast-swipe-movement-y)+150%))]",
46
- "data-ending-style:data-[swipe-direction=left]:[transform:translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))]",
47
- "data-ending-style:data-[swipe-direction=right]:[transform:translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))]",
48
- "data-ending-style:data-[swipe-direction=up]:[transform:translateY(calc(var(--toast-swipe-movement-y)-150%))]",
49
- "data-expanded:data-ending-style:data-[swipe-direction=down]:[transform:translateY(calc(var(--toast-swipe-movement-y)+150%))]",
50
- "data-expanded:data-ending-style:data-[swipe-direction=left]:[transform:translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))]",
51
- "data-expanded:data-ending-style:data-[swipe-direction=right]:[transform:translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))]",
52
- "data-expanded:data-ending-style:data-[swipe-direction=up]:[transform:translateY(calc(var(--toast-swipe-movement-y)-150%))]",
53
- className
49
+ 'data-expanded:h-(--toast-height) data-expanded:[transform:translateX(var(--toast-swipe-movement-x))_translateY(var(--offset-y))]',
50
+ 'data-limited:opacity-0 data-starting-style:[transform:translateY(150%)]',
51
+ '[&[data-ending-style]:not([data-limited]):not([data-swipe-direction])]:[transform:translateY(150%)]',
52
+ 'data-ending-style:data-[swipe-direction=down]:[transform:translateY(calc(var(--toast-swipe-movement-y)+150%))]',
53
+ 'data-ending-style:data-[swipe-direction=left]:[transform:translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))]',
54
+ 'data-ending-style:data-[swipe-direction=right]:[transform:translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))]',
55
+ 'data-ending-style:data-[swipe-direction=up]:[transform:translateY(calc(var(--toast-swipe-movement-y)-150%))]',
56
+ 'data-expanded:data-ending-style:data-[swipe-direction=down]:[transform:translateY(calc(var(--toast-swipe-movement-y)+150%))]',
57
+ 'data-expanded:data-ending-style:data-[swipe-direction=left]:[transform:translateX(calc(var(--toast-swipe-movement-x)-150%))_translateY(var(--offset-y))]',
58
+ 'data-expanded:data-ending-style:data-[swipe-direction=right]:[transform:translateX(calc(var(--toast-swipe-movement-x)+150%))_translateY(var(--offset-y))]',
59
+ 'data-expanded:data-ending-style:data-[swipe-direction=up]:[transform:translateY(calc(var(--toast-swipe-movement-y)-150%))]',
60
+ className,
54
61
  )}
55
62
  {...props}
56
63
  />
57
- )
64
+ );
58
65
  }
59
66
 
60
67
  function ToastContent({ className, ...props }: ToastPrimitive.Content.Props) {
@@ -62,22 +69,22 @@ function ToastContent({ className, ...props }: ToastPrimitive.Content.Props) {
62
69
  <ToastPrimitive.Content
63
70
  data-slot="toast-content"
64
71
  className={cn(
65
- "flex h-full items-center gap-3 overflow-hidden p-4 transition-opacity duration-250 ease-[cubic-bezier(0.22,1,0.36,1)] data-behind:opacity-0 data-expanded:opacity-100",
66
- className
72
+ 'flex h-full items-center gap-3 overflow-hidden p-4 transition-opacity duration-250 ease-[cubic-bezier(0.22,1,0.36,1)] data-behind:opacity-0 data-expanded:opacity-100',
73
+ className,
67
74
  )}
68
75
  {...props}
69
76
  />
70
- )
77
+ );
71
78
  }
72
79
 
73
80
  function ToastTitle({ className, ...props }: ToastPrimitive.Title.Props) {
74
81
  return (
75
82
  <ToastPrimitive.Title
76
83
  data-slot="toast-title"
77
- className={cn("text-sm font-medium", className)}
84
+ className={cn('text-sm font-medium', className)}
78
85
  {...props}
79
86
  />
80
- )
87
+ );
81
88
  }
82
89
 
83
90
  function ToastDescription({
@@ -87,10 +94,10 @@ function ToastDescription({
87
94
  return (
88
95
  <ToastPrimitive.Description
89
96
  data-slot="toast-description"
90
- className={cn("text-sm text-muted-foreground", className)}
97
+ className={cn('text-sm text-muted-foreground', className)}
91
98
  {...props}
92
99
  />
93
- )
100
+ );
94
101
  }
95
102
 
96
103
  function ToastAction({
@@ -102,10 +109,10 @@ function ToastAction({
102
109
  <ToastPrimitive.Action
103
110
  data-slot="toast-action"
104
111
  render={render}
105
- className={cn("shrink-0", className)}
112
+ className={cn('shrink-0', className)}
106
113
  {...props}
107
114
  />
108
- )
115
+ );
109
116
  }
110
117
 
111
118
  function ToastClose({
@@ -121,52 +128,45 @@ function ToastClose({
121
128
  render={render}
122
129
  className={cn(
123
130
  "relative shrink-0 text-muted-foreground after:absolute after:-inset-2 after:content-[''] hover:text-foreground",
124
- className
131
+ className,
125
132
  )}
126
133
  {...props}
127
134
  >
128
- {children ?? (
129
- <IconXmarkOutline18 aria-hidden="true" />
130
- )}
135
+ {children ?? <IconXmarkOutline18 aria-hidden="true" />}
131
136
  </ToastPrimitive.Close>
132
- )
137
+ );
133
138
  }
134
139
 
135
140
  function ToastIcon({ type }: { type: string | undefined }) {
136
- let icon: React.ReactNode = null
141
+ let icon: React.ReactNode = null;
137
142
 
138
- if (type === "success") {
139
- icon = (
140
- <IconCircleCheckOutline18 aria-hidden="true" />
141
- )
143
+ if (type === 'success') {
144
+ icon = <IconCircleCheckOutline18 aria-hidden="true" />;
142
145
  }
143
146
 
144
- if (type === "info") {
145
- icon = (
146
- <IconCircleInfoOutline18 aria-hidden="true" />
147
- )
147
+ if (type === 'info') {
148
+ icon = <IconCircleInfoOutline18 aria-hidden="true" />;
148
149
  }
149
150
 
150
- if (type === "warning") {
151
- icon = (
152
- <IconTriangleWarningOutline18 aria-hidden="true" />
153
- )
151
+ if (type === 'warning') {
152
+ icon = <IconTriangleWarningOutline18 aria-hidden="true" />;
154
153
  }
155
154
 
156
- if (type === "error") {
155
+ if (type === 'error') {
157
156
  icon = (
158
- <IconOctagonWarningOutline18 className="text-destructive" aria-hidden="true" />
159
- )
157
+ <IconOctagonWarningOutline18
158
+ className="text-destructive"
159
+ aria-hidden="true"
160
+ />
161
+ );
160
162
  }
161
163
 
162
- if (type === "loading") {
163
- icon = (
164
- <IconLoader6Outline18 className="animate-spin" aria-hidden="true" />
165
- )
164
+ if (type === 'loading') {
165
+ icon = <IconLoader6Outline18 className="animate-spin" aria-hidden="true" />;
166
166
  }
167
167
 
168
168
  if (!icon) {
169
- return null
169
+ return null;
170
170
  }
171
171
 
172
172
  return (
@@ -176,11 +176,11 @@ function ToastIcon({ type }: { type: string | undefined }) {
176
176
  >
177
177
  {icon}
178
178
  </span>
179
- )
179
+ );
180
180
  }
181
181
 
182
182
  function ToastList() {
183
- const { toasts } = ToastPrimitive.useToastManager()
183
+ const { toasts } = ToastPrimitive.useToastManager();
184
184
 
185
185
  return toasts.map((toastItem) => (
186
186
  <Toast key={toastItem.id} toast={toastItem}>
@@ -194,7 +194,7 @@ function ToastList() {
194
194
  <ToastClose />
195
195
  </ToastContent>
196
196
  </Toast>
197
- ))
197
+ ));
198
198
  }
199
199
 
200
200
  function Toaster({
@@ -211,11 +211,11 @@ function Toaster({
211
211
  </ToastViewport>
212
212
  </ToastPortal>
213
213
  </ToastProvider>
214
- )
214
+ );
215
215
  }
216
216
 
217
- const createToastManager = ToastPrimitive.createToastManager
218
- const useToastManager = ToastPrimitive.useToastManager
217
+ const createToastManager = ToastPrimitive.createToastManager;
218
+ const useToastManager = ToastPrimitive.useToastManager;
219
219
 
220
220
  export {
221
221
  Toaster,
@@ -231,4 +231,4 @@ export {
231
231
  createToastManager,
232
232
  toast,
233
233
  useToastManager,
234
- }
234
+ };
@@ -1,35 +1,35 @@
1
- import * as React from "react"
2
- import { Toggle as TogglePrimitive } from "@base-ui/react/toggle"
3
- import { ToggleGroup as ToggleGroupPrimitive } from "@base-ui/react/toggle-group"
4
- import { type VariantProps } from "class-variance-authority"
1
+ import * as React from 'react';
2
+ import { Toggle as TogglePrimitive } from '@base-ui/react/toggle';
3
+ import { ToggleGroup as ToggleGroupPrimitive } from '@base-ui/react/toggle-group';
4
+ import { type VariantProps } from 'class-variance-authority';
5
5
 
6
- import { cn } from "../../lib/utils"
7
- import { toggleVariants } from "./toggle"
6
+ import { cn } from '../../lib/utils';
7
+ import { toggleVariants } from './toggle';
8
8
 
9
9
  const ToggleGroupContext = React.createContext<
10
10
  VariantProps<typeof toggleVariants> & {
11
- spacing?: number
12
- orientation?: "horizontal" | "vertical"
11
+ spacing?: number;
12
+ orientation?: 'horizontal' | 'vertical';
13
13
  }
14
14
  >({
15
- size: "default",
16
- variant: "default",
15
+ size: 'default',
16
+ variant: 'default',
17
17
  spacing: 2,
18
- orientation: "horizontal",
19
- })
18
+ orientation: 'horizontal',
19
+ });
20
20
 
21
21
  function ToggleGroup({
22
22
  className,
23
23
  variant,
24
24
  size,
25
25
  spacing = 2,
26
- orientation = "horizontal",
26
+ orientation = 'horizontal',
27
27
  children,
28
28
  ...props
29
29
  }: ToggleGroupPrimitive.Props &
30
30
  VariantProps<typeof toggleVariants> & {
31
- spacing?: number
32
- orientation?: "horizontal" | "vertical"
31
+ spacing?: number;
32
+ orientation?: 'horizontal' | 'vertical';
33
33
  }) {
34
34
  return (
35
35
  <ToggleGroupPrimitive
@@ -38,10 +38,10 @@ function ToggleGroup({
38
38
  data-size={size}
39
39
  data-spacing={spacing}
40
40
  data-orientation={orientation}
41
- style={{ "--gap": spacing } as React.CSSProperties}
41
+ style={{ '--gap': spacing } as React.CSSProperties}
42
42
  className={cn(
43
- "group/toggle-group flex w-fit flex-row items-center gap-[--spacing(var(--gap))] rounded-lg data-[size=sm]:rounded-[min(var(--radius-md),10px)] data-vertical:flex-col data-vertical:items-stretch",
44
- className
43
+ 'group/toggle-group flex w-fit flex-row items-center gap-[--spacing(var(--gap))] rounded-lg data-[size=sm]:rounded-[min(var(--radius-md),10px)] data-vertical:flex-col data-vertical:items-stretch',
44
+ className,
45
45
  )}
46
46
  {...props}
47
47
  >
@@ -51,17 +51,17 @@ function ToggleGroup({
51
51
  {children}
52
52
  </ToggleGroupContext.Provider>
53
53
  </ToggleGroupPrimitive>
54
- )
54
+ );
55
55
  }
56
56
 
57
57
  function ToggleGroupItem({
58
58
  className,
59
59
  children,
60
- variant = "default",
61
- size = "default",
60
+ variant = 'default',
61
+ size = 'default',
62
62
  ...props
63
63
  }: TogglePrimitive.Props & VariantProps<typeof toggleVariants>) {
64
- const context = React.useContext(ToggleGroupContext)
64
+ const context = React.useContext(ToggleGroupContext);
65
65
 
66
66
  return (
67
67
  <TogglePrimitive
@@ -70,18 +70,18 @@ function ToggleGroupItem({
70
70
  data-size={context.size || size}
71
71
  data-spacing={context.spacing}
72
72
  className={cn(
73
- "shrink-0 group-data-[spacing=0]/toggle-group:rounded-none group-data-[spacing=0]/toggle-group:px-2 focus:z-10 focus-visible:z-10 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-end]:pr-1.5 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-start]:pl-1.5 group-data-horizontal/toggle-group:data-[spacing=0]:first:rounded-l-lg group-data-vertical/toggle-group:data-[spacing=0]:first:rounded-t-lg group-data-horizontal/toggle-group:data-[spacing=0]:last:rounded-r-lg group-data-vertical/toggle-group:data-[spacing=0]:last:rounded-b-lg group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:border-l-0 group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:border-t-0 group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-l group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-t",
73
+ 'shrink-0 group-data-[spacing=0]/toggle-group:rounded-none group-data-[spacing=0]/toggle-group:px-2 focus:z-10 focus-visible:z-10 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-end]:pr-1.5 group-data-[spacing=0]/toggle-group:has-data-[icon=inline-start]:pl-1.5 group-data-horizontal/toggle-group:data-[spacing=0]:first:rounded-l-lg group-data-vertical/toggle-group:data-[spacing=0]:first:rounded-t-lg group-data-horizontal/toggle-group:data-[spacing=0]:last:rounded-r-lg group-data-vertical/toggle-group:data-[spacing=0]:last:rounded-b-lg group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:border-l-0 group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:border-t-0 group-data-horizontal/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-l group-data-vertical/toggle-group:data-[spacing=0]:data-[variant=outline]:first:border-t',
74
74
  toggleVariants({
75
75
  variant: context.variant || variant,
76
76
  size: context.size || size,
77
77
  }),
78
- className
78
+ className,
79
79
  )}
80
80
  {...props}
81
81
  >
82
82
  {children}
83
83
  </TogglePrimitive>
84
- )
84
+ );
85
85
  }
86
86
 
87
- export { ToggleGroup, ToggleGroupItem }
87
+ export { ToggleGroup, ToggleGroupItem };
@@ -1,34 +1,34 @@
1
- import { Toggle as TogglePrimitive } from "@base-ui/react/toggle"
2
- import { cva, type VariantProps } from "class-variance-authority"
1
+ import { Toggle as TogglePrimitive } from '@base-ui/react/toggle';
2
+ import { cva, type VariantProps } from 'class-variance-authority';
3
3
 
4
- import { cn } from "../../lib/utils"
4
+ import { cn } from '../../lib/utils';
5
5
 
6
6
  const toggleVariants = cva(
7
7
  "group/toggle inline-flex items-center justify-center gap-1 rounded-lg text-sm font-medium whitespace-nowrap transition-all outline-none hover:bg-muted hover:text-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 aria-pressed:bg-muted data-[state=on]:bg-muted dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
8
8
  {
9
9
  variants: {
10
10
  variant: {
11
- default: "bg-transparent",
12
- outline: "border border-derived bg-transparent hover:bg-muted",
11
+ default: 'bg-transparent',
12
+ outline: 'border border-derived bg-transparent hover:bg-muted',
13
13
  },
14
14
  size: {
15
15
  default:
16
- "h-8 min-w-8 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
16
+ 'h-8 min-w-8 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2',
17
17
  sm: "h-7 min-w-7 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5",
18
- lg: "h-9 min-w-9 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2",
18
+ lg: 'h-9 min-w-9 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2',
19
19
  },
20
20
  },
21
21
  defaultVariants: {
22
- variant: "default",
23
- size: "default",
22
+ variant: 'default',
23
+ size: 'default',
24
24
  },
25
- }
26
- )
25
+ },
26
+ );
27
27
 
28
28
  function Toggle({
29
29
  className,
30
- variant = "default",
31
- size = "default",
30
+ variant = 'default',
31
+ size = 'default',
32
32
  ...props
33
33
  }: TogglePrimitive.Props & VariantProps<typeof toggleVariants>) {
34
34
  return (
@@ -37,7 +37,7 @@ function Toggle({
37
37
  className={cn(toggleVariants({ variant, size, className }))}
38
38
  {...props}
39
39
  />
40
- )
40
+ );
41
41
  }
42
42
 
43
- export { Toggle, toggleVariants }
43
+ export { Toggle, toggleVariants };
@@ -1,8 +1,8 @@
1
- "use client"
1
+ 'use client';
2
2
 
3
- import { Tooltip as TooltipPrimitive } from "@base-ui/react/tooltip"
3
+ import { Tooltip as TooltipPrimitive } from '@base-ui/react/tooltip';
4
4
 
5
- import { cn } from "../../lib/utils"
5
+ import { cn } from '../../lib/utils';
6
6
 
7
7
  function TooltipProvider({
8
8
  delay = 0,
@@ -14,29 +14,29 @@ function TooltipProvider({
14
14
  delay={delay}
15
15
  {...props}
16
16
  />
17
- )
17
+ );
18
18
  }
19
19
 
20
20
  function Tooltip({ ...props }: TooltipPrimitive.Root.Props) {
21
- return <TooltipPrimitive.Root data-slot="tooltip" {...props} />
21
+ return <TooltipPrimitive.Root data-slot="tooltip" {...props} />;
22
22
  }
23
23
 
24
24
  function TooltipTrigger({ ...props }: TooltipPrimitive.Trigger.Props) {
25
- return <TooltipPrimitive.Trigger data-slot="tooltip-trigger" {...props} />
25
+ return <TooltipPrimitive.Trigger data-slot="tooltip-trigger" {...props} />;
26
26
  }
27
27
 
28
28
  function TooltipContent({
29
29
  className,
30
- side = "top",
30
+ side = 'top',
31
31
  sideOffset = 4,
32
- align = "center",
32
+ align = 'center',
33
33
  alignOffset = 0,
34
34
  children,
35
35
  ...props
36
36
  }: TooltipPrimitive.Popup.Props &
37
37
  Pick<
38
38
  TooltipPrimitive.Positioner.Props,
39
- "align" | "alignOffset" | "side" | "sideOffset"
39
+ 'align' | 'alignOffset' | 'side' | 'sideOffset'
40
40
  >) {
41
41
  return (
42
42
  <TooltipPrimitive.Portal>
@@ -50,8 +50,8 @@ function TooltipContent({
50
50
  <TooltipPrimitive.Popup
51
51
  data-slot="tooltip-content"
52
52
  className={cn(
53
- "z-50 inline-flex w-fit max-w-xs origin-(--transform-origin) items-center gap-1.5 rounded-md bg-foreground px-2.5 py-1 text-xs text-background has-data-[slot=kbd]:pr-1.5 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 **:data-[slot=kbd]:relative **:data-[slot=kbd]:isolate **:data-[slot=kbd]:z-50 **:data-[slot=kbd]:rounded-sm data-[state=delayed-open]:animate-in data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",
54
- className
53
+ 'z-50 inline-flex w-fit max-w-xs origin-(--transform-origin) items-center gap-1.5 rounded-md bg-foreground px-2.5 py-1 text-xs text-background has-data-[slot=kbd]:pr-1.5 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 **:data-[slot=kbd]:relative **:data-[slot=kbd]:isolate **:data-[slot=kbd]:z-50 **:data-[slot=kbd]:rounded-sm data-[state=delayed-open]:animate-in data-[state=delayed-open]:fade-in-0 data-[state=delayed-open]:zoom-in-95 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95',
54
+ className,
55
55
  )}
56
56
  {...props}
57
57
  >
@@ -60,7 +60,7 @@ function TooltipContent({
60
60
  </TooltipPrimitive.Popup>
61
61
  </TooltipPrimitive.Positioner>
62
62
  </TooltipPrimitive.Portal>
63
- )
63
+ );
64
64
  }
65
65
 
66
- export { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider }
66
+ export { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };
@@ -1,19 +1,21 @@
1
- import * as React from "react"
1
+ import * as React from 'react';
2
2
 
3
- const MOBILE_BREAKPOINT = 768
3
+ const MOBILE_BREAKPOINT = 768;
4
4
 
5
5
  export function useIsMobile() {
6
- const [isMobile, setIsMobile] = React.useState<boolean | undefined>(undefined)
6
+ const [isMobile, setIsMobile] = React.useState<boolean | undefined>(
7
+ undefined,
8
+ );
7
9
 
8
10
  React.useEffect(() => {
9
- const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`)
11
+ const mql = window.matchMedia(`(max-width: ${MOBILE_BREAKPOINT - 1}px)`);
10
12
  const onChange = () => {
11
- setIsMobile(window.innerWidth < MOBILE_BREAKPOINT)
12
- }
13
- mql.addEventListener("change", onChange)
14
- setIsMobile(window.innerWidth < MOBILE_BREAKPOINT)
15
- return () => mql.removeEventListener("change", onChange)
16
- }, [])
13
+ setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);
14
+ };
15
+ mql.addEventListener('change', onChange);
16
+ setIsMobile(window.innerWidth < MOBILE_BREAKPOINT);
17
+ return () => mql.removeEventListener('change', onChange);
18
+ }, []);
17
19
 
18
- return !!isMobile
20
+ return !!isMobile;
19
21
  }
@@ -0,0 +1,39 @@
1
+ import type React from 'react';
2
+
3
+ import { Icon, type IconProps } from './Icon';
4
+
5
+ interface IconKlexOutline18Props extends IconProps {
6
+ strokeWidth?: number;
7
+ }
8
+
9
+ export const IconKlexOutline18: React.FC<IconKlexOutline18Props> = ({
10
+ strokeWidth = 1.5,
11
+ ...props
12
+ }) => {
13
+ return (
14
+ <Icon size="18px" {...props}>
15
+ <path
16
+ d="M15.1157 7.5232C15.2123 4.8178 13.609 2.25 10.7464 2.25C7.2812 2.25 6.2607 4.5553 5.9252 7.0712C5.0212 13.8511 2.8784 14.1964 2.8784 14.6483C2.8784 14.8774 3.5062 15.7469 5.7033 14.8053C6.6157 14.4143 7.3672 15.3563 8.0575 15.4331C8.7912 15.5147 9.2226 15.1597 9.9408 14.9622C10.7668 14.7351 11.526 15.59 12.1379 15.59C14.2472 15.59 14.965 11.7418 15.1157 7.5232Z"
17
+ fill="none"
18
+ stroke="currentColor"
19
+ strokeLinecap="round"
20
+ strokeLinejoin="round"
21
+ strokeWidth={strokeWidth}
22
+ />
23
+ <ellipse
24
+ cx="10.7255"
25
+ cy="6.9582"
26
+ fill="currentColor"
27
+ rx=".6278"
28
+ ry=".9416"
29
+ />
30
+ <ellipse
31
+ cx="12.9226"
32
+ cy="6.9582"
33
+ fill="currentColor"
34
+ rx=".6278"
35
+ ry=".9416"
36
+ />
37
+ </Icon>
38
+ );
39
+ };
@@ -0,0 +1,35 @@
1
+ import type React from 'react';
2
+
3
+ import { Icon, type IconProps } from './Icon';
4
+
5
+ interface IconLaptopProps extends IconProps {
6
+ strokeWidth?: number;
7
+ }
8
+
9
+ export const IconLaptop: React.FC<IconLaptopProps> = ({
10
+ strokeWidth = 1.5,
11
+ ...props
12
+ }) => {
13
+ return (
14
+ <Icon size="18px" {...props}>
15
+ <rect
16
+ fill="none"
17
+ height="9"
18
+ rx="1.5"
19
+ stroke="currentColor"
20
+ strokeWidth={strokeWidth}
21
+ width="12"
22
+ x="3"
23
+ y="2.5"
24
+ />
25
+ <path
26
+ d="M3 11.5 1.75 14.5h14.5L15 11.5"
27
+ fill="none"
28
+ stroke="currentColor"
29
+ strokeLinecap="round"
30
+ strokeLinejoin="round"
31
+ strokeWidth={strokeWidth}
32
+ />
33
+ </Icon>
34
+ );
35
+ };
@@ -0,0 +1,33 @@
1
+ import type React from 'react';
2
+
3
+ import { Icon, type IconProps } from './Icon';
4
+
5
+ interface IconSignOutProps extends IconProps {
6
+ strokeWidth?: number;
7
+ }
8
+
9
+ export const IconSignOut: React.FC<IconSignOutProps> = ({
10
+ strokeWidth = 1.5,
11
+ ...props
12
+ }) => {
13
+ return (
14
+ <Icon size="18px" {...props}>
15
+ <path
16
+ d="M8.25 2.75h-3.5a2 2 0 0 0-2 2v8.5a2 2 0 0 0 2 2h3.5"
17
+ fill="none"
18
+ stroke="currentColor"
19
+ strokeLinecap="round"
20
+ strokeLinejoin="round"
21
+ strokeWidth={strokeWidth}
22
+ />
23
+ <path
24
+ d="m11.25 5.5 3.5 3.5-3.5 3.5M14.75 9h-7.5"
25
+ fill="none"
26
+ stroke="currentColor"
27
+ strokeLinecap="round"
28
+ strokeLinejoin="round"
29
+ strokeWidth={strokeWidth}
30
+ />
31
+ </Icon>
32
+ );
33
+ };
@@ -1,3 +1,6 @@
1
1
  export { Icon, type IconProps } from './Icon';
2
- export { IconNewTerminal } from './IconNewTerminal';
3
2
  export { IconBrowserTab } from './IconBrowserTab';
3
+ export { IconKlexOutline18 } from './IconKlexOutline18';
4
+ export { IconLaptop } from './IconLaptop';
5
+ export { IconNewTerminal } from './IconNewTerminal';
6
+ export { IconSignOut } from './IconSignOut';