Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 4 additions & 0 deletions apps/docs/.gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
test-results
.DS_Store
node_modules
/build
Expand All @@ -8,3 +9,6 @@ node_modules
!.env.example
vite.config.js.timestamp-*
vite.config.ts.timestamp-*

# Paraglide
src/lib/paraglide
4 changes: 3 additions & 1 deletion apps/docs/.prettierrc
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,7 @@
"endOfLine": "lf",
"jsxSingleQuote": false,
"bracketSameLine": false,
"quoteProps": "as-needed"
"quoteProps": "as-needed",
"plugins": ["prettier-plugin-tailwindcss"],
"tailwindStylesheet": "./src/app.css"
}
16 changes: 16 additions & 0 deletions apps/docs/components.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"$schema": "https://shadcn-svelte.com/schema.json",
"tailwind": {
"css": "src/app.css",
"baseColor": "slate"
},
"aliases": {
"components": "$lib/components",
"utils": "$lib/utils",
"ui": "$lib/components/ui",
"hooks": "$lib/hooks",
"lib": "$lib"
},
"typescript": true,
"registry": "https://shadcn-svelte.com/registry"
}
6 changes: 6 additions & 0 deletions apps/docs/e2e/demo.test.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
import { expect, test } from "@playwright/test";

test("home page has expected h1", async ({ page }) => {
await page.goto("/");
await expect(page.locator("h1")).toBeVisible();
});
4 changes: 4 additions & 0 deletions apps/docs/messages/de.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"$schema": "https://inlang.com/schema/inlang-message-format",
"hello_world": "Hello, {name} from de!"
}
4 changes: 4 additions & 0 deletions apps/docs/messages/en.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"$schema": "https://inlang.com/schema/inlang-message-format",
"hello_world": "Hello, {name} from en!"
}
104 changes: 69 additions & 35 deletions apps/docs/package.json
Original file line number Diff line number Diff line change
@@ -1,37 +1,71 @@
{
"name": "docs",
"version": "0.0.1",
"private": true,
"type": "module",
"scripts": {
"dev": "vite dev",
"build": "svelte-kit sync && vite build",
"preview": "vite preview",
"test": "npm run test:integration && npm run test:unit",
"check-types": "tsc --noEmit",
"check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json",
"check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch",
"lint": "eslint .",
"test:integration": "playwright test",
"test:unit": "vitest"
},
"dependencies": {
"@repo/ui": "workspace:*"
},
"devDependencies": {
"@repo/eslint-config": "workspace:*",
"@repo/typescript-config": "workspace:*",
"@sveltejs/adapter-auto": "^4.0.0",
"@sveltejs/kit": "^2.36.1",
"@sveltejs/vite-plugin-svelte": "^5.1.0",
"prettier": "^3.6.0",
"eslint": "^9.34.0",
"prettier-plugin-svelte": "^3.4.0",
"svelte": "^5.38.0",
"svelte-check": "^4.3.0",
"tslib": "^2.8.1",
"typescript": "5.9.2",
"vite": "^6.3.2",
"vitest": "^3.2.0"
}
"name": "docs",
"version": "0.0.1",
"type": "module",
"scripts": {
"dev": "vite dev",
"build": "svelte-kit sync && vite build",
"preview": "vite preview",
"test": "npm run test:integration && npm run test:unit && npm run test:e2e && npm run test:unit -- --run",
"check-types": "tsc --noEmit",
"check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json",
"check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch",
"lint": "eslint .",
"test:integration": "playwright test",
"test:unit": "vitest",
"test:e2e": "playwright test"
},
"devDependencies": {
"@inlang/paraglide-js": "^2.0.0",
"@internationalized/date": "^3.9.0",
"@lucide/svelte": "^0.544.0",
"@playwright/test": "^1.49.1",
"@repo/eslint-config": "workspace:*",
"@repo/typescript-config": "workspace:*",
"@shikijs/langs": "^3.13.0",
"@shikijs/themes": "^3.13.0",
"@sveltejs/adapter-node": "^5.2.12",
"@sveltejs/kit": "^2.36.1",
"@sveltejs/vite-plugin-svelte": "^5.1.0",
"@tailwindcss/forms": "^0.5.9",
"@tailwindcss/typography": "^0.5.15",
"@tailwindcss/vite": "^4.0.0",
"@tanstack/table-core": "^8.21.3",
"@vitest/browser": "^3.2.3",
"bits-ui": "^2.11.0",
"clsx": "^2.1.1",
"embla-carousel-svelte": "^8.6.0",
"eslint": "^9.34.0",
"formsnap": "^2.0.1",
"isomorphic-dompurify": "^2.28.0",
"layerchart": "2.0.0-next.27",
"mdsvex": "^0.12.3",
"mode-watcher": "^1.1.0",
"paneforge": "^1.0.2",
"playwright": "^1.53.0",
"prettier": "^3.6.0",
"prettier-plugin-svelte": "^3.4.0",
"prettier-plugin-tailwindcss": "^0.6.11",
"runed": "^0.31.1",
"shiki": "^3.13.0",
"svelte": "^5.38.0",
"svelte-check": "^4.3.0",
"svelte-sonner": "^1.0.5",
"svelte-toolbelt": "^0.9.3",
"sveltekit-superforms": "^2.27.1",
"tailwind-merge": "^3.3.1",
"tailwind-variants": "^3.1.1",
"tailwindcss": "^4.0.0",
"tslib": "^2.8.1",
"tw-animate-css": "^1.3.8",
"typescript": "5.9.2",
"vaul-svelte": "1.0.0-next.7",
"vite": "^6.3.2",
"vite-plugin-devtools-json": "^1.0.0",
"vitest": "^3.2.3",
"vitest-browser-svelte": "^0.1.0"
},
"dependencies": {
"marked": "^12.0.2"
}
}
14 changes: 7 additions & 7 deletions apps/docs/playwright.config.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import type { PlaywrightTestConfig } from '@playwright/test';
import type { PlaywrightTestConfig } from "@playwright/test";

const config: PlaywrightTestConfig = {
webServer: {
command: 'npm run build && npm run preview',
port: 4173
},
testDir: 'tests',
testMatch: /(.+\.)?(test|spec)\.[jt]s/
webServer: {
command: "npm run build && npm run preview",
port: 4173
},
testDir: "e2e",
testMatch: /(.+\.)?(test|spec)\.[jt]s/
};

export default config;
1 change: 1 addition & 0 deletions apps/docs/project.inlang/cache/plugins/2sy648wh9sugi

Large diffs are not rendered by default.

16 changes: 16 additions & 0 deletions apps/docs/project.inlang/cache/plugins/ygx0uiahq6uw

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions apps/docs/project.inlang/project_id
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ppKjPEXEl4r1KIqH6g
12 changes: 12 additions & 0 deletions apps/docs/project.inlang/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"$schema": "https://inlang.com/schema/project-settings",
"modules": [
"https://cdn.jsdelivr.net/npm/@inlang/plugin-message-format@4/dist/index.js",
"https://cdn.jsdelivr.net/npm/@inlang/plugin-m-function-matcher@2/dist/index.js"
],
"plugin.inlang.messageFormat": {
"pathPattern": "./messages/{locale}.json"
},
"baseLocale": "en",
"locales": ["en", "de"]
}
175 changes: 175 additions & 0 deletions apps/docs/src/app.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,175 @@
@import "tailwindcss";

@import "tw-animate-css";

@plugin "@tailwindcss/typography";

@custom-variant dark (&:is(.dark *));


:root {
--radius: 0.65rem;
--background: oklch(1 0 0);
--foreground: oklch(0.141 0.005 285.823);
--card: oklch(1 0 0);
--card-foreground: oklch(0.141 0.005 285.823);
--popover: oklch(1 0 0);
--popover-foreground: oklch(0.141 0.005 285.823);
--primary: oklch(0.705 0.213 47.604);
--primary-foreground: oklch(0.98 0.016 73.684);
--secondary: oklch(0.967 0.001 286.375);
--secondary-foreground: oklch(0.21 0.006 285.885);
--muted: oklch(0.967 0.001 286.375);
--muted-foreground: oklch(0.552 0.016 285.938);
--accent: oklch(0.967 0.001 286.375);
--accent-foreground: oklch(0.21 0.006 285.885);
--destructive: oklch(0.577 0.245 27.325);
--border: oklch(0.92 0.004 286.32);
--input: oklch(0.92 0.004 286.32);
--ring: oklch(0.705 0.213 47.604);
--chart-1: oklch(0.646 0.222 41.116);
--chart-2: oklch(0.6 0.118 184.704);
--chart-3: oklch(0.398 0.07 227.392);
--chart-4: oklch(0.828 0.189 84.429);
--chart-5: oklch(0.769 0.188 70.08);
--sidebar: oklch(0.985 0 0);
--sidebar-foreground: oklch(0.141 0.005 285.823);
--sidebar-primary: oklch(0.705 0.213 47.604);
--sidebar-primary-foreground: oklch(0.98 0.016 73.684);
--sidebar-accent: oklch(0.967 0.001 286.375);
--sidebar-accent-foreground: oklch(0.21 0.006 285.885);
--sidebar-border: oklch(0.92 0.004 286.32);
--sidebar-ring: oklch(0.705 0.213 47.604);
}

.dark {
--background: oklch(0.141 0.005 285.823);
--foreground: oklch(0.985 0 0);
--card: oklch(0.21 0.006 285.885);
--card-foreground: oklch(0.985 0 0);
--popover: oklch(0.21 0.006 285.885);
--popover-foreground: oklch(0.985 0 0);
--primary: oklch(0.646 0.222 41.116);
--primary-foreground: oklch(0.98 0.016 73.684);
--secondary: oklch(0.274 0.006 286.033);
--secondary-foreground: oklch(0.985 0 0);
--muted: oklch(0.274 0.006 286.033);
--muted-foreground: oklch(0.705 0.015 286.067);
--accent: oklch(0.274 0.006 286.033);
--accent-foreground: oklch(0.985 0 0);
--destructive: oklch(0.704 0.191 22.216);
--border: oklch(1 0 0 / 10%);
--input: oklch(1 0 0 / 15%);
--ring: oklch(0.646 0.222 41.116);
--chart-1: oklch(0.488 0.243 264.376);
--chart-2: oklch(0.696 0.17 162.48);
--chart-3: oklch(0.769 0.188 70.08);
--chart-4: oklch(0.627 0.265 303.9);
--chart-5: oklch(0.645 0.246 16.439);
--sidebar: oklch(0.21 0.006 285.885);
--sidebar-foreground: oklch(0.985 0 0);
--sidebar-primary: oklch(0.646 0.222 41.116);
--sidebar-primary-foreground: oklch(0.98 0.016 73.684);
--sidebar-accent: oklch(0.274 0.006 286.033);
--sidebar-accent-foreground: oklch(0.985 0 0);
--sidebar-border: oklch(1 0 0 / 10%);
--sidebar-ring: oklch(0.646 0.222 41.116);
}

@theme inline {
--radius-sm: calc(var(--radius) - 4px);
--radius-md: calc(var(--radius) - 2px);
--radius-lg: var(--radius);
--radius-xl: calc(var(--radius) + 4px);
--color-background: var(--background);
--color-foreground: var(--foreground);
--color-card: var(--card);
--color-card-foreground: var(--card-foreground);
--color-popover: var(--popover);
--color-popover-foreground: var(--popover-foreground);
--color-primary: var(--primary);
--color-primary-foreground: var(--primary-foreground);
--color-secondary: var(--secondary);
--color-secondary-foreground: var(--secondary-foreground);
--color-muted: var(--muted);
--color-muted-foreground: var(--muted-foreground);
--color-accent: var(--accent);
--color-accent-foreground: var(--accent-foreground);
--color-destructive: var(--destructive);
--color-border: var(--border);
--color-input: var(--input);
--color-ring: var(--ring);
--color-chart-1: var(--chart-1);
--color-chart-2: var(--chart-2);
--color-chart-3: var(--chart-3);
--color-chart-4: var(--chart-4);
--color-chart-5: var(--chart-5);
--color-sidebar: var(--sidebar);
--color-sidebar-foreground: var(--sidebar-foreground);
--color-sidebar-primary: var(--sidebar-primary);
--color-sidebar-primary-foreground: var(--sidebar-primary-foreground);
--color-sidebar-accent: var(--sidebar-accent);
--color-sidebar-accent-foreground: var(--sidebar-accent-foreground);
--color-sidebar-border: var(--sidebar-border);
--color-sidebar-ring: var(--sidebar-ring);
}

@layer base {
* {
@apply border-border outline-ring/50;
}
body {
@apply bg-background text-foreground;
}
}

@layer utilities {
/* Docs typography overrides */
.prose {
--tw-prose-body: var(--foreground);
--tw-prose-headings: var(--foreground);
--tw-prose-bold: var(--foreground);
--tw-prose-links: color-mix(in oklch, var(--primary) 85%, black);
--tw-prose-counters: var(--muted-foreground);
--tw-prose-bullets: var(--muted-foreground);
--tw-prose-hr: var(--border);
--tw-prose-quotes: var(--foreground);
--tw-prose-quote-borders: var(--border);
--tw-prose-captions: var(--muted-foreground);
--tw-prose-code: var(--foreground);
--tw-prose-th-borders: var(--border);
--tw-prose-td-borders: var(--border);
}

.prose :where(h1,h2,h3,h4){
@apply scroll-mt-20 font-semibold tracking-tight;
}
.prose :where(h1){ @apply text-3xl md:text-4xl mb-4; }
.prose :where(h2){ @apply text-2xl md:text-3xl mt-10 mb-3; }
.prose :where(h3){ @apply text-xl md:text-2xl mt-8 mb-2; }
.prose :where(h4){ @apply text-lg md:text-xl mt-6 mb-2; }

.prose :where(p){ @apply leading-7; }
.prose :where(ul,ol){ @apply my-4 pl-6; }
.prose :where(li){ @apply my-1; }
.prose :where(blockquote){ @apply border-l-4 border-border pl-4 italic text-muted-foreground; }
.prose :where(hr){ @apply my-8 border-border; }

/* Links */
.prose :where(a){ @apply text-primary underline decoration-from-font underline-offset-4 hover:opacity-90; }

/* Code blocks */
.prose :where(code){ @apply rounded bg-muted/60 px-1.5 py-0.5 text-sm; }
.prose :where(pre){
@apply my-6 overflow-x-auto rounded-lg bg-muted/60 p-4 text-sm leading-6 shadow-sm;
}
.prose :where(pre code){ @apply bg-transparent p-0; }

/* Tables */
.prose :where(table){ @apply w-full table-auto border-collapse text-sm my-6; }
.prose :where(th){ @apply bg-muted/50 px-3 py-2 text-left font-medium; }
.prose :where(td){ @apply border-t border-border px-3 py-2 align-top; }

/* Images */
.prose :where(img){ @apply my-4 rounded-lg border border-border; }
}
22 changes: 11 additions & 11 deletions apps/docs/src/app.html
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<link rel="icon" href="%sveltekit.assets%/favicon.png" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
%sveltekit.head%
</head>
<body data-sveltekit-preload-data="hover">
<div style="display: contents">%sveltekit.body%</div>
</body>
<!doctype html>
<html lang="%paraglide.lang%">
<head>
<meta charset="utf-8" />
<link rel="icon" href="%sveltekit.assets%/favicon.png" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
%sveltekit.head%
</head>
<body data-sveltekit-preload-data="hover">
<div style="display: contents">%sveltekit.body%</div>
</body>
</html>
Loading