@newt-app/templates 0.17.0 → 0.18.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.
- package/dist/index.js +63 -35
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -474,38 +474,38 @@ export default function Home() {
|
|
|
474
474
|
return (
|
|
475
475
|
<main className="max-w-lg mx-auto min-h-full px-4 py-8 space-y-4">
|
|
476
476
|
<div className="pb-4 border-b">
|
|
477
|
-
<p className="font-mono text-sm text-
|
|
478
|
-
<p className="text-sm text-
|
|
477
|
+
<p className="font-mono text-sm text-muted-foreground">apps/web/page.tsx</p>
|
|
478
|
+
<p className="text-sm text-muted-foreground">Delete me to get started!</p>
|
|
479
479
|
</div>
|
|
480
480
|
|
|
481
481
|
<div className="flex items-center gap-3 py-2">
|
|
482
482
|
<Logo className="w-10 h-auto text-foreground" />
|
|
483
483
|
<div>
|
|
484
484
|
<h1 className="text-4xl font-black tracking-tight"><%= projectName %></h1>
|
|
485
|
-
<p className="text-sm text-
|
|
485
|
+
<p className="text-sm text-muted-foreground tracking-widest uppercase">
|
|
486
486
|
Next + Nest = Newt \u{1F49C}
|
|
487
487
|
</p>
|
|
488
488
|
</div>
|
|
489
489
|
</div>
|
|
490
490
|
|
|
491
491
|
<div className="rounded-xl border p-6 space-y-1">
|
|
492
|
-
<p className="text-xs font-mono uppercase tracking-widest text-
|
|
493
|
-
<p className="font-mono text-sm text-
|
|
494
|
-
<p className="text-sm text-
|
|
492
|
+
<p className="text-xs font-mono uppercase tracking-widest text-muted-foreground">next.js</p>
|
|
493
|
+
<p className="font-mono text-sm text-muted-foreground">apps/web/layout.tsx</p>
|
|
494
|
+
<p className="text-sm text-muted-foreground">Next.js rendering</p>
|
|
495
495
|
</div>
|
|
496
496
|
|
|
497
497
|
<div className="rounded-xl border p-6 space-y-1">
|
|
498
|
-
<p className="text-xs font-mono uppercase tracking-widest text-
|
|
499
|
-
<p className="font-mono text-sm text-
|
|
500
|
-
<pre className="mt-2 border rounded-md p-3 text-sm bg-
|
|
498
|
+
<p className="text-xs font-mono uppercase tracking-widest text-muted-foreground">nest.js</p>
|
|
499
|
+
<p className="font-mono text-sm text-muted-foreground">GET /api/hello</p>
|
|
500
|
+
<pre className="mt-2 border rounded-md p-3 text-sm bg-muted/50">
|
|
501
501
|
<code>{JSON.stringify(hello, null, 2)}</code>
|
|
502
502
|
</pre>
|
|
503
503
|
</div>
|
|
504
504
|
|
|
505
505
|
<div className="rounded-xl border p-6">
|
|
506
|
-
<p className="text-xs font-mono uppercase tracking-widest text-
|
|
506
|
+
<p className="text-xs font-mono uppercase tracking-widest text-muted-foreground mb-4">better-auth</p>
|
|
507
507
|
{isPending ? (
|
|
508
|
-
<p className="text-sm text-
|
|
508
|
+
<p className="text-sm text-muted-foreground">Loading\u2026</p>
|
|
509
509
|
) : session ? (
|
|
510
510
|
<div className="space-y-3">
|
|
511
511
|
<p className="text-sm">Signed in as {session.user.name}</p>
|
|
@@ -519,7 +519,7 @@ export default function Home() {
|
|
|
519
519
|
</div>
|
|
520
520
|
|
|
521
521
|
<div className="px-2 py-4 text-sm">
|
|
522
|
-
<p className="mb-2 text-
|
|
522
|
+
<p className="mb-2 text-muted-foreground">Learn more</p>
|
|
523
523
|
<ul className="list-disc list-inside space-y-2 mt-2">
|
|
524
524
|
<li>
|
|
525
525
|
<Link href="https://github.com">GitHub</Link>
|
|
@@ -587,7 +587,7 @@ export function AuthForm() {
|
|
|
587
587
|
className={
|
|
588
588
|
tab === 'signup'
|
|
589
589
|
? 'font-semibold'
|
|
590
|
-
: 'text-
|
|
590
|
+
: 'text-muted-foreground hover:text-gray-200'
|
|
591
591
|
}
|
|
592
592
|
>
|
|
593
593
|
Sign up
|
|
@@ -598,7 +598,7 @@ export function AuthForm() {
|
|
|
598
598
|
className={
|
|
599
599
|
tab === 'signin'
|
|
600
600
|
? 'font-semibold'
|
|
601
|
-
: 'text-
|
|
601
|
+
: 'text-muted-foreground hover:text-gray-200'
|
|
602
602
|
}
|
|
603
603
|
>
|
|
604
604
|
Sign in
|
|
@@ -622,7 +622,7 @@ export function AuthForm() {
|
|
|
622
622
|
value={field.state.value}
|
|
623
623
|
onChange={(e) => field.handleChange(e.target.value)}
|
|
624
624
|
required
|
|
625
|
-
className="flex h-9 w-full rounded-md border border-neutral-700 bg-
|
|
625
|
+
className="flex h-9 w-full rounded-md border border-neutral-700 bg-muted/50/50 px-3 py-1 text-sm shadow-xs transition-[color,box-shadow] outline-none placeholder:text-neutral-500 focus-visible:border-neutral-500 focus-visible:ring-2 focus-visible:ring-neutral-500/20"
|
|
626
626
|
/>
|
|
627
627
|
</div>
|
|
628
628
|
)}
|
|
@@ -638,7 +638,7 @@ export function AuthForm() {
|
|
|
638
638
|
value={field.state.value}
|
|
639
639
|
onChange={(e) => field.handleChange(e.target.value)}
|
|
640
640
|
required
|
|
641
|
-
className="flex h-9 w-full rounded-md border border-neutral-700 bg-
|
|
641
|
+
className="flex h-9 w-full rounded-md border border-neutral-700 bg-muted/50/50 px-3 py-1 text-sm shadow-xs transition-[color,box-shadow] outline-none placeholder:text-neutral-500 focus-visible:border-neutral-500 focus-visible:ring-2 focus-visible:ring-neutral-500/20"
|
|
642
642
|
/>
|
|
643
643
|
</div>
|
|
644
644
|
)}
|
|
@@ -654,7 +654,7 @@ export function AuthForm() {
|
|
|
654
654
|
onChange={(e) => field.handleChange(e.target.value)}
|
|
655
655
|
required
|
|
656
656
|
minLength={8}
|
|
657
|
-
className="flex h-9 w-full rounded-md border border-neutral-700 bg-
|
|
657
|
+
className="flex h-9 w-full rounded-md border border-neutral-700 bg-muted/50/50 px-3 py-1 text-sm shadow-xs transition-[color,box-shadow] outline-none placeholder:text-neutral-500 focus-visible:border-neutral-500 focus-visible:ring-2 focus-visible:ring-neutral-500/20"
|
|
658
658
|
/>
|
|
659
659
|
</div>
|
|
660
660
|
)}
|
|
@@ -1260,6 +1260,7 @@ var globals_css_default = {
|
|
|
1260
1260
|
:root {
|
|
1261
1261
|
--background: oklch(0.145 0 0);
|
|
1262
1262
|
--foreground: oklch(0.985 0 0);
|
|
1263
|
+
--muted: oklch(0.269 0 0);
|
|
1263
1264
|
--muted-foreground: oklch(0.708 0 0);
|
|
1264
1265
|
--border: oklch(0.469 0 0);
|
|
1265
1266
|
}
|
|
@@ -1267,6 +1268,7 @@ var globals_css_default = {
|
|
|
1267
1268
|
@theme inline {
|
|
1268
1269
|
--color-background: var(--background);
|
|
1269
1270
|
--color-foreground: var(--foreground);
|
|
1271
|
+
--color-muted: var(--muted);
|
|
1270
1272
|
--color-muted-foreground: var(--muted-foreground);
|
|
1271
1273
|
--color-border: var(--border);
|
|
1272
1274
|
}
|
|
@@ -1328,6 +1330,31 @@ var ui = {
|
|
|
1328
1330
|
};
|
|
1329
1331
|
var ui_default = ui;
|
|
1330
1332
|
|
|
1333
|
+
// src/shadcn-ui/templates/components-json.ts
|
|
1334
|
+
var components_json_default = {
|
|
1335
|
+
filename: "packages/ui/components.json",
|
|
1336
|
+
template: `{
|
|
1337
|
+
"$schema": "https://ui.shadcn.com/schema.json",
|
|
1338
|
+
"style": "base-nova",
|
|
1339
|
+
"rsc": true,
|
|
1340
|
+
"tsx": true,
|
|
1341
|
+
"tailwind": {
|
|
1342
|
+
"config": "",
|
|
1343
|
+
"css": "src/styles/globals.css",
|
|
1344
|
+
"baseColor": "neutral",
|
|
1345
|
+
"cssVariables": true
|
|
1346
|
+
},
|
|
1347
|
+
"iconLibrary": "lucide",
|
|
1348
|
+
"aliases": {
|
|
1349
|
+
"components": "@<%= projectName %>/ui/components",
|
|
1350
|
+
"utils": "@<%= projectName %>/ui/lib/utils",
|
|
1351
|
+
"hooks": "@<%= projectName %>/ui/hooks",
|
|
1352
|
+
"lib": "@<%= projectName %>/ui/lib",
|
|
1353
|
+
"ui": "@<%= projectName %>/ui/components"
|
|
1354
|
+
}
|
|
1355
|
+
}`
|
|
1356
|
+
};
|
|
1357
|
+
|
|
1331
1358
|
// src/shadcn-ui/templates/package-json.ts
|
|
1332
1359
|
var package_json_default6 = {
|
|
1333
1360
|
filename: "packages/ui/package.json",
|
|
@@ -9025,7 +9052,8 @@ var shadcnUi = {
|
|
|
9025
9052
|
toggle_group_default,
|
|
9026
9053
|
toggle_default,
|
|
9027
9054
|
tooltip_default,
|
|
9028
|
-
mode_toggle_default
|
|
9055
|
+
mode_toggle_default,
|
|
9056
|
+
components_json_default
|
|
9029
9057
|
],
|
|
9030
9058
|
packages: [
|
|
9031
9059
|
{ package: "next-themes", module: "apps/web", version: "^0.4.6" }
|
|
@@ -10594,7 +10622,7 @@ export function TodoList({
|
|
|
10594
10622
|
<>
|
|
10595
10623
|
<div className="flex items-center justify-between mb-8">
|
|
10596
10624
|
<h1 className="text-2xl font-semibold">Todos</h1>
|
|
10597
|
-
<div className="flex items-center gap-3 text-sm text-
|
|
10625
|
+
<div className="flex items-center gap-3 text-sm text-muted-foreground">
|
|
10598
10626
|
<span>{session.user.email}</span>
|
|
10599
10627
|
<button
|
|
10600
10628
|
className="hover:text-gray-100"
|
|
@@ -10618,7 +10646,7 @@ export function TodoList({
|
|
|
10618
10646
|
value={field.state.value}
|
|
10619
10647
|
onChange={(e) => field.handleChange(e.target.value)}
|
|
10620
10648
|
placeholder="New todo\u2026"
|
|
10621
|
-
className="flex h-9 flex-1 rounded-md border border-neutral-700 bg-
|
|
10649
|
+
className="flex h-9 flex-1 rounded-md border border-neutral-700 bg-muted/50/50 px-3 py-1 text-sm shadow-xs transition-[color,box-shadow] outline-none placeholder:text-neutral-500 focus-visible:border-neutral-500 focus-visible:ring-2 focus-visible:ring-neutral-500/20"
|
|
10622
10650
|
/>
|
|
10623
10651
|
)}
|
|
10624
10652
|
</form.Field>
|
|
@@ -10633,7 +10661,7 @@ export function TodoList({
|
|
|
10633
10661
|
</form>
|
|
10634
10662
|
|
|
10635
10663
|
{isPending ? (
|
|
10636
|
-
<p className="text-sm text-
|
|
10664
|
+
<p className="text-sm text-muted-foreground">Loading\u2026</p>
|
|
10637
10665
|
) : (
|
|
10638
10666
|
<ul className="divide-y divide-neutral-700">
|
|
10639
10667
|
{todos.map((todo) => (
|
|
@@ -10644,7 +10672,7 @@ export function TodoList({
|
|
|
10644
10672
|
onChange={() => toggleMutation.mutate(todo.id)}
|
|
10645
10673
|
/>
|
|
10646
10674
|
<span
|
|
10647
|
-
className={\`flex-1 text-sm \${todo.done ? 'line-through text-
|
|
10675
|
+
className={\`flex-1 text-sm \${todo.done ? 'line-through text-muted-foreground' : ''}\`}
|
|
10648
10676
|
>
|
|
10649
10677
|
{todo.title}
|
|
10650
10678
|
</span>
|
|
@@ -10660,7 +10688,7 @@ export function TodoList({
|
|
|
10660
10688
|
)}
|
|
10661
10689
|
|
|
10662
10690
|
{!isPending && todos.length === 0 && (
|
|
10663
|
-
<p className="text-sm text-
|
|
10691
|
+
<p className="text-sm text-muted-foreground">No todos yet.</p>
|
|
10664
10692
|
)}
|
|
10665
10693
|
</>
|
|
10666
10694
|
);
|
|
@@ -10690,38 +10718,38 @@ export default function Home() {
|
|
|
10690
10718
|
return (
|
|
10691
10719
|
<main className="max-w-lg mx-auto min-h-full px-4 py-8 space-y-4">
|
|
10692
10720
|
<div className="pb-4 border-b">
|
|
10693
|
-
<p className="font-mono text-sm text-
|
|
10694
|
-
<p className="text-sm text-
|
|
10721
|
+
<p className="font-mono text-sm text-muted-foreground">apps/web/page.tsx</p>
|
|
10722
|
+
<p className="text-sm text-muted-foreground">Delete me to get started!</p>
|
|
10695
10723
|
</div>
|
|
10696
10724
|
|
|
10697
10725
|
<div className="flex items-center gap-3 py-2">
|
|
10698
10726
|
<Logo className="w-10 h-auto text-foreground" />
|
|
10699
10727
|
<div>
|
|
10700
10728
|
<h1 className="text-4xl font-black tracking-tight"><%= projectName %></h1>
|
|
10701
|
-
<p className="text-sm text-
|
|
10729
|
+
<p className="text-sm text-muted-foreground tracking-widest uppercase">
|
|
10702
10730
|
Next + Nest = Newt \u{1F49C}
|
|
10703
10731
|
</p>
|
|
10704
10732
|
</div>
|
|
10705
10733
|
</div>
|
|
10706
10734
|
|
|
10707
10735
|
<div className="rounded-xl border p-6 space-y-1">
|
|
10708
|
-
<p className="text-xs font-mono uppercase tracking-widest text-
|
|
10709
|
-
<p className="font-mono text-sm text-
|
|
10710
|
-
<p className="text-sm text-
|
|
10736
|
+
<p className="text-xs font-mono uppercase tracking-widest text-muted-foreground">next.js</p>
|
|
10737
|
+
<p className="font-mono text-sm text-muted-foreground">apps/web/layout.tsx</p>
|
|
10738
|
+
<p className="text-sm text-muted-foreground">Next.js rendering</p>
|
|
10711
10739
|
</div>
|
|
10712
10740
|
|
|
10713
10741
|
<div className="rounded-xl border p-6 space-y-1">
|
|
10714
|
-
<p className="text-xs font-mono uppercase tracking-widest text-
|
|
10715
|
-
<p className="font-mono text-sm text-
|
|
10716
|
-
<pre className="mt-2 border rounded-md p-3 text-sm bg-
|
|
10742
|
+
<p className="text-xs font-mono uppercase tracking-widest text-muted-foreground">nest.js</p>
|
|
10743
|
+
<p className="font-mono text-sm text-muted-foreground">GET /api/hello</p>
|
|
10744
|
+
<pre className="mt-2 border rounded-md p-3 text-sm bg-muted/50">
|
|
10717
10745
|
<code>{JSON.stringify(hello, null, 2)}</code>
|
|
10718
10746
|
</pre>
|
|
10719
10747
|
</div>
|
|
10720
10748
|
|
|
10721
10749
|
<div className="rounded-xl border p-6">
|
|
10722
|
-
<p className="text-xs font-mono uppercase tracking-widest text-
|
|
10750
|
+
<p className="text-xs font-mono uppercase tracking-widest text-muted-foreground mb-4">better-auth</p>
|
|
10723
10751
|
{isPending ? (
|
|
10724
|
-
<p className="text-sm text-
|
|
10752
|
+
<p className="text-sm text-muted-foreground">Loading\u2026</p>
|
|
10725
10753
|
) : session ? (
|
|
10726
10754
|
<TodoList session={session} />
|
|
10727
10755
|
) : (
|
|
@@ -10730,7 +10758,7 @@ export default function Home() {
|
|
|
10730
10758
|
</div>
|
|
10731
10759
|
|
|
10732
10760
|
<div className="px-2 py-4 text-sm">
|
|
10733
|
-
<p className="mb-2 text-
|
|
10761
|
+
<p className="mb-2 text-muted-foreground">Learn more</p>
|
|
10734
10762
|
<ul className="list-disc list-inside space-y-2 mt-2">
|
|
10735
10763
|
<li>
|
|
10736
10764
|
<Link href="https://github.com">GitHub</Link>
|