@better-t-stack/template-generator 3.13.2-dev.6c6cffb
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/fs-writer.d.mts +8 -0
- package/dist/fs-writer.d.mts.map +1 -0
- package/dist/fs-writer.mjs +50 -0
- package/dist/fs-writer.mjs.map +1 -0
- package/dist/index.d.mts +182 -0
- package/dist/index.d.mts.map +1 -0
- package/dist/index.mjs +26727 -0
- package/dist/index.mjs.map +1 -0
- package/dist/template-reader.d.mts +30 -0
- package/dist/template-reader.d.mts.map +1 -0
- package/dist/template-reader.mjs +2860 -0
- package/dist/template-reader.mjs.map +1 -0
- package/dist/types-BubFnV2d.d.mts +36 -0
- package/dist/types-BubFnV2d.d.mts.map +1 -0
- package/package.json +66 -0
- package/scripts/generate-templates.ts +97 -0
- package/templates/addons/biome/biome.json.hbs +96 -0
- package/templates/addons/husky/.husky/pre-commit +1 -0
- package/templates/addons/pwa/apps/web/next/public/favicon/apple-touch-icon.png +0 -0
- package/templates/addons/pwa/apps/web/next/public/favicon/favicon-96x96.png +0 -0
- package/templates/addons/pwa/apps/web/next/public/favicon/favicon.svg +6 -0
- package/templates/addons/pwa/apps/web/next/public/favicon/site.webmanifest.hbs +21 -0
- package/templates/addons/pwa/apps/web/next/public/favicon/web-app-manifest-192x192.png +0 -0
- package/templates/addons/pwa/apps/web/next/public/favicon/web-app-manifest-512x512.png +0 -0
- package/templates/addons/pwa/apps/web/next/src/app/manifest.ts.hbs +26 -0
- package/templates/addons/pwa/apps/web/vite/public/logo.png +0 -0
- package/templates/addons/pwa/apps/web/vite/pwa-assets.config.ts.hbs +12 -0
- package/templates/addons/ruler/.ruler/bts.md.hbs +142 -0
- package/templates/addons/ruler/.ruler/ruler.toml.hbs +80 -0
- package/templates/addons/turborepo/turbo.json.hbs +74 -0
- package/templates/addons/ultracite/biome.json.hbs +26 -0
- package/templates/api/orpc/fullstack/next/src/app/api/rpc/[[...rest]]/route.ts.hbs +50 -0
- package/templates/api/orpc/fullstack/tanstack-start/src/routes/api/rpc/$.ts.hbs +58 -0
- package/templates/api/orpc/native/utils/orpc.ts.hbs +39 -0
- package/templates/api/orpc/server/_gitignore +34 -0
- package/templates/api/orpc/server/package.json.hbs +15 -0
- package/templates/api/orpc/server/src/context.ts.hbs +148 -0
- package/templates/api/orpc/server/src/index.ts.hbs +21 -0
- package/templates/api/orpc/server/src/routers/index.ts.hbs +55 -0
- package/templates/api/orpc/server/tsconfig.json.hbs +10 -0
- package/templates/api/orpc/web/nuxt/app/plugins/orpc.ts.hbs +32 -0
- package/templates/api/orpc/web/nuxt/app/plugins/vue-query.ts.hbs +44 -0
- package/templates/api/orpc/web/react/base/src/utils/orpc.ts.hbs +113 -0
- package/templates/api/orpc/web/solid/src/utils/orpc.ts.hbs +30 -0
- package/templates/api/orpc/web/svelte/src/lib/orpc.ts.hbs +30 -0
- package/templates/api/trpc/fullstack/next/src/app/api/trpc/[trpc]/route.ts.hbs +14 -0
- package/templates/api/trpc/fullstack/tanstack-start/src/routes/api/trpc/$.ts.hbs +22 -0
- package/templates/api/trpc/native/utils/trpc.ts.hbs +37 -0
- package/templates/api/trpc/server/_gitignore +34 -0
- package/templates/api/trpc/server/package.json.hbs +14 -0
- package/templates/api/trpc/server/src/context.ts.hbs +148 -0
- package/templates/api/trpc/server/src/index.ts.hbs +26 -0
- package/templates/api/trpc/server/src/routers/index.ts.hbs +55 -0
- package/templates/api/trpc/server/tsconfig.json.hbs +10 -0
- package/templates/api/trpc/web/react/base/src/utils/trpc.ts.hbs +97 -0
- package/templates/auth/better-auth/convex/backend/convex/auth.config.ts.hbs +6 -0
- package/templates/auth/better-auth/convex/backend/convex/auth.ts.hbs +68 -0
- package/templates/auth/better-auth/convex/backend/convex/http.ts.hbs +12 -0
- package/templates/auth/better-auth/convex/backend/convex/privateData.ts.hbs +17 -0
- package/templates/auth/better-auth/convex/native/bare/components/sign-in.tsx.hbs +127 -0
- package/templates/auth/better-auth/convex/native/bare/components/sign-up.tsx.hbs +138 -0
- package/templates/auth/better-auth/convex/native/base/lib/auth-client.ts.hbs +18 -0
- package/templates/auth/better-auth/convex/native/unistyles/components/sign-in.tsx.hbs +127 -0
- package/templates/auth/better-auth/convex/native/unistyles/components/sign-up.tsx.hbs +145 -0
- package/templates/auth/better-auth/convex/native/uniwind/components/sign-in.tsx.hbs +73 -0
- package/templates/auth/better-auth/convex/native/uniwind/components/sign-up.tsx.hbs +85 -0
- package/templates/auth/better-auth/convex/web/react/next/src/app/api/auth/[...all]/route.ts.hbs +3 -0
- package/templates/auth/better-auth/convex/web/react/next/src/app/dashboard/page.tsx.hbs +40 -0
- package/templates/auth/better-auth/convex/web/react/next/src/components/sign-in-form.tsx.hbs +129 -0
- package/templates/auth/better-auth/convex/web/react/next/src/components/sign-up-form.tsx.hbs +154 -0
- package/templates/auth/better-auth/convex/web/react/next/src/components/user-menu.tsx.hbs +48 -0
- package/templates/auth/better-auth/convex/web/react/next/src/lib/auth-client.ts.hbs +6 -0
- package/templates/auth/better-auth/convex/web/react/next/src/lib/auth-server.ts.hbs +16 -0
- package/templates/auth/better-auth/convex/web/react/tanstack-router/src/components/sign-in-form.tsx.hbs +133 -0
- package/templates/auth/better-auth/convex/web/react/tanstack-router/src/components/sign-up-form.tsx.hbs +158 -0
- package/templates/auth/better-auth/convex/web/react/tanstack-router/src/components/user-menu.tsx.hbs +52 -0
- package/templates/auth/better-auth/convex/web/react/tanstack-router/src/lib/auth-client.ts.hbs +11 -0
- package/templates/auth/better-auth/convex/web/react/tanstack-router/src/routes/dashboard.tsx.hbs +43 -0
- package/templates/auth/better-auth/convex/web/react/tanstack-start/src/components/sign-in-form.tsx.hbs +133 -0
- package/templates/auth/better-auth/convex/web/react/tanstack-start/src/components/sign-up-form.tsx.hbs +158 -0
- package/templates/auth/better-auth/convex/web/react/tanstack-start/src/components/user-menu.tsx.hbs +47 -0
- package/templates/auth/better-auth/convex/web/react/tanstack-start/src/lib/auth-client.ts.hbs +6 -0
- package/templates/auth/better-auth/convex/web/react/tanstack-start/src/lib/auth-server.ts.hbs +13 -0
- package/templates/auth/better-auth/convex/web/react/tanstack-start/src/routes/api/auth/$.ts.hbs +11 -0
- package/templates/auth/better-auth/convex/web/react/tanstack-start/src/routes/dashboard.tsx.hbs +43 -0
- package/templates/auth/better-auth/fullstack/next/src/app/api/auth/[...all]/route.ts.hbs +4 -0
- package/templates/auth/better-auth/fullstack/tanstack-start/src/routes/api/auth/$.ts.hbs +15 -0
- package/templates/auth/better-auth/native/bare/app/(drawer)/index.tsx.hbs +186 -0
- package/templates/auth/better-auth/native/bare/components/sign-in.tsx.hbs +131 -0
- package/templates/auth/better-auth/native/bare/components/sign-up.tsx.hbs +150 -0
- package/templates/auth/better-auth/native/base/lib/auth-client.ts.hbs +16 -0
- package/templates/auth/better-auth/native/unistyles/app/(drawer)/index.tsx.hbs +187 -0
- package/templates/auth/better-auth/native/unistyles/components/sign-in.tsx.hbs +139 -0
- package/templates/auth/better-auth/native/unistyles/components/sign-up.tsx.hbs +157 -0
- package/templates/auth/better-auth/native/uniwind/app/(drawer)/index.tsx.hbs +123 -0
- package/templates/auth/better-auth/native/uniwind/components/sign-in.tsx.hbs +87 -0
- package/templates/auth/better-auth/native/uniwind/components/sign-up.tsx.hbs +128 -0
- package/templates/auth/better-auth/server/base/_gitignore +34 -0
- package/templates/auth/better-auth/server/base/package.json.hbs +14 -0
- package/templates/auth/better-auth/server/base/src/index.ts.hbs +304 -0
- package/templates/auth/better-auth/server/base/tsconfig.json.hbs +10 -0
- package/templates/auth/better-auth/server/db/drizzle/mysql/src/schema/auth.ts.hbs +100 -0
- package/templates/auth/better-auth/server/db/drizzle/postgres/src/schema/auth.ts.hbs +93 -0
- package/templates/auth/better-auth/server/db/drizzle/sqlite/src/schema/auth.ts.hbs +107 -0
- package/templates/auth/better-auth/server/db/mongoose/mongodb/src/models/auth.model.ts.hbs +68 -0
- package/templates/auth/better-auth/server/db/prisma/mongodb/prisma/schema/auth.prisma.hbs +62 -0
- package/templates/auth/better-auth/server/db/prisma/mysql/prisma/schema/auth.prisma.hbs +62 -0
- package/templates/auth/better-auth/server/db/prisma/postgres/prisma/schema/auth.prisma.hbs +62 -0
- package/templates/auth/better-auth/server/db/prisma/sqlite/prisma/schema/auth.prisma.hbs +62 -0
- package/templates/auth/better-auth/web/nuxt/app/components/SignInForm.vue.hbs +82 -0
- package/templates/auth/better-auth/web/nuxt/app/components/SignUpForm.vue.hbs +91 -0
- package/templates/auth/better-auth/web/nuxt/app/components/UserMenu.vue.hbs +42 -0
- package/templates/auth/better-auth/web/nuxt/app/middleware/auth.ts.hbs +14 -0
- package/templates/auth/better-auth/web/nuxt/app/pages/dashboard.vue.hbs +99 -0
- package/templates/auth/better-auth/web/nuxt/app/pages/login.vue.hbs +27 -0
- package/templates/auth/better-auth/web/nuxt/app/plugins/auth-client.ts.hbs +21 -0
- package/templates/auth/better-auth/web/react/base/src/lib/auth-client.ts.hbs +16 -0
- package/templates/auth/better-auth/web/react/next/src/app/dashboard/dashboard.tsx.hbs +60 -0
- package/templates/auth/better-auth/web/react/next/src/app/dashboard/page.tsx.hbs +42 -0
- package/templates/auth/better-auth/web/react/next/src/app/login/page.tsx.hbs +16 -0
- package/templates/auth/better-auth/web/react/next/src/components/sign-in-form.tsx.hbs +135 -0
- package/templates/auth/better-auth/web/react/next/src/components/sign-up-form.tsx.hbs +160 -0
- package/templates/auth/better-auth/web/react/next/src/components/user-menu.tsx.hbs +62 -0
- package/templates/auth/better-auth/web/react/react-router/src/components/sign-in-form.tsx.hbs +135 -0
- package/templates/auth/better-auth/web/react/react-router/src/components/sign-up-form.tsx.hbs +160 -0
- package/templates/auth/better-auth/web/react/react-router/src/components/user-menu.tsx.hbs +61 -0
- package/templates/auth/better-auth/web/react/react-router/src/routes/dashboard.tsx.hbs +80 -0
- package/templates/auth/better-auth/web/react/react-router/src/routes/login.tsx.hbs +13 -0
- package/templates/auth/better-auth/web/react/tanstack-router/src/components/sign-in-form.tsx.hbs +135 -0
- package/templates/auth/better-auth/web/react/tanstack-router/src/components/sign-up-form.tsx.hbs +160 -0
- package/templates/auth/better-auth/web/react/tanstack-router/src/components/user-menu.tsx.hbs +63 -0
- package/templates/auth/better-auth/web/react/tanstack-router/src/routes/dashboard.tsx.hbs +71 -0
- package/templates/auth/better-auth/web/react/tanstack-router/src/routes/login.tsx.hbs +18 -0
- package/templates/auth/better-auth/web/react/tanstack-start/src/components/sign-in-form.tsx.hbs +135 -0
- package/templates/auth/better-auth/web/react/tanstack-start/src/components/sign-up-form.tsx.hbs +160 -0
- package/templates/auth/better-auth/web/react/tanstack-start/src/components/user-menu.tsx.hbs +63 -0
- package/templates/auth/better-auth/web/react/tanstack-start/src/functions/get-user.ts.hbs +6 -0
- package/templates/auth/better-auth/web/react/tanstack-start/src/middleware/auth.ts.hbs +31 -0
- package/templates/auth/better-auth/web/react/tanstack-start/src/routes/dashboard.tsx.hbs +84 -0
- package/templates/auth/better-auth/web/react/tanstack-start/src/routes/login.tsx.hbs +18 -0
- package/templates/auth/better-auth/web/solid/src/components/sign-in-form.tsx.hbs +124 -0
- package/templates/auth/better-auth/web/solid/src/components/sign-up-form.tsx.hbs +148 -0
- package/templates/auth/better-auth/web/solid/src/components/user-menu.tsx.hbs +55 -0
- package/templates/auth/better-auth/web/solid/src/lib/auth-client.ts.hbs +12 -0
- package/templates/auth/better-auth/web/solid/src/routes/dashboard.tsx.hbs +67 -0
- package/templates/auth/better-auth/web/solid/src/routes/login.tsx.hbs +23 -0
- package/templates/auth/better-auth/web/svelte/src/components/SignInForm.svelte.hbs +109 -0
- package/templates/auth/better-auth/web/svelte/src/components/SignUpForm.svelte.hbs +142 -0
- package/templates/auth/better-auth/web/svelte/src/components/UserMenu.svelte.hbs +52 -0
- package/templates/auth/better-auth/web/svelte/src/lib/auth-client.ts.hbs +12 -0
- package/templates/auth/better-auth/web/svelte/src/routes/dashboard/+page.svelte.hbs +59 -0
- package/templates/auth/better-auth/web/svelte/src/routes/login/+page.svelte.hbs +12 -0
- package/templates/auth/clerk/convex/backend/convex/auth.config.ts.hbs +12 -0
- package/templates/auth/clerk/convex/backend/convex/privateData.ts.hbs +16 -0
- package/templates/auth/clerk/convex/native/base/app/(auth)/_layout.tsx.hbs +12 -0
- package/templates/auth/clerk/convex/native/base/app/(auth)/sign-in.tsx.hbs +67 -0
- package/templates/auth/clerk/convex/native/base/app/(auth)/sign-up.tsx.hbs +110 -0
- package/templates/auth/clerk/convex/native/base/components/sign-out-button.tsx.hbs +27 -0
- package/templates/auth/clerk/convex/web/react/next/src/app/dashboard/page.tsx.hbs +29 -0
- package/templates/auth/clerk/convex/web/react/next/src/middleware.ts.hbs +12 -0
- package/templates/auth/clerk/convex/web/react/react-router/src/routes/dashboard.tsx.hbs +32 -0
- package/templates/auth/clerk/convex/web/react/tanstack-router/src/routes/dashboard.tsx.hbs +37 -0
- package/templates/auth/clerk/convex/web/react/tanstack-start/src/routes/dashboard.tsx.hbs +37 -0
- package/templates/auth/clerk/convex/web/react/tanstack-start/src/start.ts.hbs +8 -0
- package/templates/backend/convex/packages/backend/_gitignore +2 -0
- package/templates/backend/convex/packages/backend/convex/README.md +90 -0
- package/templates/backend/convex/packages/backend/convex/convex.config.ts.hbs +17 -0
- package/templates/backend/convex/packages/backend/convex/healthCheck.ts.hbs +7 -0
- package/templates/backend/convex/packages/backend/convex/schema.ts.hbs +11 -0
- package/templates/backend/convex/packages/backend/convex/tsconfig.json.hbs +25 -0
- package/templates/backend/convex/packages/backend/package.json.hbs +15 -0
- package/templates/backend/server/base/_gitignore +55 -0
- package/templates/backend/server/base/package.json.hbs +17 -0
- package/templates/backend/server/base/tsconfig.json.hbs +13 -0
- package/templates/backend/server/base/tsdown.config.ts.hbs +9 -0
- package/templates/backend/server/elysia/src/index.ts.hbs +122 -0
- package/templates/backend/server/express/src/index.ts.hbs +126 -0
- package/templates/backend/server/fastify/src/index.ts.hbs +187 -0
- package/templates/backend/server/hono/src/index.ts.hbs +171 -0
- package/templates/base/_gitignore +50 -0
- package/templates/base/package.json.hbs +10 -0
- package/templates/base/tsconfig.json.hbs +3 -0
- package/templates/db/base/_gitignore +35 -0
- package/templates/db/base/package.json.hbs +14 -0
- package/templates/db/base/tsconfig.json.hbs +10 -0
- package/templates/db/drizzle/base/src/schema/index.ts.hbs +7 -0
- package/templates/db/drizzle/mysql/drizzle.config.ts.hbs +19 -0
- package/templates/db/drizzle/mysql/src/index.ts.hbs +54 -0
- package/templates/db/drizzle/postgres/drizzle.config.ts.hbs +19 -0
- package/templates/db/drizzle/postgres/src/index.ts.hbs +44 -0
- package/templates/db/drizzle/sqlite/drizzle.config.ts.hbs +28 -0
- package/templates/db/drizzle/sqlite/src/index.ts.hbs +39 -0
- package/templates/db/mongoose/mongodb/src/index.ts.hbs +10 -0
- package/templates/db/prisma/mongodb/prisma/schema/schema.prisma.hbs +19 -0
- package/templates/db/prisma/mongodb/prisma.config.ts.hbs +18 -0
- package/templates/db/prisma/mongodb/src/index.ts.hbs +5 -0
- package/templates/db/prisma/mysql/prisma/schema/schema.prisma.hbs +21 -0
- package/templates/db/prisma/mysql/prisma.config.ts.hbs +21 -0
- package/templates/db/prisma/mysql/src/index.ts.hbs +55 -0
- package/templates/db/prisma/postgres/prisma/schema/schema.prisma.hbs +21 -0
- package/templates/db/prisma/postgres/prisma.config.ts.hbs +21 -0
- package/templates/db/prisma/postgres/src/index.ts.hbs +69 -0
- package/templates/db/prisma/sqlite/prisma/schema/schema.prisma.hbs +18 -0
- package/templates/db/prisma/sqlite/prisma.config.ts.hbs +25 -0
- package/templates/db/prisma/sqlite/src/index.ts.hbs +25 -0
- package/templates/db-setup/docker-compose/mongodb/docker-compose.yml.hbs +23 -0
- package/templates/db-setup/docker-compose/mysql/docker-compose.yml.hbs +24 -0
- package/templates/db-setup/docker-compose/postgres/docker-compose.yml.hbs +23 -0
- package/templates/examples/ai/convex/packages/backend/convex/agent.ts.hbs +9 -0
- package/templates/examples/ai/convex/packages/backend/convex/chat.ts.hbs +67 -0
- package/templates/examples/ai/fullstack/next/src/app/api/ai/route.ts.hbs +20 -0
- package/templates/examples/ai/fullstack/tanstack-start/src/routes/api/ai/$.ts.hbs +36 -0
- package/templates/examples/ai/native/bare/app/(drawer)/ai.tsx.hbs +586 -0
- package/templates/examples/ai/native/bare/polyfills.js +22 -0
- package/templates/examples/ai/native/unistyles/app/(drawer)/ai.tsx.hbs +588 -0
- package/templates/examples/ai/native/unistyles/polyfills.js +22 -0
- package/templates/examples/ai/native/uniwind/app/(drawer)/ai.tsx.hbs +331 -0
- package/templates/examples/ai/native/uniwind/polyfills.js +22 -0
- package/templates/examples/ai/web/nuxt/app/pages/ai.vue.hbs +54 -0
- package/templates/examples/ai/web/react/next/src/app/ai/page.tsx.hbs +267 -0
- package/templates/examples/ai/web/react/react-router/src/routes/ai.tsx.hbs +235 -0
- package/templates/examples/ai/web/react/tanstack-router/src/routes/ai.tsx.hbs +242 -0
- package/templates/examples/ai/web/react/tanstack-start/src/routes/ai.tsx.hbs +243 -0
- package/templates/examples/ai/web/svelte/src/routes/ai/+page.svelte.hbs +107 -0
- package/templates/examples/todo/convex/packages/backend/convex/todos.ts.hbs +42 -0
- package/templates/examples/todo/native/bare/app/(drawer)/todos.tsx.hbs +521 -0
- package/templates/examples/todo/native/unistyles/app/(drawer)/todos.tsx.hbs +340 -0
- package/templates/examples/todo/native/uniwind/app/(drawer)/todos.tsx.hbs +282 -0
- package/templates/examples/todo/server/drizzle/base/src/routers/todo.ts.hbs +75 -0
- package/templates/examples/todo/server/drizzle/mysql/src/schema/todo.ts +7 -0
- package/templates/examples/todo/server/drizzle/postgres/src/schema/todo.ts +7 -0
- package/templates/examples/todo/server/drizzle/sqlite/src/schema/todo.ts +7 -0
- package/templates/examples/todo/server/mongoose/base/src/routers/todo.ts.hbs +66 -0
- package/templates/examples/todo/server/mongoose/mongodb/src/models/todo.model.ts.hbs +24 -0
- package/templates/examples/todo/server/prisma/base/src/routers/todo.ts.hbs +116 -0
- package/templates/examples/todo/server/prisma/mongodb/prisma/schema/todo.prisma.hbs +7 -0
- package/templates/examples/todo/server/prisma/mysql/prisma/schema/todo.prisma.hbs +7 -0
- package/templates/examples/todo/server/prisma/postgres/prisma/schema/todo.prisma.hbs +7 -0
- package/templates/examples/todo/server/prisma/sqlite/prisma/schema/todo.prisma.hbs +7 -0
- package/templates/examples/todo/web/nuxt/app/pages/todos.vue.hbs +220 -0
- package/templates/examples/todo/web/react/next/src/app/todos/page.tsx.hbs +245 -0
- package/templates/examples/todo/web/react/react-router/src/routes/todos.tsx.hbs +242 -0
- package/templates/examples/todo/web/react/tanstack-router/src/routes/todos.tsx.hbs +247 -0
- package/templates/examples/todo/web/react/tanstack-start/src/routes/todos.tsx.hbs +272 -0
- package/templates/examples/todo/web/solid/src/routes/todos.tsx.hbs +132 -0
- package/templates/examples/todo/web/svelte/src/routes/todos/+page.svelte.hbs +317 -0
- package/templates/extras/_npmrc.hbs +5 -0
- package/templates/extras/bunfig.toml.hbs +6 -0
- package/templates/extras/pnpm-workspace.yaml +3 -0
- package/templates/frontend/native/bare/_gitignore +18 -0
- package/templates/frontend/native/bare/app/(drawer)/(tabs)/_layout.tsx.hbs +41 -0
- package/templates/frontend/native/bare/app/(drawer)/(tabs)/index.tsx.hbs +43 -0
- package/templates/frontend/native/bare/app/(drawer)/(tabs)/two.tsx.hbs +43 -0
- package/templates/frontend/native/bare/app/(drawer)/_layout.tsx.hbs +90 -0
- package/templates/frontend/native/bare/app/(drawer)/index.tsx.hbs +234 -0
- package/templates/frontend/native/bare/app/+not-found.tsx.hbs +65 -0
- package/templates/frontend/native/bare/app/_layout.tsx.hbs +165 -0
- package/templates/frontend/native/bare/app/modal.tsx.hbs +34 -0
- package/templates/frontend/native/bare/app.json.hbs +50 -0
- package/templates/frontend/native/bare/components/container.tsx.hbs +25 -0
- package/templates/frontend/native/bare/components/header-button.tsx.hbs +47 -0
- package/templates/frontend/native/bare/components/tabbar-icon.tsx.hbs +9 -0
- package/templates/frontend/native/bare/lib/android-navigation-bar.tsx.hbs +12 -0
- package/templates/frontend/native/bare/lib/constants.ts.hbs +19 -0
- package/templates/frontend/native/bare/lib/use-color-scheme.ts.hbs +20 -0
- package/templates/frontend/native/bare/metro.config.js.hbs +9 -0
- package/templates/frontend/native/bare/package.json.hbs +51 -0
- package/templates/frontend/native/bare/tsconfig.json.hbs +11 -0
- package/templates/frontend/native/base/assets/images/android-icon-background.png +0 -0
- package/templates/frontend/native/base/assets/images/android-icon-foreground.png +0 -0
- package/templates/frontend/native/base/assets/images/android-icon-monochrome.png +0 -0
- package/templates/frontend/native/base/assets/images/favicon.png +0 -0
- package/templates/frontend/native/base/assets/images/icon.png +0 -0
- package/templates/frontend/native/base/assets/images/partial-react-logo.png +0 -0
- package/templates/frontend/native/base/assets/images/react-logo.png +0 -0
- package/templates/frontend/native/base/assets/images/react-logo@2x.png +0 -0
- package/templates/frontend/native/base/assets/images/react-logo@3x.png +0 -0
- package/templates/frontend/native/base/assets/images/splash-icon.png +0 -0
- package/templates/frontend/native/unistyles/_gitignore +24 -0
- package/templates/frontend/native/unistyles/app/(drawer)/(tabs)/_layout.tsx.hbs +39 -0
- package/templates/frontend/native/unistyles/app/(drawer)/(tabs)/index.tsx.hbs +37 -0
- package/templates/frontend/native/unistyles/app/(drawer)/(tabs)/two.tsx.hbs +37 -0
- package/templates/frontend/native/unistyles/app/(drawer)/_layout.tsx.hbs +87 -0
- package/templates/frontend/native/unistyles/app/(drawer)/index.tsx.hbs +333 -0
- package/templates/frontend/native/unistyles/app/+not-found.tsx.hbs +65 -0
- package/templates/frontend/native/unistyles/app/_layout.tsx.hbs +169 -0
- package/templates/frontend/native/unistyles/app/modal.tsx.hbs +33 -0
- package/templates/frontend/native/unistyles/app.json.hbs +49 -0
- package/templates/frontend/native/unistyles/babel.config.js.hbs +21 -0
- package/templates/frontend/native/unistyles/breakpoints.ts.hbs +9 -0
- package/templates/frontend/native/unistyles/components/container.tsx.hbs +15 -0
- package/templates/frontend/native/unistyles/components/header-button.tsx.hbs +36 -0
- package/templates/frontend/native/unistyles/components/tabbar-icon.tsx.hbs +8 -0
- package/templates/frontend/native/unistyles/index.js.hbs +2 -0
- package/templates/frontend/native/unistyles/metro.config.js.hbs +5 -0
- package/templates/frontend/native/unistyles/package.json.hbs +51 -0
- package/templates/frontend/native/unistyles/theme.ts.hbs +98 -0
- package/templates/frontend/native/unistyles/tsconfig.json.hbs +12 -0
- package/templates/frontend/native/unistyles/unistyles.ts.hbs +27 -0
- package/templates/frontend/native/uniwind/_gitignore +21 -0
- package/templates/frontend/native/uniwind/app/(drawer)/(tabs)/_layout.tsx.hbs +46 -0
- package/templates/frontend/native/uniwind/app/(drawer)/(tabs)/index.tsx.hbs +15 -0
- package/templates/frontend/native/uniwind/app/(drawer)/(tabs)/two.tsx.hbs +15 -0
- package/templates/frontend/native/uniwind/app/(drawer)/_layout.tsx.hbs +91 -0
- package/templates/frontend/native/uniwind/app/(drawer)/index.tsx.hbs +191 -0
- package/templates/frontend/native/uniwind/app/+not-found.tsx.hbs +27 -0
- package/templates/frontend/native/uniwind/app/_layout.tsx.hbs +132 -0
- package/templates/frontend/native/uniwind/app/modal.tsx.hbs +37 -0
- package/templates/frontend/native/uniwind/app.json.hbs +19 -0
- package/templates/frontend/native/uniwind/components/container.tsx.hbs +33 -0
- package/templates/frontend/native/uniwind/components/theme-toggle.tsx.hbs +35 -0
- package/templates/frontend/native/uniwind/contexts/app-theme-context.tsx.hbs +62 -0
- package/templates/frontend/native/uniwind/global.css +5 -0
- package/templates/frontend/native/uniwind/metro.config.js.hbs +13 -0
- package/templates/frontend/native/uniwind/package.json.hbs +54 -0
- package/templates/frontend/native/uniwind/tsconfig.json.hbs +14 -0
- package/templates/frontend/nuxt/_gitignore +27 -0
- package/templates/frontend/nuxt/app/app.config.ts.hbs +15 -0
- package/templates/frontend/nuxt/app/app.vue.hbs +17 -0
- package/templates/frontend/nuxt/app/assets/css/main.css +2 -0
- package/templates/frontend/nuxt/app/components/Header.vue.hbs +40 -0
- package/templates/frontend/nuxt/app/layouts/default.vue.hbs +10 -0
- package/templates/frontend/nuxt/app/pages/index.vue.hbs +97 -0
- package/templates/frontend/nuxt/nuxt.config.ts.hbs +29 -0
- package/templates/frontend/nuxt/package.json.hbs +24 -0
- package/templates/frontend/nuxt/public/favicon.ico +0 -0
- package/templates/frontend/nuxt/public/robots.txt +2 -0
- package/templates/frontend/nuxt/server/tsconfig.json +3 -0
- package/templates/frontend/nuxt/tsconfig.json.hbs +18 -0
- package/templates/frontend/react/next/next-env.d.ts.hbs +5 -0
- package/templates/frontend/react/next/next.config.ts.hbs +22 -0
- package/templates/frontend/react/next/package.json.hbs +34 -0
- package/templates/frontend/react/next/postcss.config.mjs.hbs +5 -0
- package/templates/frontend/react/next/src/app/favicon.ico +0 -0
- package/templates/frontend/react/next/src/app/layout.tsx.hbs +76 -0
- package/templates/frontend/react/next/src/app/page.tsx.hbs +79 -0
- package/templates/frontend/react/next/src/components/mode-toggle.tsx.hbs +37 -0
- package/templates/frontend/react/next/src/components/providers.tsx.hbs +89 -0
- package/templates/frontend/react/next/src/components/theme-provider.tsx.hbs +11 -0
- package/templates/frontend/react/next/tsconfig.json.hbs +41 -0
- package/templates/frontend/react/react-router/package.json.hbs +42 -0
- package/templates/frontend/react/react-router/public/favicon.ico +0 -0
- package/templates/frontend/react/react-router/react-router.config.ts +6 -0
- package/templates/frontend/react/react-router/src/components/mode-toggle.tsx.hbs +29 -0
- package/templates/frontend/react/react-router/src/components/theme-provider.tsx.hbs +11 -0
- package/templates/frontend/react/react-router/src/root.tsx.hbs +190 -0
- package/templates/frontend/react/react-router/src/routes/_index.tsx.hbs +85 -0
- package/templates/frontend/react/react-router/src/routes.ts +4 -0
- package/templates/frontend/react/react-router/tsconfig.json.hbs +27 -0
- package/templates/frontend/react/react-router/vite.config.ts.hbs +12 -0
- package/templates/frontend/react/tanstack-router/index.html.hbs +13 -0
- package/templates/frontend/react/tanstack-router/package.json.hbs +41 -0
- package/templates/frontend/react/tanstack-router/src/components/mode-toggle.tsx.hbs +29 -0
- package/templates/frontend/react/tanstack-router/src/components/theme-provider.tsx.hbs +11 -0
- package/templates/frontend/react/tanstack-router/src/main.tsx.hbs +90 -0
- package/templates/frontend/react/tanstack-router/src/routes/__root.tsx.hbs +103 -0
- package/templates/frontend/react/tanstack-router/src/routes/index.tsx.hbs +85 -0
- package/templates/frontend/react/tanstack-router/tsconfig.json.hbs +18 -0
- package/templates/frontend/react/tanstack-router/vite.config.ts.hbs +21 -0
- package/templates/frontend/react/tanstack-start/package.json.hbs +43 -0
- package/templates/frontend/react/tanstack-start/public/robots.txt +3 -0
- package/templates/frontend/react/tanstack-start/src/router.tsx.hbs +144 -0
- package/templates/frontend/react/tanstack-start/src/routes/__root.tsx.hbs +208 -0
- package/templates/frontend/react/tanstack-start/src/routes/index.tsx.hbs +85 -0
- package/templates/frontend/react/tanstack-start/tsconfig.json.hbs +28 -0
- package/templates/frontend/react/tanstack-start/vite.config.ts.hbs +22 -0
- package/templates/frontend/react/web-base/_gitignore +60 -0
- package/templates/frontend/react/web-base/components.json +24 -0
- package/templates/frontend/react/web-base/src/components/header.tsx.hbs +78 -0
- package/templates/frontend/react/web-base/src/components/loader.tsx.hbs +9 -0
- package/templates/frontend/react/web-base/src/components/ui/button.tsx.hbs +57 -0
- package/templates/frontend/react/web-base/src/components/ui/card.tsx.hbs +103 -0
- package/templates/frontend/react/web-base/src/components/ui/checkbox.tsx.hbs +26 -0
- package/templates/frontend/react/web-base/src/components/ui/dropdown-menu.tsx.hbs +262 -0
- package/templates/frontend/react/web-base/src/components/ui/input.tsx.hbs +20 -0
- package/templates/frontend/react/web-base/src/components/ui/label.tsx.hbs +20 -0
- package/templates/frontend/react/web-base/src/components/ui/skeleton.tsx.hbs +13 -0
- package/templates/frontend/react/web-base/src/components/ui/sonner.tsx.hbs +44 -0
- package/templates/frontend/react/web-base/src/index.css.hbs +131 -0
- package/templates/frontend/react/web-base/src/lib/utils.ts.hbs +6 -0
- package/templates/frontend/solid/_gitignore +11 -0
- package/templates/frontend/solid/index.html +13 -0
- package/templates/frontend/solid/package.json.hbs +24 -0
- package/templates/frontend/solid/public/robots.txt +3 -0
- package/templates/frontend/solid/src/components/header.tsx.hbs +38 -0
- package/templates/frontend/solid/src/components/loader.tsx +9 -0
- package/templates/frontend/solid/src/main.tsx.hbs +41 -0
- package/templates/frontend/solid/src/routes/__root.tsx.hbs +34 -0
- package/templates/frontend/solid/src/routes/index.tsx.hbs +72 -0
- package/templates/frontend/solid/src/styles.css +5 -0
- package/templates/frontend/solid/tsconfig.json.hbs +29 -0
- package/templates/frontend/solid/vite.config.ts.hbs +21 -0
- package/templates/frontend/svelte/_gitignore +24 -0
- package/templates/frontend/svelte/_npmrc +1 -0
- package/templates/frontend/svelte/package.json.hbs +27 -0
- package/templates/frontend/svelte/src/app.css +5 -0
- package/templates/frontend/svelte/src/app.d.ts +13 -0
- package/templates/frontend/svelte/src/app.html +12 -0
- package/templates/frontend/svelte/src/components/Header.svelte.hbs +40 -0
- package/templates/frontend/svelte/src/lib/index.ts +2 -0
- package/templates/frontend/svelte/src/routes/+layout.svelte.hbs +54 -0
- package/templates/frontend/svelte/src/routes/+page.svelte.hbs +92 -0
- package/templates/frontend/svelte/static/favicon.png +0 -0
- package/templates/frontend/svelte/svelte.config.js.hbs +18 -0
- package/templates/frontend/svelte/tsconfig.json.hbs +19 -0
- package/templates/frontend/svelte/vite.config.ts.hbs +7 -0
- package/templates/packages/config/package.json.hbs +5 -0
- package/templates/packages/config/tsconfig.base.json.hbs +33 -0
- package/templates/packages/env/env.d.ts.hbs +16 -0
- package/templates/packages/env/package.json.hbs +7 -0
- package/templates/packages/env/src/native.ts.hbs +21 -0
- package/templates/packages/env/src/server.ts.hbs +39 -0
- package/templates/packages/env/src/web.ts.hbs +98 -0
- package/templates/packages/env/tsconfig.json.hbs +3 -0
- package/templates/packages/infra/alchemy.run.ts.hbs +271 -0
- package/templates/packages/infra/package.json.hbs +10 -0
- package/templates/payments/polar/server/base/src/lib/payments.ts.hbs +7 -0
- package/templates/payments/polar/web/nuxt/app/pages/success.vue.hbs +11 -0
- package/templates/payments/polar/web/react/next/src/app/success/page.tsx.hbs +15 -0
- package/templates/payments/polar/web/react/react-router/src/routes/success.tsx.hbs +13 -0
- package/templates/payments/polar/web/react/tanstack-router/src/routes/success.tsx.hbs +19 -0
- package/templates/payments/polar/web/react/tanstack-start/src/functions/get-payment.ts.hbs +15 -0
- package/templates/payments/polar/web/react/tanstack-start/src/routes/success.tsx.hbs +19 -0
- package/templates/payments/polar/web/solid/src/routes/success.tsx.hbs +23 -0
- package/templates/payments/polar/web/svelte/src/routes/success/+page.svelte.hbs +12 -0
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { Checkbox as CheckboxPrimitive } from '@base-ui/react/checkbox'
|
|
2
|
+
|
|
3
|
+
import { CheckIcon } from 'lucide-react'
|
|
4
|
+
import { cn } from '@/lib/utils'
|
|
5
|
+
|
|
6
|
+
function Checkbox({ className, ...props }: CheckboxPrimitive.Root.Props) {
|
|
7
|
+
return (
|
|
8
|
+
<CheckboxPrimitive.Root
|
|
9
|
+
data-slot="checkbox"
|
|
10
|
+
className={cn(
|
|
11
|
+
'border-input dark:bg-input/30 data-checked:bg-primary data-checked:text-primary-foreground dark:data-checked:bg-primary data-checked:border-primary aria-invalid:aria-checked:border-primary aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 flex size-4 items-center justify-center rounded-none border transition-colors group-has-disabled/field:opacity-50 focus-visible:ring-1 aria-invalid:ring-1 peer relative shrink-0 outline-none after:absolute after:-inset-x-3 after:-inset-y-2 disabled:cursor-not-allowed disabled:opacity-50',
|
|
12
|
+
className,
|
|
13
|
+
)}
|
|
14
|
+
{...props}
|
|
15
|
+
>
|
|
16
|
+
<CheckboxPrimitive.Indicator
|
|
17
|
+
data-slot="checkbox-indicator"
|
|
18
|
+
className="[&>svg]:size-3.5 grid place-content-center text-current transition-none"
|
|
19
|
+
>
|
|
20
|
+
<CheckIcon />
|
|
21
|
+
</CheckboxPrimitive.Indicator>
|
|
22
|
+
</CheckboxPrimitive.Root>
|
|
23
|
+
)
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export { Checkbox }
|
|
@@ -0,0 +1,262 @@
|
|
|
1
|
+
import * as React from 'react'
|
|
2
|
+
import { Menu as MenuPrimitive } from '@base-ui/react/menu'
|
|
3
|
+
|
|
4
|
+
import { CheckIcon, ChevronRightIcon } from 'lucide-react'
|
|
5
|
+
import { cn } from '@/lib/utils'
|
|
6
|
+
|
|
7
|
+
function DropdownMenu({ ...props }: MenuPrimitive.Root.Props) {
|
|
8
|
+
return <MenuPrimitive.Root data-slot="dropdown-menu" {...props} />
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
function DropdownMenuPortal({ ...props }: MenuPrimitive.Portal.Props) {
|
|
12
|
+
return <MenuPrimitive.Portal data-slot="dropdown-menu-portal" {...props} />
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
function DropdownMenuTrigger({ ...props }: MenuPrimitive.Trigger.Props) {
|
|
16
|
+
return <MenuPrimitive.Trigger data-slot="dropdown-menu-trigger" {...props} />
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
function DropdownMenuContent({
|
|
20
|
+
align = 'start',
|
|
21
|
+
alignOffset = 0,
|
|
22
|
+
side = 'bottom',
|
|
23
|
+
sideOffset = 4,
|
|
24
|
+
className,
|
|
25
|
+
...props
|
|
26
|
+
}: MenuPrimitive.Popup.Props &
|
|
27
|
+
Pick<
|
|
28
|
+
MenuPrimitive.Positioner.Props,
|
|
29
|
+
'align' | 'alignOffset' | 'side' | 'sideOffset'
|
|
30
|
+
>) {
|
|
31
|
+
return (
|
|
32
|
+
<MenuPrimitive.Portal>
|
|
33
|
+
<MenuPrimitive.Positioner
|
|
34
|
+
className="isolate z-50 outline-none"
|
|
35
|
+
align={align}
|
|
36
|
+
alignOffset={alignOffset}
|
|
37
|
+
side={side}
|
|
38
|
+
sideOffset={sideOffset}
|
|
39
|
+
>
|
|
40
|
+
<MenuPrimitive.Popup
|
|
41
|
+
data-slot="dropdown-menu-content"
|
|
42
|
+
className={cn(
|
|
43
|
+
'data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-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 ring-foreground/10 bg-popover text-popover-foreground min-w-32 rounded-none shadow-md ring-1 duration-100 z-50 max-h-(--available-height) w-(--anchor-width) origin-(--transform-origin) overflow-x-hidden overflow-y-auto outline-none data-closed:overflow-hidden',
|
|
44
|
+
className,
|
|
45
|
+
)}
|
|
46
|
+
{...props}
|
|
47
|
+
/>
|
|
48
|
+
</MenuPrimitive.Positioner>
|
|
49
|
+
</MenuPrimitive.Portal>
|
|
50
|
+
)
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
function DropdownMenuGroup({ ...props }: MenuPrimitive.Group.Props) {
|
|
54
|
+
return <MenuPrimitive.Group data-slot="dropdown-menu-group" {...props} />
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
function DropdownMenuLabel({
|
|
58
|
+
className,
|
|
59
|
+
inset,
|
|
60
|
+
...props
|
|
61
|
+
}: MenuPrimitive.GroupLabel.Props & {
|
|
62
|
+
inset?: boolean
|
|
63
|
+
}) {
|
|
64
|
+
return (
|
|
65
|
+
<MenuPrimitive.GroupLabel
|
|
66
|
+
data-slot="dropdown-menu-label"
|
|
67
|
+
data-inset={inset}
|
|
68
|
+
className={cn(
|
|
69
|
+
'text-muted-foreground px-2 py-2 text-xs data-[inset]:pl-8',
|
|
70
|
+
className,
|
|
71
|
+
)}
|
|
72
|
+
{...props}
|
|
73
|
+
/>
|
|
74
|
+
)
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
function DropdownMenuItem({
|
|
78
|
+
className,
|
|
79
|
+
inset,
|
|
80
|
+
variant = 'default',
|
|
81
|
+
...props
|
|
82
|
+
}: MenuPrimitive.Item.Props & {
|
|
83
|
+
inset?: boolean
|
|
84
|
+
variant?: 'default' | 'destructive'
|
|
85
|
+
}) {
|
|
86
|
+
return (
|
|
87
|
+
<MenuPrimitive.Item
|
|
88
|
+
data-slot="dropdown-menu-item"
|
|
89
|
+
data-inset={inset}
|
|
90
|
+
data-variant={variant}
|
|
91
|
+
className={cn(
|
|
92
|
+
"focus:bg-accent focus:text-accent-foreground data-[variant=destructive]:text-destructive data-[variant=destructive]:focus:bg-destructive/10 dark:data-[variant=destructive]:focus:bg-destructive/20 data-[variant=destructive]:focus:text-destructive data-[variant=destructive]:*:[svg]:text-destructive not-data-[variant=destructive]:focus:**:text-accent-foreground gap-2 rounded-none px-2 py-2 text-xs [&_svg:not([class*='size-'])]:size-4 group/dropdown-menu-item relative flex cursor-default items-center outline-hidden select-none data-disabled:pointer-events-none data-disabled:opacity-50 data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0",
|
|
93
|
+
className,
|
|
94
|
+
)}
|
|
95
|
+
{...props}
|
|
96
|
+
/>
|
|
97
|
+
)
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
function DropdownMenuSub({ ...props }: MenuPrimitive.SubmenuRoot.Props) {
|
|
101
|
+
return <MenuPrimitive.SubmenuRoot data-slot="dropdown-menu-sub" {...props} />
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
function DropdownMenuSubTrigger({
|
|
105
|
+
className,
|
|
106
|
+
inset,
|
|
107
|
+
children,
|
|
108
|
+
...props
|
|
109
|
+
}: MenuPrimitive.SubmenuTrigger.Props & {
|
|
110
|
+
inset?: boolean
|
|
111
|
+
}) {
|
|
112
|
+
return (
|
|
113
|
+
<MenuPrimitive.SubmenuTrigger
|
|
114
|
+
data-slot="dropdown-menu-sub-trigger"
|
|
115
|
+
data-inset={inset}
|
|
116
|
+
className={cn(
|
|
117
|
+
"focus:bg-accent focus:text-accent-foreground data-open:bg-accent data-open:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground gap-2 rounded-none px-2 py-2 text-xs [&_svg:not([class*='size-'])]:size-4 flex cursor-default items-center outline-hidden select-none data-[inset]:pl-8 [&_svg]:pointer-events-none [&_svg]:shrink-0",
|
|
118
|
+
className,
|
|
119
|
+
)}
|
|
120
|
+
{...props}
|
|
121
|
+
>
|
|
122
|
+
{children}
|
|
123
|
+
<ChevronRightIcon className="ml-auto" />
|
|
124
|
+
</MenuPrimitive.SubmenuTrigger>
|
|
125
|
+
)
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
function DropdownMenuSubContent({
|
|
129
|
+
align = 'start',
|
|
130
|
+
alignOffset = -3,
|
|
131
|
+
side = 'right',
|
|
132
|
+
sideOffset = 0,
|
|
133
|
+
className,
|
|
134
|
+
...props
|
|
135
|
+
}: React.ComponentProps<typeof DropdownMenuContent>) {
|
|
136
|
+
return (
|
|
137
|
+
<DropdownMenuContent
|
|
138
|
+
data-slot="dropdown-menu-sub-content"
|
|
139
|
+
className={cn(
|
|
140
|
+
'data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-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 ring-foreground/10 bg-popover text-popover-foreground min-w-[96px] rounded-none shadow-lg ring-1 duration-100 w-auto',
|
|
141
|
+
className,
|
|
142
|
+
)}
|
|
143
|
+
align={align}
|
|
144
|
+
alignOffset={alignOffset}
|
|
145
|
+
side={side}
|
|
146
|
+
sideOffset={sideOffset}
|
|
147
|
+
{...props}
|
|
148
|
+
/>
|
|
149
|
+
)
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
function DropdownMenuCheckboxItem({
|
|
153
|
+
className,
|
|
154
|
+
children,
|
|
155
|
+
checked,
|
|
156
|
+
...props
|
|
157
|
+
}: MenuPrimitive.CheckboxItem.Props) {
|
|
158
|
+
return (
|
|
159
|
+
<MenuPrimitive.CheckboxItem
|
|
160
|
+
data-slot="dropdown-menu-checkbox-item"
|
|
161
|
+
className={cn(
|
|
162
|
+
"focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground gap-2 rounded-none py-2 pr-8 pl-2 text-xs [&_svg:not([class*='size-'])]:size-4 relative flex cursor-default items-center outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0",
|
|
163
|
+
className,
|
|
164
|
+
)}
|
|
165
|
+
checked={checked}
|
|
166
|
+
{...props}
|
|
167
|
+
>
|
|
168
|
+
<span
|
|
169
|
+
className="pointer-events-none absolute right-2 flex items-center justify-center pointer-events-none"
|
|
170
|
+
data-slot="dropdown-menu-checkbox-item-indicator"
|
|
171
|
+
>
|
|
172
|
+
<MenuPrimitive.CheckboxItemIndicator>
|
|
173
|
+
<CheckIcon />
|
|
174
|
+
</MenuPrimitive.CheckboxItemIndicator>
|
|
175
|
+
</span>
|
|
176
|
+
{children}
|
|
177
|
+
</MenuPrimitive.CheckboxItem>
|
|
178
|
+
)
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
function DropdownMenuRadioGroup({ ...props }: MenuPrimitive.RadioGroup.Props) {
|
|
182
|
+
return (
|
|
183
|
+
<MenuPrimitive.RadioGroup
|
|
184
|
+
data-slot="dropdown-menu-radio-group"
|
|
185
|
+
{...props}
|
|
186
|
+
/>
|
|
187
|
+
)
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
function DropdownMenuRadioItem({
|
|
191
|
+
className,
|
|
192
|
+
children,
|
|
193
|
+
...props
|
|
194
|
+
}: MenuPrimitive.RadioItem.Props) {
|
|
195
|
+
return (
|
|
196
|
+
<MenuPrimitive.RadioItem
|
|
197
|
+
data-slot="dropdown-menu-radio-item"
|
|
198
|
+
className={cn(
|
|
199
|
+
"focus:bg-accent focus:text-accent-foreground focus:**:text-accent-foreground gap-2 rounded-none py-2 pr-8 pl-2 text-xs [&_svg:not([class*='size-'])]:size-4 relative flex cursor-default items-center outline-hidden select-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0",
|
|
200
|
+
className,
|
|
201
|
+
)}
|
|
202
|
+
{...props}
|
|
203
|
+
>
|
|
204
|
+
<span
|
|
205
|
+
className="pointer-events-none absolute right-2 flex items-center justify-center pointer-events-none"
|
|
206
|
+
data-slot="dropdown-menu-radio-item-indicator"
|
|
207
|
+
>
|
|
208
|
+
<MenuPrimitive.RadioItemIndicator>
|
|
209
|
+
<CheckIcon />
|
|
210
|
+
</MenuPrimitive.RadioItemIndicator>
|
|
211
|
+
</span>
|
|
212
|
+
{children}
|
|
213
|
+
</MenuPrimitive.RadioItem>
|
|
214
|
+
)
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
function DropdownMenuSeparator({
|
|
218
|
+
className,
|
|
219
|
+
...props
|
|
220
|
+
}: MenuPrimitive.Separator.Props) {
|
|
221
|
+
return (
|
|
222
|
+
<MenuPrimitive.Separator
|
|
223
|
+
data-slot="dropdown-menu-separator"
|
|
224
|
+
className={cn('bg-border -mx-1 h-px', className)}
|
|
225
|
+
{...props}
|
|
226
|
+
/>
|
|
227
|
+
)
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
function DropdownMenuShortcut({
|
|
231
|
+
className,
|
|
232
|
+
...props
|
|
233
|
+
}: React.ComponentProps<'span'>) {
|
|
234
|
+
return (
|
|
235
|
+
<span
|
|
236
|
+
data-slot="dropdown-menu-shortcut"
|
|
237
|
+
className={cn(
|
|
238
|
+
'text-muted-foreground group-focus/dropdown-menu-item:text-accent-foreground ml-auto text-xs tracking-widest',
|
|
239
|
+
className,
|
|
240
|
+
)}
|
|
241
|
+
{...props}
|
|
242
|
+
/>
|
|
243
|
+
)
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
export {
|
|
247
|
+
DropdownMenu,
|
|
248
|
+
DropdownMenuPortal,
|
|
249
|
+
DropdownMenuTrigger,
|
|
250
|
+
DropdownMenuContent,
|
|
251
|
+
DropdownMenuGroup,
|
|
252
|
+
DropdownMenuLabel,
|
|
253
|
+
DropdownMenuItem,
|
|
254
|
+
DropdownMenuCheckboxItem,
|
|
255
|
+
DropdownMenuRadioGroup,
|
|
256
|
+
DropdownMenuRadioItem,
|
|
257
|
+
DropdownMenuSeparator,
|
|
258
|
+
DropdownMenuShortcut,
|
|
259
|
+
DropdownMenuSub,
|
|
260
|
+
DropdownMenuSubTrigger,
|
|
261
|
+
DropdownMenuSubContent,
|
|
262
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import * as React from 'react'
|
|
2
|
+
import { Input as InputPrimitive } from '@base-ui/react/input'
|
|
3
|
+
|
|
4
|
+
import { cn } from '@/lib/utils'
|
|
5
|
+
|
|
6
|
+
function Input({ className, type, ...props }: React.ComponentProps<'input'>) {
|
|
7
|
+
return (
|
|
8
|
+
<InputPrimitive
|
|
9
|
+
type={type}
|
|
10
|
+
data-slot="input"
|
|
11
|
+
className={cn(
|
|
12
|
+
'dark:bg-input/30 border-input focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:aria-invalid:border-destructive/50 disabled:bg-input/50 dark:disabled:bg-input/80 h-8 rounded-none border bg-transparent px-2.5 py-1 text-xs transition-colors file:h-6 file:text-xs file:font-medium focus-visible:ring-1 aria-invalid:ring-1 md:text-xs file:text-foreground placeholder:text-muted-foreground w-full min-w-0 outline-none file:inline-flex file:border-0 file:bg-transparent disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50',
|
|
13
|
+
className,
|
|
14
|
+
)}
|
|
15
|
+
{...props}
|
|
16
|
+
/>
|
|
17
|
+
)
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export { Input }
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
'use client'
|
|
2
|
+
|
|
3
|
+
import * as React from 'react'
|
|
4
|
+
|
|
5
|
+
import { cn } from '@/lib/utils'
|
|
6
|
+
|
|
7
|
+
function Label({ className, ...props }: React.ComponentProps<'label'>) {
|
|
8
|
+
return (
|
|
9
|
+
<label
|
|
10
|
+
data-slot="label"
|
|
11
|
+
className={cn(
|
|
12
|
+
'gap-2 text-xs leading-none group-data-[disabled=true]:opacity-50 peer-disabled:opacity-50 flex items-center select-none group-data-[disabled=true]:pointer-events-none peer-disabled:cursor-not-allowed',
|
|
13
|
+
className,
|
|
14
|
+
)}
|
|
15
|
+
{...props}
|
|
16
|
+
/>
|
|
17
|
+
)
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export { Label }
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { cn } from "@/lib/utils";
|
|
2
|
+
|
|
3
|
+
function Skeleton({ className, ...props }: React.HTMLAttributes<HTMLDivElement>) {
|
|
4
|
+
return (
|
|
5
|
+
<div
|
|
6
|
+
data-slot="skeleton"
|
|
7
|
+
className={cn("bg-muted rounded-none animate-pulse", className)}
|
|
8
|
+
{...props}
|
|
9
|
+
/>
|
|
10
|
+
);
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export { Skeleton };
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { useTheme } from 'next-themes'
|
|
2
|
+
import { Toaster as Sonner } from 'sonner'
|
|
3
|
+
import {
|
|
4
|
+
CircleCheckIcon,
|
|
5
|
+
InfoIcon,
|
|
6
|
+
Loader2Icon,
|
|
7
|
+
OctagonXIcon,
|
|
8
|
+
TriangleAlertIcon,
|
|
9
|
+
} from 'lucide-react'
|
|
10
|
+
import type {ToasterProps} from 'sonner';
|
|
11
|
+
|
|
12
|
+
const Toaster = ({ ...props }: ToasterProps) => {
|
|
13
|
+
const { theme = 'system' } = useTheme()
|
|
14
|
+
|
|
15
|
+
return (
|
|
16
|
+
<Sonner
|
|
17
|
+
theme={theme as ToasterProps['theme']}
|
|
18
|
+
className="toaster group"
|
|
19
|
+
icons=\{{
|
|
20
|
+
success: <CircleCheckIcon className="size-4" />,
|
|
21
|
+
info: <InfoIcon className="size-4" />,
|
|
22
|
+
warning: <TriangleAlertIcon className="size-4" />,
|
|
23
|
+
error: <OctagonXIcon className="size-4" />,
|
|
24
|
+
loading: <Loader2Icon className="size-4 animate-spin" />,
|
|
25
|
+
}}
|
|
26
|
+
style={
|
|
27
|
+
{
|
|
28
|
+
'--normal-bg': 'var(--popover)',
|
|
29
|
+
'--normal-text': 'var(--popover-foreground)',
|
|
30
|
+
'--normal-border': 'var(--border)',
|
|
31
|
+
'--border-radius': 'var(--radius)',
|
|
32
|
+
} as React.CSSProperties
|
|
33
|
+
}
|
|
34
|
+
toastOptions=\{{
|
|
35
|
+
classNames: {
|
|
36
|
+
toast: 'cn-toast',
|
|
37
|
+
},
|
|
38
|
+
}}
|
|
39
|
+
{...props}
|
|
40
|
+
/>
|
|
41
|
+
)
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export { Toaster }
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
@import 'tailwindcss';
|
|
2
|
+
@import 'tw-animate-css';
|
|
3
|
+
@import 'shadcn/tailwind.css';
|
|
4
|
+
{{#if (includes examples "ai")}}
|
|
5
|
+
@source "../node_modules/streamdown/dist/*.js";
|
|
6
|
+
{{/if}}
|
|
7
|
+
|
|
8
|
+
@custom-variant dark (&:is(.dark *));
|
|
9
|
+
|
|
10
|
+
:root {
|
|
11
|
+
--background: oklch(1 0 0);
|
|
12
|
+
--foreground: oklch(0.145 0 0);
|
|
13
|
+
--card: oklch(1 0 0);
|
|
14
|
+
--card-foreground: oklch(0.145 0 0);
|
|
15
|
+
--popover: oklch(1 0 0);
|
|
16
|
+
--popover-foreground: oklch(0.145 0 0);
|
|
17
|
+
--primary: oklch(0.205 0 0);
|
|
18
|
+
--primary-foreground: oklch(0.985 0 0);
|
|
19
|
+
--secondary: oklch(0.97 0 0);
|
|
20
|
+
--secondary-foreground: oklch(0.205 0 0);
|
|
21
|
+
--muted: oklch(0.97 0 0);
|
|
22
|
+
--muted-foreground: oklch(0.556 0 0);
|
|
23
|
+
--accent: oklch(0.97 0 0);
|
|
24
|
+
--accent-foreground: oklch(0.205 0 0);
|
|
25
|
+
--destructive: oklch(0.58 0.22 27);
|
|
26
|
+
--border: oklch(0.922 0 0);
|
|
27
|
+
--input: oklch(0.922 0 0);
|
|
28
|
+
--ring: oklch(0.708 0 0);
|
|
29
|
+
--chart-1: oklch(0.809 0.105 251.813);
|
|
30
|
+
--chart-2: oklch(0.623 0.214 259.815);
|
|
31
|
+
--chart-3: oklch(0.546 0.245 262.881);
|
|
32
|
+
--chart-4: oklch(0.488 0.243 264.376);
|
|
33
|
+
--chart-5: oklch(0.424 0.199 265.638);
|
|
34
|
+
--radius: 0.625rem;
|
|
35
|
+
--sidebar: oklch(0.985 0 0);
|
|
36
|
+
--sidebar-foreground: oklch(0.145 0 0);
|
|
37
|
+
--sidebar-primary: oklch(0.205 0 0);
|
|
38
|
+
--sidebar-primary-foreground: oklch(0.985 0 0);
|
|
39
|
+
--sidebar-accent: oklch(0.97 0 0);
|
|
40
|
+
--sidebar-accent-foreground: oklch(0.205 0 0);
|
|
41
|
+
--sidebar-border: oklch(0.922 0 0);
|
|
42
|
+
--sidebar-ring: oklch(0.708 0 0);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.dark {
|
|
46
|
+
--background: oklch(0.145 0 0);
|
|
47
|
+
--foreground: oklch(0.985 0 0);
|
|
48
|
+
--card: oklch(0.205 0 0);
|
|
49
|
+
--card-foreground: oklch(0.985 0 0);
|
|
50
|
+
--popover: oklch(0.205 0 0);
|
|
51
|
+
--popover-foreground: oklch(0.985 0 0);
|
|
52
|
+
--primary: oklch(0.87 0 0);
|
|
53
|
+
--primary-foreground: oklch(0.205 0 0);
|
|
54
|
+
--secondary: oklch(0.269 0 0);
|
|
55
|
+
--secondary-foreground: oklch(0.985 0 0);
|
|
56
|
+
--muted: oklch(0.269 0 0);
|
|
57
|
+
--muted-foreground: oklch(0.708 0 0);
|
|
58
|
+
--accent: oklch(0.371 0 0);
|
|
59
|
+
--accent-foreground: oklch(0.985 0 0);
|
|
60
|
+
--destructive: oklch(0.704 0.191 22.216);
|
|
61
|
+
--border: oklch(1 0 0 / 10%);
|
|
62
|
+
--input: oklch(1 0 0 / 15%);
|
|
63
|
+
--ring: oklch(0.556 0 0);
|
|
64
|
+
--chart-1: oklch(0.809 0.105 251.813);
|
|
65
|
+
--chart-2: oklch(0.623 0.214 259.815);
|
|
66
|
+
--chart-3: oklch(0.546 0.245 262.881);
|
|
67
|
+
--chart-4: oklch(0.488 0.243 264.376);
|
|
68
|
+
--chart-5: oklch(0.424 0.199 265.638);
|
|
69
|
+
--sidebar: oklch(0.205 0 0);
|
|
70
|
+
--sidebar-foreground: oklch(0.985 0 0);
|
|
71
|
+
--sidebar-primary: oklch(0.488 0.243 264.376);
|
|
72
|
+
--sidebar-primary-foreground: oklch(0.985 0 0);
|
|
73
|
+
--sidebar-accent: oklch(0.269 0 0);
|
|
74
|
+
--sidebar-accent-foreground: oklch(0.985 0 0);
|
|
75
|
+
--sidebar-border: oklch(1 0 0 / 10%);
|
|
76
|
+
--sidebar-ring: oklch(0.556 0 0);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
@theme inline {
|
|
80
|
+
--font-sans: 'Inter Variable', sans-serif;
|
|
81
|
+
--color-sidebar-ring: var(--sidebar-ring);
|
|
82
|
+
--color-sidebar-border: var(--sidebar-border);
|
|
83
|
+
--color-sidebar-accent-foreground: var(--sidebar-accent-foreground);
|
|
84
|
+
--color-sidebar-accent: var(--sidebar-accent);
|
|
85
|
+
--color-sidebar-primary-foreground: var(--sidebar-primary-foreground);
|
|
86
|
+
--color-sidebar-primary: var(--sidebar-primary);
|
|
87
|
+
--color-sidebar-foreground: var(--sidebar-foreground);
|
|
88
|
+
--color-sidebar: var(--sidebar);
|
|
89
|
+
--color-chart-5: var(--chart-5);
|
|
90
|
+
--color-chart-4: var(--chart-4);
|
|
91
|
+
--color-chart-3: var(--chart-3);
|
|
92
|
+
--color-chart-2: var(--chart-2);
|
|
93
|
+
--color-chart-1: var(--chart-1);
|
|
94
|
+
--color-ring: var(--ring);
|
|
95
|
+
--color-input: var(--input);
|
|
96
|
+
--color-border: var(--border);
|
|
97
|
+
--color-destructive: var(--destructive);
|
|
98
|
+
--color-accent-foreground: var(--accent-foreground);
|
|
99
|
+
--color-accent: var(--accent);
|
|
100
|
+
--color-muted-foreground: var(--muted-foreground);
|
|
101
|
+
--color-muted: var(--muted);
|
|
102
|
+
--color-secondary-foreground: var(--secondary-foreground);
|
|
103
|
+
--color-secondary: var(--secondary);
|
|
104
|
+
--color-primary-foreground: var(--primary-foreground);
|
|
105
|
+
--color-primary: var(--primary);
|
|
106
|
+
--color-popover-foreground: var(--popover-foreground);
|
|
107
|
+
--color-popover: var(--popover);
|
|
108
|
+
--color-card-foreground: var(--card-foreground);
|
|
109
|
+
--color-card: var(--card);
|
|
110
|
+
--color-foreground: var(--foreground);
|
|
111
|
+
--color-background: var(--background);
|
|
112
|
+
--radius-sm: calc(var(--radius) - 4px);
|
|
113
|
+
--radius-md: calc(var(--radius) - 2px);
|
|
114
|
+
--radius-lg: var(--radius);
|
|
115
|
+
--radius-xl: calc(var(--radius) + 4px);
|
|
116
|
+
--radius-2xl: calc(var(--radius) + 8px);
|
|
117
|
+
--radius-3xl: calc(var(--radius) + 12px);
|
|
118
|
+
--radius-4xl: calc(var(--radius) + 16px);
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
@layer base {
|
|
122
|
+
* {
|
|
123
|
+
@apply border-border outline-ring/50;
|
|
124
|
+
}
|
|
125
|
+
body {
|
|
126
|
+
@apply font-sans bg-background text-foreground;
|
|
127
|
+
}
|
|
128
|
+
html {
|
|
129
|
+
@apply font-sans;
|
|
130
|
+
}
|
|
131
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
+
<link rel="icon" href="/favicon.ico" />
|
|
7
|
+
<meta name="theme-color" content="#000000" />
|
|
8
|
+
</head>
|
|
9
|
+
<body>
|
|
10
|
+
<div id="app"></div>
|
|
11
|
+
<script type="module" src="/src/main.tsx"></script>
|
|
12
|
+
</body>
|
|
13
|
+
</html>
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "web",
|
|
3
|
+
"private": true,
|
|
4
|
+
"type": "module",
|
|
5
|
+
"scripts": {
|
|
6
|
+
"dev": "vite dev",
|
|
7
|
+
"build": "vite build",
|
|
8
|
+
"serve": "vite preview",
|
|
9
|
+
"test": "vitest run"
|
|
10
|
+
},
|
|
11
|
+
"dependencies": {
|
|
12
|
+
"@tailwindcss/vite": "^4.1.13",
|
|
13
|
+
"@tanstack/router-plugin": "^1.131.44",
|
|
14
|
+
"@tanstack/solid-form": "^1.20.0",
|
|
15
|
+
"@tanstack/solid-router": "^1.131.44",
|
|
16
|
+
"lucide-solid": "^0.544.0",
|
|
17
|
+
"solid-js": "^1.9.9",
|
|
18
|
+
"tailwindcss": "^4.1.13"
|
|
19
|
+
},
|
|
20
|
+
"devDependencies": {
|
|
21
|
+
"vite": "^7.1.5",
|
|
22
|
+
"vite-plugin-solid": "^2.11.8"
|
|
23
|
+
}
|
|
24
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { Link } from "@tanstack/solid-router";
|
|
2
|
+
{{#if (eq auth "better-auth")}}
|
|
3
|
+
import UserMenu from "./user-menu";
|
|
4
|
+
{{/if}}
|
|
5
|
+
import { For } from "solid-js";
|
|
6
|
+
|
|
7
|
+
export default function Header() {
|
|
8
|
+
const links = [
|
|
9
|
+
{ to: "/", label: "Home" },
|
|
10
|
+
{{#if (eq auth "better-auth")}}
|
|
11
|
+
{ to: "/dashboard", label: "Dashboard" },
|
|
12
|
+
{{/if}}
|
|
13
|
+
{{#if (includes examples "todo")}}
|
|
14
|
+
{ to: "/todos", label: "Todos" },
|
|
15
|
+
{{/if}}
|
|
16
|
+
{{#if (includes examples "ai")}}
|
|
17
|
+
{ to: "/ai", label: "AI Chat" },
|
|
18
|
+
{{/if}}
|
|
19
|
+
];
|
|
20
|
+
|
|
21
|
+
return (
|
|
22
|
+
<div>
|
|
23
|
+
<div class="flex flex-row items-center justify-between px-2 py-1">
|
|
24
|
+
<nav class="flex gap-4 text-lg">
|
|
25
|
+
<For each={links}>
|
|
26
|
+
{(link) => <Link to={link.to}>{link.label}</Link>}
|
|
27
|
+
</For>
|
|
28
|
+
</nav>
|
|
29
|
+
<div class="flex items-center gap-2">
|
|
30
|
+
{{#if (eq auth "better-auth")}}
|
|
31
|
+
<UserMenu />
|
|
32
|
+
{{/if}}
|
|
33
|
+
</div>
|
|
34
|
+
</div>
|
|
35
|
+
<hr />
|
|
36
|
+
</div>
|
|
37
|
+
);
|
|
38
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { RouterProvider, createRouter } from "@tanstack/solid-router";
|
|
2
|
+
import { render } from "solid-js/web";
|
|
3
|
+
import { routeTree } from "./routeTree.gen";
|
|
4
|
+
import "./styles.css";
|
|
5
|
+
{{#if (eq api "orpc")}}
|
|
6
|
+
import { QueryClientProvider } from "@tanstack/solid-query";
|
|
7
|
+
import { orpc, queryClient } from "./utils/orpc";
|
|
8
|
+
{{/if}}
|
|
9
|
+
|
|
10
|
+
const router = createRouter({
|
|
11
|
+
routeTree,
|
|
12
|
+
defaultPreload: "intent",
|
|
13
|
+
scrollRestoration: true,
|
|
14
|
+
defaultPreloadStaleTime: 0,
|
|
15
|
+
{{#if (eq api "orpc")}}
|
|
16
|
+
context: { orpc, queryClient },
|
|
17
|
+
{{/if}}
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
declare module "@tanstack/solid-router" {
|
|
21
|
+
interface Register {
|
|
22
|
+
router: typeof router;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
function App() {
|
|
27
|
+
return (
|
|
28
|
+
{{#if (eq api "orpc")}}
|
|
29
|
+
<QueryClientProvider client={queryClient}>
|
|
30
|
+
{{/if}}
|
|
31
|
+
<RouterProvider router={router} />
|
|
32
|
+
{{#if (eq api "orpc")}}
|
|
33
|
+
</QueryClientProvider>
|
|
34
|
+
{{/if}}
|
|
35
|
+
);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
const rootElement = document.getElementById("app");
|
|
39
|
+
if (rootElement) {
|
|
40
|
+
render(() => <App />, rootElement);
|
|
41
|
+
}
|