@tanstack/create 0.61.2 → 0.61.3
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/CHANGELOG.md +11 -0
- package/dist/frameworks/react/add-ons/ai/assets/src/components/demo-AIAssistant.tsx +2 -2
- package/dist/frameworks/react/add-ons/ai/assets/src/components/demo-GuitarRecommendation.tsx +1 -1
- package/dist/frameworks/react/add-ons/ai/assets/src/lib/demo-ai-hook.ts +1 -1
- package/dist/frameworks/react/add-ons/ai/assets/src/lib/demo-guitar-tools.ts +1 -1
- package/dist/frameworks/react/add-ons/ai/assets/src/routes/demo/ai-chat.tsx +5 -5
- package/dist/frameworks/react/add-ons/ai/assets/src/routes/demo/api.ai.chat.ts +1 -1
- package/dist/frameworks/react/add-ons/ai/assets/src/routes/demo/guitars/$guitarId.tsx +1 -1
- package/dist/frameworks/react/add-ons/ai/assets/src/routes/demo/guitars/index.tsx +1 -1
- package/dist/frameworks/react/add-ons/better-auth/assets/src/integrations/better-auth/header-user.tsx +1 -1
- package/dist/frameworks/react/add-ons/better-auth/assets/src/routes/api/auth/$.ts +1 -1
- package/dist/frameworks/react/add-ons/better-auth/assets/src/routes/demo/better-auth.tsx +1 -1
- package/dist/frameworks/react/add-ons/db/assets/src/components/demo.chat-area.tsx +1 -1
- package/dist/frameworks/react/add-ons/db/assets/src/components/demo.messages.tsx +1 -1
- package/dist/frameworks/react/add-ons/db/assets/src/hooks/demo.useChat.ts +1 -1
- package/dist/frameworks/react/add-ons/db/assets/src/routes/demo/db-chat.tsx +1 -1
- package/dist/frameworks/react/add-ons/drizzle/assets/src/routes/demo/drizzle.tsx.ejs +2 -2
- package/dist/frameworks/react/add-ons/form/assets/src/components/demo.FormComponents.tsx.ejs +15 -11
- package/dist/frameworks/react/add-ons/form/assets/src/routes/demo/form.address.tsx.ejs +1 -1
- package/dist/frameworks/react/add-ons/form/assets/src/routes/demo/form.simple.tsx.ejs +1 -1
- package/dist/frameworks/react/add-ons/mcp/assets/src/routes/demo/api.mcp-todos.ts +1 -1
- package/dist/frameworks/react/add-ons/mcp/assets/src/routes/mcp.ts +2 -2
- package/dist/frameworks/react/add-ons/neon/assets/src/routes/demo/neon.tsx +1 -1
- package/dist/frameworks/react/add-ons/oRPC/assets/src/orpc/client.ts +1 -1
- package/dist/frameworks/react/add-ons/oRPC/assets/src/routes/api.$.ts +3 -3
- package/dist/frameworks/react/add-ons/oRPC/assets/src/routes/api.rpc.$.ts +2 -2
- package/dist/frameworks/react/add-ons/oRPC/assets/src/routes/demo/orpc-todo.tsx +1 -1
- package/dist/frameworks/react/add-ons/paraglide/assets/src/components/LocaleSwitcher.tsx.ejs +2 -2
- package/dist/frameworks/react/add-ons/paraglide/assets/src/routes/demo.i18n.tsx.ejs +1 -1
- package/dist/frameworks/react/add-ons/prisma/assets/src/routes/demo/prisma.tsx.ejs +1 -1
- package/dist/frameworks/react/add-ons/shadcn/assets/components.json +5 -5
- package/dist/frameworks/react/add-ons/shadcn/assets/src/lib/utils.ts +2 -1
- package/dist/frameworks/react/add-ons/store/assets/src/routes/demo/store.tsx.ejs +1 -1
- package/dist/frameworks/react/add-ons/storybook/assets/src/routes/demo/storybook.tsx +5 -5
- package/dist/frameworks/react/add-ons/strapi/assets/src/routes/demo/strapi.tsx +1 -1
- package/dist/frameworks/react/add-ons/strapi/assets/src/routes/demo/strapi_.$articleId.tsx +1 -1
- package/dist/frameworks/react/add-ons/t3env/README.md +1 -1
- package/dist/frameworks/react/add-ons/tRPC/assets/src/integrations/trpc/react.ts +1 -1
- package/dist/frameworks/react/add-ons/tRPC/assets/src/routes/api.trpc.$.tsx +1 -1
- package/dist/frameworks/react/add-ons/tRPC/assets/src/routes/demo/trpc-todo.tsx +1 -1
- package/dist/frameworks/react/add-ons/table/assets/src/routes/demo/table.tsx.ejs +2 -2
- package/dist/frameworks/react/add-ons/tanstack-query/assets/src/integrations/tanstack-query/root-provider.tsx.ejs +2 -2
- package/dist/frameworks/react/examples/events/assets/src/components/RemyAssistant.tsx +2 -2
- package/dist/frameworks/react/examples/events/assets/src/components/SpeakerCard.tsx +1 -1
- package/dist/frameworks/react/examples/events/assets/src/components/TalkCard.tsx +1 -1
- package/dist/frameworks/react/examples/events/assets/src/components/ui/card.tsx +1 -1
- package/dist/frameworks/react/examples/events/assets/src/routes/api.remy-chat.ts +1 -1
- package/dist/frameworks/react/examples/events/assets/src/routes/index.tsx +4 -4
- package/dist/frameworks/react/examples/events/assets/src/routes/schedule.index.tsx +1 -1
- package/dist/frameworks/react/examples/events/assets/src/routes/speakers.$slug.tsx +2 -2
- package/dist/frameworks/react/examples/events/assets/src/routes/speakers.index.tsx +2 -2
- package/dist/frameworks/react/examples/events/assets/src/routes/talks.$slug.tsx +1 -1
- package/dist/frameworks/react/examples/events/assets/src/routes/talks.index.tsx +2 -2
- package/dist/frameworks/react/examples/resume/assets/src/components/ResumeAssistant.tsx +2 -2
- package/dist/frameworks/react/examples/resume/assets/src/components/ui/badge.tsx +1 -1
- package/dist/frameworks/react/examples/resume/assets/src/components/ui/card.tsx +1 -1
- package/dist/frameworks/react/examples/resume/assets/src/components/ui/checkbox.tsx +1 -1
- package/dist/frameworks/react/examples/resume/assets/src/components/ui/hover-card.tsx +1 -1
- package/dist/frameworks/react/examples/resume/assets/src/components/ui/separator.tsx +1 -1
- package/dist/frameworks/react/examples/resume/assets/src/routes/api.resume-chat.ts +1 -1
- package/dist/frameworks/react/examples/resume/assets/src/routes/index.tsx +6 -6
- package/dist/frameworks/react/project/base/package.json +5 -2
- package/dist/frameworks/react/project/base/src/routes/__root.tsx.ejs +2 -2
- package/dist/frameworks/react/project/base/tsconfig.json.ejs +5 -5
- package/dist/frameworks/react/project/base/vite.config.ts.ejs +2 -11
- package/dist/frameworks/react/toolchains/eslint/assets/eslint.config.js +16 -1
- package/dist/frameworks/solid/toolchains/eslint/assets/eslint.config.js +16 -1
- package/package.json +1 -1
- package/src/frameworks/react/add-ons/ai/assets/src/components/demo-AIAssistant.tsx +2 -2
- package/src/frameworks/react/add-ons/ai/assets/src/components/demo-GuitarRecommendation.tsx +1 -1
- package/src/frameworks/react/add-ons/ai/assets/src/lib/demo-ai-hook.ts +1 -1
- package/src/frameworks/react/add-ons/ai/assets/src/lib/demo-guitar-tools.ts +1 -1
- package/src/frameworks/react/add-ons/ai/assets/src/routes/demo/ai-chat.tsx +5 -5
- package/src/frameworks/react/add-ons/ai/assets/src/routes/demo/api.ai.chat.ts +1 -1
- package/src/frameworks/react/add-ons/ai/assets/src/routes/demo/guitars/$guitarId.tsx +1 -1
- package/src/frameworks/react/add-ons/ai/assets/src/routes/demo/guitars/index.tsx +1 -1
- package/src/frameworks/react/add-ons/better-auth/assets/src/integrations/better-auth/header-user.tsx +1 -1
- package/src/frameworks/react/add-ons/better-auth/assets/src/routes/api/auth/$.ts +1 -1
- package/src/frameworks/react/add-ons/better-auth/assets/src/routes/demo/better-auth.tsx +1 -1
- package/src/frameworks/react/add-ons/db/assets/src/components/demo.chat-area.tsx +1 -1
- package/src/frameworks/react/add-ons/db/assets/src/components/demo.messages.tsx +1 -1
- package/src/frameworks/react/add-ons/db/assets/src/hooks/demo.useChat.ts +1 -1
- package/src/frameworks/react/add-ons/db/assets/src/routes/demo/db-chat.tsx +1 -1
- package/src/frameworks/react/add-ons/drizzle/assets/src/routes/demo/drizzle.tsx.ejs +2 -2
- package/src/frameworks/react/add-ons/form/assets/src/components/demo.FormComponents.tsx.ejs +15 -11
- package/src/frameworks/react/add-ons/form/assets/src/routes/demo/form.address.tsx.ejs +1 -1
- package/src/frameworks/react/add-ons/form/assets/src/routes/demo/form.simple.tsx.ejs +1 -1
- package/src/frameworks/react/add-ons/mcp/assets/src/routes/demo/api.mcp-todos.ts +1 -1
- package/src/frameworks/react/add-ons/mcp/assets/src/routes/mcp.ts +2 -2
- package/src/frameworks/react/add-ons/neon/assets/src/routes/demo/neon.tsx +1 -1
- package/src/frameworks/react/add-ons/oRPC/assets/src/orpc/client.ts +1 -1
- package/src/frameworks/react/add-ons/oRPC/assets/src/routes/api.$.ts +3 -3
- package/src/frameworks/react/add-ons/oRPC/assets/src/routes/api.rpc.$.ts +2 -2
- package/src/frameworks/react/add-ons/oRPC/assets/src/routes/demo/orpc-todo.tsx +1 -1
- package/src/frameworks/react/add-ons/paraglide/assets/src/components/LocaleSwitcher.tsx.ejs +2 -2
- package/src/frameworks/react/add-ons/paraglide/assets/src/routes/demo.i18n.tsx.ejs +1 -1
- package/src/frameworks/react/add-ons/prisma/assets/src/routes/demo/prisma.tsx.ejs +1 -1
- package/src/frameworks/react/add-ons/shadcn/assets/components.json +5 -5
- package/src/frameworks/react/add-ons/shadcn/assets/src/lib/utils.ts +2 -1
- package/src/frameworks/react/add-ons/store/assets/src/routes/demo/store.tsx.ejs +1 -1
- package/src/frameworks/react/add-ons/storybook/assets/src/routes/demo/storybook.tsx +5 -5
- package/src/frameworks/react/add-ons/strapi/assets/src/routes/demo/strapi.tsx +1 -1
- package/src/frameworks/react/add-ons/strapi/assets/src/routes/demo/strapi_.$articleId.tsx +1 -1
- package/src/frameworks/react/add-ons/t3env/README.md +1 -1
- package/src/frameworks/react/add-ons/tRPC/assets/src/integrations/trpc/react.ts +1 -1
- package/src/frameworks/react/add-ons/tRPC/assets/src/routes/api.trpc.$.tsx +1 -1
- package/src/frameworks/react/add-ons/tRPC/assets/src/routes/demo/trpc-todo.tsx +1 -1
- package/src/frameworks/react/add-ons/table/assets/src/routes/demo/table.tsx.ejs +2 -2
- package/src/frameworks/react/add-ons/tanstack-query/assets/src/integrations/tanstack-query/root-provider.tsx.ejs +2 -2
- package/src/frameworks/react/examples/events/assets/src/components/RemyAssistant.tsx +2 -2
- package/src/frameworks/react/examples/events/assets/src/components/SpeakerCard.tsx +1 -1
- package/src/frameworks/react/examples/events/assets/src/components/TalkCard.tsx +1 -1
- package/src/frameworks/react/examples/events/assets/src/components/ui/card.tsx +1 -1
- package/src/frameworks/react/examples/events/assets/src/routes/api.remy-chat.ts +1 -1
- package/src/frameworks/react/examples/events/assets/src/routes/index.tsx +4 -4
- package/src/frameworks/react/examples/events/assets/src/routes/schedule.index.tsx +1 -1
- package/src/frameworks/react/examples/events/assets/src/routes/speakers.$slug.tsx +2 -2
- package/src/frameworks/react/examples/events/assets/src/routes/speakers.index.tsx +2 -2
- package/src/frameworks/react/examples/events/assets/src/routes/talks.$slug.tsx +1 -1
- package/src/frameworks/react/examples/events/assets/src/routes/talks.index.tsx +2 -2
- package/src/frameworks/react/examples/resume/assets/src/components/ResumeAssistant.tsx +2 -2
- package/src/frameworks/react/examples/resume/assets/src/components/ui/badge.tsx +1 -1
- package/src/frameworks/react/examples/resume/assets/src/components/ui/card.tsx +1 -1
- package/src/frameworks/react/examples/resume/assets/src/components/ui/checkbox.tsx +1 -1
- package/src/frameworks/react/examples/resume/assets/src/components/ui/hover-card.tsx +1 -1
- package/src/frameworks/react/examples/resume/assets/src/components/ui/separator.tsx +1 -1
- package/src/frameworks/react/examples/resume/assets/src/routes/api.resume-chat.ts +1 -1
- package/src/frameworks/react/examples/resume/assets/src/routes/index.tsx +6 -6
- package/src/frameworks/react/project/base/package.json +5 -2
- package/src/frameworks/react/project/base/src/routes/__root.tsx.ejs +2 -2
- package/src/frameworks/react/project/base/tsconfig.json.ejs +5 -5
- package/src/frameworks/react/project/base/vite.config.ts.ejs +2 -11
- package/src/frameworks/react/toolchains/eslint/assets/eslint.config.js +16 -1
- package/src/frameworks/solid/toolchains/eslint/assets/eslint.config.js +16 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,16 @@
|
|
|
1
1
|
# @tanstack/create
|
|
2
2
|
|
|
3
|
+
## 0.61.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Improve generated React scaffold reliability and default lint ergonomics. ([`cc5857c`](https://github.com/TanStack/cli/commit/cc5857c5c212132852f37878e039071c5a9b1ac5))
|
|
8
|
+
|
|
9
|
+
- Migrate React template imports to package `imports` aliases (`#/*`) while preserving `@/*` compatibility during transition.
|
|
10
|
+
- Harden eslint toolchain templates for fresh apps by avoiding known parser/project and resolver issues.
|
|
11
|
+
- Fix generated shadcn utility import style for stricter eslint configs.
|
|
12
|
+
- Improve TanStack Form demo select contrast in dark mode.
|
|
13
|
+
|
|
3
14
|
## 0.61.2
|
|
4
15
|
|
|
5
16
|
### Patch Changes
|
|
@@ -5,8 +5,8 @@ import { Store } from '@tanstack/store'
|
|
|
5
5
|
import { Send, X, ChevronRight, BotIcon } from 'lucide-react'
|
|
6
6
|
import { Streamdown } from 'streamdown'
|
|
7
7
|
|
|
8
|
-
import { useGuitarRecommendationChat } from '
|
|
9
|
-
import type { ChatMessages } from '
|
|
8
|
+
import { useGuitarRecommendationChat } from '#/lib/demo-ai-hook'
|
|
9
|
+
import type { ChatMessages } from '#/lib/demo-ai-hook'
|
|
10
10
|
|
|
11
11
|
import GuitarRecommendation from './demo-GuitarRecommendation'
|
|
12
12
|
|
package/dist/frameworks/react/add-ons/ai/assets/src/components/demo-GuitarRecommendation.tsx
CHANGED
|
@@ -2,7 +2,7 @@ import { useNavigate } from '@tanstack/react-router'
|
|
|
2
2
|
|
|
3
3
|
import { showAIAssistant } from './demo-AIAssistant'
|
|
4
4
|
|
|
5
|
-
import guitars from '
|
|
5
|
+
import guitars from '#/data/demo-guitars'
|
|
6
6
|
|
|
7
7
|
export default function GuitarRecommendation({ id }: { id: string }) {
|
|
8
8
|
const navigate = useNavigate()
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
import type { InferChatMessages } from '@tanstack/ai-react'
|
|
7
7
|
import { clientTools } from '@tanstack/ai-client'
|
|
8
8
|
|
|
9
|
-
import { recommendGuitarToolDef } from '
|
|
9
|
+
import { recommendGuitarToolDef } from '#/lib/demo-guitar-tools'
|
|
10
10
|
|
|
11
11
|
const recommendGuitarToolClient = recommendGuitarToolDef.client(({ id }) => ({
|
|
12
12
|
id: +id,
|
|
@@ -11,12 +11,12 @@ import {
|
|
|
11
11
|
} from 'lucide-react'
|
|
12
12
|
import { Streamdown } from 'streamdown'
|
|
13
13
|
|
|
14
|
-
import { useGuitarRecommendationChat } from '
|
|
15
|
-
import type { ChatMessages } from '
|
|
16
|
-
import { useAudioRecorder } from '
|
|
17
|
-
import { useTTS } from '
|
|
14
|
+
import { useGuitarRecommendationChat } from '#/lib/demo-ai-hook'
|
|
15
|
+
import type { ChatMessages } from '#/lib/demo-ai-hook'
|
|
16
|
+
import { useAudioRecorder } from '#/hooks/demo-useAudioRecorder'
|
|
17
|
+
import { useTTS } from '#/hooks/demo-useTTS'
|
|
18
18
|
|
|
19
|
-
import GuitarRecommendation from '
|
|
19
|
+
import GuitarRecommendation from '#/components/demo-GuitarRecommendation'
|
|
20
20
|
|
|
21
21
|
import './ai-chat.css'
|
|
22
22
|
|
|
@@ -5,7 +5,7 @@ import { openaiText } from '@tanstack/ai-openai'
|
|
|
5
5
|
import { geminiText } from '@tanstack/ai-gemini'
|
|
6
6
|
import { ollamaText } from '@tanstack/ai-ollama'
|
|
7
7
|
|
|
8
|
-
import { getGuitars, recommendGuitarToolDef } from '
|
|
8
|
+
import { getGuitars, recommendGuitarToolDef } from '#/lib/demo-guitar-tools'
|
|
9
9
|
|
|
10
10
|
const SYSTEM_PROMPT = `You are a helpful assistant for a store that sells guitars.
|
|
11
11
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createFileRoute } from "@tanstack/react-router";
|
|
2
2
|
import { useState } from "react";
|
|
3
|
-
import { authClient } from "
|
|
3
|
+
import { authClient } from "#/lib/auth-client";
|
|
4
4
|
|
|
5
5
|
export const Route = createFileRoute("/demo/better-auth")({
|
|
6
6
|
component: BetterAuthDemo,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { useEffect, useRef } from 'react'
|
|
2
2
|
import { useLiveQuery } from '@tanstack/react-db'
|
|
3
3
|
|
|
4
|
-
import { messagesCollection, type Message } from '
|
|
4
|
+
import { messagesCollection, type Message } from '#/db-collections'
|
|
5
5
|
|
|
6
6
|
import type { Collection } from '@tanstack/react-db'
|
|
7
7
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { createFileRoute, useRouter } from '@tanstack/react-router'
|
|
2
2
|
import { createServerFn } from '@tanstack/react-start'
|
|
3
|
-
import { db } from '
|
|
3
|
+
import { db } from '#/db/index'
|
|
4
4
|
import { desc } from 'drizzle-orm'
|
|
5
|
-
import { todos } from '
|
|
5
|
+
import { todos } from '#/db/schema'
|
|
6
6
|
|
|
7
7
|
const getTodos = createServerFn({
|
|
8
8
|
method: 'GET',
|
package/dist/frameworks/react/add-ons/form/assets/src/components/demo.FormComponents.tsx.ejs
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { useStore } from '@tanstack/react-form'
|
|
2
2
|
|
|
3
|
-
import { useFieldContext, useFormContext } from '
|
|
3
|
+
import { useFieldContext, useFormContext } from '#/hooks/demo.form-context'
|
|
4
4
|
<% if (addOnEnabled.shadcn) { %>
|
|
5
|
-
import { Button } from '
|
|
6
|
-
import { Input } from '
|
|
7
|
-
import { Textarea as ShadcnTextarea } from '
|
|
8
|
-
import * as ShadcnSelect from '
|
|
9
|
-
import { Slider as ShadcnSlider } from '
|
|
10
|
-
import { Switch as ShadcnSwitch } from '
|
|
11
|
-
import { Label } from '
|
|
5
|
+
import { Button } from '#/components/ui/button'
|
|
6
|
+
import { Input } from '#/components/ui/input'
|
|
7
|
+
import { Textarea as ShadcnTextarea } from '#/components/ui/textarea'
|
|
8
|
+
import * as ShadcnSelect from '#/components/ui/select'
|
|
9
|
+
import { Slider as ShadcnSlider } from '#/components/ui/slider'
|
|
10
|
+
import { Switch as ShadcnSwitch } from '#/components/ui/switch'
|
|
11
|
+
import { Label } from '#/components/ui/label'
|
|
12
12
|
|
|
13
13
|
export function SubscribeButton({ label }: { label: string }) {
|
|
14
14
|
const form = useFormContext()
|
|
@@ -117,11 +117,15 @@ export function Select({
|
|
|
117
117
|
<ShadcnSelect.SelectTrigger className="w-full">
|
|
118
118
|
<ShadcnSelect.SelectValue placeholder={placeholder} />
|
|
119
119
|
</ShadcnSelect.SelectTrigger>
|
|
120
|
-
<ShadcnSelect.SelectContent>
|
|
120
|
+
<ShadcnSelect.SelectContent className="bg-background text-foreground">
|
|
121
121
|
<ShadcnSelect.SelectGroup>
|
|
122
122
|
<ShadcnSelect.SelectLabel>{label}</ShadcnSelect.SelectLabel>
|
|
123
123
|
{values.map((value) => (
|
|
124
|
-
<ShadcnSelect.SelectItem
|
|
124
|
+
<ShadcnSelect.SelectItem
|
|
125
|
+
key={value.value}
|
|
126
|
+
value={value.value}
|
|
127
|
+
className="text-foreground"
|
|
128
|
+
>
|
|
125
129
|
{value.label}
|
|
126
130
|
</ShadcnSelect.SelectItem>
|
|
127
131
|
))}
|
|
@@ -297,4 +301,4 @@ export function Select({
|
|
|
297
301
|
</div>
|
|
298
302
|
)
|
|
299
303
|
}
|
|
300
|
-
<% } %>
|
|
304
|
+
<% } %>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { <% if (fileRouter) { %>createFileRoute<% } else { %>createRoute<% } %> } from '@tanstack/react-router'
|
|
2
2
|
|
|
3
|
-
import { useAppForm } from '
|
|
3
|
+
import { useAppForm } from '#/hooks/demo.form'
|
|
4
4
|
|
|
5
5
|
<% if (codeRouter) { %>
|
|
6
6
|
import type { RootRoute } from '@tanstack/react-router'
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { <% if (fileRouter) { %>createFileRoute<% } else { %>createRoute<% } %> } from '@tanstack/react-router'
|
|
2
2
|
import { z } from 'zod'
|
|
3
3
|
|
|
4
|
-
import { useAppForm } from '
|
|
4
|
+
import { useAppForm } from '#/hooks/demo.form'
|
|
5
5
|
|
|
6
6
|
<% if (codeRouter) { %>
|
|
7
7
|
import type { RootRoute } from '@tanstack/react-router'
|
|
@@ -2,9 +2,9 @@ import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js'
|
|
|
2
2
|
import { createFileRoute } from '@tanstack/react-router'
|
|
3
3
|
import z from 'zod'
|
|
4
4
|
|
|
5
|
-
import { handleMcpRequest } from '
|
|
5
|
+
import { handleMcpRequest } from '#/utils/mcp-handler'
|
|
6
6
|
|
|
7
|
-
import { addTodo } from '
|
|
7
|
+
import { addTodo } from '#/mcp-todos'
|
|
8
8
|
|
|
9
9
|
const server = new McpServer({
|
|
10
10
|
name: 'start-server',
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import '
|
|
1
|
+
import '#/polyfill'
|
|
2
2
|
|
|
3
3
|
import { OpenAPIHandler } from '@orpc/openapi/fetch'
|
|
4
4
|
import { ZodToJsonSchemaConverter } from '@orpc/zod/zod4'
|
|
@@ -7,8 +7,8 @@ import { createFileRoute } from '@tanstack/react-router'
|
|
|
7
7
|
import { onError } from '@orpc/server'
|
|
8
8
|
import { OpenAPIReferencePlugin } from '@orpc/openapi/plugins'
|
|
9
9
|
|
|
10
|
-
import { TodoSchema } from '
|
|
11
|
-
import router from '
|
|
10
|
+
import { TodoSchema } from '#/orpc/schema'
|
|
11
|
+
import router from '#/orpc/router'
|
|
12
12
|
|
|
13
13
|
const handler = new OpenAPIHandler(router, {
|
|
14
14
|
interceptors: [
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import '
|
|
1
|
+
import '#/polyfill'
|
|
2
2
|
|
|
3
3
|
import { RPCHandler } from '@orpc/server/fetch'
|
|
4
4
|
import { createFileRoute } from '@tanstack/react-router'
|
|
5
|
-
import router from '
|
|
5
|
+
import router from '#/orpc/router'
|
|
6
6
|
|
|
7
7
|
const handler = new RPCHandler(router)
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@ import { useCallback, useState } from 'react'
|
|
|
2
2
|
import { createFileRoute } from '@tanstack/react-router'
|
|
3
3
|
import { useMutation, useQuery } from '@tanstack/react-query'
|
|
4
4
|
|
|
5
|
-
import { orpc } from '
|
|
5
|
+
import { orpc } from '#/orpc/client'
|
|
6
6
|
|
|
7
7
|
export const Route = createFileRoute('/demo/orpc-todo')({
|
|
8
8
|
component: ORPCTodos,
|
package/dist/frameworks/react/add-ons/paraglide/assets/src/components/LocaleSwitcher.tsx.ejs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
// Locale switcher refs:
|
|
2
2
|
// - Paraglide docs: https://inlang.com/m/gerre34r/library-inlang-paraglideJs
|
|
3
3
|
// - Router example: https://github.com/TanStack/router/tree/main/examples/react/i18n-paraglide#switching-locale
|
|
4
|
-
import { getLocale, locales, setLocale } from '
|
|
5
|
-
import { m } from '
|
|
4
|
+
import { getLocale, locales, setLocale } from '#/paraglide/runtime'
|
|
5
|
+
import { m } from '#/paraglide/messages'
|
|
6
6
|
|
|
7
7
|
export default function ParaglideLocaleSwitcher() {
|
|
8
8
|
const currentLocale = getLocale()
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createFileRoute } from "@tanstack/react-router";
|
|
2
2
|
import logo from "../logo.svg";
|
|
3
|
-
import { m } from "
|
|
3
|
+
import { m } from "#/paraglide/messages";
|
|
4
4
|
import LocaleSwitcher from "../components/LocaleSwitcher";
|
|
5
5
|
|
|
6
6
|
export const Route = createFileRoute("/demo/i18n")({
|
|
@@ -11,11 +11,11 @@
|
|
|
11
11
|
"prefix": ""
|
|
12
12
|
},
|
|
13
13
|
"aliases": {
|
|
14
|
-
"components": "
|
|
15
|
-
"utils": "
|
|
16
|
-
"ui": "
|
|
17
|
-
"lib": "
|
|
18
|
-
"hooks": "
|
|
14
|
+
"components": "#/components",
|
|
15
|
+
"utils": "#/lib/utils",
|
|
16
|
+
"ui": "#/components/ui",
|
|
17
|
+
"lib": "#/lib",
|
|
18
|
+
"hooks": "#/hooks"
|
|
19
19
|
},
|
|
20
20
|
"iconLibrary": "lucide"
|
|
21
21
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { <% if (fileRouter) { %>createFileRoute<% } else { %>createRoute<% } %> } from '@tanstack/react-router'
|
|
2
2
|
import { useStore } from '@tanstack/react-store'
|
|
3
3
|
|
|
4
|
-
import { fullName, store } from '
|
|
4
|
+
import { fullName, store } from '#/lib/demo-store'
|
|
5
5
|
<% if (codeRouter) { %>
|
|
6
6
|
import type { RootRoute } from '@tanstack/react-router'
|
|
7
7
|
<% } else { %>
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { createFileRoute } from "@tanstack/react-router";
|
|
2
2
|
import { useState } from "react";
|
|
3
3
|
|
|
4
|
-
import { Dialog } from "
|
|
5
|
-
import { Input } from "
|
|
6
|
-
import { RadioGroup } from "
|
|
7
|
-
import { Slider } from "
|
|
8
|
-
import { Button } from "
|
|
4
|
+
import { Dialog } from "#/components/storybook/dialog";
|
|
5
|
+
import { Input } from "#/components/storybook/input";
|
|
6
|
+
import { RadioGroup } from "#/components/storybook/radio-group";
|
|
7
|
+
import { Slider } from "#/components/storybook/slider";
|
|
8
|
+
import { Button } from "#/components/storybook/button";
|
|
9
9
|
|
|
10
10
|
export const Route = createFileRoute("/demo/storybook")({
|
|
11
11
|
component: StorybookDemo,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { createServerFileRoute } from '@tanstack/react-start/server'
|
|
2
2
|
import { fetchRequestHandler } from '@trpc/server/adapters/fetch'
|
|
3
|
-
import { trpcRouter } from '
|
|
3
|
+
import { trpcRouter } from '#/integrations/trpc/router'
|
|
4
4
|
import { createFileRoute } from '@tanstack/react-router'
|
|
5
5
|
|
|
6
6
|
function handler({ request }: { request: Request }) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { useCallback, useState } from 'react'
|
|
2
2
|
import { createFileRoute } from '@tanstack/react-router'
|
|
3
3
|
import { useMutation, useQuery } from '@tanstack/react-query'
|
|
4
|
-
import { useTRPC } from '
|
|
4
|
+
import { useTRPC } from '#/integrations/trpc/react'
|
|
5
5
|
|
|
6
6
|
export const Route = createFileRoute('/demo/trpc-todo')({
|
|
7
7
|
component: TRPCTodos,
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
} from '@tanstack/react-table'
|
|
12
12
|
import { compareItems, rankItem } from '@tanstack/match-sorter-utils'
|
|
13
13
|
|
|
14
|
-
import { makeData } from '
|
|
14
|
+
import { makeData } from '#/data/demo-table-data'
|
|
15
15
|
|
|
16
16
|
import type {
|
|
17
17
|
Column,
|
|
@@ -24,7 +24,7 @@ import type { RankingInfo } from '@tanstack/match-sorter-utils'
|
|
|
24
24
|
<% if (codeRouter) { %>
|
|
25
25
|
import type { RootRoute } from '@tanstack/react-router'
|
|
26
26
|
<% } %>
|
|
27
|
-
import type { Person } from '
|
|
27
|
+
import type { Person } from '#/data/demo-table-data'
|
|
28
28
|
<% if (fileRouter) { %>
|
|
29
29
|
export const Route = createFileRoute('/demo/table')({
|
|
30
30
|
component: TableDemo,
|
|
@@ -5,8 +5,8 @@ import superjson from "superjson";
|
|
|
5
5
|
import { createTRPCClient, httpBatchStreamLink } from "@trpc/client";
|
|
6
6
|
import { createTRPCOptionsProxy } from "@trpc/tanstack-react-query";
|
|
7
7
|
|
|
8
|
-
import type { TRPCRouter } from "
|
|
9
|
-
import { TRPCProvider } from '
|
|
8
|
+
import type { TRPCRouter } from "#/integrations/trpc/router";
|
|
9
|
+
import { TRPCProvider } from '#/integrations/trpc/react'
|
|
10
10
|
|
|
11
11
|
function getUrl() {
|
|
12
12
|
const base = (() => {
|
|
@@ -3,8 +3,8 @@ import { Send, X, ChefHat, Croissant } from 'lucide-react'
|
|
|
3
3
|
import { Streamdown } from 'streamdown'
|
|
4
4
|
import { Store } from '@tanstack/store'
|
|
5
5
|
|
|
6
|
-
import { useConferenceChat } from '
|
|
7
|
-
import type { ConferenceChatMessages } from '
|
|
6
|
+
import { useConferenceChat } from '#/lib/conference-ai-hook'
|
|
7
|
+
import type { ConferenceChatMessages } from '#/lib/conference-ai-hook'
|
|
8
8
|
|
|
9
9
|
function Messages({ messages }: { messages: ConferenceChatMessages }) {
|
|
10
10
|
const messagesContainerRef = useRef<HTMLDivElement>(null)
|
|
@@ -3,10 +3,10 @@ import { ArrowRight, Calendar, MapPin, Users } from 'lucide-react'
|
|
|
3
3
|
|
|
4
4
|
import { allSpeakers, allTalks } from 'content-collections'
|
|
5
5
|
|
|
6
|
-
import SpeakerCard from '
|
|
7
|
-
import TalkCard from '
|
|
8
|
-
import RemyAssistant from '
|
|
9
|
-
import HeroCarousel from '
|
|
6
|
+
import SpeakerCard from '#/components/SpeakerCard'
|
|
7
|
+
import TalkCard from '#/components/TalkCard'
|
|
8
|
+
import RemyAssistant from '#/components/RemyAssistant'
|
|
9
|
+
import HeroCarousel from '#/components/HeroCarousel'
|
|
10
10
|
|
|
11
11
|
export const Route = createFileRoute('/')({
|
|
12
12
|
component: HomePage,
|
|
@@ -4,7 +4,7 @@ import { useState } from 'react'
|
|
|
4
4
|
|
|
5
5
|
import { allTalks, allSpeakers } from 'content-collections'
|
|
6
6
|
|
|
7
|
-
import RemyAssistant from '
|
|
7
|
+
import RemyAssistant from '#/components/RemyAssistant'
|
|
8
8
|
|
|
9
9
|
export const Route = createFileRoute('/schedule/')({
|
|
10
10
|
component: SchedulePage,
|
|
@@ -5,8 +5,8 @@ import { Link } from '@tanstack/react-router'
|
|
|
5
5
|
|
|
6
6
|
import { allSpeakers, allTalks } from 'content-collections'
|
|
7
7
|
|
|
8
|
-
import RemyAssistant from '
|
|
9
|
-
import TalkCard from '
|
|
8
|
+
import RemyAssistant from '#/components/RemyAssistant'
|
|
9
|
+
import TalkCard from '#/components/TalkCard'
|
|
10
10
|
|
|
11
11
|
export const Route = createFileRoute('/speakers/$slug')({
|
|
12
12
|
loader: async ({ params }) => {
|
|
@@ -2,8 +2,8 @@ import { createFileRoute } from '@tanstack/react-router'
|
|
|
2
2
|
|
|
3
3
|
import { allSpeakers } from 'content-collections'
|
|
4
4
|
|
|
5
|
-
import SpeakerCard from '
|
|
6
|
-
import RemyAssistant from '
|
|
5
|
+
import SpeakerCard from '#/components/SpeakerCard'
|
|
6
|
+
import RemyAssistant from '#/components/RemyAssistant'
|
|
7
7
|
|
|
8
8
|
export const Route = createFileRoute('/speakers/')({
|
|
9
9
|
component: SpeakersPage,
|
|
@@ -4,7 +4,7 @@ import { Clock, User, ArrowLeft, Tag } from 'lucide-react'
|
|
|
4
4
|
|
|
5
5
|
import { allTalks, allSpeakers } from 'content-collections'
|
|
6
6
|
|
|
7
|
-
import RemyAssistant from '
|
|
7
|
+
import RemyAssistant from '#/components/RemyAssistant'
|
|
8
8
|
|
|
9
9
|
export const Route = createFileRoute('/talks/$slug')({
|
|
10
10
|
loader: async ({ params }) => {
|