create-better-t-stack 2.18.0 → 2.18.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.
- package/dist/index.js +119 -26
- package/package.json +1 -1
- package/templates/frontend/react/next/package.json.hbs +1 -4
- package/templates/frontend/react/react-router/package.json +1 -4
- package/templates/frontend/react/tanstack-router/package.json +1 -4
- package/templates/frontend/react/tanstack-start/package.json +1 -4
- package/templates/frontend/react/web-base/src/components/ui/button.tsx +9 -9
- package/templates/frontend/react/web-base/src/components/ui/card.tsx +10 -10
- package/templates/frontend/react/web-base/src/components/ui/checkbox.tsx +6 -6
- package/templates/frontend/react/web-base/src/components/ui/dropdown-menu.tsx +26 -24
- package/templates/frontend/react/web-base/src/components/ui/input.tsx +4 -4
- package/templates/frontend/react/web-base/src/components/ui/label.tsx +5 -7
- package/templates/frontend/react/web-base/src/components/ui/skeleton.tsx +3 -3
- package/templates/frontend/react/web-base/src/components/ui/sonner.tsx +2 -0
package/dist/index.js
CHANGED
|
@@ -3369,6 +3369,34 @@ function generateReproducibleCommand(config) {
|
|
|
3369
3369
|
return `${baseCommand}${projectPathArg} ${flags.join(" ")}`;
|
|
3370
3370
|
}
|
|
3371
3371
|
|
|
3372
|
+
//#endregion
|
|
3373
|
+
//#region src/utils/open-url.ts
|
|
3374
|
+
async function openUrl(url) {
|
|
3375
|
+
const platform = process.platform;
|
|
3376
|
+
let command;
|
|
3377
|
+
let args = [];
|
|
3378
|
+
if (platform === "darwin") {
|
|
3379
|
+
command = "open";
|
|
3380
|
+
args = [url];
|
|
3381
|
+
} else if (platform === "win32") {
|
|
3382
|
+
command = "cmd";
|
|
3383
|
+
args = [
|
|
3384
|
+
"/c",
|
|
3385
|
+
"start",
|
|
3386
|
+
"",
|
|
3387
|
+
url.replace(/&/g, "^&")
|
|
3388
|
+
];
|
|
3389
|
+
} else {
|
|
3390
|
+
command = "xdg-open";
|
|
3391
|
+
args = [url];
|
|
3392
|
+
}
|
|
3393
|
+
try {
|
|
3394
|
+
await execa(command, args, { stdio: "ignore" });
|
|
3395
|
+
} catch {
|
|
3396
|
+
log.message(`Please open ${url} in your browser.`);
|
|
3397
|
+
}
|
|
3398
|
+
}
|
|
3399
|
+
|
|
3372
3400
|
//#endregion
|
|
3373
3401
|
//#region src/utils/render-title.ts
|
|
3374
3402
|
const TITLE_TEXT = `
|
|
@@ -3413,6 +3441,40 @@ const renderTitle = () => {
|
|
|
3413
3441
|
} else console.log(gradient(Object.values(catppuccinTheme)).multiline(TITLE_TEXT));
|
|
3414
3442
|
};
|
|
3415
3443
|
|
|
3444
|
+
//#endregion
|
|
3445
|
+
//#region src/utils/sponsors.ts
|
|
3446
|
+
const SPONSORS_JSON_URL = "https://sponsors.amanv.dev/sponsors.json";
|
|
3447
|
+
async function fetchSponsors(url = SPONSORS_JSON_URL) {
|
|
3448
|
+
const s = spinner();
|
|
3449
|
+
s.start("Fetching sponsors…");
|
|
3450
|
+
const response = await fetch(url);
|
|
3451
|
+
if (!response.ok) {
|
|
3452
|
+
s.stop(pc.red(`Failed to fetch sponsors: ${response.statusText}`));
|
|
3453
|
+
throw new Error(`Failed to fetch sponsors: ${response.statusText}`);
|
|
3454
|
+
}
|
|
3455
|
+
const sponsors = await response.json();
|
|
3456
|
+
s.stop("Sponsors fetched successfully!");
|
|
3457
|
+
return sponsors;
|
|
3458
|
+
}
|
|
3459
|
+
function displaySponsors(sponsors) {
|
|
3460
|
+
if (sponsors.length === 0) {
|
|
3461
|
+
log.info("No sponsors found. You can be the first one! ✨");
|
|
3462
|
+
outro(pc.cyan("Visit https://github.com/sponsors/AmanVarshney01 to become a sponsor."));
|
|
3463
|
+
return;
|
|
3464
|
+
}
|
|
3465
|
+
sponsors.forEach((entry, idx) => {
|
|
3466
|
+
const sponsor = entry.sponsor;
|
|
3467
|
+
const displayName = sponsor.name ?? sponsor.login;
|
|
3468
|
+
const tier = entry.tierName ? ` (${entry.tierName})` : "";
|
|
3469
|
+
log.step(`${idx + 1}. ${pc.green(displayName)}${pc.yellow(tier)}`);
|
|
3470
|
+
log.message(` ${pc.dim("GitHub:")} https://github.com/${sponsor.login}`);
|
|
3471
|
+
const website = sponsor.websiteUrl ?? sponsor.linkUrl;
|
|
3472
|
+
if (website) log.message(` ${pc.dim("Website:")} ${website}`);
|
|
3473
|
+
});
|
|
3474
|
+
log.message("");
|
|
3475
|
+
outro(pc.magenta("Visit https://github.com/sponsors/AmanVarshney01 to become a sponsor."));
|
|
3476
|
+
}
|
|
3477
|
+
|
|
3416
3478
|
//#endregion
|
|
3417
3479
|
//#region src/validation.ts
|
|
3418
3480
|
function processAndValidateFlags(options, providedFlags, projectName) {
|
|
@@ -3746,32 +3808,63 @@ async function createProjectHandler(input) {
|
|
|
3746
3808
|
process.exit(1);
|
|
3747
3809
|
}
|
|
3748
3810
|
}
|
|
3749
|
-
const router = t.router({
|
|
3750
|
-
|
|
3751
|
-
|
|
3752
|
-
|
|
3753
|
-
|
|
3754
|
-
|
|
3755
|
-
|
|
3756
|
-
|
|
3757
|
-
|
|
3758
|
-
|
|
3759
|
-
|
|
3760
|
-
|
|
3761
|
-
|
|
3762
|
-
|
|
3763
|
-
|
|
3764
|
-
|
|
3765
|
-
|
|
3766
|
-
|
|
3767
|
-
|
|
3768
|
-
|
|
3769
|
-
|
|
3770
|
-
|
|
3771
|
-
|
|
3772
|
-
|
|
3773
|
-
|
|
3774
|
-
|
|
3811
|
+
const router = t.router({
|
|
3812
|
+
init: t.procedure.meta({
|
|
3813
|
+
description: "Create a new Better-T Stack project",
|
|
3814
|
+
default: true
|
|
3815
|
+
}).input(zod.tuple([ProjectNameSchema.optional(), zod.object({
|
|
3816
|
+
yes: zod.boolean().optional().default(false).describe("Use default configuration"),
|
|
3817
|
+
database: DatabaseSchema.optional(),
|
|
3818
|
+
orm: ORMSchema.optional(),
|
|
3819
|
+
auth: zod.boolean().optional(),
|
|
3820
|
+
frontend: zod.array(FrontendSchema).optional(),
|
|
3821
|
+
addons: zod.array(AddonsSchema).optional(),
|
|
3822
|
+
examples: zod.array(ExamplesSchema).optional(),
|
|
3823
|
+
git: zod.boolean().optional(),
|
|
3824
|
+
packageManager: PackageManagerSchema.optional(),
|
|
3825
|
+
install: zod.boolean().optional(),
|
|
3826
|
+
dbSetup: DatabaseSetupSchema.optional(),
|
|
3827
|
+
backend: BackendSchema.optional(),
|
|
3828
|
+
runtime: RuntimeSchema.optional(),
|
|
3829
|
+
api: APISchema.optional()
|
|
3830
|
+
}).optional().default({})])).mutation(async ({ input }) => {
|
|
3831
|
+
const [projectName, options] = input;
|
|
3832
|
+
const combinedInput = {
|
|
3833
|
+
projectName,
|
|
3834
|
+
...options
|
|
3835
|
+
};
|
|
3836
|
+
await createProjectHandler(combinedInput);
|
|
3837
|
+
}),
|
|
3838
|
+
sponsors: t.procedure.meta({ description: "Show Better-T Stack sponsors" }).mutation(async () => {
|
|
3839
|
+
try {
|
|
3840
|
+
renderTitle();
|
|
3841
|
+
intro(pc.magenta("Better-T Stack Sponsors"));
|
|
3842
|
+
const sponsors = await fetchSponsors();
|
|
3843
|
+
displaySponsors(sponsors);
|
|
3844
|
+
} catch (error) {
|
|
3845
|
+
consola$1.error(error);
|
|
3846
|
+
process.exit(1);
|
|
3847
|
+
}
|
|
3848
|
+
}),
|
|
3849
|
+
docs: t.procedure.meta({ description: "Open Better-T Stack documentation" }).mutation(async () => {
|
|
3850
|
+
const DOCS_URL = "https://better-t-stack.amanv.dev/docs";
|
|
3851
|
+
try {
|
|
3852
|
+
await openUrl(DOCS_URL);
|
|
3853
|
+
log.success(pc.blue("Opened docs in your default browser."));
|
|
3854
|
+
} catch {
|
|
3855
|
+
log.message(`Please visit ${DOCS_URL}`);
|
|
3856
|
+
}
|
|
3857
|
+
}),
|
|
3858
|
+
builder: t.procedure.meta({ description: "Open the web-based stack builder" }).mutation(async () => {
|
|
3859
|
+
const BUILDER_URL = "https://better-t-stack.amanv.dev/new";
|
|
3860
|
+
try {
|
|
3861
|
+
await openUrl(BUILDER_URL);
|
|
3862
|
+
log.success(pc.blue("Opened builder in your default browser."));
|
|
3863
|
+
} catch {
|
|
3864
|
+
log.message(`Please visit ${BUILDER_URL}`);
|
|
3865
|
+
}
|
|
3866
|
+
})
|
|
3867
|
+
});
|
|
3775
3868
|
createCli({
|
|
3776
3869
|
router,
|
|
3777
3870
|
name: "create-better-t-stack",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-better-t-stack",
|
|
3
|
-
"version": "2.18.
|
|
3
|
+
"version": "2.18.2",
|
|
4
4
|
"description": "A modern CLI tool for scaffolding end-to-end type-safe TypeScript projects with best practices and customizable configurations",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -9,10 +9,7 @@
|
|
|
9
9
|
"lint": "next lint"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"
|
|
13
|
-
"@radix-ui/react-dropdown-menu": "^2.1.7",
|
|
14
|
-
"@radix-ui/react-label": "^2.1.3",
|
|
15
|
-
"@radix-ui/react-slot": "^1.2.0",
|
|
12
|
+
"radix-ui": "^1.4.2",
|
|
16
13
|
"@tanstack/react-form": "^1.3.2",
|
|
17
14
|
"class-variance-authority": "^0.7.1",
|
|
18
15
|
"clsx": "^2.1.1",
|
|
@@ -9,10 +9,7 @@
|
|
|
9
9
|
"typecheck": "react-router typegen && tsc"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"
|
|
13
|
-
"@radix-ui/react-dropdown-menu": "^2.1.15",
|
|
14
|
-
"@radix-ui/react-label": "^2.1.7",
|
|
15
|
-
"@radix-ui/react-slot": "^1.2.3",
|
|
12
|
+
"radix-ui": "^1.4.2",
|
|
16
13
|
"@react-router/fs-routes": "^7.6.1",
|
|
17
14
|
"@react-router/node": "^7.6.1",
|
|
18
15
|
"@react-router/serve": "^7.6.1",
|
|
@@ -23,10 +23,7 @@
|
|
|
23
23
|
},
|
|
24
24
|
"dependencies": {
|
|
25
25
|
"@hookform/resolvers": "^3.10.0",
|
|
26
|
-
|
|
27
|
-
"@radix-ui/react-dropdown-menu": "^2.1.6",
|
|
28
|
-
"@radix-ui/react-label": "^2.1.2",
|
|
29
|
-
"@radix-ui/react-slot": "^1.1.2",
|
|
26
|
+
"radix-ui": "^1.4.2",
|
|
30
27
|
"@tanstack/react-form": "^1.0.5",
|
|
31
28
|
"@tailwindcss/vite": "^4.0.15",
|
|
32
29
|
"@tanstack/react-router": "^1.114.25",
|
|
@@ -8,10 +8,7 @@
|
|
|
8
8
|
"dev": "vite dev --port=3001"
|
|
9
9
|
},
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"
|
|
12
|
-
"@radix-ui/react-dropdown-menu": "^2.1.6",
|
|
13
|
-
"@radix-ui/react-label": "^2.1.2",
|
|
14
|
-
"@radix-ui/react-slot": "^1.1.2",
|
|
11
|
+
"radix-ui": "^1.4.2",
|
|
15
12
|
"@tanstack/react-form": "^1.0.5",
|
|
16
13
|
"@tailwindcss/vite": "^4.1.8",
|
|
17
14
|
"@tanstack/react-query": "^5.80.6",
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as React from "react"
|
|
2
|
-
import { Slot } from "
|
|
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",
|
|
@@ -33,7 +33,7 @@ const buttonVariants = cva(
|
|
|
33
33
|
size: "default",
|
|
34
34
|
},
|
|
35
35
|
}
|
|
36
|
-
)
|
|
36
|
+
)
|
|
37
37
|
|
|
38
38
|
function Button({
|
|
39
39
|
className,
|
|
@@ -43,9 +43,9 @@ function Button({
|
|
|
43
43
|
...props
|
|
44
44
|
}: React.ComponentProps<"button"> &
|
|
45
45
|
VariantProps<typeof buttonVariants> & {
|
|
46
|
-
asChild?: boolean
|
|
46
|
+
asChild?: boolean
|
|
47
47
|
}) {
|
|
48
|
-
const Comp = asChild ? Slot : "button"
|
|
48
|
+
const Comp = asChild ? SlotPrimitive.Slot : "button"
|
|
49
49
|
|
|
50
50
|
return (
|
|
51
51
|
<Comp
|
|
@@ -53,7 +53,7 @@ function Button({
|
|
|
53
53
|
className={cn(buttonVariants({ variant, size, className }))}
|
|
54
54
|
{...props}
|
|
55
55
|
/>
|
|
56
|
-
)
|
|
56
|
+
)
|
|
57
57
|
}
|
|
58
58
|
|
|
59
|
-
export { Button, buttonVariants }
|
|
59
|
+
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 (
|
|
@@ -12,7 +12,7 @@ function Card({ className, ...props }: React.ComponentProps<"div">) {
|
|
|
12
12
|
)}
|
|
13
13
|
{...props}
|
|
14
14
|
/>
|
|
15
|
-
)
|
|
15
|
+
)
|
|
16
16
|
}
|
|
17
17
|
|
|
18
18
|
function CardHeader({ className, ...props }: React.ComponentProps<"div">) {
|
|
@@ -25,7 +25,7 @@ function CardHeader({ className, ...props }: React.ComponentProps<"div">) {
|
|
|
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,7 +45,7 @@ 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">) {
|
|
@@ -58,7 +58,7 @@ function CardAction({ className, ...props }: React.ComponentProps<"div">) {
|
|
|
58
58
|
)}
|
|
59
59
|
{...props}
|
|
60
60
|
/>
|
|
61
|
-
)
|
|
61
|
+
)
|
|
62
62
|
}
|
|
63
63
|
|
|
64
64
|
function CardContent({ className, ...props }: React.ComponentProps<"div">) {
|
|
@@ -68,7 +68,7 @@ function CardContent({ className, ...props }: React.ComponentProps<"div">) {
|
|
|
68
68
|
className={cn("px-6", className)}
|
|
69
69
|
{...props}
|
|
70
70
|
/>
|
|
71
|
-
)
|
|
71
|
+
)
|
|
72
72
|
}
|
|
73
73
|
|
|
74
74
|
function CardFooter({ className, ...props }: React.ComponentProps<"div">) {
|
|
@@ -78,7 +78,7 @@ function CardFooter({ className, ...props }: React.ComponentProps<"div">) {
|
|
|
78
78
|
className={cn("flex items-center px-6 [.border-t]:pt-6", className)}
|
|
79
79
|
{...props}
|
|
80
80
|
/>
|
|
81
|
-
)
|
|
81
|
+
)
|
|
82
82
|
}
|
|
83
83
|
|
|
84
84
|
export {
|
|
@@ -89,4 +89,4 @@ export {
|
|
|
89
89
|
CardAction,
|
|
90
90
|
CardDescription,
|
|
91
91
|
CardContent,
|
|
92
|
-
}
|
|
92
|
+
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as React from "react"
|
|
2
|
-
import
|
|
3
|
-
import { CheckIcon } from "lucide-react"
|
|
1
|
+
import * as React from "react"
|
|
2
|
+
import { Checkbox as CheckboxPrimitive } from "radix-ui"
|
|
3
|
+
import { CheckIcon } from "lucide-react"
|
|
4
4
|
|
|
5
|
-
import { cn } from "@/lib/utils"
|
|
5
|
+
import { cn } from "@/lib/utils"
|
|
6
6
|
|
|
7
7
|
function Checkbox({
|
|
8
8
|
className,
|
|
@@ -24,7 +24,7 @@ function Checkbox({
|
|
|
24
24
|
<CheckIcon className="size-3.5" />
|
|
25
25
|
</CheckboxPrimitive.Indicator>
|
|
26
26
|
</CheckboxPrimitive.Root>
|
|
27
|
-
)
|
|
27
|
+
)
|
|
28
28
|
}
|
|
29
29
|
|
|
30
|
-
export { Checkbox }
|
|
30
|
+
export { Checkbox }
|
|
@@ -1,13 +1,15 @@
|
|
|
1
|
-
|
|
2
|
-
import * as DropdownMenuPrimitive from "@radix-ui/react-dropdown-menu";
|
|
3
|
-
import { CheckIcon, ChevronRightIcon, CircleIcon } from "lucide-react";
|
|
1
|
+
"use client"
|
|
4
2
|
|
|
5
|
-
import
|
|
3
|
+
import * as React from "react"
|
|
4
|
+
import { DropdownMenu as DropdownMenuPrimitive } from "radix-ui"
|
|
5
|
+
import { CheckIcon, ChevronRightIcon, CircleIcon } from "lucide-react"
|
|
6
|
+
|
|
7
|
+
import { cn } from "@/lib/utils"
|
|
6
8
|
|
|
7
9
|
function DropdownMenu({
|
|
8
10
|
...props
|
|
9
11
|
}: React.ComponentProps<typeof DropdownMenuPrimitive.Root>) {
|
|
10
|
-
return <DropdownMenuPrimitive.Root data-slot="dropdown-menu" {...props}
|
|
12
|
+
return <DropdownMenuPrimitive.Root data-slot="dropdown-menu" {...props} />
|
|
11
13
|
}
|
|
12
14
|
|
|
13
15
|
function DropdownMenuPortal({
|
|
@@ -15,7 +17,7 @@ function DropdownMenuPortal({
|
|
|
15
17
|
}: React.ComponentProps<typeof DropdownMenuPrimitive.Portal>) {
|
|
16
18
|
return (
|
|
17
19
|
<DropdownMenuPrimitive.Portal data-slot="dropdown-menu-portal" {...props} />
|
|
18
|
-
)
|
|
20
|
+
)
|
|
19
21
|
}
|
|
20
22
|
|
|
21
23
|
function DropdownMenuTrigger({
|
|
@@ -26,7 +28,7 @@ function DropdownMenuTrigger({
|
|
|
26
28
|
data-slot="dropdown-menu-trigger"
|
|
27
29
|
{...props}
|
|
28
30
|
/>
|
|
29
|
-
)
|
|
31
|
+
)
|
|
30
32
|
}
|
|
31
33
|
|
|
32
34
|
function DropdownMenuContent({
|
|
@@ -46,7 +48,7 @@ function DropdownMenuContent({
|
|
|
46
48
|
{...props}
|
|
47
49
|
/>
|
|
48
50
|
</DropdownMenuPrimitive.Portal>
|
|
49
|
-
)
|
|
51
|
+
)
|
|
50
52
|
}
|
|
51
53
|
|
|
52
54
|
function DropdownMenuGroup({
|
|
@@ -54,7 +56,7 @@ function DropdownMenuGroup({
|
|
|
54
56
|
}: React.ComponentProps<typeof DropdownMenuPrimitive.Group>) {
|
|
55
57
|
return (
|
|
56
58
|
<DropdownMenuPrimitive.Group data-slot="dropdown-menu-group" {...props} />
|
|
57
|
-
)
|
|
59
|
+
)
|
|
58
60
|
}
|
|
59
61
|
|
|
60
62
|
function DropdownMenuItem({
|
|
@@ -63,8 +65,8 @@ function DropdownMenuItem({
|
|
|
63
65
|
variant = "default",
|
|
64
66
|
...props
|
|
65
67
|
}: React.ComponentProps<typeof DropdownMenuPrimitive.Item> & {
|
|
66
|
-
inset?: boolean
|
|
67
|
-
variant?: "default" | "destructive"
|
|
68
|
+
inset?: boolean
|
|
69
|
+
variant?: "default" | "destructive"
|
|
68
70
|
}) {
|
|
69
71
|
return (
|
|
70
72
|
<DropdownMenuPrimitive.Item
|
|
@@ -77,7 +79,7 @@ function DropdownMenuItem({
|
|
|
77
79
|
)}
|
|
78
80
|
{...props}
|
|
79
81
|
/>
|
|
80
|
-
)
|
|
82
|
+
)
|
|
81
83
|
}
|
|
82
84
|
|
|
83
85
|
function DropdownMenuCheckboxItem({
|
|
@@ -103,7 +105,7 @@ function DropdownMenuCheckboxItem({
|
|
|
103
105
|
</span>
|
|
104
106
|
{children}
|
|
105
107
|
</DropdownMenuPrimitive.CheckboxItem>
|
|
106
|
-
)
|
|
108
|
+
)
|
|
107
109
|
}
|
|
108
110
|
|
|
109
111
|
function DropdownMenuRadioGroup({
|
|
@@ -114,7 +116,7 @@ function DropdownMenuRadioGroup({
|
|
|
114
116
|
data-slot="dropdown-menu-radio-group"
|
|
115
117
|
{...props}
|
|
116
118
|
/>
|
|
117
|
-
)
|
|
119
|
+
)
|
|
118
120
|
}
|
|
119
121
|
|
|
120
122
|
function DropdownMenuRadioItem({
|
|
@@ -138,7 +140,7 @@ function DropdownMenuRadioItem({
|
|
|
138
140
|
</span>
|
|
139
141
|
{children}
|
|
140
142
|
</DropdownMenuPrimitive.RadioItem>
|
|
141
|
-
)
|
|
143
|
+
)
|
|
142
144
|
}
|
|
143
145
|
|
|
144
146
|
function DropdownMenuLabel({
|
|
@@ -146,7 +148,7 @@ function DropdownMenuLabel({
|
|
|
146
148
|
inset,
|
|
147
149
|
...props
|
|
148
150
|
}: React.ComponentProps<typeof DropdownMenuPrimitive.Label> & {
|
|
149
|
-
inset?: boolean
|
|
151
|
+
inset?: boolean
|
|
150
152
|
}) {
|
|
151
153
|
return (
|
|
152
154
|
<DropdownMenuPrimitive.Label
|
|
@@ -158,7 +160,7 @@ function DropdownMenuLabel({
|
|
|
158
160
|
)}
|
|
159
161
|
{...props}
|
|
160
162
|
/>
|
|
161
|
-
)
|
|
163
|
+
)
|
|
162
164
|
}
|
|
163
165
|
|
|
164
166
|
function DropdownMenuSeparator({
|
|
@@ -171,7 +173,7 @@ function DropdownMenuSeparator({
|
|
|
171
173
|
className={cn("bg-border -mx-1 my-1 h-px", className)}
|
|
172
174
|
{...props}
|
|
173
175
|
/>
|
|
174
|
-
)
|
|
176
|
+
)
|
|
175
177
|
}
|
|
176
178
|
|
|
177
179
|
function DropdownMenuShortcut({
|
|
@@ -187,13 +189,13 @@ function DropdownMenuShortcut({
|
|
|
187
189
|
)}
|
|
188
190
|
{...props}
|
|
189
191
|
/>
|
|
190
|
-
)
|
|
192
|
+
)
|
|
191
193
|
}
|
|
192
194
|
|
|
193
195
|
function DropdownMenuSub({
|
|
194
196
|
...props
|
|
195
197
|
}: React.ComponentProps<typeof DropdownMenuPrimitive.Sub>) {
|
|
196
|
-
return <DropdownMenuPrimitive.Sub data-slot="dropdown-menu-sub" {...props}
|
|
198
|
+
return <DropdownMenuPrimitive.Sub data-slot="dropdown-menu-sub" {...props} />
|
|
197
199
|
}
|
|
198
200
|
|
|
199
201
|
function DropdownMenuSubTrigger({
|
|
@@ -202,7 +204,7 @@ function DropdownMenuSubTrigger({
|
|
|
202
204
|
children,
|
|
203
205
|
...props
|
|
204
206
|
}: React.ComponentProps<typeof DropdownMenuPrimitive.SubTrigger> & {
|
|
205
|
-
inset?: boolean
|
|
207
|
+
inset?: boolean
|
|
206
208
|
}) {
|
|
207
209
|
return (
|
|
208
210
|
<DropdownMenuPrimitive.SubTrigger
|
|
@@ -217,7 +219,7 @@ function DropdownMenuSubTrigger({
|
|
|
217
219
|
{children}
|
|
218
220
|
<ChevronRightIcon className="ml-auto size-4" />
|
|
219
221
|
</DropdownMenuPrimitive.SubTrigger>
|
|
220
|
-
)
|
|
222
|
+
)
|
|
221
223
|
}
|
|
222
224
|
|
|
223
225
|
function DropdownMenuSubContent({
|
|
@@ -233,7 +235,7 @@ function DropdownMenuSubContent({
|
|
|
233
235
|
)}
|
|
234
236
|
{...props}
|
|
235
237
|
/>
|
|
236
|
-
)
|
|
238
|
+
)
|
|
237
239
|
}
|
|
238
240
|
|
|
239
241
|
export {
|
|
@@ -252,4 +254,4 @@ export {
|
|
|
252
254
|
DropdownMenuSub,
|
|
253
255
|
DropdownMenuSubTrigger,
|
|
254
256
|
DropdownMenuSubContent,
|
|
255
|
-
}
|
|
257
|
+
}
|
|
@@ -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 Input({ className, type, ...props }: React.ComponentProps<"input">) {
|
|
6
6
|
return (
|
|
@@ -15,7 +15,7 @@ function Input({ className, type, ...props }: React.ComponentProps<"input">) {
|
|
|
15
15
|
)}
|
|
16
16
|
{...props}
|
|
17
17
|
/>
|
|
18
|
-
)
|
|
18
|
+
)
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
export { Input }
|
|
21
|
+
export { Input }
|
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
|
|
1
|
+
import * as React from "react"
|
|
2
|
+
import { Label as LabelPrimitive } from "radix-ui"
|
|
2
3
|
|
|
3
|
-
import
|
|
4
|
-
import * as LabelPrimitive from "@radix-ui/react-label";
|
|
5
|
-
|
|
6
|
-
import { cn } from "@/lib/utils";
|
|
4
|
+
import { cn } from "@/lib/utils"
|
|
7
5
|
|
|
8
6
|
function Label({
|
|
9
7
|
className,
|
|
@@ -18,7 +16,7 @@ function Label({
|
|
|
18
16
|
)}
|
|
19
17
|
{...props}
|
|
20
18
|
/>
|
|
21
|
-
)
|
|
19
|
+
)
|
|
22
20
|
}
|
|
23
21
|
|
|
24
|
-
export { Label }
|
|
22
|
+
export { Label }
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { cn } from "@/lib/utils"
|
|
1
|
+
import { cn } from "@/lib/utils"
|
|
2
2
|
|
|
3
3
|
function Skeleton({ className, ...props }: React.ComponentProps<"div">) {
|
|
4
4
|
return (
|
|
@@ -7,7 +7,7 @@ function Skeleton({ className, ...props }: React.ComponentProps<"div">) {
|
|
|
7
7
|
className={cn("bg-accent animate-pulse rounded-md", className)}
|
|
8
8
|
{...props}
|
|
9
9
|
/>
|
|
10
|
-
)
|
|
10
|
+
)
|
|
11
11
|
}
|
|
12
12
|
|
|
13
|
-
export { Skeleton }
|
|
13
|
+
export { Skeleton }
|