create-better-t-stack 3.7.0 → 3.7.2

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 (29) hide show
  1. package/dist/cli.js +1 -1
  2. package/dist/index.js +1 -1
  3. package/dist/{src-CPJF6Hyu.js → src-BNPik1LZ.js} +27 -34
  4. package/package.json +1 -2
  5. package/templates/auth/better-auth/web/react/base/src/lib/auth-client.ts.hbs +6 -2
  6. package/templates/auth/better-auth/web/react/tanstack-router/src/components/sign-in-form.tsx +117 -121
  7. package/templates/auth/better-auth/web/react/tanstack-router/src/components/sign-up-form.tsx +141 -145
  8. package/templates/auth/better-auth/web/react/tanstack-start/src/components/sign-in-form.tsx +117 -121
  9. package/templates/auth/better-auth/web/react/tanstack-start/src/components/sign-up-form.tsx +141 -145
  10. package/templates/auth/better-auth/web/solid/src/components/sign-in-form.tsx +3 -11
  11. package/templates/auth/better-auth/web/solid/src/components/sign-up-form.tsx +4 -14
  12. package/templates/backend/convex/packages/backend/convex/healthCheck.ts +2 -2
  13. package/templates/examples/ai/native/bare/polyfills.js +3 -7
  14. package/templates/examples/ai/native/unistyles/polyfills.js +3 -6
  15. package/templates/examples/ai/native/uniwind/polyfills.js +3 -7
  16. package/templates/examples/todo/server/drizzle/postgres/src/schema/todo.ts +1 -1
  17. package/templates/frontend/react/react-router/src/components/mode-toggle.tsx +3 -9
  18. package/templates/frontend/react/tanstack-router/src/components/mode-toggle.tsx +3 -9
  19. package/templates/frontend/react/web-base/src/components/ui/button.tsx +13 -16
  20. package/templates/frontend/react/web-base/src/components/ui/card.tsx +13 -30
  21. package/templates/frontend/react/web-base/src/components/ui/checkbox.tsx +8 -11
  22. package/templates/frontend/react/web-base/src/components/ui/dropdown-menu.tsx +37 -66
  23. package/templates/frontend/react/web-base/src/components/ui/input.tsx +5 -5
  24. package/templates/frontend/react/web-base/src/components/ui/label.tsx +7 -10
  25. package/templates/frontend/react/web-base/src/components/ui/skeleton.tsx +3 -3
  26. package/templates/frontend/react/web-base/src/lib/utils.ts +3 -3
  27. package/templates/frontend/svelte/src/app.d.ts +7 -7
  28. package/templates/frontend/svelte/src/lib/index.ts +1 -0
  29. package/templates/frontend/svelte/vite.config.ts +4 -4
@@ -8,157 +8,153 @@ import { Button } from "./ui/button";
8
8
  import { Input } from "./ui/input";
9
9
  import { Label } from "./ui/label";
10
10
 
11
- export default function SignUpForm({
12
- onSwitchToSignIn,
13
- }: {
14
- onSwitchToSignIn: () => void;
15
- }) {
16
- const navigate = useNavigate({
17
- from: "/",
18
- });
19
- const { isPending } = authClient.useSession();
11
+ export default function SignUpForm({ onSwitchToSignIn }: { onSwitchToSignIn: () => void }) {
12
+ const navigate = useNavigate({
13
+ from: "/",
14
+ });
15
+ const { isPending } = authClient.useSession();
20
16
 
21
- const form = useForm({
22
- defaultValues: {
23
- email: "",
24
- password: "",
25
- name: "",
26
- },
27
- onSubmit: async ({ value }) => {
28
- await authClient.signUp.email(
29
- {
30
- email: value.email,
31
- password: value.password,
32
- name: value.name,
33
- },
34
- {
35
- onSuccess: () => {
36
- navigate({
37
- to: "/dashboard",
38
- });
39
- toast.success("Sign up successful");
40
- },
41
- onError: (error) => {
42
- toast.error(error.error.message || error.error.statusText);
43
- },
44
- },
45
- );
46
- },
47
- validators: {
48
- onSubmit: z.object({
49
- name: z.string().min(2, "Name must be at least 2 characters"),
50
- email: z.email("Invalid email address"),
51
- password: z.string().min(8, "Password must be at least 8 characters"),
52
- }),
53
- },
54
- });
17
+ const form = useForm({
18
+ defaultValues: {
19
+ email: "",
20
+ password: "",
21
+ name: "",
22
+ },
23
+ onSubmit: async ({ value }) => {
24
+ await authClient.signUp.email(
25
+ {
26
+ email: value.email,
27
+ password: value.password,
28
+ name: value.name,
29
+ },
30
+ {
31
+ onSuccess: () => {
32
+ navigate({
33
+ to: "/dashboard",
34
+ });
35
+ toast.success("Sign up successful");
36
+ },
37
+ onError: (error) => {
38
+ toast.error(error.error.message || error.error.statusText);
39
+ },
40
+ },
41
+ );
42
+ },
43
+ validators: {
44
+ onSubmit: z.object({
45
+ name: z.string().min(2, "Name must be at least 2 characters"),
46
+ email: z.email("Invalid email address"),
47
+ password: z.string().min(8, "Password must be at least 8 characters"),
48
+ }),
49
+ },
50
+ });
55
51
 
56
- if (isPending) {
57
- return <Loader />;
58
- }
52
+ if (isPending) {
53
+ return <Loader />;
54
+ }
59
55
 
60
- return (
61
- <div className="mx-auto w-full mt-10 max-w-md p-6">
62
- <h1 className="mb-6 text-center text-3xl font-bold">Create Account</h1>
56
+ return (
57
+ <div className="mx-auto w-full mt-10 max-w-md p-6">
58
+ <h1 className="mb-6 text-center text-3xl font-bold">Create Account</h1>
63
59
 
64
- <form
65
- onSubmit={(e) => {
66
- e.preventDefault();
67
- e.stopPropagation();
68
- form.handleSubmit();
69
- }}
70
- className="space-y-4"
71
- >
72
- <div>
73
- <form.Field name="name">
74
- {(field) => (
75
- <div className="space-y-2">
76
- <Label htmlFor={field.name}>Name</Label>
77
- <Input
78
- id={field.name}
79
- name={field.name}
80
- value={field.state.value}
81
- onBlur={field.handleBlur}
82
- onChange={(e) => field.handleChange(e.target.value)}
83
- />
84
- {field.state.meta.errors.map((error) => (
85
- <p key={error?.message} className="text-red-500">
86
- {error?.message}
87
- </p>
88
- ))}
89
- </div>
90
- )}
91
- </form.Field>
92
- </div>
60
+ <form
61
+ onSubmit={(e) => {
62
+ e.preventDefault();
63
+ e.stopPropagation();
64
+ form.handleSubmit();
65
+ }}
66
+ className="space-y-4"
67
+ >
68
+ <div>
69
+ <form.Field name="name">
70
+ {(field) => (
71
+ <div className="space-y-2">
72
+ <Label htmlFor={field.name}>Name</Label>
73
+ <Input
74
+ id={field.name}
75
+ name={field.name}
76
+ value={field.state.value}
77
+ onBlur={field.handleBlur}
78
+ onChange={(e) => field.handleChange(e.target.value)}
79
+ />
80
+ {field.state.meta.errors.map((error) => (
81
+ <p key={error?.message} className="text-red-500">
82
+ {error?.message}
83
+ </p>
84
+ ))}
85
+ </div>
86
+ )}
87
+ </form.Field>
88
+ </div>
93
89
 
94
- <div>
95
- <form.Field name="email">
96
- {(field) => (
97
- <div className="space-y-2">
98
- <Label htmlFor={field.name}>Email</Label>
99
- <Input
100
- id={field.name}
101
- name={field.name}
102
- type="email"
103
- value={field.state.value}
104
- onBlur={field.handleBlur}
105
- onChange={(e) => field.handleChange(e.target.value)}
106
- />
107
- {field.state.meta.errors.map((error) => (
108
- <p key={error?.message} className="text-red-500">
109
- {error?.message}
110
- </p>
111
- ))}
112
- </div>
113
- )}
114
- </form.Field>
115
- </div>
90
+ <div>
91
+ <form.Field name="email">
92
+ {(field) => (
93
+ <div className="space-y-2">
94
+ <Label htmlFor={field.name}>Email</Label>
95
+ <Input
96
+ id={field.name}
97
+ name={field.name}
98
+ type="email"
99
+ value={field.state.value}
100
+ onBlur={field.handleBlur}
101
+ onChange={(e) => field.handleChange(e.target.value)}
102
+ />
103
+ {field.state.meta.errors.map((error) => (
104
+ <p key={error?.message} className="text-red-500">
105
+ {error?.message}
106
+ </p>
107
+ ))}
108
+ </div>
109
+ )}
110
+ </form.Field>
111
+ </div>
116
112
 
117
- <div>
118
- <form.Field name="password">
119
- {(field) => (
120
- <div className="space-y-2">
121
- <Label htmlFor={field.name}>Password</Label>
122
- <Input
123
- id={field.name}
124
- name={field.name}
125
- type="password"
126
- value={field.state.value}
127
- onBlur={field.handleBlur}
128
- onChange={(e) => field.handleChange(e.target.value)}
129
- />
130
- {field.state.meta.errors.map((error) => (
131
- <p key={error?.message} className="text-red-500">
132
- {error?.message}
133
- </p>
134
- ))}
135
- </div>
136
- )}
137
- </form.Field>
138
- </div>
113
+ <div>
114
+ <form.Field name="password">
115
+ {(field) => (
116
+ <div className="space-y-2">
117
+ <Label htmlFor={field.name}>Password</Label>
118
+ <Input
119
+ id={field.name}
120
+ name={field.name}
121
+ type="password"
122
+ value={field.state.value}
123
+ onBlur={field.handleBlur}
124
+ onChange={(e) => field.handleChange(e.target.value)}
125
+ />
126
+ {field.state.meta.errors.map((error) => (
127
+ <p key={error?.message} className="text-red-500">
128
+ {error?.message}
129
+ </p>
130
+ ))}
131
+ </div>
132
+ )}
133
+ </form.Field>
134
+ </div>
139
135
 
140
- <form.Subscribe>
141
- {(state) => (
142
- <Button
143
- type="submit"
144
- className="w-full"
145
- disabled={!state.canSubmit || state.isSubmitting}
146
- >
147
- {state.isSubmitting ? "Submitting..." : "Sign Up"}
148
- </Button>
149
- )}
150
- </form.Subscribe>
151
- </form>
136
+ <form.Subscribe>
137
+ {(state) => (
138
+ <Button
139
+ type="submit"
140
+ className="w-full"
141
+ disabled={!state.canSubmit || state.isSubmitting}
142
+ >
143
+ {state.isSubmitting ? "Submitting..." : "Sign Up"}
144
+ </Button>
145
+ )}
146
+ </form.Subscribe>
147
+ </form>
152
148
 
153
- <div className="mt-4 text-center">
154
- <Button
155
- variant="link"
156
- onClick={onSwitchToSignIn}
157
- className="text-indigo-600 hover:text-indigo-800"
158
- >
159
- Already have an account? Sign In
160
- </Button>
161
- </div>
162
- </div>
163
- );
149
+ <div className="mt-4 text-center">
150
+ <Button
151
+ variant="link"
152
+ onClick={onSwitchToSignIn}
153
+ className="text-indigo-600 hover:text-indigo-800"
154
+ >
155
+ Already have an account? Sign In
156
+ </Button>
157
+ </div>
158
+ </div>
159
+ );
164
160
  }
@@ -4,11 +4,7 @@ import { useNavigate } from "@tanstack/solid-router";
4
4
  import z from "zod";
5
5
  import { For } from "solid-js";
6
6
 
7
- export default function SignInForm({
8
- onSwitchToSignUp,
9
- }: {
10
- onSwitchToSignUp: () => void;
11
- }) {
7
+ export default function SignInForm({ onSwitchToSignUp }: { onSwitchToSignUp: () => void }) {
12
8
  const navigate = useNavigate({
13
9
  from: "/",
14
10
  });
@@ -72,9 +68,7 @@ export default function SignInForm({
72
68
  class="w-full rounded border p-2"
73
69
  />
74
70
  <For each={field().state.meta.errors}>
75
- {(error) => (
76
- <p class="text-sm text-red-600">{error?.message}</p>
77
- )}
71
+ {(error) => <p class="text-sm text-red-600">{error?.message}</p>}
78
72
  </For>
79
73
  </div>
80
74
  )}
@@ -96,9 +90,7 @@ export default function SignInForm({
96
90
  class="w-full rounded border p-2"
97
91
  />
98
92
  <For each={field().state.meta.errors}>
99
- {(error) => (
100
- <p class="text-sm text-red-600">{error?.message}</p>
101
- )}
93
+ {(error) => <p class="text-sm text-red-600">{error?.message}</p>}
102
94
  </For>
103
95
  </div>
104
96
  )}
@@ -4,11 +4,7 @@ import { useNavigate } from "@tanstack/solid-router";
4
4
  import z from "zod";
5
5
  import { For } from "solid-js";
6
6
 
7
- export default function SignUpForm({
8
- onSwitchToSignIn,
9
- }: {
10
- onSwitchToSignIn: () => void;
11
- }) {
7
+ export default function SignUpForm({ onSwitchToSignIn }: { onSwitchToSignIn: () => void }) {
12
8
  const navigate = useNavigate({
13
9
  from: "/",
14
10
  });
@@ -74,9 +70,7 @@ export default function SignUpForm({
74
70
  class="w-full rounded border p-2"
75
71
  />
76
72
  <For each={field().state.meta.errors}>
77
- {(error) => (
78
- <p class="text-sm text-red-600">{error?.message}</p>
79
- )}
73
+ {(error) => <p class="text-sm text-red-600">{error?.message}</p>}
80
74
  </For>
81
75
  </div>
82
76
  )}
@@ -98,9 +92,7 @@ export default function SignUpForm({
98
92
  class="w-full rounded border p-2"
99
93
  />
100
94
  <For each={field().state.meta.errors}>
101
- {(error) => (
102
- <p class="text-sm text-red-600">{error?.message}</p>
103
- )}
95
+ {(error) => <p class="text-sm text-red-600">{error?.message}</p>}
104
96
  </For>
105
97
  </div>
106
98
  )}
@@ -122,9 +114,7 @@ export default function SignUpForm({
122
114
  class="w-full rounded border p-2"
123
115
  />
124
116
  <For each={field().state.meta.errors}>
125
- {(error) => (
126
- <p class="text-sm text-red-600">{error?.message}</p>
127
- )}
117
+ {(error) => <p class="text-sm text-red-600">{error?.message}</p>}
128
118
  </For>
129
119
  </div>
130
120
  )}
@@ -3,5 +3,5 @@ import { query } from "./_generated/server";
3
3
  export const get = query({
4
4
  handler: async () => {
5
5
  return "OK";
6
- }
7
- })
6
+ },
7
+ });
@@ -3,13 +3,10 @@ import { Platform } from "react-native";
3
3
 
4
4
  if (Platform.OS !== "web") {
5
5
  const setupPolyfills = async () => {
6
- const { polyfillGlobal } = await import(
7
- "react-native/Libraries/Utilities/PolyfillFunctions"
8
- );
6
+ const { polyfillGlobal } = await import("react-native/Libraries/Utilities/PolyfillFunctions");
9
7
 
10
- const { TextEncoderStream, TextDecoderStream } = await import(
11
- "@stardazed/streams-text-encoding"
12
- );
8
+ const { TextEncoderStream, TextDecoderStream } =
9
+ await import("@stardazed/streams-text-encoding");
13
10
 
14
11
  if (!("structuredClone" in global)) {
15
12
  polyfillGlobal("structuredClone", () => structuredClone);
@@ -23,4 +20,3 @@ if (Platform.OS !== "web") {
23
20
  }
24
21
 
25
22
  export {};
26
-
@@ -3,13 +3,10 @@ import { Platform } from "react-native";
3
3
 
4
4
  if (Platform.OS !== "web") {
5
5
  const setupPolyfills = async () => {
6
- const { polyfillGlobal } = await import(
7
- "react-native/Libraries/Utilities/PolyfillFunctions"
8
- );
6
+ const { polyfillGlobal } = await import("react-native/Libraries/Utilities/PolyfillFunctions");
9
7
 
10
- const { TextEncoderStream, TextDecoderStream } = await import(
11
- "@stardazed/streams-text-encoding"
12
- );
8
+ const { TextEncoderStream, TextDecoderStream } =
9
+ await import("@stardazed/streams-text-encoding");
13
10
 
14
11
  if (!("structuredClone" in global)) {
15
12
  polyfillGlobal("structuredClone", () => structuredClone);
@@ -3,13 +3,10 @@ import { Platform } from "react-native";
3
3
 
4
4
  if (Platform.OS !== "web") {
5
5
  const setupPolyfills = async () => {
6
- const { polyfillGlobal } = await import(
7
- "react-native/Libraries/Utilities/PolyfillFunctions"
8
- );
6
+ const { polyfillGlobal } = await import("react-native/Libraries/Utilities/PolyfillFunctions");
9
7
 
10
- const { TextEncoderStream, TextDecoderStream } = await import(
11
- "@stardazed/streams-text-encoding"
12
- );
8
+ const { TextEncoderStream, TextDecoderStream } =
9
+ await import("@stardazed/streams-text-encoding");
13
10
 
14
11
  if (!("structuredClone" in global)) {
15
12
  polyfillGlobal("structuredClone", () => structuredClone);
@@ -23,4 +20,3 @@ if (Platform.OS !== "web") {
23
20
  }
24
21
 
25
22
  export {};
26
-
@@ -3,5 +3,5 @@ import { pgTable, text, boolean, serial } from "drizzle-orm/pg-core";
3
3
  export const todo = pgTable("todo", {
4
4
  id: serial("id").primaryKey(),
5
5
  text: text("text").notNull(),
6
- completed: boolean("completed").default(false).notNull()
6
+ completed: boolean("completed").default(false).notNull(),
7
7
  });
@@ -22,15 +22,9 @@ export function ModeToggle() {
22
22
  </Button>
23
23
  </DropdownMenuTrigger>
24
24
  <DropdownMenuContent align="end">
25
- <DropdownMenuItem onClick={() => setTheme("light")}>
26
- Light
27
- </DropdownMenuItem>
28
- <DropdownMenuItem onClick={() => setTheme("dark")}>
29
- Dark
30
- </DropdownMenuItem>
31
- <DropdownMenuItem onClick={() => setTheme("system")}>
32
- System
33
- </DropdownMenuItem>
25
+ <DropdownMenuItem onClick={() => setTheme("light")}>Light</DropdownMenuItem>
26
+ <DropdownMenuItem onClick={() => setTheme("dark")}>Dark</DropdownMenuItem>
27
+ <DropdownMenuItem onClick={() => setTheme("system")}>System</DropdownMenuItem>
34
28
  </DropdownMenuContent>
35
29
  </DropdownMenu>
36
30
  );
@@ -22,15 +22,9 @@ export function ModeToggle() {
22
22
  </Button>
23
23
  </DropdownMenuTrigger>
24
24
  <DropdownMenuContent align="end">
25
- <DropdownMenuItem onClick={() => setTheme("light")}>
26
- Light
27
- </DropdownMenuItem>
28
- <DropdownMenuItem onClick={() => setTheme("dark")}>
29
- Dark
30
- </DropdownMenuItem>
31
- <DropdownMenuItem onClick={() => setTheme("system")}>
32
- System
33
- </DropdownMenuItem>
25
+ <DropdownMenuItem onClick={() => setTheme("light")}>Light</DropdownMenuItem>
26
+ <DropdownMenuItem onClick={() => setTheme("dark")}>Dark</DropdownMenuItem>
27
+ <DropdownMenuItem onClick={() => setTheme("system")}>System</DropdownMenuItem>
34
28
  </DropdownMenuContent>
35
29
  </DropdownMenu>
36
30
  );
@@ -1,24 +1,21 @@
1
- import * as React from "react"
2
- import { Slot as SlotPrimitive } from "radix-ui"
3
- import { cva, type VariantProps } from "class-variance-authority"
1
+ import * as React from "react";
2
+ import { Slot as SlotPrimitive } from "radix-ui";
3
+ import { cva, type VariantProps } from "class-variance-authority";
4
4
 
5
- import { cn } from "@/lib/utils"
5
+ import { cn } from "@/lib/utils";
6
6
 
7
7
  const buttonVariants = cva(
8
8
  "inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive",
9
9
  {
10
10
  variants: {
11
11
  variant: {
12
- default:
13
- "bg-primary text-primary-foreground shadow-xs hover:bg-primary/90",
12
+ default: "bg-primary text-primary-foreground shadow-xs hover:bg-primary/90",
14
13
  destructive:
15
14
  "bg-destructive text-white shadow-xs hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",
16
15
  outline:
17
16
  "border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
18
- secondary:
19
- "bg-secondary text-secondary-foreground shadow-xs hover:bg-secondary/80",
20
- ghost:
21
- "hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",
17
+ secondary: "bg-secondary text-secondary-foreground shadow-xs hover:bg-secondary/80",
18
+ ghost: "hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",
22
19
  link: "text-primary underline-offset-4 hover:underline",
23
20
  },
24
21
  size: {
@@ -32,8 +29,8 @@ const buttonVariants = cva(
32
29
  variant: "default",
33
30
  size: "default",
34
31
  },
35
- }
36
- )
32
+ },
33
+ );
37
34
 
38
35
  function Button({
39
36
  className,
@@ -43,9 +40,9 @@ function Button({
43
40
  ...props
44
41
  }: React.ComponentProps<"button"> &
45
42
  VariantProps<typeof buttonVariants> & {
46
- asChild?: boolean
43
+ asChild?: boolean;
47
44
  }) {
48
- const Comp = asChild ? SlotPrimitive.Slot : "button"
45
+ const Comp = asChild ? SlotPrimitive.Slot : "button";
49
46
 
50
47
  return (
51
48
  <Comp
@@ -53,7 +50,7 @@ function Button({
53
50
  className={cn(buttonVariants({ variant, size, className }))}
54
51
  {...props}
55
52
  />
56
- )
53
+ );
57
54
  }
58
55
 
59
- export { Button, buttonVariants }
56
+ export { Button, buttonVariants };
@@ -1,6 +1,6 @@
1
- import * as React from "react"
1
+ import * as React from "react";
2
2
 
3
- import { cn } from "@/lib/utils"
3
+ import { cn } from "@/lib/utils";
4
4
 
5
5
  function Card({ className, ...props }: React.ComponentProps<"div">) {
6
6
  return (
@@ -8,11 +8,11 @@ function Card({ className, ...props }: React.ComponentProps<"div">) {
8
8
  data-slot="card"
9
9
  className={cn(
10
10
  "bg-card text-card-foreground flex flex-col gap-6 rounded-xl border py-6 shadow-sm",
11
- className
11
+ className,
12
12
  )}
13
13
  {...props}
14
14
  />
15
- )
15
+ );
16
16
  }
17
17
 
18
18
  function CardHeader({ className, ...props }: React.ComponentProps<"div">) {
@@ -21,11 +21,11 @@ function CardHeader({ className, ...props }: React.ComponentProps<"div">) {
21
21
  data-slot="card-header"
22
22
  className={cn(
23
23
  "@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-1.5 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",
24
- className
24
+ className,
25
25
  )}
26
26
  {...props}
27
27
  />
28
- )
28
+ );
29
29
  }
30
30
 
31
31
  function CardTitle({ className, ...props }: React.ComponentProps<"div">) {
@@ -35,7 +35,7 @@ function CardTitle({ className, ...props }: React.ComponentProps<"div">) {
35
35
  className={cn("leading-none font-semibold", className)}
36
36
  {...props}
37
37
  />
38
- )
38
+ );
39
39
  }
40
40
 
41
41
  function CardDescription({ className, ...props }: React.ComponentProps<"div">) {
@@ -45,30 +45,21 @@ function CardDescription({ className, ...props }: React.ComponentProps<"div">) {
45
45
  className={cn("text-muted-foreground text-sm", className)}
46
46
  {...props}
47
47
  />
48
- )
48
+ );
49
49
  }
50
50
 
51
51
  function CardAction({ className, ...props }: React.ComponentProps<"div">) {
52
52
  return (
53
53
  <div
54
54
  data-slot="card-action"
55
- className={cn(
56
- "col-start-2 row-span-2 row-start-1 self-start justify-self-end",
57
- className
58
- )}
55
+ className={cn("col-start-2 row-span-2 row-start-1 self-start justify-self-end", className)}
59
56
  {...props}
60
57
  />
61
- )
58
+ );
62
59
  }
63
60
 
64
61
  function CardContent({ className, ...props }: React.ComponentProps<"div">) {
65
- return (
66
- <div
67
- data-slot="card-content"
68
- className={cn("px-6", className)}
69
- {...props}
70
- />
71
- )
62
+ return <div data-slot="card-content" className={cn("px-6", className)} {...props} />;
72
63
  }
73
64
 
74
65
  function CardFooter({ className, ...props }: React.ComponentProps<"div">) {
@@ -78,15 +69,7 @@ function CardFooter({ className, ...props }: React.ComponentProps<"div">) {
78
69
  className={cn("flex items-center px-6 [.border-t]:pt-6", className)}
79
70
  {...props}
80
71
  />
81
- )
72
+ );
82
73
  }
83
74
 
84
- export {
85
- Card,
86
- CardHeader,
87
- CardFooter,
88
- CardTitle,
89
- CardAction,
90
- CardDescription,
91
- CardContent,
92
- }
75
+ export { Card, CardHeader, CardFooter, CardTitle, CardAction, CardDescription, CardContent };