Skip to content

Commit 348b1da

Browse files
authored
Merge pull request #260 from ducflair/dev
docs: improve repo docs and website
2 parents 4a3272e + ec860e5 commit 348b1da

7 files changed

Lines changed: 121 additions & 78 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ This documentation aims to provide a comprehensive guide to the format's structu
4545

4646
## Contributing
4747

48-
We welcome contributions of all kinds. See [CONTRIBUTING.md](./CONTRIBUTING.md) for setup instructions (including the required Git LFS install) and commit message guidelines.
48+
We welcome contributions. See [CONTRIBUTING.md](./CONTRIBUTING.md) for setup instructions (including the required Git LFS install) and commit message guidelines.
4949

5050
## License
5151

apps/web/app/(home)/page.tsx

Lines changed: 67 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
import { Button } from '@/components/ui/button';
22
import { Icons } from '@/components/ui/icons';
33
import { HOMEPAGE_IMG } from '@/constants/images';
4-
import { GITHUB_URL, REDDIT_URL } from '@/constants/links';
4+
import { PLAYGROUND_URL } from '@/constants/links';
5+
import { DOCS } from '@/constants/routes';
56
import Link from 'next/link';
67

78
export default function HomePage() {
@@ -10,44 +11,91 @@ export default function HomePage() {
1011
<div className="max-w-4xl">
1112
<img src={HOMEPAGE_IMG} alt="Duc File Format" className="mb-8 mx-auto w-full md:w-auto bg-contain bg-center md:h-[400px]" />
1213
<p className="mb-8 text-lg px-24 text-fd-muted-foreground">
13-
An innovative and versatile format designed for precision in 2D CAD (computer-aided design),
14-
offering unprecedented levels of detail and flexibility.
14+
An open <strong>SQLite-backed</strong> 2D CAD file format, shipped with first-class
15+
libraries for <strong>Rust</strong>, <strong>Python</strong> and{' '}
16+
<strong>TypeScript</strong>
1517
</p>
16-
17-
<div className="flex justify-center gap-4 mb-12">
18-
<Link href="/docs">
18+
19+
<div className="flex justify-center gap-4 mb-12 flex-wrap">
20+
<Link href={DOCS}>
1921
<Button>
2022
Documentation
23+
<Icons.arrowRight className='size-4' />
2124
</Button>
2225
</Link>
23-
<Link href={REDDIT_URL} target="_blank" rel="noopener noreferrer">
26+
<Link href={PLAYGROUND_URL} target="_blank" rel="noopener noreferrer">
2427
<Button variant={"outline"}>
25-
<Icons.reddit className='size-4' />
26-
Ask on Reddit
28+
Playground
2729
<Icons.arrowUpRight className='size-4' />
2830
</Button>
2931
</Link>
3032
</div>
3133

3234
<div className="grid md:grid-cols-3 gap-6 text-left">
3335
<div className="p-6 rounded-lg bg-card border border-border">
34-
<h3 className="text-xl font-semibold mb-2">Structure Flexibility</h3>
35-
<p className="text-muted-foreground">JSON-based format enabling easy integration and future AI capabilities.</p>
36+
<h3 className="text-xl font-semibold mb-2">SQLite at the core</h3>
37+
<p className="text-muted-foreground">
38+
A <code className="text-sm">.duc</code> file is a zlib-compressed SQLite database.
39+
Query it directly, version it, or stream it, the same file works from a browser, a
40+
Python notebook, or a Rust service.
41+
</p>
3642
</div>
3743
<div className="p-6 rounded-lg bg-card border border-border">
38-
<h3 className="text-xl font-semibold mb-2">Dynamic Zoom</h3>
39-
<p className="text-muted-foreground">Fluid transition between different unit scopes, from macro to micro scales.</p>
44+
<h3 className="text-xl font-semibold mb-2">Dynamic scales</h3>
45+
<p className="text-muted-foreground">
46+
Fluid transition between unit scopes, from meters down to nanometers, in metric or
47+
imperial. At every level, 100 grid units resolve to a single measurement unit and
48+
each square holds an infinite density of points, so precision is never lost as you
49+
zoom between macro and micro.
50+
</p>
4051
</div>
4152
<div className="p-6 rounded-lg bg-card border border-border">
42-
<h3 className="text-xl font-semibold mb-2">Layered Design</h3>
43-
<p className="text-muted-foreground">Support for Notes, Loose, and Precise layers with unique properties.</p>
53+
<h3 className="text-xl font-semibold mb-2">Infinite canvas</h3>
54+
<p className="text-muted-foreground">
55+
A boundless geometric surface anchored at (0, 0) with free negative coordinates.
56+
Pan and zoom without limits, the same file stays usable from a quick sketch to a
57+
city-scale plan.
58+
</p>
4459
</div>
4560
</div>
4661

47-
<div className="mt-12 p-4 rounded-lg bg-secondary text-secondary-foreground">
48-
<p className="text-sm">
49-
This project is so amazing that we managed to build a headless CAD canvas component out of it, coming soon to a browser near you.
50-
</p>
62+
<div className="mt-12 grid md:grid-cols-3 gap-4 text-left">
63+
<Link
64+
href="https://crates.io/crates/duc"
65+
target="_blank"
66+
rel="noopener noreferrer"
67+
className="p-4 rounded-lg bg-secondary text-secondary-foreground flex items-center justify-between hover:opacity-80 transition-opacity"
68+
>
69+
<div>
70+
<div className="text-xs uppercase tracking-wide opacity-70">Rust</div>
71+
<div className="font-mono text-sm">duc</div>
72+
</div>
73+
<Icons.arrowUpRight className='size-4' />
74+
</Link>
75+
<Link
76+
href="https://pypi.org/project/ducpy/"
77+
target="_blank"
78+
rel="noopener noreferrer"
79+
className="p-4 rounded-lg bg-secondary text-secondary-foreground flex items-center justify-between hover:opacity-80 transition-opacity"
80+
>
81+
<div>
82+
<div className="text-xs uppercase tracking-wide opacity-70">Python</div>
83+
<div className="font-mono text-sm">ducpy</div>
84+
</div>
85+
<Icons.arrowUpRight className='size-4' />
86+
</Link>
87+
<Link
88+
href="https://www.npmjs.com/package/ducjs"
89+
target="_blank"
90+
rel="noopener noreferrer"
91+
className="p-4 rounded-lg bg-secondary text-secondary-foreground flex items-center justify-between hover:opacity-80 transition-opacity"
92+
>
93+
<div>
94+
<div className="text-xs uppercase tracking-wide opacity-70">TypeScript</div>
95+
<div className="font-mono text-sm">ducjs</div>
96+
</div>
97+
<Icons.arrowUpRight className='size-4' />
98+
</Link>
5199
</div>
52100
</div>
53101
</main>

apps/web/app/layout.config.tsx

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
1-
import type { BaseLayoutProps } from 'fumadocs-ui/layouts/shared';
2-
import { GITHUB_URL, PLAYGROUND_URL, REDDIT_URL } from '@/constants/links';
3-
import { BLOG, DOCS, HOME } from '@/constants/routes';
41
import { Icons } from '@/components/ui/icons';
5-
import Link from 'next/link';
2+
import { GITHUB_URL, PLAYGROUND_URL } from '@/constants/links';
3+
import { BLOG, DOCS } from '@/constants/routes';
4+
import type { BaseLayoutProps } from 'fumadocs-ui/layouts/shared';
65

76
export const siteName = 'Duc';
87
export const baseUrl = 'https://duc.ducflair.com';

apps/web/components/footer.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1+
import { ThemeToggle } from "@/components/theme-toggle";
2+
import { FORUM_URL, GITHUB_URL } from "@/constants/links";
13
import { BLOG, DOCS, HOME } from "@/constants/routes";
2-
import { GITHUB_URL, REDDIT_URL } from "@/constants/links";
34
import Link from "next/link";
4-
import { ThemeToggle } from "@/components/theme-toggle";
55

66
const links = [{
77
title: 'Home',
@@ -16,8 +16,8 @@ const links = [{
1616
title: 'GitHub',
1717
href: GITHUB_URL
1818
}, {
19-
title: 'Reddit',
20-
href: REDDIT_URL
19+
title: 'Forum',
20+
href: FORUM_URL
2121
}];
2222
const currentYear = new Date().getFullYear();
2323

apps/web/components/navbar.tsx

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
import { GITHUB_URL, REDDIT_URL } from '@/constants/links';
2-
import { BLOG, DOCS, HOME } from '@/constants/routes';
1+
import { siteName } from '@/app/layout.config';
2+
import { Button } from '@/components/ui/button';
33
import { Icons } from '@/components/ui/icons';
4+
import { GITHUB_URL } from '@/constants/links';
5+
import { BLOG, DOCS, HOME } from '@/constants/routes';
46
import Link from 'next/link';
5-
import { Button } from '@/components/ui/button';
6-
import { siteName } from '@/app/layout.config';
77

88
function Navbar() {
99
return (
@@ -29,11 +29,6 @@ function Navbar() {
2929
<Icons.gitHub className='size-5!' />
3030
</Button>
3131
</Link>
32-
<Link href={REDDIT_URL}>
33-
<Button variant='ghost' size='sm'>
34-
<Icons.reddit className='size-5!' />
35-
</Button>
36-
</Link>
3732
</div>
3833
</div>
3934
)

apps/web/constants/links.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
export const GITHUB_URL = "https://github.com/ducflair/duc"
22
export const REDDIT_URL = "https://reddit.com/r/duc_"
3+
export const FORUM_URL = "https://help.ducflair.com/c/duc"
34
export const PLAYGROUND_URL = "https://scopture.com"

package.json

Lines changed: 41 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,46 @@
11
{
22
"name": "duc-monorepo",
33
"version": "0.0.0-development",
4+
"description": "",
5+
"packageManager": "bun@1.1.24",
6+
"private": true,
7+
"engines": {
8+
"node": ">=20"
9+
},
10+
"scripts": {
11+
"build": "turbo build",
12+
"packages:build": "turbo build --filter=ducjs --filter=ducpy --filter=ducrs --filter=ducsvg --filter=ducpdf",
13+
"packages:test": "turbo test --filter=ducjs --filter=ducpy --filter=ducrs --filter=ducsvg --filter=ducpdf",
14+
"sst:shell": "bash -c 'CMD=\"$1\"; shift; [ -n \"$1\" ] && [ \"$1\" != \"_\" ] && export SST_STAGE=\"$1\"; eval \"$CMD\"' _",
15+
"clean": "bun del-cli \"**/dist\" \".turbo\" \"**/node_modules\" \"**/package-lock.json\" \"**/tsconfig.tsbuildinfo\" \"**/tsconfig.node.tsbuildinfo\" \"**/vite.config.js\"",
16+
"docs:dev": "turbo dev --filter=@duc/docs",
17+
"docs:build": "turbo build --filter=@duc/docs",
18+
"ducpy:docs:dev": "turbo run dev:docs --filter=ducpy",
19+
"ducpy:docs:build": "turbo run gen:docs --filter=ducpy",
20+
"ducpy:test": "turbo run test --filter=ducpy --force",
21+
"ducpy:build": "bun turbo run build --filter=ducpy -- ${1}",
22+
"ducrs:build": "turbo build --filter=ducrs",
23+
"ducrs:test": "turbo run test --filter=ducrs",
24+
"ducjs:build": "turbo build --filter=ducjs",
25+
"ducjs:test": "turbo run test --filter=ducjs",
26+
"ducsvg:build": "turbo build --filter=ducsvg",
27+
"ducsvg:test": "turbo run test --filter=ducsvg",
28+
"ducpdf:build": "turbo build --filter=ducpdf",
29+
"ducpdf:test": "turbo run test --filter=ducpdf",
30+
"duc2pdf:build": "turbo build --filter=duc2pdf",
31+
"duc2pdf:test": "turbo run test --filter=duc2pdf",
32+
"semantic-release": "turbo run semantic-release",
33+
"sst:deploy": "bun sst:shell 'bun run sst:clean && sst unlock && sst refresh && sst deploy'",
34+
"sst:clean": "bun del-cli \".sst\" \"**/sst-env.d.ts\" \"**/sst.pyi\"",
35+
"sst:dev": "bun run sst dev",
36+
"knip:deps": "bun sst:shell 'bun run sst unlock && sst shell -- bunx knip --dependencies'",
37+
"knip": "bun sst:shell 'bun run sst unlock && sst shell -- bunx knip'"
38+
},
39+
"workspaces": [
40+
"apps/*",
41+
"packages/*",
42+
"packages/ducpdf/src/duc2pdf"
43+
],
444
"devDependencies": {
545
"@semantic-release/changelog": "^6.0.3",
646
"@semantic-release/commit-analyzer": "^13.0.1",
@@ -41,45 +81,5 @@
4181
"tailwind-merge": "^3.4.0",
4282
"tw-animate-css": "^1.4.0",
4383
"zod": "^3.25.76"
44-
},
45-
"engines": {
46-
"node": ">=20"
47-
},
48-
"description": "",
49-
"packageManager": "bun@1.1.24",
50-
"private": true,
51-
"scripts": {
52-
"build": "turbo build",
53-
"packages:build": "turbo build --filter=ducjs --filter=ducpy --filter=ducrs --filter=ducsvg --filter=ducpdf",
54-
"packages:test": "turbo test --filter=ducjs --filter=ducpy --filter=ducrs --filter=ducsvg --filter=ducpdf",
55-
"sst:shell": "bash -c 'CMD=\"$1\"; shift; [ -n \"$1\" ] && [ \"$1\" != \"_\" ] && export SST_STAGE=\"$1\"; eval \"$CMD\"' _",
56-
"clean": "bun del-cli \"**/dist\" \".turbo\" \"**/node_modules\" \"**/package-lock.json\" \"**/tsconfig.tsbuildinfo\" \"**/tsconfig.node.tsbuildinfo\" \"**/vite.config.js\"",
57-
"docs:dev": "turbo dev --filter=@duc/docs",
58-
"docs:build": "turbo build --filter=@duc/docs",
59-
"ducpy:docs:dev": "turbo run dev:docs --filter=ducpy",
60-
"ducpy:docs:build": "turbo run gen:docs --filter=ducpy",
61-
"ducpy:test": "turbo run test --filter=ducpy --force",
62-
"ducpy:build": "bun turbo run build --filter=ducpy -- ${1}",
63-
"ducrs:build": "turbo build --filter=ducrs",
64-
"ducrs:test": "turbo run test --filter=ducrs",
65-
"ducjs:build": "turbo build --filter=ducjs",
66-
"ducjs:test": "turbo run test --filter=ducjs",
67-
"ducsvg:build": "turbo build --filter=ducsvg",
68-
"ducsvg:test": "turbo run test --filter=ducsvg",
69-
"ducpdf:build": "turbo build --filter=ducpdf",
70-
"ducpdf:test": "turbo run test --filter=ducpdf",
71-
"duc2pdf:build": "turbo build --filter=duc2pdf",
72-
"duc2pdf:test": "turbo run test --filter=duc2pdf",
73-
"semantic-release": "turbo run semantic-release",
74-
"sst:deploy": "bun sst:shell 'bun run sst:clean && sst unlock && sst refresh && sst deploy'",
75-
"sst:clean": "bun del-cli \".sst\" \"**/sst-env.d.ts\" \"**/sst.pyi\"",
76-
"sst:dev": "bun run sst dev",
77-
"knip:deps": "bun sst:shell 'bun run sst unlock && sst shell -- bunx knip --dependencies'",
78-
"knip": "bun sst:shell 'bun run sst unlock && sst shell -- bunx knip'"
79-
},
80-
"workspaces": [
81-
"apps/*",
82-
"packages/*",
83-
"packages/ducpdf/src/duc2pdf"
84-
]
84+
}
8585
}

0 commit comments

Comments
 (0)