Compare commits
81 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 87c9c3a151 | |||
| ddd6fd96b8 | |||
| 944311cba1 | |||
| bc0c3c1a1b | |||
| 23e0571b2c | |||
| 24c2c2ad5f | |||
| 1b056f0f01 | |||
| 13503d4c19 | |||
| a9a719f1ef | |||
| e4639054e7 | |||
| 264629ed47 | |||
| 5428122609 | |||
| 8d3306ea1f | |||
| b64a779619 | |||
| 975dcfe023 | |||
| 74ba94b66f | |||
| 580fa9ecc3 | |||
| 27e6765a43 | |||
| 9de7c4d8ae | |||
| a98bed0da7 | |||
| e876035fc6 | |||
| f4fd3a8607 | |||
| 83c644d2bf | |||
| 1d4eb97d98 | |||
| a7302326f2 | |||
| 72931c5220 | |||
| b848eabdf3 | |||
| cd2913d6f7 | |||
| ec6da1d383 | |||
| ccc6da2e8c | |||
| 39933d3c74 | |||
| 5ee037a7c3 | |||
| d97b889455 | |||
| 65d160af3b | |||
| 837c4448b0 | |||
| db650b3ea6 | |||
| 76afc98890 | |||
| 8d46a01a10 | |||
| 7a6d664c42 | |||
| 70830478d9 | |||
| c575b7e7a7 | |||
| ec7f1f8a14 | |||
| 24f6c797f2 | |||
| a2885a3283 | |||
| 0143f1e465 | |||
| dc57f9af20 | |||
| 984ede7d55 | |||
| fc398bd1f9 | |||
| 75faf3efaa | |||
| 4f5dd1f399 | |||
| 033ae23b7c | |||
| a0be70d5a6 | |||
| ef29427877 | |||
| 2af0155e6a | |||
| 8130c5cc68 | |||
| 67d23a229f | |||
| 6c9515c385 | |||
| d4f12f6773 | |||
| 65a70996c4 | |||
| 2b8443a1b1 | |||
| c169058915 | |||
| 4c2003d05e | |||
| 42bb758383 | |||
| 26dab9b26b | |||
| d1a4129323 | |||
| a283ddf457 | |||
| b172762288 | |||
| b3da7e84d8 | |||
| 96989be616 | |||
| 9514f15073 | |||
| 1a57eccd38 | |||
| fdfd82207d | |||
| 6e32acfeff | |||
| 999e9cbc36 | |||
| c71f9f3dc2 | |||
| d3e0351d05 | |||
| 4108ecdce9 | |||
| 4bf3e2a1df | |||
| e9da5eeba5 | |||
| d934f4ca89 | |||
| 5b54f9a7be |
@@ -1,4 +1,4 @@
|
||||
# Upstream (michaelshimeles/paper-rs) carries no ArtCraft/Discord branding; keep it that way. Run: perl tools/craft-skills/skills/debrand/debrand.pl --check .
|
||||
# The tree carries no ArtCraft/Discord branding; keep it that way. Run: perl tools/craft-skills/skills/debrand/debrand.pl --check .
|
||||
keep ^(LICENSE-(MIT|APACHE)|\.debrand)$
|
||||
forbid (?i)artcraft
|
||||
forbid (?i)discord
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
* @nxtime
|
||||
@@ -0,0 +1,19 @@
|
||||
---
|
||||
name: Bug report
|
||||
about: Something does not work as expected
|
||||
labels: bug
|
||||
---
|
||||
|
||||
**What happened**
|
||||
|
||||
**What you expected**
|
||||
|
||||
**Steps to reproduce**
|
||||
1.
|
||||
2.
|
||||
|
||||
**Version and platform**
|
||||
PaperCraft version (the release you installed), OS, and the GPU if it is a rendering problem.
|
||||
|
||||
**Screenshot, recording or project**
|
||||
Attach one if you can. Remove anything private first.
|
||||
@@ -0,0 +1,5 @@
|
||||
blank_issues_enabled: true
|
||||
contact_links:
|
||||
- name: Security vulnerability
|
||||
url: https://github.com/nxtime/papercraft/security/advisories/new
|
||||
about: Report security problems privately, not as an issue.
|
||||
@@ -0,0 +1,14 @@
|
||||
---
|
||||
name: Feature request
|
||||
about: Suggest an idea or a missing capability
|
||||
labels: enhancement
|
||||
---
|
||||
|
||||
**The problem**
|
||||
What are you trying to do, and what gets in the way?
|
||||
|
||||
**What you would like**
|
||||
|
||||
**Alternatives you considered**
|
||||
|
||||
**Is it already in ROADMAP.md?**
|
||||
@@ -0,0 +1,24 @@
|
||||
## What and why
|
||||
|
||||
<!-- What changed, and the problem it solves. Link the issue: Fixes #123 -->
|
||||
|
||||
## How I tested it
|
||||
|
||||
<!-- Tests added, commands run, platforms tried. -->
|
||||
|
||||
## AI assistance
|
||||
|
||||
<!-- Which tool helped and how much, or "none". See AI_POLICY.md. You must understand every line. -->
|
||||
|
||||
## Screenshots
|
||||
|
||||
<!-- For UI changes: before and after, at scale 2, in each theme. -->
|
||||
|
||||
## Checklist
|
||||
|
||||
- [ ] Tests first; new code is covered, error paths included
|
||||
- [ ] `cargo fmt --all`, `cargo clippy --all-targets` and the affected `cargo test --test` targets pass
|
||||
- [ ] Follows [RULES.md](../RULES.md) (no overflow, data safety, one undo step per tool call)
|
||||
- [ ] Docs, tool descriptions and `PROGRESS.md` updated where needed
|
||||
- [ ] Conventional commit messages
|
||||
- [ ] I read and understand every line of this change (AI-assisted or not)
|
||||
@@ -0,0 +1,101 @@
|
||||
# Builds Windows, macOS and Linux on GitHub's runners when a v* tag is pushed, then publishes a
|
||||
# GitHub release with the files once the full test suite (test.yml) passes, then refreshes the
|
||||
# landing page (site.yml). Gitea reads .github/workflows too, so every job is gated on the
|
||||
# server URL: this pipeline only ever runs on github.com.
|
||||
name: release
|
||||
|
||||
on:
|
||||
push:
|
||||
tags: ["v*"]
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
tag:
|
||||
description: Existing tag to build and release (e.g. v0.8.4)
|
||||
required: true
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
env:
|
||||
CARGO_TERM_COLOR: always
|
||||
TAG: ${{ inputs.tag || github.ref_name }}
|
||||
|
||||
jobs:
|
||||
test:
|
||||
uses: ./.github/workflows/test.yml
|
||||
with: { ref: "${{ inputs.tag || github.ref }}" }
|
||||
|
||||
windows:
|
||||
if: github.server_url == 'https://github.com'
|
||||
runs-on: windows-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with: { ref: "${{ inputs.tag || github.ref }}" }
|
||||
- uses: dtolnay/rust-toolchain@stable
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
- name: Build and zip
|
||||
shell: pwsh
|
||||
run: |
|
||||
cargo build --release --locked --bins
|
||||
$v = $env:TAG.TrimStart('v')
|
||||
New-Item -ItemType Directory -Force dist | Out-Null
|
||||
$exes = 'papercraft','papercraft-cli','papercraft-mcp','papercraft-relay' | ForEach-Object { "target/release/$_.exe" }
|
||||
Compress-Archive -Path $exes -DestinationPath "dist/papercraft-$v-windows-x86_64.zip"
|
||||
- uses: actions/upload-artifact@v4
|
||||
with: { name: windows, path: dist/* }
|
||||
|
||||
macos:
|
||||
if: github.server_url == 'https://github.com'
|
||||
runs-on: macos-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with: { ref: "${{ inputs.tag || github.ref }}" }
|
||||
- uses: dtolnay/rust-toolchain@stable
|
||||
with: { targets: aarch64-apple-darwin }
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
- name: Package (Apple silicon, ad-hoc signed, not notarized)
|
||||
run: packaging/macos/package.sh --arch aarch64
|
||||
- uses: actions/upload-artifact@v4
|
||||
with: { name: macos, path: dist/release/* }
|
||||
|
||||
linux:
|
||||
if: github.server_url == 'https://github.com'
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with: { ref: "${{ inputs.tag || github.ref }}" }
|
||||
- uses: dtolnay/rust-toolchain@stable
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
- name: Build dependencies
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y pkg-config libssl-dev libxkbcommon-x11-dev libxcb-xkb-dev libx11-xcb-dev libwayland-dev libvulkan-dev libdbus-1-dev
|
||||
- name: Build and tar
|
||||
run: |
|
||||
cargo build --release --locked --bins
|
||||
v="${TAG#v}"
|
||||
mkdir -p dist stage
|
||||
cp target/release/papercraft target/release/papercraft-cli target/release/papercraft-mcp target/release/papercraft-relay stage/
|
||||
tar -C stage -czf "dist/papercraft-$v-linux-x86_64.tar.gz" .
|
||||
tar -C stage -czf "dist/papercraft-cli-$v-linux-x86_64.tar.gz" papercraft-cli papercraft-mcp
|
||||
- uses: actions/upload-artifact@v4
|
||||
with: { name: linux, path: dist/* }
|
||||
|
||||
publish:
|
||||
if: github.server_url == 'https://github.com'
|
||||
needs: [test, windows, macos, linux]
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/download-artifact@v4
|
||||
with: { path: files, merge-multiple: true }
|
||||
- name: Create the release
|
||||
env:
|
||||
GH_TOKEN: ${{ github.token }}
|
||||
run: |
|
||||
gh release create "$TAG" files/* --repo "$GITHUB_REPOSITORY" --title "PaperCraft ${TAG#v}" \
|
||||
--generate-notes --verify-tag || gh release upload "$TAG" files/* --repo "$GITHUB_REPOSITORY" --clobber
|
||||
|
||||
site:
|
||||
if: github.server_url == 'https://github.com'
|
||||
needs: publish
|
||||
uses: ./.github/workflows/site.yml
|
||||
@@ -0,0 +1,69 @@
|
||||
# Builds the landing page (site/) with the latest GitHub release and commits it to the `pages`
|
||||
# branch, which GitHub Pages serves (Settings → Pages → Deploy from a branch → pages, / (root)).
|
||||
# release.yml calls it after publishing, a daily run catches releases made by hand, and pushes to
|
||||
# the page's sources rebuild it. Nothing is committed when the result is unchanged. Gitea reads
|
||||
# .github/workflows too, so the job is gated on the server URL.
|
||||
name: site
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: "23 5 * * *"
|
||||
push:
|
||||
branches: [main]
|
||||
paths:
|
||||
- site/**
|
||||
- docs/demo.mp4
|
||||
- docs/screenshots/readme/**
|
||||
- assets/app-icon/papercraft.svg
|
||||
- assets/agents/**
|
||||
- .github/workflows/site.yml
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
concurrency:
|
||||
group: site
|
||||
cancel-in-progress: false
|
||||
|
||||
jobs:
|
||||
publish:
|
||||
if: github.server_url == 'https://github.com'
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
# The page comes from the default branch even when a release tag calls this workflow.
|
||||
- uses: actions/checkout@v4
|
||||
with: { ref: "${{ github.event.repository.default_branch }}" }
|
||||
- name: Install ffmpeg
|
||||
run: sudo apt-get update && sudo apt-get install -y --no-install-recommends ffmpeg
|
||||
- name: Check out the pages branch
|
||||
run: |
|
||||
echo "PAGES=$RUNNER_TEMP/pages" >> "$GITHUB_ENV"
|
||||
PAGES="$RUNNER_TEMP/pages"
|
||||
if git ls-remote --exit-code --heads origin pages > /dev/null; then
|
||||
git fetch --depth 1 origin pages:refs/remotes/origin/pages
|
||||
git worktree add --detach "$PAGES" origin/pages
|
||||
else
|
||||
git worktree add --orphan -b pages "$PAGES"
|
||||
fi
|
||||
- name: Build
|
||||
env:
|
||||
GH_TOKEN: ${{ github.token }}
|
||||
run: sh site/build.sh dist/site "$PAGES"
|
||||
- name: Commit and push
|
||||
run: |
|
||||
cd "${PAGES:?}"
|
||||
# Clearing through git drops files the new build no longer has, and only tracked ones.
|
||||
git rm -rqf --ignore-unmatch .
|
||||
cp -a "$GITHUB_WORKSPACE/dist/site/." .
|
||||
git add -A
|
||||
if git diff --cached --quiet; then
|
||||
echo "The page is already up to date."
|
||||
exit 0
|
||||
fi
|
||||
tag="$(jq -r .tag release.json)"
|
||||
git -c user.name="github-actions[bot]" \
|
||||
-c user.email="41898282+github-actions[bot]@users.noreply.github.com" \
|
||||
commit -q -m "chore(site): publish the page for $tag"
|
||||
git push origin HEAD:refs/heads/pages
|
||||
@@ -0,0 +1,34 @@
|
||||
# The full test suite. Local runs cover only the targets a change touches (RULES.md, "The machine
|
||||
# you build on"); this is where everything runs, before a release can publish. Run it alone with
|
||||
# `gh workflow run test.yml -f ref=<branch or tag>`. Gitea reads .github/workflows too, so the job
|
||||
# is gated on the server URL.
|
||||
name: test
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
ref:
|
||||
type: string
|
||||
required: false
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
ref:
|
||||
description: Branch or tag to test (default the one you run from)
|
||||
required: false
|
||||
|
||||
env:
|
||||
CARGO_TERM_COLOR: always
|
||||
|
||||
jobs:
|
||||
test:
|
||||
if: github.server_url == 'https://github.com'
|
||||
# Windows: the platform the app is developed on, and its runners render with a software GPU.
|
||||
runs-on: windows-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
with: { ref: "${{ inputs.ref || github.ref }}" }
|
||||
- uses: dtolnay/rust-toolchain@stable
|
||||
with: { targets: wasm32-unknown-unknown }
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
- run: cargo test --locked --no-fail-fast
|
||||
- run: cargo check --locked --lib --target wasm32-unknown-unknown
|
||||
@@ -0,0 +1,2 @@
|
||||
[ 3482ms] [INFO] %cDownload the React DevTools for a better development experience: https://react.dev/link/react-devtools font-weight:bold @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 3531ms] [LOG] [HMR] connected @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
@@ -0,0 +1,9 @@
|
||||
[ 210ms] [LOG] [Fast Refresh] rebuilding @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 1039ms] [LOG] [Fast Refresh] done in 930ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 1076ms] [INFO] %cDownload the React DevTools for a better development experience: https://react.dev/link/react-devtools font-weight:bold @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 1086ms] [LOG] [HMR] connected @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 37298ms] [ERROR] Pattern attribute value [0-9() -]{10,16} is not a valid regular expression: Uncaught SyntaxError: Invalid regular expression: /[0-9() -]{10,16}/v: Invalid character in character class @ http://localhost:3000/motorista/entrar:0
|
||||
[ 60872ms] [LOG] [Fast Refresh] rebuilding @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 60976ms] [LOG] [Fast Refresh] done in 99ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 61021ms] [LOG] [Fast Refresh] done in 99ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 66490ms] [LOG] [Fast Refresh] done in 99ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
@@ -0,0 +1,13 @@
|
||||
[ 93ms] [LOG] [Fast Refresh] done in 99ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 953ms] [INFO] %cDownload the React DevTools for a better development experience: https://react.dev/link/react-devtools font-weight:bold @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 963ms] [LOG] [HMR] connected @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 4345ms] [LOG] [Fast Refresh] rebuilding @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 4433ms] [LOG] [Fast Refresh] done in 189ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 4548ms] [VERBOSE] [DOM] Password forms should have (optionally hidden) username fields for accessibility: (More info: https://goo.gl/9p2vKq) %o @ http://localhost:3000/entrar/senha:0
|
||||
[ 9731ms] [LOG] [Fast Refresh] done in 5486ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 9777ms] [LOG] [Fast Refresh] done in 5486ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 11070ms] [LOG] [Fast Refresh] done in 5486ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 30758ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=fBVPvwqt_6CU4TU3WWYmu' failed: @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 31764ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=fBVPvwqt_6CU4TU3WWYmu' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 32766ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=fBVPvwqt_6CU4TU3WWYmu' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 33776ms] [LOG] [HMR] connected @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
@@ -0,0 +1,79 @@
|
||||
[ 805ms] [INFO] %cDownload the React DevTools for a better development experience: https://react.dev/link/react-devtools font-weight:bold @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 813ms] [LOG] [HMR] connected @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 1121ms] [VERBOSE] [DOM] Password forms should have (optionally hidden) username fields for accessibility: (More info: https://goo.gl/9p2vKq) %o @ http://localhost:3000/entrar/senha:0
|
||||
[ 2267ms] [LOG] [Fast Refresh] rebuilding @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 2310ms] [LOG] [Fast Refresh] done in 144ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 9621ms] [LOG] [Fast Refresh] rebuilding @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 9763ms] [LOG] [Fast Refresh] done in 243ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 48693ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 48749ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 48826ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 51025ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 51539ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 51907ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 107213ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 118297ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 123464ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 125669ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 125771ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 126799ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 126941ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 127929ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 127981ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 154930ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 156620ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 157845ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 158106ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 158454ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 158504ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 158748ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 158848ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 158955ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 159307ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 159399ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 159488ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 159901ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 159993ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 187894ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 188000ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 205603ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 207208ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 207296ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 207951ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 208126ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 208244ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 208353ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 208415ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 208590ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 208695ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 208794ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 208878ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 208986ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 209132ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 209234ms] [LOG] [Fast Refresh] done in 39171ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 228278ms] [LOG] [Fast Refresh] rebuilding @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 228308ms] [LOG] [Fast Refresh] done in 3ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 238991ms] [LOG] [Fast Refresh] done in 10713ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 239037ms] [LOG] [Fast Refresh] done in 10713ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 239175ms] [LOG] [Fast Refresh] rebuilding @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 239206ms] [LOG] [Fast Refresh] done in 3ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 239602ms] [LOG] [Fast Refresh] done in 3ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 239697ms] [LOG] [Fast Refresh] done in 3ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 264111ms] [LOG] [Fast Refresh] done in 3ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 265916ms] [LOG] [Fast Refresh] done in 3ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 321743ms] [LOG] [Fast Refresh] done in 3ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 333352ms] [LOG] [Fast Refresh] done in 3ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 369410ms] [LOG] [Fast Refresh] done in 3ms @ http://localhost:3000/_next/static/chunks/1bba_next_dist_041c6vio7na_y._.js:719
|
||||
[ 413886ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=ruCdDO_vey1tElDs8WYR0' failed: @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 414902ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=ruCdDO_vey1tElDs8WYR0' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 415904ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=ruCdDO_vey1tElDs8WYR0' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 416906ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=ruCdDO_vey1tElDs8WYR0' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 417908ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=ruCdDO_vey1tElDs8WYR0' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 418911ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=ruCdDO_vey1tElDs8WYR0' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 423918ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=ruCdDO_vey1tElDs8WYR0' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 428928ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=ruCdDO_vey1tElDs8WYR0' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 433950ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=ruCdDO_vey1tElDs8WYR0' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 438984ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=ruCdDO_vey1tElDs8WYR0' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 444022ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=ruCdDO_vey1tElDs8WYR0' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 449184ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=ruCdDO_vey1tElDs8WYR0' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
[ 454479ms] [ERROR] WebSocket connection to 'ws://localhost:3000/_next/hmr?id=ruCdDO_vey1tElDs8WYR0' failed: Error in connection establishment: net::ERR_CONNECTION_REFUSED @ http://localhost:3000/_next/static/chunks/1bba_next_dist_client_0ru2jkh0js1s8._.js:16225
|
||||
@@ -0,0 +1,28 @@
|
||||
- generic [ref=e2]:
|
||||
- complementary [ref=e3]:
|
||||
- generic [ref=e8]:
|
||||
- generic [ref=e9]: Rota Fresca
|
||||
- generic [ref=e10]: Distribuição de alimentos
|
||||
- generic [ref=e11]:
|
||||
- heading "Do depósito à prateleira, na hora certa." [level=2] [ref=e12]
|
||||
- paragraph [ref=e13]: Pedidos, entregas e notas da sua rede no mesmo lugar.
|
||||
- main [ref=e14]:
|
||||
- link "Precisa de ajuda?" [ref=e16] [cursor=pointer]:
|
||||
- /url: mailto:suporte@rotafresca.com.br
|
||||
- generic [ref=e17]:
|
||||
- generic [ref=e18]:
|
||||
- heading "Entrar" [level=1] [ref=e19]
|
||||
- paragraph [ref=e20]: Use o e-mail da sua conta. Conforme o tipo de conta, pedimos a senha ou mandamos um link de acesso.
|
||||
- generic [ref=e21]:
|
||||
- generic [ref=e22]:
|
||||
- generic [ref=e23]: E-mail
|
||||
- textbox "E-mail" [ref=e24]:
|
||||
- /placeholder: nome@empresa.com.br
|
||||
- button "Continuar" [ref=e25]
|
||||
- generic [ref=e26]: ou
|
||||
- generic [ref=e33]:
|
||||
- paragraph [ref=e34]: É motorista?
|
||||
- paragraph [ref=e35]: Entre pelo app Rota Fresca no celular, com o seu número. Não precisa de e-mail.
|
||||
- generic [ref=e36]:
|
||||
- paragraph [ref=e37]: Recebeu um convite? Abra o link do e-mail para criar seu acesso.
|
||||
- paragraph [ref=e38]: Termos de uso · Privacidade
|
||||
@@ -0,0 +1,20 @@
|
||||
- generic [active] [ref=f1e1]:
|
||||
- generic [ref=f1e2]:
|
||||
- generic [ref=f1e3]:
|
||||
- generic [ref=f1e8]:
|
||||
- generic [ref=f1e9]: Rota Fresca
|
||||
- generic [ref=f1e10]: App do motorista
|
||||
- banner [ref=f1e11]:
|
||||
- heading "Entrar" [level=1] [ref=f1e12]
|
||||
- paragraph [ref=f1e13]: Use o número de celular que a central cadastrou. Mandamos um código, sem senha.
|
||||
- generic [ref=f1e14]:
|
||||
- generic [ref=f1e15]: Celular
|
||||
- generic [ref=f1e16]:
|
||||
- generic [ref=f1e17]: "+55"
|
||||
- textbox "(21) 98877-4410" [ref=f1e18]
|
||||
- generic [ref=f1e19]:
|
||||
- button "Receber código no WhatsApp" [ref=f1e20]
|
||||
- button "Receber por SMS" [ref=f1e21]
|
||||
- paragraph [ref=f1e22]: Trocou de número? Fale com a central.
|
||||
- button "Open Next.js Dev Tools" [ref=f1e28] [cursor=pointer]
|
||||
- alert [ref=f1e32]
|
||||
@@ -0,0 +1,32 @@
|
||||
- generic [active] [ref=f2e1]:
|
||||
- generic [ref=f2e2]:
|
||||
- complementary [ref=f2e3]:
|
||||
- generic [ref=f2e9]:
|
||||
- generic [ref=f2e10]: Rota Fresca
|
||||
- generic [ref=f2e11]: Distribuição de alimentos
|
||||
- generic [ref=f2e12]:
|
||||
- heading "Do depósito à prateleira, na hora certa." [level=2] [ref=f2e13]
|
||||
- paragraph [ref=f2e14]: Pedidos, entregas e notas da sua rede no mesmo lugar.
|
||||
- main [ref=f2e15]:
|
||||
- link "Precisa de ajuda?" [ref=f2e17] [cursor=pointer]:
|
||||
- /url: mailto:suporte@rotafresca.com.br
|
||||
- generic [ref=f2e18]:
|
||||
- generic [ref=f2e19]:
|
||||
- heading "Entrar" [level=1] [ref=f2e20]
|
||||
- paragraph [ref=f2e21]: Use o e-mail da sua conta. Conforme o tipo de conta, pedimos a senha ou mandamos um link de acesso.
|
||||
- generic [ref=f2e22]:
|
||||
- generic [ref=f2e23]:
|
||||
- generic [ref=f2e24]: E-mail
|
||||
- textbox "E-mail" [ref=f2e25]:
|
||||
- /placeholder: nome@empresa.com.br
|
||||
- button "Continuar" [ref=f2e26]
|
||||
- generic [ref=f2e27]: ou
|
||||
- button "Entrar com chave de acesso (passkey)" [ref=f2e31]
|
||||
- generic [ref=f2e35]:
|
||||
- paragraph [ref=f2e36]: É motorista?
|
||||
- paragraph [ref=f2e37]: Entre pelo app Rota Fresca no celular, com o seu número. Não precisa de e-mail.
|
||||
- generic [ref=f2e38]:
|
||||
- paragraph [ref=f2e39]: Recebeu um convite? Abra o link do e-mail para criar seu acesso.
|
||||
- paragraph [ref=f2e40]: Termos de uso · Privacidade
|
||||
- button "Open Next.js Dev Tools" [ref=f2e46] [cursor=pointer]
|
||||
- alert [ref=f2e50]
|
||||
@@ -0,0 +1,38 @@
|
||||
- generic [active] [ref=f2e1]:
|
||||
- button "Open Next.js Dev Tools" [ref=f2e46] [cursor=pointer]
|
||||
- alert [ref=f2e50]: Digite sua senha
|
||||
- generic [ref=f2e51]:
|
||||
- complementary [ref=f2e52]:
|
||||
- generic [ref=f2e58]:
|
||||
- generic [ref=f2e59]: Rota Fresca
|
||||
- generic [ref=f2e60]: Distribuição de alimentos
|
||||
- generic [ref=f2e61]:
|
||||
- heading "Do depósito à prateleira, na hora certa." [level=2] [ref=f2e62]
|
||||
- paragraph [ref=f2e63]: Pedidos, entregas e notas da sua rede no mesmo lugar.
|
||||
- main [ref=f2e64]:
|
||||
- link "Precisa de ajuda?" [ref=f2e66] [cursor=pointer]:
|
||||
- /url: mailto:suporte@rotafresca.com.br
|
||||
- generic [ref=f2e67]:
|
||||
- generic [ref=f2e68]:
|
||||
- generic [ref=f2e69]: ana.souza@rotafresca.com.br
|
||||
- button "Trocar" [ref=f2e74]
|
||||
- generic [ref=f2e75]:
|
||||
- heading "Digite sua senha" [level=1] [ref=f2e76]
|
||||
- paragraph [ref=f2e77]: Conta de consultor. Depois da senha pedimos o código do autenticador.
|
||||
- generic [ref=f2e78]:
|
||||
- generic [ref=f2e79]:
|
||||
- generic [ref=f2e80]:
|
||||
- generic [ref=f2e81]: Senha
|
||||
- textbox "Senha" [ref=f2e82]
|
||||
- generic [ref=f2e83]:
|
||||
- generic [ref=f2e84]:
|
||||
- checkbox "Mostrar senha" [ref=f2e85]
|
||||
- checkbox [aria-hidden]
|
||||
- text: Mostrar senha
|
||||
- link "Esqueci minha senha" [ref=f2e86] [cursor=pointer]:
|
||||
- /url: /entrar/redefinir
|
||||
- button "Entrar" [ref=f2e87]
|
||||
- paragraph [ref=f2e88]: Pode colar a senha ou usar o gerenciador de senhas do navegador.
|
||||
- generic [ref=f2e89]:
|
||||
- paragraph [ref=f2e90]: Recebeu um convite? Abra o link do e-mail para criar seu acesso.
|
||||
- paragraph [ref=f2e91]: Termos de uso · Privacidade
|
||||
@@ -0,0 +1,40 @@
|
||||
- generic [ref=f2e1]:
|
||||
- button "Open Next.js Dev Tools" [ref=f2e46] [cursor=pointer]
|
||||
- alert [ref=f2e50]: Rota Fresca
|
||||
- generic [ref=f2e51]:
|
||||
- complementary [ref=f2e52]:
|
||||
- generic [ref=f2e58]:
|
||||
- generic [ref=f2e59]: Rota Fresca
|
||||
- generic [ref=f2e60]: Distribuição de alimentos
|
||||
- generic [ref=f2e61]:
|
||||
- heading "Do depósito à prateleira, na hora certa." [level=2] [ref=f2e62]
|
||||
- paragraph [ref=f2e63]: Pedidos, entregas e notas da sua rede no mesmo lugar.
|
||||
- main [ref=f2e64]:
|
||||
- link "Precisa de ajuda?" [ref=f2e66] [cursor=pointer]:
|
||||
- /url: mailto:suporte@rotafresca.com.br
|
||||
- generic [ref=f2e67]:
|
||||
- generic [ref=f2e68]:
|
||||
- generic [ref=f2e69]: ana.souza@rotafresca.com.br
|
||||
- button "Trocar" [ref=f2e74]
|
||||
- generic [ref=f2e75]:
|
||||
- heading "Digite sua senha" [level=1] [ref=f2e76]
|
||||
- paragraph [ref=f2e77]: Conta de consultor. Depois da senha pedimos o código do autenticador.
|
||||
- generic [ref=f2e78]:
|
||||
- generic [ref=f2e79]:
|
||||
- generic [ref=f2e80]:
|
||||
- generic [ref=f2e81]: Senha
|
||||
- textbox "Senha" [active] [invalid] [ref=f2e82]
|
||||
- generic [ref=f2e83]:
|
||||
- generic [ref=f2e84]:
|
||||
- checkbox "Mostrar senha" [ref=f2e85]
|
||||
- checkbox [aria-hidden]
|
||||
- text: Mostrar senha
|
||||
- link "Esqueci minha senha" [ref=f2e86] [cursor=pointer]:
|
||||
- /url: /entrar/redefinir
|
||||
- alert [ref=f2e92]:
|
||||
- generic [ref=f2e93]: Senha incorreta. Confira e tente de novo.
|
||||
- button "Entrar" [ref=f2e87]
|
||||
- paragraph [ref=f2e88]: Pode colar a senha ou usar o gerenciador de senhas do navegador.
|
||||
- generic [ref=f2e89]:
|
||||
- paragraph [ref=f2e90]: Recebeu um convite? Abra o link do e-mail para criar seu acesso.
|
||||
- paragraph [ref=f2e91]: Termos de uso · Privacidade
|
||||
@@ -0,0 +1,32 @@
|
||||
- generic [active] [ref=f3e1]:
|
||||
- generic [ref=f3e2]:
|
||||
- complementary [ref=f3e3]:
|
||||
- generic [ref=f3e9]:
|
||||
- generic [ref=f3e10]: Rota Fresca
|
||||
- generic [ref=f3e11]: Distribuição de alimentos
|
||||
- generic [ref=f3e12]:
|
||||
- heading "Do depósito à prateleira, na hora certa." [level=2] [ref=f3e13]
|
||||
- paragraph [ref=f3e14]: Pedidos, entregas e notas da sua rede no mesmo lugar.
|
||||
- main [ref=f3e15]:
|
||||
- link "Precisa de ajuda?" [ref=f3e17] [cursor=pointer]:
|
||||
- /url: mailto:suporte@rotafresca.com.br
|
||||
- generic [ref=f3e18]:
|
||||
- generic [ref=f3e19]:
|
||||
- heading "Entrar" [level=1] [ref=f3e20]
|
||||
- paragraph [ref=f3e21]: Use o e-mail da sua conta. Conforme o tipo de conta, pedimos a senha ou mandamos um link de acesso.
|
||||
- generic [ref=f3e22]:
|
||||
- generic [ref=f3e23]:
|
||||
- generic [ref=f3e24]: E-mail
|
||||
- textbox "E-mail" [ref=f3e25]:
|
||||
- /placeholder: nome@empresa.com.br
|
||||
- button "Continuar" [ref=f3e26]
|
||||
- generic [ref=f3e27]: ou
|
||||
- button "Entrar com chave de acesso (passkey)" [ref=f3e31]
|
||||
- generic [ref=f3e35]:
|
||||
- paragraph [ref=f3e36]: É motorista?
|
||||
- paragraph [ref=f3e37]: Entre pelo app Rota Fresca no celular, com o seu número. Não precisa de e-mail.
|
||||
- generic [ref=f3e38]:
|
||||
- paragraph [ref=f3e39]: Recebeu um convite? Abra o link do e-mail para criar seu acesso.
|
||||
- paragraph [ref=f3e40]: Termos de uso · Privacidade
|
||||
- button "Open Next.js Dev Tools" [ref=f3e46] [cursor=pointer]
|
||||
- alert [ref=f3e50]
|
||||
@@ -0,0 +1,38 @@
|
||||
- generic [active] [ref=f3e1]:
|
||||
- button "Open Next.js Dev Tools" [ref=f3e46] [cursor=pointer]
|
||||
- alert [ref=f3e50]
|
||||
- generic [ref=f3e51]:
|
||||
- complementary [ref=f3e52]:
|
||||
- generic [ref=f3e58]:
|
||||
- generic [ref=f3e59]: Rota Fresca
|
||||
- generic [ref=f3e60]: Distribuição de alimentos
|
||||
- generic [ref=f3e61]:
|
||||
- heading "Do depósito à prateleira, na hora certa." [level=2] [ref=f3e62]
|
||||
- paragraph [ref=f3e63]: Pedidos, entregas e notas da sua rede no mesmo lugar.
|
||||
- main [ref=f3e64]:
|
||||
- link "Precisa de ajuda?" [ref=f3e66] [cursor=pointer]:
|
||||
- /url: mailto:suporte@rotafresca.com.br
|
||||
- generic [ref=f3e67]:
|
||||
- generic [ref=f3e68]:
|
||||
- generic [ref=f3e69]: ana.souza@rotafresca.com.br
|
||||
- button "Trocar" [ref=f3e74]
|
||||
- generic [ref=f3e75]:
|
||||
- heading "Digite sua senha" [level=1] [ref=f3e76]
|
||||
- paragraph [ref=f3e77]: Conta de consultor. Depois da senha pedimos o código do autenticador.
|
||||
- generic [ref=f3e78]:
|
||||
- generic [ref=f3e79]:
|
||||
- generic [ref=f3e80]:
|
||||
- generic [ref=f3e81]: Senha
|
||||
- textbox "Senha" [ref=f3e82]
|
||||
- generic [ref=f3e83]:
|
||||
- generic [ref=f3e84]:
|
||||
- checkbox "Mostrar senha" [ref=f3e85]
|
||||
- checkbox [aria-hidden]
|
||||
- text: Mostrar senha
|
||||
- link "Esqueci minha senha" [ref=f3e86] [cursor=pointer]:
|
||||
- /url: /entrar/redefinir
|
||||
- button "Entrar" [ref=f3e87]
|
||||
- paragraph [ref=f3e88]: Pode colar a senha ou usar o gerenciador de senhas do navegador.
|
||||
- generic [ref=f3e89]:
|
||||
- paragraph [ref=f3e90]: Recebeu um convite? Abra o link do e-mail para criar seu acesso.
|
||||
- paragraph [ref=f3e91]: Termos de uso · Privacidade
|
||||
@@ -0,0 +1,33 @@
|
||||
- generic [active] [ref=f3e1]:
|
||||
- button "Open Next.js Dev Tools" [ref=f3e46] [cursor=pointer]
|
||||
- alert [ref=f3e50]
|
||||
- generic [ref=f3e92]:
|
||||
- complementary [ref=f3e93]:
|
||||
- generic [ref=f3e99]:
|
||||
- generic [ref=f3e100]: Rota Fresca
|
||||
- generic [ref=f3e101]: Distribuição de alimentos
|
||||
- generic [ref=f3e102]:
|
||||
- heading "Do depósito à prateleira, na hora certa." [level=2] [ref=f3e103]
|
||||
- paragraph [ref=f3e104]: Pedidos, entregas e notas da sua rede no mesmo lugar.
|
||||
- main [ref=f3e105]:
|
||||
- link "Precisa de ajuda?" [ref=f3e107] [cursor=pointer]:
|
||||
- /url: mailto:suporte@rotafresca.com.br
|
||||
- generic [ref=f3e108]:
|
||||
- heading "Confirme que é você" [level=1] [ref=f3e113]
|
||||
- generic [ref=f3e114]:
|
||||
- generic [ref=f3e115]:
|
||||
- generic [ref=f3e116]:
|
||||
- generic [ref=f3e117]: Código
|
||||
- textbox "Código" [ref=f3e118]
|
||||
- generic [ref=f3e119]:
|
||||
- checkbox "Não pedir de novo neste computador por 30 dias" [checked] [ref=f3e120]
|
||||
- checkbox [checked] [aria-hidden]
|
||||
- text: Não pedir de novo neste computador por 30 dias
|
||||
- button "Confirmar" [ref=f3e121]
|
||||
- generic [ref=f3e122]:
|
||||
- link "Usar um código de recuperação" [ref=f3e123] [cursor=pointer]:
|
||||
- /url: /entrar/codigo?recuperacao=1
|
||||
- paragraph [ref=f3e124]: Perdeu o celular? Peça ao administrador da conta para refazer o autenticador.
|
||||
- generic [ref=f3e125]:
|
||||
- paragraph [ref=f3e126]: Recebeu um convite? Abra o link do e-mail para criar seu acesso.
|
||||
- paragraph [ref=f3e127]: Termos de uso · Privacidade
|
||||
@@ -0,0 +1,47 @@
|
||||
- generic [active] [ref=f3e1]:
|
||||
- button "Open Next.js Dev Tools" [ref=f3e46] [cursor=pointer]
|
||||
- alert [ref=f3e50]: Bom dia, Ana
|
||||
- generic [ref=f3e128]:
|
||||
- complementary [ref=f3e129]:
|
||||
- generic [ref=f3e130]:
|
||||
- generic [ref=f3e136]:
|
||||
- generic [ref=f3e137]: Rota Fresca
|
||||
- generic [ref=f3e138]: Distribuição de alimentos
|
||||
- navigation [ref=f3e139]:
|
||||
- link "Painel" [ref=f3e140] [cursor=pointer]:
|
||||
- /url: /painel
|
||||
- link "Roteiro do dia" [ref=f3e143] [cursor=pointer]:
|
||||
- /url: /roteiro
|
||||
- link "Lojas (PDVs)" [ref=f3e146] [cursor=pointer]:
|
||||
- /url: /lojas
|
||||
- link "Pedidos" [ref=f3e149] [cursor=pointer]:
|
||||
- /url: /pedidos
|
||||
- link "Entregas" [ref=f3e152] [cursor=pointer]:
|
||||
- /url: /entregas
|
||||
- link "Validade e lotes" [ref=f3e155] [cursor=pointer]:
|
||||
- /url: /validade
|
||||
- link "Relatórios" [ref=f3e158] [cursor=pointer]:
|
||||
- /url: /relatorios
|
||||
- link "Integrações e notas" [ref=f3e161] [cursor=pointer]:
|
||||
- /url: /integracoes
|
||||
- link "Leitura de documentos" [ref=f3e164] [cursor=pointer]:
|
||||
- /url: /documentos
|
||||
- link "Contatos e mensagens" [ref=f3e167] [cursor=pointer]:
|
||||
- /url: /contatos
|
||||
- link "Configurações" [ref=f3e170] [cursor=pointer]:
|
||||
- /url: /configuracoes
|
||||
- generic [ref=f3e173]:
|
||||
- generic [aria-hidden] [ref=f3e174]: A
|
||||
- generic [ref=f3e175]:
|
||||
- generic [ref=f3e176]: Ana Souza
|
||||
- generic [ref=f3e177]: Consultora · Zona Oeste
|
||||
- main [ref=f3e178]:
|
||||
- generic [ref=f3e179]:
|
||||
- generic [ref=f3e180]:
|
||||
- heading "Bom dia, Ana" [level=1] [ref=f3e181]
|
||||
- paragraph [ref=f3e182]: domingo, 25 de outubro
|
||||
- generic [ref=f3e183]:
|
||||
- textbox "Buscar loja, pedido ou produto" [ref=f3e187]
|
||||
- button "Notificações" [ref=f3e188]
|
||||
- button "Importar / Exportar" [ref=f3e189]
|
||||
- button "Novo pedido" [ref=f3e190]
|
||||
|
After Width: | Height: | Size: 344 KiB |
|
After Width: | Height: | Size: 70 KiB |
|
After Width: | Height: | Size: 33 KiB |
|
After Width: | Height: | Size: 56 KiB |
|
After Width: | Height: | Size: 344 KiB |
@@ -0,0 +1,77 @@
|
||||
# Guidance for coding agents
|
||||
|
||||
PaperCraft is a native Rust design and whiteboard canvas (egui, wgpu, winit) that AI agents drive
|
||||
over MCP and a CLI. Read [CONTRIBUTING.md](CONTRIBUTING.md) and [RULES.md](RULES.md) first; this
|
||||
file is the short version for agents, and [AI_POLICY.md](AI_POLICY.md) says what the person using
|
||||
you is accountable for.
|
||||
|
||||
## Commands
|
||||
|
||||
```sh
|
||||
cargo build --release
|
||||
cargo fmt --all
|
||||
cargo clippy --all-targets
|
||||
cargo test --test incremental # only the targets your change touches
|
||||
cargo test --lib editor::changes # unit tests of one module
|
||||
cargo check --lib --target wasm32-unknown-unknown
|
||||
```
|
||||
|
||||
Do not run the full suite locally: it builds dozens of test binaries. It runs on GitHub before
|
||||
each release (`.github/workflows/test.yml`). `tests/update.rs` cannot run on Windows outside CI
|
||||
(it needs elevation); that failure is known.
|
||||
|
||||
Builds run on the person's own machine, so mind its resources (RULES.md, "The machine you build
|
||||
on"): check free memory and running builds first, cap jobs at no more than half the cores
|
||||
(`cargo test -j 8 -- --test-threads=8` on 16 cores), run at low priority, run one heavy job at a
|
||||
time, and stop at once if they say it is slow.
|
||||
|
||||
## Running the app safely
|
||||
|
||||
Never run a test copy against the person's real projects or MCP port, and never close or restart
|
||||
their running PaperCraft. Give yours its own folder and port, and keep its PID so you can stop only
|
||||
your own process:
|
||||
|
||||
```sh
|
||||
PAPERCRAFT_HOME=/tmp/pc PAPERCRAFT_MCP_PORT=29998 ./target/release/papercraft
|
||||
```
|
||||
|
||||
Do not stop processes by name.
|
||||
|
||||
## Layout
|
||||
|
||||
`src/model` (document), `src/editor` (tools and edits), `src/render` (wgpu), `src/mcp` (tools,
|
||||
HTML/CSS mapping, lint), `src/ui` (egui panels), `src/io` (import and export), `src/project`
|
||||
(store and formats), `tests/` (scenario tests), `specs/` (feature specs), `skills/` (agent
|
||||
skills). The README's project layout lists the rest.
|
||||
|
||||
## Conventions
|
||||
|
||||
* Tests first; match the style of the tests next to yours, and check the behaviour is not already
|
||||
covered.
|
||||
* Changes to the document go through `Editor::edit`: one transaction, one undo step.
|
||||
* Handle errors; do not `unwrap` user data and do not discard errors with `let _ =`.
|
||||
* Comments explain *why*, never summarise the code. No dead code, debug prints or
|
||||
commented-out blocks.
|
||||
* Files stay under about 800 lines; split by feature.
|
||||
* Reuse the shared UI kit and theme instead of one-off values. Nothing may overflow its container.
|
||||
* Writes to projects are atomic and format changes ship a migration (see RULES.md, "Data safety").
|
||||
* Adding or removing an MCP tool means a test in `tests/mcp.rs`, a precise description, and the
|
||||
tool count updated in the README and ROADMAP.
|
||||
* Commits are conventional (`feat(scope): summary`) and focused. Do not commit, push or tag unless
|
||||
the person asked you to.
|
||||
|
||||
## Designing with PaperCraft (skills, examples, screenshots)
|
||||
|
||||
* Themes are modes, never copies: one artboard per screen, a value per mode on each variable, and
|
||||
`set_variable_mode` to switch. Never duplicate artboards for light and dark.
|
||||
* Every colour on a themed screen is a variable.
|
||||
* Check each artboard for overflow, programmatically and by screenshot in each mode, and run
|
||||
`lint_design`.
|
||||
* Release design locks when you finish.
|
||||
|
||||
## Avoid
|
||||
|
||||
* Creative additions nobody asked for; stay inside the task.
|
||||
* Trivial tests, wide or optional types added to appease the compiler, and swallowed errors.
|
||||
* Editing generated files, lockfiles or release artifacts by hand, or touching files unrelated to
|
||||
the task. Leave other people's uncommitted work alone.
|
||||
@@ -0,0 +1,40 @@
|
||||
# AI usage policy
|
||||
|
||||
PaperCraft is built to be driven by AI agents, and many of its contributors use them too. AI tools
|
||||
are welcome here. What we ask is that a person stays accountable for everything submitted.
|
||||
|
||||
## For contributors
|
||||
|
||||
* **You own what you submit.** Read every line of your pull request before asking for review. If
|
||||
you cannot explain what a change does and how it fits the rest of the system without asking an
|
||||
AI, do not submit it yet.
|
||||
* **Disclose meaningful AI help.** Say which tool you used and roughly how much it wrote in the
|
||||
pull request description (for example "drafted with Claude Code, reviewed and tested by me").
|
||||
Autocomplete and spell-checking do not need a note.
|
||||
* **Write issues yourself.** An agent can help you research, but the report should be in your own
|
||||
words, trimmed to what matters, with reproduction steps you ran. Long generated text that nobody
|
||||
checked puts the burden on maintainers.
|
||||
* **Think before you generate.** Agents jump to code and make their own job easy: trivial tests,
|
||||
wide or optional types, swallowed errors, redundant comments, copied local patterns that do not
|
||||
fit. Push back on all of it. [RULES.md](RULES.md) lists the standards to hold the output to.
|
||||
* **Verify.** Run the checks in [CONTRIBUTING.md](CONTRIBUTING.md), use the app, and attach
|
||||
screenshots for UI changes. "The agent said it works" is not a test result.
|
||||
* **Answer automated review.** If a bot reviews your pull request, fix its findings or reply with
|
||||
a one-line reason a finding does not apply.
|
||||
* **No bulk or drive-by pull requests.** Many small generated changes across the tree, or changes
|
||||
to something nobody asked for, will be closed. Open an issue first for anything beyond a small
|
||||
fix.
|
||||
|
||||
Pull requests that clearly skip these steps may be closed without a detailed review. Repeated
|
||||
low-effort submissions can lead to a block, under the [Code of Conduct](CODE_OF_CONDUCT.md).
|
||||
|
||||
## For coding agents
|
||||
|
||||
Read [AGENTS.md](AGENTS.md). It holds the commands, conventions and guardrails an agent working in
|
||||
this repository should follow.
|
||||
|
||||
## Why
|
||||
|
||||
Every issue and pull request is read by a person. Review time is the scarce resource, and a change
|
||||
nobody understood costs more than it saves. AI that is reviewed, tested and understood by the
|
||||
person submitting it is a good way to build PaperCraft; AI used to skip that work is not.
|
||||
@@ -0,0 +1,31 @@
|
||||
# Code of Conduct
|
||||
|
||||
PaperCraft is built by people with different backgrounds and experience. We want everyone to be
|
||||
able to contribute without harassment.
|
||||
|
||||
## Our standard
|
||||
|
||||
Be respectful and constructive. Assume good intent, give specific and kind feedback, and accept
|
||||
it the same way. Disagree about the work, not the person.
|
||||
|
||||
Not acceptable:
|
||||
|
||||
* harassment, insults, slurs, or personal or political attacks;
|
||||
* sexualised language or imagery, or unwelcome attention;
|
||||
* threats, doxxing, or publishing someone's private information;
|
||||
* sustained disruption of discussions, or pressure to merge or answer;
|
||||
* anything else a reasonable person would consider inappropriate in a professional setting.
|
||||
|
||||
## Scope
|
||||
|
||||
This applies in issues, pull requests, discussions, commit messages and any space where someone
|
||||
represents the project.
|
||||
|
||||
## Enforcement
|
||||
|
||||
Maintainers may edit or remove comments, close or lock threads, and block people who break these
|
||||
rules. To report a problem, use GitHub's "Report content" on the comment, or contact a maintainer
|
||||
through a private channel on their GitHub profile. Reports are handled privately and in good
|
||||
faith, and retaliation against a reporter is itself a violation.
|
||||
|
||||
The spirit of this text follows the [Contributor Covenant](https://www.contributor-covenant.org).
|
||||
@@ -0,0 +1,129 @@
|
||||
# Contributing to PaperCraft
|
||||
|
||||
Thanks for wanting to help. PaperCraft is an alpha, so there is plenty to do and the bar for a
|
||||
first contribution is low: a typo fix, a clearer error message, a missing test or a one-line bug
|
||||
fix are all welcome.
|
||||
|
||||
Please read [RULES.md](RULES.md) before writing code: it holds the standards a change is judged by.
|
||||
By taking part you agree to the [Code of Conduct](CODE_OF_CONDUCT.md). Using an AI tool is fine;
|
||||
the [AI usage policy](AI_POLICY.md) says what you stay responsible for, and coding agents should read
|
||||
[AGENTS.md](AGENTS.md).
|
||||
|
||||
## Ways to help
|
||||
|
||||
* **Report a bug** or **suggest a feature** with an [issue](https://github.com/nxtime/papercraft/issues/new/choose).
|
||||
A screenshot or a short recording helps; so does the project folder (or a page of it) that
|
||||
triggers the bug.
|
||||
* **Pick something from [ROADMAP.md](ROADMAP.md).** Rows marked `todo` or `partial` are open. Say
|
||||
which one you are taking in an issue first, so two people do not build the same thing.
|
||||
* **Improve the docs, skills or screenshots.** [docs/](docs), [skills/](skills) and the README are
|
||||
as important as code.
|
||||
* **Review a pull request.** A second pair of eyes is always useful.
|
||||
|
||||
Security problems do not go in public issues: see [SECURITY.md](SECURITY.md).
|
||||
|
||||
## Before you start
|
||||
|
||||
For anything bigger than a small fix, open an issue (or comment on one) describing the problem and
|
||||
how you plan to solve it. Large features start as a short spec in [specs/](specs): a `spec.md`
|
||||
(why, what, what is out of scope) and a `plan.md`. [specs/component-props](specs/component-props)
|
||||
shows the shape. A spec agreed up front saves a rewrite later.
|
||||
|
||||
## Set up
|
||||
|
||||
You need Rust 1.95 or newer (`rust-version` in `Cargo.toml`) and the platform libraries listed in
|
||||
the README's [Build from source](README.md#build-from-source).
|
||||
|
||||
```sh
|
||||
git clone https://github.com/nxtime/papercraft
|
||||
cd papercraft
|
||||
cargo build --release
|
||||
```
|
||||
|
||||
Run a test copy next to your own PaperCraft so it cannot touch your real projects or collide with
|
||||
the running app's MCP port:
|
||||
|
||||
```sh
|
||||
PAPERCRAFT_HOME=/tmp/pc PAPERCRAFT_MCP_PORT=29998 ./target/release/papercraft
|
||||
```
|
||||
|
||||
`PAPERCRAFT_HOME` moves the project root and the config folder; `PAPERCRAFT_MCP_PORT` moves the
|
||||
MCP server. Always set both when developing.
|
||||
|
||||
The code depends on [`craft-ui`](https://git.marcospaulo.dev.br/masi/craft-libs), which Cargo
|
||||
fetches from a public git repository at the revision pinned in `Cargo.toml`.
|
||||
|
||||
## Make the change
|
||||
|
||||
1. Fork the repository and branch from `main` (`fix/short-name`, `feat/short-name`).
|
||||
2. **Write the test first.** Fix a bug by adding a test that fails, then make it pass. See
|
||||
[Tests](#tests).
|
||||
3. Keep the change focused. One concern per pull request; unrelated cleanups go in their own.
|
||||
4. Run the checks below and fix what they report.
|
||||
5. Update the docs the change touches: the README, `docs/`, the tool description for an MCP tool,
|
||||
the skills if agents should now behave differently.
|
||||
6. Add a short entry to [PROGRESS.md](PROGRESS.md) for user-visible changes.
|
||||
|
||||
### Checks
|
||||
|
||||
```sh
|
||||
cargo fmt --all
|
||||
cargo clippy --all-targets
|
||||
cargo test --test <target> # the targets your change touches
|
||||
cargo check --lib --target wasm32-unknown-unknown # the web build
|
||||
```
|
||||
|
||||
Each file in `tests/` is its own binary linking the whole app, so the full suite is slow and heavy
|
||||
on a desktop. It runs on GitHub instead: before every release (`.github/workflows/test.yml`), or
|
||||
on demand with `gh workflow run test.yml -f ref=<branch>`.
|
||||
|
||||
Keep the tree free of the third-party branding patterns listed in `.debrand`.
|
||||
|
||||
### Tests
|
||||
|
||||
* Unit tests sit next to the code in `#[cfg(test)]` modules.
|
||||
* Scenario tests live in [tests/](tests). They drive the editor with synthetic pointer and
|
||||
keyboard events; `tests/mcp.rs` covers every MCP tool on a headless session.
|
||||
* Aim for **80% coverage** on code you add or change, including the error paths.
|
||||
* GPU-dependent tests skip when no adapter exists. Set `PAPERCRAFT_REQUIRE_GPU=1` to make them
|
||||
fail instead.
|
||||
* `tests/update.rs` cannot run on Windows (it needs elevation); that failure is known and not
|
||||
yours.
|
||||
* For UI work, run the app, look at it, and attach a screenshot. Headless rendering needs no
|
||||
display: `papercraft --screenshot ui.png --demo --size 1440x900 --scale 2`.
|
||||
|
||||
## Commits
|
||||
|
||||
[Conventional commits](https://www.conventionalcommits.org): `type(scope): summary`, with the
|
||||
types `feat`, `fix`, `refactor`, `docs`, `test`, `chore`, `perf` and `ci`.
|
||||
|
||||
```
|
||||
fix(ui): keep the review row's revert button off the hover edge
|
||||
feat(mcp): add set_screens
|
||||
docs(readme): add the demo video
|
||||
```
|
||||
|
||||
Write the summary in the imperative, under about 72 characters, and use the body to say *why*.
|
||||
Reference the issue (`Fixes #123`).
|
||||
|
||||
## Pull requests
|
||||
|
||||
* Fill in the template: what changed, why, how you tested it, screenshots for UI changes.
|
||||
* Keep it reviewable. If it grows past a few hundred lines of non-generated code, split it.
|
||||
* The branch must be up to date with `main`; rebase rather than merge.
|
||||
* Expect review comments; they are about the code, not you. Push fixes as new commits and we
|
||||
squash on merge.
|
||||
* A maintainer merges once a review is approved.
|
||||
|
||||
## Releases
|
||||
|
||||
Maintainers cut releases. A `v*` tag pushed to GitHub builds Windows, macOS and Linux and
|
||||
publishes them (`.github/workflows/release.yml`). Contributors do not need to bump versions.
|
||||
|
||||
## Licensing
|
||||
|
||||
PaperCraft is dual-licensed under [MIT](LICENSE-MIT) or [Apache-2.0](LICENSE-APACHE). Unless you
|
||||
state otherwise, anything you submit is licensed under the same terms, with no extra conditions.
|
||||
Only submit work you wrote or have the right to submit. Code ported from another project needs a
|
||||
compatible license and an entry in [THIRD_PARTY.md](THIRD_PARTY.md); bundled assets go in
|
||||
[ATTRIBUTION.md](ATTRIBUTION.md).
|
||||
@@ -784,7 +784,7 @@ dependencies = [
|
||||
[[package]]
|
||||
name = "craft-ui"
|
||||
version = "0.1.0"
|
||||
source = "git+https://git.marcospaulo.dev.br/masi/craft-libs?rev=22544b6d619d4f16779b8bdfa3f0b642a86fc065#22544b6d619d4f16779b8bdfa3f0b642a86fc065"
|
||||
source = "git+https://git.marcospaulo.dev.br/masi/craft-libs?rev=9c470aa935c4ce48f2ba4f0a17f9410c0c8660fb#9c470aa935c4ce48f2ba4f0a17f9410c0c8660fb"
|
||||
dependencies = [
|
||||
"egui",
|
||||
]
|
||||
@@ -3128,7 +3128,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "papercraft"
|
||||
version = "0.7.1"
|
||||
version = "0.9.1"
|
||||
dependencies = [
|
||||
"arboard",
|
||||
"axum",
|
||||
@@ -3161,6 +3161,7 @@ dependencies = [
|
||||
"resvg",
|
||||
"rfd",
|
||||
"rmcp",
|
||||
"ruzstd",
|
||||
"semver",
|
||||
"serde",
|
||||
"serde_json",
|
||||
@@ -3174,8 +3175,10 @@ dependencies = [
|
||||
"web-sys",
|
||||
"web-time",
|
||||
"wgpu",
|
||||
"windows-sys 0.61.2",
|
||||
"winit",
|
||||
"winresource",
|
||||
"zstd",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@@ -3853,6 +3856,15 @@ version = "1.0.23"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "cf54715a573b99ac80df0bc206da022bcd442c974952c7b9720069370852e21f"
|
||||
|
||||
[[package]]
|
||||
name = "ruzstd"
|
||||
version = "0.8.3"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "a7c1c839d570d835527c9a5e4db7cb2198683a988cb9d7293fc8674e6bd58fc8"
|
||||
dependencies = [
|
||||
"twox-hash",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "ryu"
|
||||
version = "1.0.23"
|
||||
@@ -4754,6 +4766,12 @@ dependencies = [
|
||||
"thiserror 2.0.21",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "twox-hash"
|
||||
version = "2.1.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "86a801b3cea342a06d468c8710662aa29e5e05e4f5c0d62f00bbb7f2ad7941c2"
|
||||
|
||||
[[package]]
|
||||
name = "type-map"
|
||||
version = "0.5.1"
|
||||
@@ -4777,7 +4795,7 @@ checksum = "f2f6fb2847f6742cd76af783a2a2c49e9375d0a111c7bef6f71cd9e738c72d6e"
|
||||
dependencies = [
|
||||
"memoffset",
|
||||
"tempfile",
|
||||
"windows-sys 0.60.2",
|
||||
"windows-sys 0.61.2",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@@ -6018,6 +6036,34 @@ version = "1.0.23"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "29666d0abbfad1e3dc4dcf6144730dd3a3ab225bbbdac83319345b1b44ccfc1b"
|
||||
|
||||
[[package]]
|
||||
name = "zstd"
|
||||
version = "0.13.3"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "e91ee311a569c327171651566e07972200e76fcfe2242a4fa446149a3881c08a"
|
||||
dependencies = [
|
||||
"zstd-safe",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "zstd-safe"
|
||||
version = "7.3.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "64d80649ab6db9d9f6f9c80a40becd948eda4714a0a5ac8c4d157a32231c7882"
|
||||
dependencies = [
|
||||
"zstd-sys",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "zstd-sys"
|
||||
version = "2.1.2+zstd.1.5.7"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "481ada9c543b2323cbb7bbdbb5249177fbf0188ed959ed2c15e4b22421c84ed3"
|
||||
dependencies = [
|
||||
"cc",
|
||||
"pkg-config",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "zune-core"
|
||||
version = "0.5.3"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "papercraft"
|
||||
version = "0.7.1"
|
||||
version = "0.9.1"
|
||||
edition = "2024"
|
||||
rust-version = "1.95"
|
||||
description = "A native infinite-canvas app for planning, working and sketching"
|
||||
@@ -44,7 +44,7 @@ env_logger = "0.11"
|
||||
rfd = "0.17"
|
||||
fastrand = "2"
|
||||
dirs = "6"
|
||||
craft-ui = { version = "0.1.0", git = "https://git.marcospaulo.dev.br/masi/craft-libs", rev = "22544b6d619d4f16779b8bdfa3f0b642a86fc065" }
|
||||
craft-ui = { version = "0.1.0", git = "https://git.marcospaulo.dev.br/masi/craft-libs", rev = "9c470aa935c4ce48f2ba4f0a17f9410c0c8660fb" }
|
||||
i_overlay = "9.0.1"
|
||||
miniz_oxide = "0.9.1"
|
||||
usvg = "0.48"
|
||||
@@ -97,8 +97,14 @@ reqwest = { version = "0.13", default-features = false, features = ["native-tls"
|
||||
# libc: SIGINT to the spawned chat CLIs.
|
||||
keyring = { version = "3", default-features = false, features = ["apple-native", "windows-native", "sync-secret-service", "crypto-rust"] }
|
||||
libc = "0.2"
|
||||
# Pages and versions on disk are zstd-compressed JSON (`project::packed`).
|
||||
zstd = "0.13"
|
||||
|
||||
# Browser build (`src/web.rs`): canvas + WebGPU/WebGL surface, DOM events instead of winit.
|
||||
# Process RAM and CPU readings for the performance overlay (`ui::perf`).
|
||||
[target.'cfg(windows)'.dependencies]
|
||||
windows-sys = { version = "0.61", features = ["Win32_Foundation", "Win32_System_ProcessStatus", "Win32_System_Threading"] }
|
||||
|
||||
[target.'cfg(target_arch = "wasm32")'.dependencies]
|
||||
wgpu = { version = "30", features = ["webgl"] }
|
||||
wasm-bindgen = "0.2"
|
||||
@@ -106,4 +112,6 @@ wasm-bindgen-futures = "0.4"
|
||||
js-sys = "0.3"
|
||||
console_error_panic_hook = "0.1"
|
||||
console_log = "1"
|
||||
# zstd without C, for the browser: reads the packed files native builds write.
|
||||
ruzstd = "0.8"
|
||||
web-sys = { version = "0.3", features = ["Window", "Document", "Element", "HtmlElement", "HtmlCanvasElement", "KeyboardEvent", "PointerEvent", "WheelEvent", "ClipboardEvent", "DataTransfer", "MediaQueryList", "Location", "Performance", "Navigator", "Clipboard", "CssStyleDeclaration", "console", "WebSocket", "MessageEvent", "CloseEvent", "ErrorEvent", "Storage", "Crypto", "DragEvent", "FileList", "File", "Blob", "Request", "RequestInit", "Response"] }
|
||||
|
||||
@@ -76,6 +76,142 @@ are credited in `THIRD_PARTY.md`.
|
||||
* **Not carried over**: comments, design tokens, AI image generation, video export, teams;
|
||||
moving layers between pages; remote image URLs (see README Known gaps).
|
||||
|
||||
### 2026-10-28: overflow lint rule and `get_bounds`
|
||||
|
||||
* `lint_design` has an `overflow` rule (`src/mcp/lint_overflow.rs`): layers past their artboard or clipping parent, and text taller than its box. Scrolling frames and what is pinned in them are exempt; it is never auto-fixed. It is a pure function over a node set, so a scope filter can pass any subset.
|
||||
* New tool `get_bounds {nodeIds?, pageId?, depth?}` (`src/mcp/bounds.rs`): every layer's rect in one read (about 2000 rows per call, then `continueWith`). Tool count is now 87 (one more than before; if another branch also adds a tool, recount). Tests: `tests/mcp_bounds.rs`.
|
||||
|
||||
### 2026-10-28: agent reads no longer look like edits
|
||||
|
||||
* Read-only tool calls (`get_node_info`, `get_children`, ...) have honest verbs ("Looking at the design") and light the "Working" pill for 1.5 s instead of 6 s, so it goes out right after a sweep ends.
|
||||
* A sweep of reads draws at most one layer outline (a read outlines only when no other read ran in the last 2 s) and no longer pans the follow-agent camera; edits behave as before. "Is this a read" comes from `mcp::tools::edits_doc`.
|
||||
|
||||
### 2026-10-28: 0.9.0 (presentations, critique, several agents, lighter chats)
|
||||
|
||||
* Export the screens as a presentation PDF: cover, contents and a slide per screen (File menu, palette, `--format presentation`, `export_presentation`).
|
||||
* `critique_design` reviews finished work through personas (vision, UX, flow, QA, visual, accessibility, copy, end-user); `design_lessons` keeps the findings the person approved for every later design.
|
||||
* Several agents on one project: named CLI agents (`--as`), conflict reports and `ifRev` on writes, `claim_nodes` / `release_claims` / `list_claims`, scoped delegate builds and per-agent undo. 94 tools.
|
||||
* Screens keep their device height and scroll what does not fit; sections group screens on the canvas; pages can carry icons.
|
||||
* UI kits for shadcn, MUI, Mantine, Bootstrap and Chakra; `write_html` follows the browser more closely.
|
||||
* Memory: chat screenshots move to files (kept 14 days), thumbnails stay small, canvas images decode only for the GPU. A long chat dropped from about 1 GB to about 400 MB.
|
||||
* Fix: long answer options in a question card wrap instead of widening the whole chat.
|
||||
|
||||
### 2026-10-28: 0.8.4 (demo video, fresh screenshots)
|
||||
|
||||
* README opens with a time-lapse of designing a habit-tracker app (`docs/demo.gif`, full video `docs/demo.mp4`), and every screenshot is retaken from that design.
|
||||
* Fix: the Performance overlay reads its settings from the project config folder, so `PAPERCRAFT_HOME` isolates it too.
|
||||
|
||||
### 2026-10-28: 0.8.3 (menus, panel grips, narrow windows)
|
||||
|
||||
* Menus open 6 px below their button, are at least 180 px wide and show an icon beside each item. Below 1100 px the hamburger opens every menu in one popup.
|
||||
* Side panels: a slim rounded grip in the gap resizes them (double click resets) and `/` hides or shows both. Panels size to their content and step aside when the window is too narrow for the canvas.
|
||||
* Sharper window buttons (pixel-snapped glyphs); the hamburger morphs into a back arrow while the File / Edit strip slides open and shut.
|
||||
* Fixes: lint Fix buttons no longer cover the issue text; review rows keep their badge and revert button off the hover edge; the Export button stays on one line.
|
||||
|
||||
### 2026-10-28: 0.8.2 (refresh-rate cap, accurate RAM/CPU, toolbar)
|
||||
|
||||
* Settings > Performance > Refresh rate is now a real frame cap applied live (30 to 360 Hz, 60 by default); **Auto** draws as fast as the display allows and is the default on macOS.
|
||||
* Performance Monitor: RAM is the private working set and CPU is divided by logical cores on Windows, so both match Task Manager.
|
||||
* Windows and Linux toolbar: a hamburger button shows or hides the File / Edit strip (remembered); the close button uses the theme's danger colour on the acrylic surface, with hover animation and a pointing-hand cursor.
|
||||
|
||||
### 2026-10-28: 0.8.1 (Performance Monitor on Windows, Design tab speed)
|
||||
|
||||
* Performance Monitor: RAM (working set) and CPU now show on Windows; before they were `n/a` there. The overlay and slow-frame badge judge frames against a refresh rate you pick in Settings > Performance: 30 to 360 Hz (144, 165 and 240 included), 60 by default.
|
||||
* Design tab: the lint and the open-feedback scan are kept until the document changes instead of walking every node each frame; a 12.6k-node page no longer drops to a few FPS while the tab is open.
|
||||
* Windows and Linux: window buttons in the toolbar; controls and acrylic come from craft-ui.
|
||||
|
||||
### 2026-10-27: 0.8.0 (screens, packed pages, canvas performance)
|
||||
|
||||
* Screens (`specs/screens`): a frame can be declared a screen or an overlay (drawer, modal, sheet) with `set_screens`, inspector toggles, or Declare N screens on the page. Agent edits to layers hidden behind an overlay or opaque layer in their screen are refused unless `allowHidden`; partly covered ones are reported with their visible share. `get_basic_info` lists screens, `get_node_info` tells a layer's visibility, `lint_design` skips hidden layers, On click lists screens, nested screens get canvas labels.
|
||||
* Pages and saved versions are stored as zstd-compressed compact JSON (`.json.zst`, project format 3): the 68 MB Interview project is 1.3 MB on disk and loads faster. A legacy `.json` still reads and is replaced on the next save; older builds refuse format 3.
|
||||
* Canvas performance: the editor logs which layers each change touched, so the scene cache re-tessellates only those and keeps no copy of the document (443 → 346 MB on Interview). Zoom holds its geometry until it settles, tiny layers are skipped, vertices are 24 bytes, redraws follow vsync, the idle pointer no longer redraws, freed memory goes back to the system when idle, off-screen frame labels are skipped, and the layers panel keeps its row heights between frames (panning a large page: ~9 → ~0.7 ms a frame).
|
||||
* Frame labels: none on frames too narrow on screen, overlapping labels are dropped (selected and larger frames first), long names end in an ellipsis.
|
||||
* Dropdowns size to their longest option (capped), keep the name of `A / B / Name` options, scroll when long and show the full name on hover.
|
||||
* Settings: a Performance page (FPS, frame time, RAM, CPU, GPU, optional overlay and slow-frame badge), agent logos in the agent rows; the Chat page no longer collapses.
|
||||
|
||||
### 2026-10-25: 0.8.0 (properties modal, row merges)
|
||||
|
||||
* Properties modal (inspector, on a main: Edit properties…): a tab per property (name, kind, layer, default, delete); an options property as a Table (a row per option, a column per layer · style; colours picked from the project's variables with a swatch, visibility as a toggle, icon, image and text fields; add or remove options and columns) or as Source (each option's changes as JSON with syntax highlighting); templates from the + Property menu; Save replaces them all. The inline list is name, kind and a remove button. The `status` template writes colours the project has as variables as those variables.
|
||||
* Canvas overlays (agent glow, agent outlines, review outlines, the agent-elsewhere chip) sit below modals instead of showing through them. Two segmented controls in one row no longer share widget ids (the second did not respond).
|
||||
* `merge_variants` keeps what each moved instance shows (texts that came from its old variant), carries nested instances' property values (a badge's Tone) in the options, and takes `textLayers` for state texts only.
|
||||
|
||||
### 2026-10-25: 0.8.0 (prototype links tool, merge icon colours)
|
||||
|
||||
* `set_prototype_links`: agents can link a layer to a screen for Present mode (back arrows, rows, tabs); before, only the inspector could.
|
||||
* `merge_variants` compares an icon's colour (keeping its variable), now that icons are compared as one unit.
|
||||
|
||||
### 2026-10-25: 0.8.0 (data safety fixes)
|
||||
|
||||
* Sync no longer throws away an instance written over a nested one the way older versions stored it (its own root, no swap): it becomes a swap of the main's child at that place. Projects built before #11 lost such layers (a checked checkbox, a status badge) on the next edit of the outer main.
|
||||
* Icons: the HTML parser keeps attribute names in lowercase, so the icon and plugin code never removed the SVG's original `viewBox`; since #14 that made `<x-paper-icon>` (and icon swaps) scale twice and come out tiny. Unreleased builds only; 0.7.3 is not affected.
|
||||
* `merge_variants` refuses merges that would leave one option and changes nothing then.
|
||||
|
||||
### 2026-10-25: 0.8.0 (merge variants, pinned bars)
|
||||
|
||||
* `merge_variants`: per-state components (`Tab bar / Hoje`, `Status / Sucesso`...) become one component with an enum property. Each variant's differences from the base, matched by layer path (fills, colours, borders, weight, radius, visibility, icons; texts on request), become its option; every instance on every page moves to the base with its value; the base takes the family name; the emptied variants are deleted. A variant with layers the base lacks is left out and reported.
|
||||
* Absolute children of a scrolling screen stay pinned while its content scrolls (a tab bar, a floating button), and do not add to the scroll range.
|
||||
|
||||
### 2026-10-25: 0.8.0 (fix #22)
|
||||
|
||||
* #22: a hug column whose width comes from its parent (stretched or filled) re-measures its height once its text wraps at that width, and the parent measures again, instead of keeping a height measured while the text was narrow.
|
||||
|
||||
### 2026-10-25: 0.8.0 (component properties)
|
||||
|
||||
* Main components carry properties (`Node.props`): `text`, `bool`, `icon` and `enum`, whose options are changes in the overrides format (a layer name, `$root` or a path `Item > Label`, to a text or styles that may hold `text`, `icon` and `visibility`), so they restyle, retext, show, hide or re-icon any layer. Instances keep their values (`prop_values`) as overrides, so main edits keep them; changing the definitions re-applies every instance on every page.
|
||||
* Templates: `text` (a property per text layer), `active` (which item of a tab bar, nav or segmented row is active) and `status` (options with a colour tint the root and colour the label and icon).
|
||||
* `set_component_props`, `set_instance_props`, `props='{...}'` on `<x-paper-instance>`, properties in `get_components`, `{Prop}` in code link templates, and an inspector section (a control per property on an instance; Texts and Active item templates on a main). Icon swaps keep the layer's name and link (a `children` override); recoloured icon shapes inside instances now keep their colour after a sync.
|
||||
* Spec: `specs/component-props/spec.md`.
|
||||
|
||||
### 2026-10-25: 0.8.0 (scrolling screens)
|
||||
|
||||
* Screens keep their size and scroll what overflows: a frame's `scroll` flag (CSS `overflow: auto|scroll`, `overflow-y-auto` in the Tailwind export) makes it fixed height and clipped, and the wheel over it scrolls its content on the canvas and in Present, then pans once the content ends. The offset is view state, not saved; hit-testing and overlays follow it.
|
||||
* Toggles: a scroll button beside each screen's name (shown when it scrolls, overflows, or is hovered), Scroll overflow on a selected frame, and Screens scroll on the page for every screen at once. A fit-content screen that grew goes back to its min height.
|
||||
* Agents are told to keep screens at their size and use overflow:auto for long content.
|
||||
|
||||
### 2026-10-25: 0.8.0 (fixes #19, #20, #21)
|
||||
|
||||
* #19: a clipping frame draws its border after its children, so filled rows no longer hide it. Clipping stays rectangular: children's square corners still show past a rounded border.
|
||||
* #20: a border written with a colour variable (`1px solid var(--border)`) binds the stroke, a literal one unbinds it, and reads show `var(--name)` for bound strokes. `find_nodes` says when it stopped at 500 matches.
|
||||
* #21: hug (fit-content) frames grow around growing children (CSS flex-basis auto) instead of staying at their min height; with short content the min height stays and the growing child fills it, so a pinned footer works.
|
||||
|
||||
### 2026-10-25: 0.8.0 (follow agents, skeletons)
|
||||
|
||||
* Follow agents (Settings, Chat; on by default): in Design and Chat mode alike, the canvas pans, and switches page, to the layer any agent changes (the chat, Claude Code over MCP, a helper). Moving the canvas yourself pauses it for a moment; off, a chip offers the agent's page.
|
||||
* Skeletons: the moment the model starts writing a tool call (`ToolDraft` and `ToolInput` events from Claude Code's stream and the API), the canvas shows a shimmering skeleton over its target, or where a new artboard goes, labelled with what it is doing, until the call has run. Fresh agent content comes in through a skeleton that fades, so an outline never frames empty space.
|
||||
* Top bar: the title and the agent pill leave room measured from the buttons on the right, so nothing overlaps at narrow widths.
|
||||
|
||||
### 2026-10-25: 0.8.0 (fixes #14 to #18)
|
||||
|
||||
* #14: `write_html` fits an `<svg>` viewBox into its width and height like a browser (centred, aspect kept).
|
||||
* #15: a note on something placed straight in its artboard treats the artboard as the screen: tidy keeps cards off it instead of in its free space.
|
||||
* #16: `not-an-instance` no longer matches look-alikes with a different icon; its fix names the `<x-paper-instance>` to write (swap_instance refuses plain frames).
|
||||
* #17: instances with their own text re-measure it when the main's text style changes, so hug buttons keep fitting their labels (also covers the size reset after a swap).
|
||||
* #18: `lint_design` reports borders whose hex equals a color variable, and `fix` binds them (`stroke`), so a mode switch reaches them.
|
||||
|
||||
### 2026-10-25: 0.7.3 (QA sub-agent, helper agents, auto mode, mid-turn messages, isolated dev settings)
|
||||
|
||||
* QA sub-agent: Claude Code chats always get a Sonnet `qa` agent that lints and screenshots built frames and returns only findings, so screenshots stay out of the main context.
|
||||
* Helper agents (`src/mcp/delegate.rs`, Settings, Chat, Helper): `delegate` hands `qa`, `read` or `build` tasks to a cheaper agent CLI (pi with MiniMax M3.1 Flash, opencode, an Ollama-backed agent, any command taking `{prompt}`). It drives PaperCraft through `papercraft-cli`, runs off the UI thread, and only its last 6,000 characters come back. With a helper set, the chat agent orchestrates: keeps the brief and taste, delegates review, bulk reading and fully specified edits.
|
||||
* Dev config isolation: `PAPERCRAFT_HOME` also isolates the chat settings (`$PAPERCRAFT_HOME/.config`), so a second copy for testing never touches the installed app's settings.
|
||||
* Live check in an isolated copy: `delegate` ran the pi helper (MiniMax M3.1 Flash) as QA, a message added mid-turn went Waiting then Seen, and the agent drafted #13.
|
||||
* Fixes #10, #11, #12, #13:
|
||||
* #10: `move_nodes` to another page keeps mains' component keys and relinks every instance to moved nodes; new `rename_file` renames a project.
|
||||
* #11: swapped nested instances persist as swap overrides (`InstanceLink.swap`), preserving component identity across outer component updates and copies.
|
||||
* #12: `move_nodes` to another page takes the moved nodes' annotations along; detached notes resolve as `Detached #n`.
|
||||
* #13: `get_computed_styles` reports a text colour bound to a variable as `var(--name)`.
|
||||
* Auto mode (the composer's Auto chip): when a turn ends on `ask_user` questions, the first (recommended) option of each is sent and the chat goes on, until Stop or a turn hits its budget. The agent is told to put its recommendation first, default what only the user can know, and end each turn with next steps.
|
||||
* The Present button uses a play icon drawn like the icons beside it. Composer chips wrap instead of running under Stop and Add. Top bar: the agent pill drops its text when it would run under the buttons on the right.
|
||||
* While a chat turn works, the composer's Add (or Enter) queues a message (`src/mcp/steer.rs`). It rides on the agent's next PaperCraft tool result for that chat, so every backend reads it mid-turn; the composer shows each as Waiting or Seen. What no tool call picked up is sent as the next message when the turn ends, or goes back into the box after Stop.
|
||||
|
||||
### 2026-10-24: 0.7.2 (UI kits, code links, issues from the app, design playbook)
|
||||
|
||||
* Code links (Figma Code Connect style): a main component carries its library import and a React and an egui template (`set_code_link`). The React, Tailwind, inline JSX and egui exports write linked instances as that code, with overrides filled in and imports gathered once; the AI spec lists them as Library Components with a "use it, do not rebuild it" rule and stops describing their inner layers.
|
||||
* UI kits (`src/ui_kits.rs`, `apply_ui_kit`): shadcn/ui, Ant Design, React Bits and egui, each with Light and Dark variables, tokens and components in its look and density, all linked. The chat brief asks for the code library and starts from its kit.
|
||||
* Issues from the app (`src/issues.rs`): the agent's `report_issue` draft card (Send or Discard) and a Report a PaperCraft issue form, filed on the repository in Settings (token in the keychain, else the `tea` login), de-duplicated by title against open and closed issues.
|
||||
* design-playbook in the chat: with the `playbook` CLI installed, the brief asks whether to follow the playbook and the agent looks rules up with `design_rules`, citing ids in its report.
|
||||
* Top bar: project name and page picker on one centred row; the two-row title had outgrown the bar and covered the canvas.
|
||||
* Evidence: `src/ui_kits.rs`, `src/issues.rs`, `src/mcp/codegen.rs` (`linked_components_export_as_library_code`), `specs/ui-kits/spec.md`.
|
||||
|
||||
### 2026-10-24: 0.7.1 (rename fix)
|
||||
|
||||
* Enter, Escape and clicking away end a rename again (projects on the home screen, library assets, versions). The fields took focus back before checking whether they had lost it.
|
||||
@@ -115,6 +251,17 @@ are credited in `THIRD_PARTY.md`.
|
||||
* Agent view lists runs and supports review, whole-run revert, per-change undo and accept all. Review adds canvas outlines and a finish toast; palette commands review or revert the last run.
|
||||
* Id-paired page diffs power review; History version compare UI remains todo. Completed with full restore (including variables, modes and tokens), tool edit classification, and wasm support.
|
||||
|
||||
### 2026-10-28: Incremental lint
|
||||
|
||||
Agents re-linted whole pages after every edit. A bounded change log (`src/editor/changes.rs`, the
|
||||
last 10000 layer changes, each with the client that made it) now records which layers every
|
||||
commit, undo and redo touched; variable edits count as touching the layers bound to them. Write
|
||||
tools return `rev`, `get_basic_info` reports it, `get_changes {since, page?, exclude?, by?}` lists
|
||||
the changes, and `lint_design {since | changedOnly}` checks only those layers plus their
|
||||
ancestors, descendants and siblings (`src/mcp/incremental.rs`), with `covered` saying what ran.
|
||||
Tests: `tests/incremental.rs`, unit tests next to the code, the attribution check in
|
||||
`tests/mcp.rs::parallel_sessions_get_their_own_runs`.
|
||||
|
||||
### 2026-10-21: Design libraries and offline CLI
|
||||
|
||||
* Variables are now collections with modes, slash groups, four types and aliases, stored in `design.json` (project version 2; 0.4.0 refuses migrated projects). Each page keeps a derived cache; every edit is one undo step per page, and the page-only removals are gone. Per-page active mode per collection.
|
||||
|
||||
@@ -12,9 +12,17 @@
|
||||
</p>
|
||||
|
||||
<p align="center">
|
||||
<img src="docs/screenshots/readme/hero.png" alt="PaperCraft with the Redesign page of its own design file open: layers on the left, the canvas in the middle, the inspector on the right" width="100%">
|
||||
<a href="docs/demo.mp4">
|
||||
<img src="docs/demo.gif" alt="PaperCraft's editor breaking apart into its panels on a 3D stage, then chat mode with an agent, annotations pinned to a sign-in screen, the variables and libraries modals, and the home screen" width="100%">
|
||||
</a>
|
||||
<br>
|
||||
<sub>PaperCraft editing its own design file (the Redesign page).</sub>
|
||||
<sub>A 40-second tour: the editor, chat mode, annotations and design systems. <a href="docs/demo.mp4">Watch it in full quality</a> (MP4, 1080p60). Rendered from the app's own design with <a href="tools/showcase/README.md">tools/showcase</a>, not screen-recorded.</sub>
|
||||
</p>
|
||||
|
||||
<p align="center">
|
||||
<img src="docs/screenshots/readme/hero.png" alt="PaperCraft with the Pulse habit-tracker design open: layers on the left, three annotated screens on the canvas, the inspector on the right" width="100%">
|
||||
<br>
|
||||
<sub>The finished design: three screens, a component library and annotations.</sub>
|
||||
</p>
|
||||
|
||||
<p align="center">
|
||||
@@ -25,6 +33,7 @@
|
||||
<a href="#keyboard-shortcuts">Shortcuts</a> ·
|
||||
<a href="#status-and-known-limits">Status</a> ·
|
||||
<a href="#project-layout">Layout</a> ·
|
||||
<a href="#contributing">Contributing</a> ·
|
||||
<a href="#license-and-credits">License</a>
|
||||
</p>
|
||||
|
||||
@@ -54,11 +63,11 @@ It is an alpha. It is good for building screens, design systems and sketches, an
|
||||
<table>
|
||||
<tr>
|
||||
<td width="50%" valign="top">
|
||||
<img src="docs/screenshots/readme/variables.png" alt="The Variables modal listing the Colors collection with four Catppuccin modes" width="100%">
|
||||
<br><sub>Variables modal: collections, modes, groups and types.</sub>
|
||||
<img src="docs/screenshots/readme/variables.png" alt="The Variables modal listing the Colors collection with Light and Dark values for brand, foreground and background" width="100%">
|
||||
<br><sub>Variables modal: collections, modes (Light and Dark here), groups and types.</sub>
|
||||
</td>
|
||||
<td width="50%" valign="top">
|
||||
<img src="docs/screenshots/readme/assets.png" alt="The Assets side view with components grouped into Banner, Button, Checkbox and Chip" width="100%">
|
||||
<img src="docs/screenshots/readme/assets.png" alt="The Assets side view with the Habit row component and the shadcn Button kit" width="100%">
|
||||
<br><sub>Assets view: components grouped by name, from this file and enabled libraries.</sub>
|
||||
</td>
|
||||
</tr>
|
||||
@@ -68,12 +77,32 @@ It is an alpha. It is good for building screens, design systems and sketches, an
|
||||
<br><sub>Libraries modal: publish this file, enable libraries from the store.</sub>
|
||||
</td>
|
||||
<td width="50%" valign="top">
|
||||
<img src="docs/screenshots/readme/agent-review.png" alt="Agent run review: a list of changes on the left and green, yellow and red outlines on the canvas" width="100%">
|
||||
<br><sub>Review of an agent run, with the changes outlined on the canvas.</sub>
|
||||
<img src="docs/screenshots/readme/agent-review.png" alt="The Agent side view: a finished run with Review and Revert, above the list of earlier runs" width="100%">
|
||||
<br><sub>The Agent view: runs, with Review and Revert for the latest.</sub>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<table>
|
||||
<tr>
|
||||
<td width="50%" valign="top">
|
||||
<img src="docs/screenshots/readme/toolbar-panels.png" alt="The toolbar with the menu button folded into a back arrow, the File to Theme strip, and the floating left panel with a slim grip beside it" width="100%">
|
||||
<br><sub>Toolbar and panels: the menu button shows or hides the File / Edit strip, and the slim grip between a panel and the canvas resizes it (double click resets). <kbd>/</kbd> hides both side panels.</sub>
|
||||
</td>
|
||||
<td width="50%" valign="top">
|
||||
<img src="docs/screenshots/readme/menus.png" alt="The Tools menu open below its button, each tool with an icon and its shortcut" width="100%">
|
||||
<br><sub>Menus open a little below their button, are never narrower than 180 px, and carry an icon next to each item.</sub>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="50%" valign="top">
|
||||
<img src="docs/screenshots/readme/annotations.png" alt="The Annotations side view listing five notes grouped by screen, with their category chips" width="100%">
|
||||
<br><sub>Annotations: rule, behaviour, content and data notes, kept with the layers they describe.</sub>
|
||||
</td>
|
||||
<td width="50%" valign="top"></td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
**Prototyping and review**
|
||||
* Prototype links between frames and a **Present** mode that follows them with a camera glide.
|
||||
* **Version history:** named and automatic saved versions per page; rename, restore, delete.
|
||||
@@ -90,11 +119,11 @@ Projects live in `~/Documents/papercraft/<name>/` (`project.json`, one JSON file
|
||||
|
||||
## Agents
|
||||
|
||||
PaperCraft exposes **70 tools** (`src/mcp/tools.rs`) three ways. They run the same code inside the app.
|
||||
PaperCraft exposes **98 tools** (`src/mcp/tools.rs`) three ways. They run the same code inside the app.
|
||||
|
||||
| Way | Notes |
|
||||
|---|---|
|
||||
| MCP over HTTP | Built into the app: `http://127.0.0.1:29980/mcp`. Loopback only; browser requests (with an `Origin` header) and foreign `Host` headers are rejected. `PAPERCRAFT_MCP_PORT` changes the port, `PAPERCRAFT_MCP=0` turns it off. |
|
||||
| MCP over HTTP | Built into the app: `http://127.0.0.1:29980/mcp`. Loopback only; browser requests (with an `Origin` header) and foreign `Host` headers are rejected. `?tools=core` lists 33 common tools in full plus `search_tools` and `call_tool`, which reach the rest (about a third of the schema size); lean chat agents use it. `PAPERCRAFT_MCP_PORT` changes the port, `PAPERCRAFT_MCP=0` turns it off. |
|
||||
| MCP over stdio | `papercraft-mcp` relays stdio to the running app. It lists tools even when the app is closed. |
|
||||
| Shell | `papercraft-cli` calls the same tools, so an agent with a terminal needs no schemas in its context. |
|
||||
|
||||
@@ -138,10 +167,10 @@ EOF
|
||||
|
||||
### Chat
|
||||
|
||||
Chat mode (⌘J, or `Design | Chat` in the top bar) puts a conversation next to the canvas. It runs Claude Code and Codex through their CLIs, any agent that speaks the Agent Client Protocol (ACP, such as OpenCode, Gemini CLI or Cursor) found on your PATH, or the Anthropic API with your own key. It shows tool calls, checkpoints and run review in the thread. Chats are saved in the project's `chats/` folder. See [docs/chat.md](docs/chat.md).
|
||||
Chat mode (⌘J, or `Design | Chat` in the top bar) puts a conversation next to the canvas. It runs Claude Code and Codex through their CLIs, any agent that speaks the Agent Client Protocol (ACP, such as OpenCode, Cursor or Goose) found on your PATH, or the Anthropic API with your own key. It shows tool calls, checkpoints and run review in the thread. Chats are saved in the project's `chats/` folder. See [docs/chat.md](docs/chat.md).
|
||||
|
||||
<p align="center">
|
||||
<img src="docs/screenshots/readme/chat.png" alt="Chat mode: the chat column on the left shows a finished agent run with its Review, Revert and Accept actions, and the canvas on the right" width="100%">
|
||||
<img src="docs/screenshots/readme/chat.png" alt="Chat mode: the chat column on the left with its starter prompts and input, and the annotated habit-tracker screens on the canvas" width="100%">
|
||||
<br>
|
||||
<sub>Chat mode with a finished agent run: review, revert or accept from the thread.</sub>
|
||||
</p>
|
||||
@@ -162,12 +191,13 @@ Releases are at [git.marcospaulo.dev.br/masi/papercraft/releases](https://git.ma
|
||||
|
||||
| Build | File |
|
||||
|---|---|
|
||||
| Windows (x86_64) | `papercraft-<version>-windows-x86_64.zip`: `papercraft.exe`, `papercraft-cli.exe`, `papercraft-mcp.exe` and `papercraft-relay.exe` |
|
||||
| macOS app (Apple silicon) | `papercraft-<version>-macos-aarch64.dmg`, containing PaperCraft.app |
|
||||
| Linux (x86_64) | `papercraft-<version>-linux-x86_64.tar.gz` |
|
||||
| CLI tools, macOS | `papercraft-cli-<version>-macos-aarch64.zip` (`papercraft-cli` and `papercraft-mcp`) |
|
||||
| CLI tools, Linux | `papercraft-cli-<version>-linux-x86_64.tar.gz` |
|
||||
|
||||
macOS builds are ad-hoc signed and not notarized: on another Mac, open the app with right-click, Open the first time. Other platforms: build from source.
|
||||
The Windows zip is unsigned: SmartScreen may ask you to confirm the first run. macOS builds are ad-hoc signed and not notarized: on another Mac, open the app with right-click, Open the first time. Other platforms: build from source.
|
||||
|
||||
### Build from source
|
||||
|
||||
@@ -179,9 +209,10 @@ cargo build --release
|
||||
./target/release/papercraft ~/Documents/papercraft/Plan # open a project folder
|
||||
./target/release/papercraft --demo # sample board, not saved
|
||||
packaging/macos/package.sh # PaperCraft.app on a DMG, plus the CLI zip
|
||||
pwsh packaging/windows/package.ps1 -Arch x64 # Windows MSI, portable zip and CLI zip
|
||||
```
|
||||
|
||||
**macOS:** `xcode-select --install` for the linker. It renders with Metal through wgpu. **Linux:** install the runtime libraries (`sudo apt install libxkbcommon-x11-0 libxcb-xkb1 libvulkan1 mesa-vulkan-drivers` on Debian or Ubuntu); it runs on X11 and Wayland through Vulkan, with GL as a fallback, and file dialogs use the XDG desktop portal.
|
||||
**Windows:** the MSVC build tools (Visual Studio Build Tools with the C++ workload); it renders through wgpu on Direct3D 12 or Vulkan. **macOS:** `xcode-select --install` for the linker. It renders with Metal through wgpu. **Linux:** install the runtime libraries (`sudo apt install libxkbcommon-x11-0 libxcb-xkb1 libvulkan1 mesa-vulkan-drivers` on Debian or Ubuntu); it runs on X11 and Wayland through Vulkan, with GL as a fallback, and file dialogs use the XDG desktop portal.
|
||||
|
||||
To run a test copy next to your own PaperCraft, give it its own folder and port: `PAPERCRAFT_HOME=/tmp/pc PAPERCRAFT_MCP_PORT=29998 ./target/release/papercraft`.
|
||||
|
||||
@@ -228,24 +259,32 @@ The scenario tests drive the editor with synthetic pointer and keyboard events;
|
||||
| PageUp / PageDown | Previous / next page | ⌘\\ | Show / hide UI |
|
||||
| ⌘J | Design / Chat mode | ⌘L | Add selection to chat (Chat mode) |
|
||||
| N | Annotate tool | ⌘⇧A | Annotations: full, badges, hidden |
|
||||
| / | Show / hide the side panels | | |
|
||||
|
||||
Draw a frame around existing shapes and it adopts them; dragging a layer into or out of a frame re-parents it. Hold ⌘ while dragging to suspend snapping.
|
||||
|
||||
## Status and known limits
|
||||
|
||||
> [!IMPORTANT]
|
||||
> PaperCraft is an alpha. [ROADMAP.md](ROADMAP.md) lists what is missing, in priority order; [PROGRESS.md](PROGRESS.md) is the milestone history.
|
||||
> PaperCraft is an alpha (0.8.x). It is used daily on Windows, macOS and Linux, and its project format migrates forward, but expect rough edges. [ROADMAP.md](ROADMAP.md) lists what is missing, in priority order; [PROGRESS.md](PROGRESS.md) is the milestone history.
|
||||
|
||||
**What works today:** local projects with pages and an infinite canvas; vector, text, auto layout, constraints, components with properties and variants, variables with modes, shared libraries and screens; annotations, lint and Present mode with prototype links; PNG, SVG and PDF export, Figma, Excalidraw and SVG import; the MCP server, CLI (online and offline) and in-app Chat mode; versions, agent runs with review and revert; optional relay sync.
|
||||
|
||||
**Known limits:**
|
||||
|
||||
* **No rotation.** Nodes are axis-aligned boxes; rotated imports are baked into paths.
|
||||
* **Text** is Inter only, with no shaping (no ligatures, complex scripts or RTL) and no font picker. IME preedit is not displayed.
|
||||
* **Rendering approximations.** Frame clipping is a rectangle, so rounded frames do not clip their corners. Overlay, dodge, burn, light, difference, exclusion and the HSL blend modes draw as Normal on the canvas (they are exact in SVG and PDF export). There is no layer or background blur yet.
|
||||
* **Variables:** gradients keep fixed colors; there are no text styles and no component variants or properties.
|
||||
* **Variables:** gradients keep fixed colors, and there are no text styles (named type styles that update every text layer).
|
||||
* **Components:** properties (text, bool, icon, enum) and `merge_variants` cover variants, but there are no variant sets with several axes, and no responsive per-breakpoint variants or breakpoint preview.
|
||||
* **Prototyping:** links and flows work in Present mode; smart transitions and hover states do not exist yet.
|
||||
* **Booleans are destructive:** the result is a new vector path with flattened curves.
|
||||
* **`write_html`** ignores margin, tables and transforms (it reports them as `ignoredStyles`) and does not fetch remote images; pass a local path or a `data:` URI.
|
||||
* **Agents:** one project is open at a time in the app, and `move_nodes` stays on one page. The in-app Chat mode runs Claude Code, Codex, ACP agents or your own Anthropic key. Agents that are not in Chat connect over MCP or the CLI.
|
||||
* **Sharing** has no live presence (cursors, selections) yet.
|
||||
* **Scale:** cached frames take about 3 ms at 10k visible nodes; it is not tuned for 100k.
|
||||
* **Pen pressure** is simulated from stroke velocity on macOS tablets, because winit 0.30 does not expose it for mouse-like pen events.
|
||||
* **Releases** cover macOS (Apple silicon) and Linux x86_64. Windows packaging scripts exist but are not part of releases.
|
||||
* **Releases:** the Gitea releases ship Windows x86_64. macOS (Apple silicon) and Linux x86_64 builds come from the packaging scripts or from source; the Linux build is not part of the current releases.
|
||||
* **PDF** text is outlined, not selectable.
|
||||
|
||||
## Project layout
|
||||
@@ -280,12 +319,14 @@ analysis/ behaviour studies and design notes
|
||||
docs/ guides and screenshots
|
||||
```
|
||||
|
||||
## Contributing
|
||||
|
||||
Bug reports, ideas, docs and code are welcome. Start with [CONTRIBUTING.md](CONTRIBUTING.md) (setup, checks, commits, pull requests) and [RULES.md](RULES.md) (the standards a change is reviewed against). AI tools are welcome under the [AI usage policy](AI_POLICY.md), and coding agents should read [AGENTS.md](AGENTS.md). Security problems go through [SECURITY.md](SECURITY.md), and everyone follows the [Code of Conduct](CODE_OF_CONDUCT.md).
|
||||
|
||||
## License and credits
|
||||
|
||||
Dual-licensed under [MIT](LICENSE-MIT) or [Apache-2.0](LICENSE-APACHE), at your option.
|
||||
|
||||
Bundled fonts, icons and other assets keep their own licenses, listed in [ATTRIBUTION.md](ATTRIBUTION.md); Inter is © The Inter Project Authors under the SIL Open Font License 1.1. Some algorithms are ported from MIT-licensed projects (rough.js, hachure-fill, Excalidraw), with their notices in [THIRD_PARTY.md](THIRD_PARTY.md).
|
||||
|
||||
PaperCraft started as a fork of [storytold/paper-rs](https://git.marcospaulo.dev.br/storytold/paper-rs); thanks to its contributors.
|
||||
|
||||
PaperCraft is not affiliated with Paper or Figma. Only the behavior of other tools was studied (see `analysis/`); no code, shaders, icons, fonts or assets from them are used.
|
||||
|
||||
@@ -22,7 +22,7 @@ Agents can already build a design system through the tools; people cannot yet ma
|
||||
| 7 | Number variables (spacing, radius, font size) | **done** | Typed number, string and boolean variables in collections with groups and aliases; fields bind (size, gap, padding, radius, font size, line height, opacity, visible) in the inspector and `bind_variable`. |
|
||||
| 8 | Stroke and gradient variables | partial | Strokes and text color bind to variables. Gradients keep fixed colors. |
|
||||
| 9 | Text styles | todo | Named type styles (Heading / L, Body / M) that update every text layer using them. |
|
||||
| 10 | Component variants and properties | todo | Variants are separate components named `Button / Primary`. No variant sets, boolean or text properties. |
|
||||
| 10 | Component variants and properties | partial | Main components carry text, bool, icon and enum properties; `merge_variants` folds per-state components into one. Multi-axis variant sets todo. |
|
||||
| 11 | Swap instance, detach by tool | **done** | `swap_instance` and `detach_instance` MCP tools + UI controls in Design tab and Inspector. |
|
||||
| 12 | Cross-page and shared libraries | **done** | Instances of a main on any page; publish a project as a library, enable, update and disable it in other projects (Libraries modal, `*_library` tools). |
|
||||
| 13 | Export design tokens | **done** | `get_variables` with `format: "css"`, `"json"` (W3C DTCG + modes), or `"tailwind"` (`@theme`), plus Copy CSS / Copy JSON in Design tab. |
|
||||
@@ -32,7 +32,7 @@ Agents can already build a design system through the tools; people cannot yet ma
|
||||
|
||||
| # | Item | Status | Notes |
|
||||
|---|---|---|---|
|
||||
| 15 | MCP and CLI tool surface | **done** | 67 tools, one undo step per call, `papercraft-cli list / schema / call`. |
|
||||
| 15 | MCP and CLI tool surface | **done** | 98 tools, one undo step per call, `papercraft-cli list / schema / call`. |
|
||||
| 16 | Agent skills | **done** | `skills/papercraft` and `skills/papercraft-design`. |
|
||||
| 17 | Accessibility annotations | todo | Reading order, roles and alt text on layers, checked by the linter. |
|
||||
| 18 | Code export from frames | **done** | `get_jsx` supports `format: "inline"`, `"tailwind"` (Tailwind utility classes), and `"html"` (HTML + CSS rules with `:root` variables). |
|
||||
@@ -63,7 +63,7 @@ Agents can already build a design system through the tools; people cannot yet ma
|
||||
| 32 | Version history | **done** | Named and automatic saved versions per page: rename, restore, delete (`src/versions.rs`). Restore now includes variables and tokens; compare todo. |
|
||||
| 33 | Figma import | **done** | `.fig` binary (Kiwi wire decoder + zip container) and Figma REST API JSON import in `src/io/fig.rs`. |
|
||||
| 34 | Multiplayer and cloud sync | partial | Optional shared projects through the relay, with merge of concurrent edits to one page. Presence (cursors, selections) todo. Stays optional. |
|
||||
| 35 | Release builds for Windows and Linux | todo | The code targets them (wgpu, winit); packaging today is the macOS DMG and the `papercraft-cli` zip. |
|
||||
| 35 | Release builds for Windows and Linux | partial | Windows x86_64 zips are released and `packaging/windows` builds an MSI; Linux x86_64 is not in the current releases. |
|
||||
|
||||
## 5. Quality
|
||||
|
||||
@@ -92,4 +92,5 @@ Spec: [specs/agent-runs/spec.md](specs/agent-runs/spec.md), tasks: [specs/agent-
|
||||
| # | Item | Status | Notes |
|
||||
|---|---|---|---|
|
||||
| 47 | Design annotations | **done** | Notes with leader lines and categories, templates per project and page, view modes (⌘⇧A), Annotate tool (N), side view, inspector section, six MCP tools; see `docs/annotations.md`. |
|
||||
| 48 | ACP agents in Chat | **done** | Any ACP agent on the PATH (OpenCode works; Gemini CLI refuses ACP clients for now; Cursor needs `cursor-agent login`), npx agents after enabling, custom agents; see `docs/chat.md`. |
|
||||
| 48 | ACP agents in Chat | **done** | Any ACP agent on the PATH (OpenCode works; Cursor needs `cursor-agent login`), npx agents after enabling, custom agents; see `docs/chat.md`. |
|
||||
| 48b | Free agents | **done** | OpenCode and Pi on free models with `Free (auto)` rotation, Pi provider keys, an install dialog per OS; see `specs/free-agents`. |
|
||||
|
||||
@@ -0,0 +1,124 @@
|
||||
# Project rules
|
||||
|
||||
The standards a change to PaperCraft is reviewed against. [CONTRIBUTING.md](CONTRIBUTING.md) says
|
||||
*how* to contribute; this file says what "good" means once you do.
|
||||
|
||||
## Code
|
||||
|
||||
* **Immutability by default.** Return new values rather than mutating shared ones. The document
|
||||
changes only through `Editor::edit` transactions, so every change is one undo step and is
|
||||
logged for the renderer's cache.
|
||||
* **Small, cohesive files.** 200 to 400 lines is typical, 800 is the ceiling. Split a module
|
||||
when it grows past that. Organise by feature, not by type.
|
||||
* **Small functions** (under about 50 lines) and **shallow nesting** (4 levels at most); prefer
|
||||
early returns.
|
||||
* **Handle errors explicitly.** No `unwrap` or `expect` on user data, file contents or network
|
||||
responses; return an error with context. User-facing messages are plain language. Never swallow
|
||||
an error silently.
|
||||
* **Validate at the boundaries**: MCP and CLI arguments, imported files (Figma, Excalidraw, SVG),
|
||||
project folders and anything from the relay. Treat all of it as untrusted.
|
||||
* **No magic numbers.** Name thresholds, sizes and delays as constants; UI measures come from
|
||||
the theme, not literals.
|
||||
* **No dead code, debug prints or commented-out blocks.**
|
||||
* **Match the surrounding code**: naming, comment density and idiom. Comments say *why*, not
|
||||
*what*.
|
||||
* **Cross-platform.** Code must build on Windows, macOS and Linux and for the web build. Gate
|
||||
platform code with `cfg`, never assume a path separator, and keep
|
||||
`cargo check --lib --target wasm32-unknown-unknown` passing.
|
||||
* **No new heavy dependencies** without discussion. Licenses must be compatible with
|
||||
MIT OR Apache-2.0.
|
||||
|
||||
## Data safety
|
||||
|
||||
PaperCraft stores people's work. Treat that as the top priority.
|
||||
|
||||
* Writes to projects are **atomic** (`src/io/atomic.rs`); never write a page in place.
|
||||
* A format change bumps the project format version and ships a **migration**. Older data must
|
||||
keep loading; if a newer build writes something an older build cannot read, the older build
|
||||
must refuse it rather than corrupt it.
|
||||
* Agent and sync paths must never silently drop a layer. If a merge cannot keep something, it
|
||||
says so.
|
||||
* Destructive operations are undoable or confirmed.
|
||||
|
||||
## The machine you build on
|
||||
|
||||
A full build links dozens of test binaries and can take every core and most of the memory of a
|
||||
desktop. The person is still using that machine, often with PaperCraft open.
|
||||
|
||||
* **Look before you start a heavy job.** Check free memory, CPU load and what is already running
|
||||
(the person's app, another build, other agents) before a build, a test run or clippy. If memory
|
||||
is short or another build is running, wait or ask.
|
||||
* **Leave room.** Cap Cargo at no more than half the logical cores (`-j 8` on a 16-core machine,
|
||||
or `CARGO_BUILD_JOBS`) and the test harness too (`-- --test-threads=8`); go lower when memory is
|
||||
tight, since linking is the peak. Run heavy jobs at low priority (`nice` on Unix, Below Normal
|
||||
on Windows).
|
||||
* **One heavy job at a time.** Never run two builds side by side; each target folder is a full
|
||||
build's worth of compiling and linking. Parallel agents share one build slot.
|
||||
* **Run only what your change touches**: `cargo check` before `cargo build`, and the test
|
||||
targets that cover the change (`cargo test --test incremental`). The full suite runs on GitHub
|
||||
before a release (`.github/workflows/test.yml`), not on a desktop.
|
||||
* **Stop at once when the person says the machine is slow**, then check that no compiler, linker
|
||||
or test process of yours is left over.
|
||||
* **Clean up.** Delete scratch target folders and worktrees when the work is merged; they grow to
|
||||
tens of gigabytes.
|
||||
|
||||
## UI
|
||||
|
||||
* **Use the shared kit.** Controls, spacing, radii and colours come from `craft-ui`,
|
||||
`src/ui/kit.rs` and the theme, not one-off values.
|
||||
* **Themes are modes.** Never branch on a theme to pick a colour; read it from the palette.
|
||||
* **Nothing overflows.** Text truncates with an ellipsis, rows keep their controls inside, and
|
||||
panels step aside when the window is narrow. Test a narrow window and a long name.
|
||||
* **Targets are at least 44 px** where a person taps or clicks something primary, and everything
|
||||
stays reachable from the keyboard.
|
||||
* **Animation is quick**: eased and under about 200 ms.
|
||||
* **Look at it.** Run the app or take a headless screenshot at scale 2 in each theme before
|
||||
asking for review.
|
||||
|
||||
## MCP tools and the CLI
|
||||
|
||||
* Every tool has a precise one-paragraph description, a JSON schema, and a test in
|
||||
`tests/mcp.rs`. Descriptions are what agents read; write them for that reader.
|
||||
* One tool call is **one undo step**.
|
||||
* Names follow the existing style (`verb_noun`); reuse Paper-compatible names and argument shapes
|
||||
where a tool has an equivalent.
|
||||
* Reads are cheap and bounded. Apply limits, say when you truncated, and never dump the whole
|
||||
document by default.
|
||||
* The server listens on `127.0.0.1` only and rejects browser origins. Do not weaken that.
|
||||
* Update the tool count in the README and ROADMAP when you add or remove tools.
|
||||
|
||||
## Designs made with PaperCraft
|
||||
|
||||
These apply to example projects, templates, screenshots and skill content, and are what the
|
||||
skills teach agents.
|
||||
|
||||
* **Themes are modes, never copies.** One artboard per screen. Give each variable a value per
|
||||
mode and switch with `set_variable_mode`. Do not duplicate artboards as light and dark
|
||||
versions, and do not rebuild a screen with other hex values.
|
||||
* **Every colour on a themed screen is a variable** (`var(--name)` on fills and text,
|
||||
`bind_variable` for strokes, opacity and visibility).
|
||||
* **No overflow.** Nothing extends past its artboard or clipping parent. Scrolling content is
|
||||
clipped inside its viewport and ends above floating bars with a fade and enough bottom padding.
|
||||
Check each artboard programmatically *and* by screenshot in each mode.
|
||||
* Run `lint_design` and fix what it finds: contrast, the 4 px grid, type scale and 44 px targets.
|
||||
* Release design locks when you are done so the next person can inspect.
|
||||
|
||||
## Skills and docs
|
||||
|
||||
* Skills in [skills/](skills) are instructions for agents: keep them short, concrete and tested
|
||||
against a real agent run.
|
||||
* Docs describe what exists. Do not document a feature that is not built; put plans in `specs/`
|
||||
and `ROADMAP.md`.
|
||||
* Screenshots come from the real app, in a generic project (no personal data, local paths or
|
||||
real names), at scale 2.
|
||||
|
||||
## Branding
|
||||
|
||||
The tree carries no third-party product branding; `.debrand` lists the forbidden patterns and
|
||||
the check runs in review. Describe PaperCraft on its own terms.
|
||||
|
||||
## Review
|
||||
|
||||
A pull request is approved when it has no unresolved **critical** (security, data loss) or
|
||||
**high** (bug, significant quality) issues. Medium and low comments are suggestions the author
|
||||
may take or decline with a reason.
|
||||
@@ -0,0 +1,29 @@
|
||||
# Security policy
|
||||
|
||||
## Supported versions
|
||||
|
||||
PaperCraft is an alpha. Security fixes go into the latest release and `main`.
|
||||
|
||||
## Reporting a vulnerability
|
||||
|
||||
**Do not open a public issue.** Use GitHub's private reporting: the repository's **Security** tab,
|
||||
then **Report a vulnerability**. Include what you found, how to reproduce it, the version and
|
||||
platform, and the impact you see.
|
||||
|
||||
A maintainer will acknowledge the report as soon as they can and keep you updated until it is
|
||||
fixed. Please give us reasonable time to ship a fix before you disclose it.
|
||||
|
||||
## What counts
|
||||
|
||||
Examples of in-scope problems:
|
||||
|
||||
* the MCP server (`127.0.0.1:29980`) or the relay accepting requests it should reject (browser
|
||||
origins, DNS rebinding, another user);
|
||||
* path traversal or code execution from a project folder, a design-system or library package, or
|
||||
an imported Figma, Excalidraw or SVG file;
|
||||
* the updater or the agent integrations running something the person did not approve;
|
||||
* secrets (an Anthropic key, relay tokens) written to disk unprotected or sent anywhere
|
||||
unexpected.
|
||||
|
||||
PaperCraft is local-first: it opens no network port beyond the loopback MCP server unless you
|
||||
share a project through a relay you run.
|
||||
@@ -62,3 +62,15 @@ SOFTWARE.
|
||||
|
||||
Inter 4.1 by Rasmus Andersson — SIL Open Font License 1.1 (`assets/fonts/OFL.txt`). Regular,
|
||||
Medium, SemiBold, Bold, Italic and Bold Italic are bundled unmodified.
|
||||
|
||||
Interface fonts, SIL Open Font License 1.1, Latin subsets as served by Google Fonts, unmodified
|
||||
(Regular, Medium, SemiBold): Geist (Vercel), Figtree (Erik Kennedy), DM Sans (Colophon Foundry,
|
||||
Jonny Pinhorn), Nunito (Vernon Adams, Jacques Le Bailly), Quicksand (Andrew Paglinawan),
|
||||
Fredoka (Milena Brandão, Hafontia), and Varela Round (Joe Prince; Regular only).
|
||||
|
||||
## Agent logos
|
||||
|
||||
`assets/agents/*.svg` are from LobeHub Icons (`@lobehub/icons-static-svg` 1.80.0,
|
||||
https://github.com/lobehub/lobe-icons), MIT License, Copyright (c) LobeHub. They are used
|
||||
unmodified to identify each coding agent in the agent picker. The marks are trademarks of
|
||||
their owners.
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
<svg fill="currentColor" fill-rule="evenodd" height="1em" style="flex:none;line-height:1" viewBox="0 0 24 24" width="1em" xmlns="http://www.w3.org/2000/svg"><title>Claude</title><path d="M4.709 15.955l4.72-2.647.08-.23-.08-.128H9.2l-.79-.048-2.698-.073-2.339-.097-2.266-.122-.571-.121L0 11.784l.055-.352.48-.321.686.06 1.52.103 2.278.158 1.652.097 2.449.255h.389l.055-.157-.134-.098-.103-.097-2.358-1.596-2.552-1.688-1.336-.972-.724-.491-.364-.462-.158-1.008.656-.722.881.06.225.061.893.686 1.908 1.476 2.491 1.833.365.304.145-.103.019-.073-.164-.274-1.355-2.446-1.446-2.49-.644-1.032-.17-.619a2.97 2.97 0 01-.104-.729L6.283.134 6.696 0l.996.134.42.364.62 1.414 1.002 2.229 1.555 3.03.456.898.243.832.091.255h.158V9.01l.128-1.706.237-2.095.23-2.695.08-.76.376-.91.747-.492.584.28.48.685-.067.444-.286 1.851-.559 2.903-.364 1.942h.212l.243-.242.985-1.306 1.652-2.064.73-.82.85-.904.547-.431h1.033l.76 1.129-.34 1.166-1.064 1.347-.881 1.142-1.264 1.7-.79 1.36.073.11.188-.02 2.856-.606 1.543-.28 1.841-.315.833.388.091.395-.328.807-1.969.486-2.309.462-3.439.813-.042.03.049.061 1.549.146.662.036h1.622l3.02.225.79.522.474.638-.079.485-1.215.62-1.64-.389-3.829-.91-1.312-.329h-.182v.11l1.093 1.068 2.006 1.81 2.509 2.33.127.578-.322.455-.34-.049-2.205-1.657-.851-.747-1.926-1.62h-.128v.17l.444.649 2.345 3.521.122 1.08-.17.353-.608.213-.668-.122-1.374-1.925-1.415-2.167-1.143-1.943-.14.08-.674 7.254-.316.37-.729.28-.607-.461-.322-.747.322-1.476.389-1.924.315-1.53.286-1.9.17-.632-.012-.042-.14.018-1.434 1.967-2.18 2.945-1.726 1.845-.414.164-.717-.37.067-.662.401-.589 2.388-3.036 1.44-1.882.93-1.086-.006-.158h-.055L4.132 18.56l-1.13.146-.487-.456.061-.746.231-.243 1.908-1.312-.006.006z"></path></svg>
|
||||
|
After Width: | Height: | Size: 1.7 KiB |
@@ -0,0 +1 @@
|
||||
<svg fill="currentColor" fill-rule="evenodd" height="1em" style="flex:none;line-height:1" viewBox="0 0 24 24" width="1em" xmlns="http://www.w3.org/2000/svg"><title>Cline</title><path d="M17.035 3.991c2.75 0 4.98 2.24 4.98 5.003v1.667l1.45 2.896a1.01 1.01 0 01-.002.909l-1.448 2.864v1.668c0 2.762-2.23 5.002-4.98 5.002H7.074c-2.751 0-4.98-2.24-4.98-5.002V17.33l-1.48-2.855a1.01 1.01 0 01-.003-.927l1.482-2.887V8.994c0-2.763 2.23-5.003 4.98-5.003h9.962zM8.265 9.6a2.274 2.274 0 00-2.274 2.274v4.042a2.274 2.274 0 004.547 0v-4.042A2.274 2.274 0 008.265 9.6zm7.326 0a2.274 2.274 0 00-2.274 2.274v4.042a2.274 2.274 0 104.548 0v-4.042A2.274 2.274 0 0015.59 9.6z"></path><path d="M12.054 5.558a2.779 2.779 0 100-5.558 2.779 2.779 0 000 5.558z"></path></svg>
|
||||
|
After Width: | Height: | Size: 750 B |
@@ -0,0 +1 @@
|
||||
<svg fill="currentColor" fill-rule="evenodd" height="1em" style="flex:none;line-height:1" viewBox="0 0 24 24" width="1em" xmlns="http://www.w3.org/2000/svg"><title>Cursor</title><path d="M22.106 5.68L12.5.135a.998.998 0 00-.998 0L1.893 5.68a.84.84 0 00-.419.726v11.186c0 .3.16.577.42.727l9.607 5.547a.999.999 0 00.998 0l9.608-5.547a.84.84 0 00.42-.727V6.407a.84.84 0 00-.42-.726zm-.603 1.176L12.228 22.92c-.063.108-.228.064-.228-.061V12.34a.59.59 0 00-.295-.51l-9.11-5.26c-.107-.062-.063-.228.062-.228h18.55c.264 0 .428.286.296.514z"></path></svg>
|
||||
|
After Width: | Height: | Size: 547 B |
@@ -0,0 +1 @@
|
||||
<svg fill="currentColor" fill-rule="evenodd" height="1em" style="flex:none;line-height:1" viewBox="0 0 24 24" width="1em" xmlns="http://www.w3.org/2000/svg"><title>GithubCopilot</title><path d="M19.245 5.364c1.322 1.36 1.877 3.216 2.11 5.817.622 0 1.2.135 1.592.654l.73.964c.21.278.323.61.323.955v2.62c0 .339-.173.669-.453.868C20.239 19.602 16.157 21.5 12 21.5c-4.6 0-9.205-2.583-11.547-4.258-.28-.2-.452-.53-.453-.868v-2.62c0-.345.113-.679.321-.956l.73-.963c.392-.517.974-.654 1.593-.654l.029-.297c.25-2.446.81-4.213 2.082-5.52 2.461-2.54 5.71-2.851 7.146-2.864h.198c1.436.013 4.685.323 7.146 2.864zm-7.244 4.328c-.284 0-.613.016-.962.05-.123.447-.305.85-.57 1.108-1.05 1.023-2.316 1.18-2.994 1.18-.638 0-1.306-.13-1.851-.464-.516.165-1.012.403-1.044.996a65.882 65.882 0 00-.063 2.884l-.002.48c-.002.563-.005 1.126-.013 1.69.002.326.204.63.51.765 2.482 1.102 4.83 1.657 6.99 1.657 2.156 0 4.504-.555 6.985-1.657a.854.854 0 00.51-.766c.03-1.682.006-3.372-.076-5.053-.031-.596-.528-.83-1.046-.996-.546.333-1.212.464-1.85.464-.677 0-1.942-.157-2.993-1.18-.266-.258-.447-.661-.57-1.108-.32-.032-.64-.049-.96-.05zm-2.525 4.013c.539 0 .976.426.976.95v1.753c0 .525-.437.95-.976.95a.964.964 0 01-.976-.95v-1.752c0-.525.437-.951.976-.951zm5 0c.539 0 .976.426.976.95v1.753c0 .525-.437.95-.976.95a.964.964 0 01-.976-.95v-1.752c0-.525.437-.951.976-.951zM7.635 5.087c-1.05.102-1.935.438-2.385.906-.975 1.037-.765 3.668-.21 4.224.405.394 1.17.657 1.995.657h.09c.649-.013 1.785-.176 2.73-1.11.435-.41.705-1.433.675-2.47-.03-.834-.27-1.52-.63-1.813-.39-.336-1.275-.482-2.265-.394zm6.465.394c-.36.292-.6.98-.63 1.813-.03 1.037.24 2.06.675 2.47.968.957 2.136 1.104 2.776 1.11h.044c.825 0 1.59-.263 1.995-.657.555-.556.765-3.187-.21-4.224-.45-.468-1.335-.804-2.385-.906-.99-.088-1.875.058-2.265.394zM12 7.615c-.24 0-.525.015-.84.044.03.16.045.336.06.526l-.001.159a2.94 2.94 0 01-.014.25c.225-.022.425-.027.612-.028h.366c.187 0 .387.006.612.028-.015-.146-.015-.277-.015-.409.015-.19.03-.365.06-.526a9.29 9.29 0 00-.84-.044z"></path></svg>
|
||||
|
After Width: | Height: | Size: 2.0 KiB |
@@ -0,0 +1 @@
|
||||
<svg fill="currentColor" fill-rule="evenodd" height="1em" style="flex:none;line-height:1" viewBox="0 0 24 24" width="1em" xmlns="http://www.w3.org/2000/svg"><title>Goose</title><path d="M21.595 23.61c1.167-.254 2.405-.944 2.405-.944l-2.167-1.784a12.124 12.124 0 01-2.695-3.131 12.127 12.127 0 00-3.97-4.049l-.794-.462a1.115 1.115 0 01-.488-.815.844.844 0 01.154-.575c.413-.582 2.548-3.115 2.94-3.44.503-.416 1.065-.762 1.586-1.159.074-.056.148-.112.221-.17.003-.002.007-.004.009-.007.167-.131.325-.272.45-.438.453-.524.563-.988.59-1.193-.061-.197-.244-.639-.753-1.148.319.02.705.272 1.056.569.235-.376.481-.773.727-1.171.165-.266-.08-.465-.086-.471h-.001V3.22c-.007-.007-.206-.25-.471-.086-.567.35-1.134.702-1.639 1.021 0 0-.597-.012-1.305.599a2.464 2.464 0 00-.438.45l-.007.009c-.058.072-.114.147-.17.221-.397.521-.743 1.083-1.16 1.587-.323.391-2.857 2.526-3.44 2.94a.842.842 0 01-.574.153 1.115 1.115 0 01-.815-.488l-.462-.794a12.123 12.123 0 00-4.049-3.97 12.133 12.133 0 01-3.13-2.695L1.332 0S.643 1.238.39 2.405c.352.428 1.27 1.49 2.34 2.302C1.58 4.167.73 3.75.06 3.4c-.103.765-.063 1.92.043 2.816.726.317 1.961.806 3.219 1.066-1.006.236-2.11.278-2.961.262.15.554.358 1.119.64 1.688.119.263.25.52.39.77.452.125 2.222.383 3.164.171l-2.51.897a27.776 27.776 0 002.544 2.726c2.031-1.092 2.494-1.241 4.018-2.238-2.467 2.008-3.108 2.828-3.8 3.67l-.483.678c-.25.351-.469.725-.65 1.117-.61 1.31-1.47 4.1-1.47 4.1-.154.486.202.842.674.674 0 0 2.79-.861 4.1-1.47.392-.182.766-.4 1.118-.65l.677-.483c.227-.187.453-.37.701-.586 0 0 1.705 2.02 3.458 3.349l.896-2.511c-.211.942.046 2.712.17 3.163.252.142.509.272.772.392.569.28 1.134.49 1.688.64-.016-.853.026-1.956.261-2.962.26 1.258.75 2.493 1.067 3.219.895.106 2.051.146 2.816.043a73.87 73.87 0 01-1.308-2.67c.811 1.07 1.874 1.988 2.302 2.34h-.001z"></path></svg>
|
||||
|
After Width: | Height: | Size: 1.8 KiB |
@@ -0,0 +1 @@
|
||||
<svg fill="currentColor" fill-rule="evenodd" height="1em" style="flex:none;line-height:1" viewBox="0 0 24 24" width="1em" xmlns="http://www.w3.org/2000/svg"><title>Kimi</title><path d="M21.846 0a1.923 1.923 0 110 3.846H20.15a.226.226 0 01-.227-.226V1.923C19.923.861 20.784 0 21.846 0z"></path><path d="M11.065 11.199l7.257-7.2c.137-.136.06-.41-.116-.41H14.3a.164.164 0 00-.117.051l-7.82 7.756c-.122.12-.302.013-.302-.179V3.82c0-.127-.083-.23-.185-.23H3.186c-.103 0-.186.103-.186.23V19.77c0 .128.083.23.186.23h2.69c.103 0 .186-.102.186-.23v-3.25c0-.069.025-.135.069-.178l2.424-2.406a.158.158 0 01.205-.023l6.484 4.772a7.677 7.677 0 003.453 1.283c.108.012.2-.095.2-.23v-3.06c0-.117-.07-.212-.164-.227a5.028 5.028 0 01-2.027-.807l-5.613-4.064c-.117-.078-.132-.279-.028-.381z"></path></svg>
|
||||
|
After Width: | Height: | Size: 786 B |
@@ -0,0 +1 @@
|
||||
<svg fill="currentColor" fill-rule="evenodd" height="1em" style="flex:none;line-height:1" viewBox="0 0 24 24" width="1em" xmlns="http://www.w3.org/2000/svg"><title>Mistral</title><path clip-rule="evenodd" d="M3.428 3.4h3.429v3.428h3.429v3.429h-.002 3.431V6.828h3.427V3.4h3.43v13.714H24v3.429H13.714v-3.428h-3.428v-3.429h-3.43v3.428h3.43v3.429H0v-3.429h3.428V3.4zm10.286 13.715h3.428v-3.429h-3.427v3.429z"></path></svg>
|
||||
|
After Width: | Height: | Size: 418 B |
|
After Width: | Height: | Size: 19 KiB |
@@ -0,0 +1 @@
|
||||
<svg fill="currentColor" fill-rule="evenodd" height="1em" style="flex:none;line-height:1" viewBox="0 0 24 24" width="1em" xmlns="http://www.w3.org/2000/svg"><title>OpenAI</title><path d="M9.205 8.658v-2.26c0-.19.072-.333.238-.428l4.543-2.616c.619-.357 1.356-.523 2.117-.523 2.854 0 4.662 2.212 4.662 4.566 0 .167 0 .357-.024.547l-4.71-2.759a.797.797 0 00-.856 0l-5.97 3.473zm10.609 8.8V12.06c0-.333-.143-.57-.429-.737l-5.97-3.473 1.95-1.118a.433.433 0 01.476 0l4.543 2.617c1.309.76 2.189 2.378 2.189 3.948 0 1.808-1.07 3.473-2.76 4.163zM7.802 12.703l-1.95-1.142c-.167-.095-.239-.238-.239-.428V5.899c0-2.545 1.95-4.472 4.591-4.472 1 0 1.927.333 2.712.928L8.23 5.067c-.285.166-.428.404-.428.737v6.898zM12 15.128l-2.795-1.57v-3.33L12 8.658l2.795 1.57v3.33L12 15.128zm1.796 7.23c-1 0-1.927-.332-2.712-.927l4.686-2.712c.285-.166.428-.404.428-.737v-6.898l1.974 1.142c.167.095.238.238.238.428v5.233c0 2.545-1.974 4.472-4.614 4.472zm-5.637-5.303l-4.544-2.617c-1.308-.761-2.188-2.378-2.188-3.948A4.482 4.482 0 014.21 6.327v5.423c0 .333.143.571.428.738l5.947 3.449-1.95 1.118a.432.432 0 01-.476 0zm-.262 3.9c-2.688 0-4.662-2.021-4.662-4.519 0-.19.024-.38.047-.57l4.686 2.71c.286.167.571.167.856 0l5.97-3.448v2.26c0 .19-.07.333-.237.428l-4.543 2.616c-.619.357-1.356.523-2.117.523zm5.899 2.83a5.947 5.947 0 005.827-4.756C22.287 18.339 24 15.84 24 13.296c0-1.665-.713-3.282-1.998-4.448.119-.5.19-.999.19-1.498 0-3.401-2.759-5.947-5.946-5.947-.642 0-1.26.095-1.88.31A5.962 5.962 0 0010.205 0a5.947 5.947 0 00-5.827 4.757C1.713 5.447 0 7.945 0 10.49c0 1.666.713 3.283 1.998 4.448-.119.5-.19 1-.19 1.499 0 3.401 2.759 5.946 5.946 5.946.642 0 1.26-.095 1.88-.309a5.96 5.96 0 004.162 1.713z"></path></svg>
|
||||
|
After Width: | Height: | Size: 1.6 KiB |
@@ -0,0 +1 @@
|
||||
<svg fill="currentColor" fill-rule="evenodd" height="1em" style="flex:none;line-height:1" viewBox="0 0 24 24" width="1em" xmlns="http://www.w3.org/2000/svg"><title>Qwen</title><path d="M12.604 1.34c.393.69.784 1.382 1.174 2.075a.18.18 0 00.157.091h5.552c.174 0 .322.11.446.327l1.454 2.57c.19.337.24.478.024.837-.26.43-.513.864-.76 1.3l-.367.658c-.106.196-.223.28-.04.512l2.652 4.637c.172.301.111.494-.043.77-.437.785-.882 1.564-1.335 2.34-.159.272-.352.375-.68.37-.777-.016-1.552-.01-2.327.016a.099.099 0 00-.081.05 575.097 575.097 0 01-2.705 4.74c-.169.293-.38.363-.725.364-.997.003-2.002.004-3.017.002a.537.537 0 01-.465-.271l-1.335-2.323a.09.09 0 00-.083-.049H4.982c-.285.03-.553-.001-.805-.092l-1.603-2.77a.543.543 0 01-.002-.54l1.207-2.12a.198.198 0 000-.197 550.951 550.951 0 01-1.875-3.272l-.79-1.395c-.16-.31-.173-.496.095-.965.465-.813.927-1.625 1.387-2.436.132-.234.304-.334.584-.335a338.3 338.3 0 012.589-.001.124.124 0 00.107-.063l2.806-4.895a.488.488 0 01.422-.246c.524-.001 1.053 0 1.583-.006L11.704 1c.341-.003.724.032.9.34zm-3.432.403a.06.06 0 00-.052.03L6.254 6.788a.157.157 0 01-.135.078H3.253c-.056 0-.07.025-.041.074l5.81 10.156c.025.042.013.062-.034.063l-2.795.015a.218.218 0 00-.2.116l-1.32 2.31c-.044.078-.021.118.068.118l5.716.008c.046 0 .08.02.104.061l1.403 2.454c.046.081.092.082.139 0l5.006-8.76.783-1.382a.055.055 0 01.096 0l1.424 2.53a.122.122 0 00.107.062l2.763-.02a.04.04 0 00.035-.02.041.041 0 000-.04l-2.9-5.086a.108.108 0 010-.113l.293-.507 1.12-1.977c.024-.041.012-.062-.035-.062H9.2c-.059 0-.073-.026-.043-.077l1.434-2.505a.107.107 0 000-.114L9.225 1.774a.06.06 0 00-.053-.031zm6.29 8.02c.046 0 .058.02.034.06l-.832 1.465-2.613 4.585a.056.056 0 01-.05.029.058.058 0 01-.05-.029L8.498 9.841c-.02-.034-.01-.052.028-.054l.216-.012 6.722-.012z"></path></svg>
|
||||
|
After Width: | Height: | Size: 1.7 KiB |
@@ -0,0 +1 @@
|
||||
<svg fill="currentColor" fill-rule="evenodd" height="1em" style="flex:none;line-height:1" viewBox="0 0 24 24" width="1em" xmlns="http://www.w3.org/2000/svg"><title>Tencent</title><path d="M9.976 1L24 9.8l-10.587.015L10.723 23H5.489L8.18 9.8H3.244L1 5.4h8.077L9.976 1z"></path></svg>
|
||||
|
After Width: | Height: | Size: 282 B |
@@ -1,6 +1,6 @@
|
||||
# Driving PaperCraft with agents
|
||||
|
||||
PaperCraft exposes one set of 70 tools three ways. They all run the same code inside the app, so an agent sees what you see and every call is one undo step.
|
||||
PaperCraft exposes one set of 88 tools three ways. They all run the same code inside the app, so an agent sees what you see and every call is one undo step.
|
||||
|
||||
| Way | Use it when | Needs the app running |
|
||||
|---|---|---|
|
||||
@@ -108,6 +108,18 @@ write_html {
|
||||
EOF
|
||||
```
|
||||
|
||||
## Checking only what changed
|
||||
|
||||
On a big page a full `lint_design` after every edit repeats the same output, and a `get_node_info` call per layer is slow (about 53 s for 397 layers). Check the change, then check everything once.
|
||||
|
||||
* Every write tool result includes `rev`, the document revision after the call. `get_basic_info` reports the current `rev`. Reads never change it.
|
||||
* `get_changes {since, page?}` returns `{rev, since, truncated, changes: [{page, ids}]}`: what the edits since `since` touched. `truncated: true` means the log no longer reaches that far back, so do a full pass.
|
||||
* `lint_design {changedOnly: true}` lints since this client's last lint; `{since: rev}` lints since a revision you name. A scoped lint checks the touched layers plus their ancestors, descendants, siblings and every layer bound to a changed variable, and reports its coverage in `covered`, for example `{checked: 12, total: 397, since: 40, partial: true}`. Plain `lint_design` is a full pass (`partial: false`). The `overflow` rule flags a layer that extends past its parent or clipping artboard (scroll frames are excluded).
|
||||
* `get_bounds {nodeIds?, pageId?, depth?}` returns `columns` `[id, parent, x, y, w, h, absX, absY, clip]` and one row per layer for a subtree in one call (at most 2000 rows; then `truncated` and `continueWith`, the nodeIds for the next call). Use it instead of looping `get_node_info`.
|
||||
* Always finish with one full `lint_design` (no arguments) and a screenshot per artboard in each theme mode before reporting. A partial lint speeds up the loop; it does not replace that pass.
|
||||
|
||||
In the app, read-only calls no longer draw per-layer outlines or keep the "Working" pill lit for long. The agent workflow, with an example, is in [incremental-checks.md](../skills/papercraft/references/incremental-checks.md).
|
||||
|
||||
## Design-system tools
|
||||
|
||||
* Variables: `get_variables` and `set_variables` take collections, groups (`color/brand/primary`), types (`color`, `number`, `string`, `boolean`), `mode`, `alias`, `description` and `hidden`; the old `{"name":"#hex"}` call still works and lands in the first collection. `create_collection` makes a collection with modes, `delete_variables` removes by name (refuses aliased ones unless `force`), `bind_variable` binds or detaches a field of layers (`stroke`, `text-color`, `width`, `height`, `gap`, `padding`, `radius`, `font-size`, `line-height`, `opacity`, `visible`).
|
||||
|
||||
@@ -18,15 +18,16 @@ Chat drives the same tools as an agent connected over MCP, so the edits, runs, u
|
||||
|
||||
The ACP agents PaperCraft knows about, and what was checked on the development Mac:
|
||||
|
||||
* **OpenCode** (`opencode acp`): works.
|
||||
* **Gemini CLI** (`gemini --acp`): found and started, but its server currently refuses ACP clients, so turns fail with the agent's error until Google changes that.
|
||||
* **OpenCode** (`opencode acp`): works. Its free models (`opencode/*-free`, Big Pickle) need no key.
|
||||
* **Cursor** (`cursor-agent acp`): sign in first with `cursor-agent login`.
|
||||
* **Pi** (`pi-acp`, an adapter run through `npx`): enable it once in the agent panel or Settings, then it works like the others.
|
||||
* **Pi** (`pi-acp`, an adapter run through `npx`): enable it once in the agent panel or Settings. `pi-acp` does not pass MCP servers on to Pi, so a lean Pi gets its own folder (`PI_CODING_AGENT_DIR`) whose only package is `pi-mcp-adapter`, connected to PaperCraft. Pi runs on the providers you add a key for in Settings → Chat → Pi: OpenRouter (`:free` models, 50 requests a day without credits), Groq, Gemini, NVIDIA NIM and Cerebras. Keys live in the OS secret store and reach Pi only as environment variables.
|
||||
* **Goose, Kimi, Devin, Junie, Mistral Vibe, Hermes, OpenHands, Stakpak, VT Code, Poolside, Droid**: started with the command their own docs give. They are not all verified here.
|
||||
* **Claude Code and Codex ACP adapters** (`npx`): listed under Enable via npx. Claude Code and Codex themselves use the direct backends above.
|
||||
|
||||
Agents that run through `npx` are off until you enable them, because enabling runs code that npx fetches from npm.
|
||||
|
||||
**Free models.** For OpenCode and Pi the model list starts on free models (`Free only`) and offers `Free (auto)`, the default for new chats on them. It starts on the free model with the largest context. When a model fails with a rate limit, quota, overload or "gone" error before any tool ran, the turn moves to the next free one (at most two more) and the thread says so. A model that failed is skipped for 15 minutes. A failure after a tool ran is not retried, because the design may already have changed.
|
||||
|
||||
ACP permissions: PaperCraft's own tools run without asking, except the destructive ones listed under Approval below. Any other tool the agent asks to run (its own shell or file tools, for example) shows an approval card with Approve or Deny in the thread, and Deny is sent back to the agent.
|
||||
|
||||
**Custom agents** are your own ACP agents: a name, a command (a program name on the resolved `PATH`, or a full path) and arguments. The arguments are split on spaces, with no quoting. Custom agents appear under Custom in the agent panel and in Settings → Chat.
|
||||
@@ -68,7 +69,7 @@ Settings → Chat has the same list, so an agent can also be hidden from the pan
|
||||
|
||||
### Setup card
|
||||
|
||||
A chat with no backend chosen shows one card, "Connect an agent". It lists the agents detected on this computer, up to four, with `Show all agents` for the rest. Below them are `Add an API endpoint` and `Add custom agent`. The card never lists install steps.
|
||||
A chat with no backend chosen shows one card, "Connect an agent". It lists the agents detected on this computer, up to four, with `Show all agents` for the rest. Below them are `Add an API endpoint` and `Add custom agent`. When OpenCode or Pi is not found, its row has `Install…`. The dialog offers the install methods that work on this OS (Homebrew, Scoop, npm, Nix or the agent's install script; on Linux also the distribution's own). It shows the exact command and runs it only after you click Install, streaming the output. Methods that need `sudo` or an admin shell, and npm when Node is missing or too old, are shown with the reason and a command to copy instead.
|
||||
|
||||
### Sign-in
|
||||
|
||||
|
||||
|
After Width: | Height: | Size: 14 MiB |
@@ -93,6 +93,8 @@ Fill-based sets (Phosphor, Material) follow variables; Lucide is stroke-based an
|
||||
| `layer-name` | warning | default names (Frame, Rectangle, Group...) on layers with children |
|
||||
| `hard-coded-color` | warning, info | a literal color that equals a variable (warning), or a literal used repeatedly when variables exist (info) |
|
||||
|
||||
| `overflow` | error | a layer extending past its artboard or clipping parent (by how many px, on which side), or text taller than its box. Scrolling frames and layers pinned in them are exempt. Never auto-fixed by `fix: true`: resize, move or let the parent grow. `get_bounds` returns every rect in one call |
|
||||
|
||||
Instances are skipped (their main component is linted). The rules are conventions, not law: pass `scale` to match your own type scale and ignore `info` items you disagree with. Lint does not judge taste; always look at `get_screenshot` too.
|
||||
|
||||
## Libraries
|
||||
|
||||
|
Before Width: | Height: | Size: 718 KiB After Width: | Height: | Size: 720 KiB |
|
Before Width: | Height: | Size: 673 KiB After Width: | Height: | Size: 675 KiB |
|
Before Width: | Height: | Size: 604 KiB After Width: | Height: | Size: 604 KiB |
|
Before Width: | Height: | Size: 269 KiB After Width: | Height: | Size: 269 KiB |
|
Before Width: | Height: | Size: 173 KiB After Width: | Height: | Size: 173 KiB |
|
Before Width: | Height: | Size: 636 KiB After Width: | Height: | Size: 638 KiB |
|
Before Width: | Height: | Size: 1.0 MiB After Width: | Height: | Size: 1.0 MiB |
|
Before Width: | Height: | Size: 837 KiB After Width: | Height: | Size: 838 KiB |
|
Before Width: | Height: | Size: 691 KiB After Width: | Height: | Size: 694 KiB |
|
Before Width: | Height: | Size: 709 KiB After Width: | Height: | Size: 712 KiB |
|
Before Width: | Height: | Size: 882 KiB After Width: | Height: | Size: 885 KiB |
|
Before Width: | Height: | Size: 84 KiB After Width: | Height: | Size: 385 KiB |
|
After Width: | Height: | Size: 387 KiB |
|
Before Width: | Height: | Size: 124 KiB After Width: | Height: | Size: 355 KiB |
|
Before Width: | Height: | Size: 209 KiB After Width: | Height: | Size: 303 KiB |
|
Before Width: | Height: | Size: 124 KiB After Width: | Height: | Size: 356 KiB |
|
After Width: | Height: | Size: 197 KiB |
|
After Width: | Height: | Size: 160 KiB |
|
Before Width: | Height: | Size: 104 KiB After Width: | Height: | Size: 416 KiB |
@@ -59,7 +59,7 @@ function Get-PeHeader([string] $Path) {
|
||||
return @{ Machine = [BitConverter]::ToUInt16($bytes, $pe + 4); Subsystem = [BitConverter]::ToUInt16($bytes, $pe + 0x5C) }
|
||||
}
|
||||
$Machine = switch ($Arch) { 'x64' { 0x8664 } 'x86' { 0x14C } 'arm64' { 0xAA64 } }
|
||||
foreach ($name in @('papercraft.exe', 'papercraft-cli.exe', 'papercraft-mcp.exe')) {
|
||||
foreach ($name in @('papercraft.exe', 'papercraft-cli.exe', 'papercraft-mcp.exe', 'papercraft-relay.exe')) {
|
||||
$exePath = Join-Path $Bin $name
|
||||
if (Test-Path $exePath) {
|
||||
$h = Get-PeHeader $exePath
|
||||
@@ -71,13 +71,13 @@ foreach ($name in @('papercraft.exe', 'papercraft-cli.exe', 'papercraft-mcp.exe'
|
||||
$Stage = Join-Path $TargetDir "windows-package\$Arch"
|
||||
Remove-Item -Recurse -Force $Stage -ErrorAction SilentlyContinue
|
||||
New-Item -ItemType Directory -Force -Path $Stage | Out-Null
|
||||
Copy-Item (Join-Path $Bin 'papercraft.exe'), (Join-Path $Bin 'papercraft-cli.exe'), (Join-Path $Bin 'papercraft-mcp.exe') $Stage
|
||||
Copy-Item (Join-Path $Bin 'papercraft.exe'), (Join-Path $Bin 'papercraft-cli.exe'), (Join-Path $Bin 'papercraft-mcp.exe'), (Join-Path $Bin 'papercraft-relay.exe') $Stage
|
||||
foreach ($f in 'LICENSE-MIT', 'LICENSE-APACHE', 'ATTRIBUTION.md', 'README.md') {
|
||||
$p = Join-Path $Root $f
|
||||
if (Test-Path $p) { Copy-Item $p $Stage }
|
||||
}
|
||||
|
||||
& (Join-Path $PSScriptRoot 'sign.ps1') (Join-Path $Stage 'papercraft.exe') (Join-Path $Stage 'papercraft-cli.exe') (Join-Path $Stage 'papercraft-mcp.exe')
|
||||
& (Join-Path $PSScriptRoot 'sign.ps1') (Join-Path $Stage 'papercraft.exe') (Join-Path $Stage 'papercraft-cli.exe') (Join-Path $Stage 'papercraft-mcp.exe') (Join-Path $Stage 'papercraft-relay.exe')
|
||||
|
||||
# ---- MSI ---------------------------------------------------------------------------------------
|
||||
$Msi = Join-Path $Dist "papercraft-$Version-windows-$Arch.msi"
|
||||
@@ -119,9 +119,22 @@ $CliZip = Join-Path $Dist "papercraft-cli-$Version-windows-$Arch.zip"
|
||||
Remove-Item -Force $CliZip -ErrorAction SilentlyContinue
|
||||
Compress-Archive -Path $CliPortable -DestinationPath $CliZip
|
||||
|
||||
# ---- relay zip ---------------------------------------------------------------------------------
|
||||
$RelayPortable = Join-Path $TargetDir "windows-package\papercraft-relay-$Version-windows-$Arch"
|
||||
Remove-Item -Recurse -Force $RelayPortable -ErrorAction SilentlyContinue
|
||||
New-Item -ItemType Directory -Force -Path $RelayPortable | Out-Null
|
||||
Copy-Item (Join-Path $Stage 'papercraft-relay.exe') $RelayPortable
|
||||
foreach ($f in 'README.md', 'LICENSE', 'LICENSE-MIT', 'LICENSE-APACHE', 'ATTRIBUTION.md') {
|
||||
$p = Join-Path $Root $f
|
||||
if (Test-Path $p) { Copy-Item $p $RelayPortable }
|
||||
}
|
||||
$RelayZip = Join-Path $Dist "papercraft-relay-$Version-windows-$Arch.zip"
|
||||
Remove-Item -Force $RelayZip -ErrorAction SilentlyContinue
|
||||
Compress-Archive -Path $RelayPortable -DestinationPath $RelayZip
|
||||
|
||||
# Smoke test
|
||||
Invoke-Native 'papercraft-cli --help' { & (Join-Path $Stage 'papercraft-cli.exe') --help | Out-Null }
|
||||
|
||||
$artifacts = @($Zip, $CliZip)
|
||||
$artifacts = @($Zip, $CliZip, $RelayZip)
|
||||
if (Test-Path $Msi) { $artifacts += $Msi }
|
||||
Get-Item $artifacts | Format-Table Name, Length
|
||||
|
||||
@@ -0,0 +1,62 @@
|
||||
#!/bin/sh
|
||||
# Build the landing page into a folder ready for GitHub Pages:
|
||||
# sh site/build.sh <out-dir> [<previous-build-dir>]
|
||||
# Needs curl, jq and ffmpeg. GH_TOKEN, when set, authenticates the GitHub API call.
|
||||
# RELEASE_JSON=<file> uses that file instead of asking the API. The demo video is re-encoded only
|
||||
# when docs/demo.mp4 changed since <previous-build-dir>, so a release-only update stays cheap.
|
||||
# <out-dir> must be new or empty.
|
||||
set -eu
|
||||
cd "$(dirname "$0")/.."
|
||||
|
||||
OUT="${1:?usage: sh site/build.sh <out-dir> [<previous-build-dir>]}"
|
||||
PREV="${2:-}"
|
||||
REPO="${GITHUB_REPOSITORY:-nxtime/papercraft}"
|
||||
|
||||
if [ -n "$(ls -A "$OUT" 2>/dev/null)" ]; then
|
||||
echo "$OUT is not empty; pass a new folder." >&2
|
||||
exit 1
|
||||
fi
|
||||
mkdir -p "$OUT/media/agents"
|
||||
|
||||
cp site/index.html site/site.css site/site.js "$OUT/"
|
||||
cp assets/app-icon/papercraft.svg "$OUT/media/icon.svg"
|
||||
for agent in claude openai cursor goose kimi mistral qwen cline githubcopilot nousresearch; do
|
||||
cp "assets/agents/$agent.svg" "$OUT/media/agents/"
|
||||
done
|
||||
for shot in hero chat annotations variables; do
|
||||
cp "docs/screenshots/readme/$shot.png" "$OUT/media/"
|
||||
done
|
||||
# GitHub Pages runs Jekyll otherwise, which is slower and has nothing to do here.
|
||||
touch "$OUT/.nojekyll"
|
||||
|
||||
# The page reads this shape; site.js maps the API's own shape onto it the same way.
|
||||
if [ -n "${RELEASE_JSON:-}" ]; then
|
||||
cp "$RELEASE_JSON" "$OUT/release.json"
|
||||
else
|
||||
set -- -fsSL -H "Accept: application/vnd.github+json"
|
||||
if [ -n "${GH_TOKEN:-}" ]; then
|
||||
set -- "$@" -H "Authorization: Bearer $GH_TOKEN"
|
||||
fi
|
||||
curl "$@" "https://api.github.com/repos/$REPO/releases/latest" | jq '{
|
||||
tag: .tag_name,
|
||||
name: .name,
|
||||
publishedAt: .published_at,
|
||||
url: .html_url,
|
||||
assets: [.assets[] | {name, size, url: .browser_download_url, digest}]
|
||||
}' > "$OUT/release.json"
|
||||
fi
|
||||
jq -e '.tag and (.assets | length > 0)' "$OUT/release.json" > /dev/null
|
||||
|
||||
SRC_SUM="$(sha256sum docs/demo.mp4 | cut -d' ' -f1)"
|
||||
if [ -n "$PREV" ] && [ -f "$PREV/media/demo.mp4" ] && [ "$(cat "$PREV/media/demo.source" 2>/dev/null)" = "$SRC_SUM" ]; then
|
||||
cp "$PREV/media/demo.mp4" "$PREV/media/poster.jpg" "$OUT/media/"
|
||||
else
|
||||
# 720p30 without audio keeps the tour near 2 MB, against 26 MB for the 1080p60 source.
|
||||
ffmpeg -loglevel error -y -i docs/demo.mp4 -vf "scale=1280:-2,fps=30" -c:v libx264 -crf 28 \
|
||||
-preset slow -pix_fmt yuv420p -an -movflags +faststart "$OUT/media/demo.mp4"
|
||||
ffmpeg -loglevel error -y -ss 1.5 -i docs/demo.mp4 -frames:v 1 -vf scale=1280:-2 -q:v 4 \
|
||||
"$OUT/media/poster.jpg"
|
||||
fi
|
||||
echo "$SRC_SUM" > "$OUT/media/demo.source"
|
||||
|
||||
echo "Built $(jq -r .tag "$OUT/release.json") into $OUT"
|
||||
@@ -0,0 +1,375 @@
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover">
|
||||
<title>PaperCraft</title>
|
||||
<meta name="claude:viewport-fit-sides" content="cover">
|
||||
<meta name="description" content="A native, local-first design and whiteboard canvas that AI agents can drive over MCP and a CLI.">
|
||||
<meta name="theme-color" content="#11111b">
|
||||
<meta property="og:title" content="PaperCraft">
|
||||
<meta property="og:description" content="A native canvas that AI agents can drive. Local-first, no account, open source.">
|
||||
<meta property="og:image" content="media/poster.jpg">
|
||||
<link rel="icon" href="media/icon.svg" type="image/svg+xml">
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Instrument+Serif:ital@0;1&family=Geist:wght@400;500;600&family=Geist+Mono:wght@400;500&display=swap">
|
||||
<link rel="stylesheet" href="site.css">
|
||||
</head>
|
||||
<body>
|
||||
<div class="stage" aria-hidden="true"><div class="glow a"></div><div class="glow b"></div><div class="glow c"></div><div class="spot"></div></div>
|
||||
|
||||
<header class="nav" id="nav">
|
||||
<div class="wrap">
|
||||
<div class="nav-bar acrylic">
|
||||
<a class="brand" href="#top"><img src="media/icon.svg" alt="">PaperCraft</a>
|
||||
<nav class="nav-links" aria-label="Sections">
|
||||
<a href="#live">Agents</a>
|
||||
<a href="#features">Features</a>
|
||||
<a href="#local">Local-first</a>
|
||||
<a href="#download">Download</a>
|
||||
<a href="https://github.com/nxtime/papercraft">GitHub</a>
|
||||
</nav>
|
||||
<a class="btn btn-primary btn-sm" href="#download">Download <span class="ver" data-version>latest</span></a>
|
||||
<span class="progress" aria-hidden="true"></span>
|
||||
</div>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
<main id="top">
|
||||
<section class="hero wrap">
|
||||
<img class="hero-mark rise" src="media/icon.svg" alt="PaperCraft app icon" width="76" height="76">
|
||||
<div class="eyebrow rise d1">Rust · egui · wgpu · MCP</div>
|
||||
<h1 class="serif" id="headline">A native canvas that <em>AI agents</em> can drive.</h1>
|
||||
<p class="lede rise d2">PaperCraft is an infinite-canvas design tool and whiteboard. It runs on your desktop with no account and no cloud, and it serves the Model Context Protocol so Claude Code, Codex and other agents can edit the open canvas, screenshot it and lint it, one undo step per call.</p>
|
||||
<div class="cta rise d3">
|
||||
<a class="btn btn-primary" id="hero-dl" href="#download">
|
||||
<svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true"><path d="M12 3v12m0 0-5-5m5 5 5-5M4 21h16"/></svg>
|
||||
<span id="hero-dl-label">Download</span> <span class="ver" data-version>latest</span>
|
||||
</a>
|
||||
<a class="btn btn-ghost" href="https://github.com/nxtime/papercraft">
|
||||
<svg viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M12 .5a11.5 11.5 0 0 0-3.64 22.41c.58.1.79-.25.79-.56v-2c-3.2.7-3.88-1.37-3.88-1.37-.52-1.33-1.28-1.69-1.28-1.69-1.04-.71.08-.7.08-.7 1.15.08 1.76 1.19 1.76 1.19 1.03 1.76 2.69 1.25 3.35.96.1-.75.4-1.25.73-1.54-2.55-.29-5.24-1.28-5.24-5.69 0-1.26.45-2.29 1.19-3.09-.12-.29-.52-1.46.11-3.05 0 0 .97-.31 3.17 1.18a11 11 0 0 1 5.77 0c2.2-1.49 3.17-1.18 3.17-1.18.63 1.59.23 2.76.11 3.05.74.8 1.19 1.83 1.19 3.09 0 4.42-2.7 5.39-5.26 5.68.41.36.78 1.06.78 2.14v3.17c0 .31.21.67.8.56A11.5 11.5 0 0 0 12 .5Z"/></svg>
|
||||
Source on GitHub
|
||||
</a>
|
||||
</div>
|
||||
<div class="facts rise d3"><span>Local-first, no account</span><span>98 MCP tools</span><span>Windows · macOS · Linux</span><span>MIT or Apache-2.0</span></div>
|
||||
</section>
|
||||
|
||||
<section class="showcase wrap" aria-label="Product tour">
|
||||
<div class="window acrylic" id="window">
|
||||
<div class="chrome" aria-hidden="true"><i></i><i></i><i></i><span>PaperCraft · Landing page</span></div>
|
||||
<video src="media/demo.mp4" poster="media/poster.jpg" autoplay muted loop playsinline preload="metadata" aria-label="A 40-second tour of the editor, chat mode, annotations and design systems"></video>
|
||||
</div>
|
||||
<p class="caption">A 40-second tour, rendered from the app's own design rather than screen-recorded.</p>
|
||||
</section>
|
||||
|
||||
<section class="marquee" aria-label="Agents that work with PaperCraft">
|
||||
<p class="eyebrow wrap">Chat mode runs the agents you already use</p>
|
||||
<div class="track">
|
||||
<div class="belt">
|
||||
<span class="chip acrylic"><i style="--logo:url(media/agents/claude.svg)"></i>Claude Code</span>
|
||||
<span class="chip acrylic"><i style="--logo:url(media/agents/openai.svg)"></i>Codex</span>
|
||||
<span class="chip acrylic"><i style="--logo:url(media/agents/cursor.svg)"></i>Cursor</span>
|
||||
<span class="chip acrylic"><i class="none"></i>OpenCode</span>
|
||||
<span class="chip acrylic"><i style="--logo:url(media/agents/goose.svg)"></i>Goose</span>
|
||||
<span class="chip acrylic"><i style="--logo:url(media/agents/kimi.svg)"></i>Kimi</span>
|
||||
<span class="chip acrylic"><i style="--logo:url(media/agents/mistral.svg)"></i>Mistral Vibe</span>
|
||||
<span class="chip acrylic"><i style="--logo:url(media/agents/qwen.svg)"></i>Qwen Code</span>
|
||||
<span class="chip acrylic"><i style="--logo:url(media/agents/cline.svg)"></i>Cline</span>
|
||||
<span class="chip acrylic"><i style="--logo:url(media/agents/githubcopilot.svg)"></i>Copilot CLI</span>
|
||||
<span class="chip acrylic"><i style="--logo:url(media/agents/nousresearch.svg)"></i>Hermes</span>
|
||||
<span class="chip acrylic"><i class="none"></i>Any ACP agent</span>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="block wrap" id="live">
|
||||
<div class="section-head reveal">
|
||||
<div class="eyebrow">For agents</div>
|
||||
<h2 class="serif">Watch an agent <em>build a screen.</em></h2>
|
||||
<p>Each tool call is one undo step. The agent writes HTML that becomes real layers, switches the theme by changing a variable mode, takes a screenshot and lints the result.</p>
|
||||
</div>
|
||||
<div class="live acrylic reveal" id="live-demo">
|
||||
<div class="log">
|
||||
<div class="log-head"><span class="dot" aria-hidden="true"></span>Agent run · Sign in<span class="undo" id="undo-count">0 undo steps</span></div>
|
||||
<ol class="calls" id="calls">
|
||||
<li class="call"><span class="st"></span><b>create_artboard</b><span class="ms">9 ms</span><span class="arg">{"name": "Sign in", "width": 360, "height": 480}</span></li>
|
||||
<li class="call"><span class="st"></span><b>set_variables</b><span class="ms">4 ms</span><span class="arg">{"bg", "surface", "text", "accent"} with Dark and Light modes</span></li>
|
||||
<li class="call"><span class="st"></span><b>write_html</b><span class="ms">18 ms</span><span class="arg"><div style="display:flex; flex-direction:column; gap:12px"> → 6 layers</span></li>
|
||||
<li class="call"><span class="st"></span><b>update_styles</b><span class="ms">3 ms</span><span class="arg">{"#submit": {"background": "var(--accent)"}}</span></li>
|
||||
<li class="call"><span class="st"></span><b>set_variable_mode</b><span class="ms">2 ms</span><span class="arg">{"collection": "Colors", "mode": "Light"}</span></li>
|
||||
<li class="call"><span class="st"></span><b>get_screenshot</b><span class="ms">41 ms</span><span class="arg">sign-in@2x.png</span></li>
|
||||
<li class="call"><span class="st"></span><b>lint_design</b><span class="ms">7 ms</span><span class="arg">contrast, 4px grid, type scale, touch targets</span></li>
|
||||
</ol>
|
||||
</div>
|
||||
<div class="board-area" aria-hidden="true">
|
||||
<span class="board-label">Sign in</span>
|
||||
<span class="mode-pill" id="mode-pill">Mode: Dark</span>
|
||||
<div class="board" id="board">
|
||||
<div class="a-logo"></div>
|
||||
<div class="a-title">Welcome back</div>
|
||||
<div class="a-sub">Sign in to continue to your workspace.</div>
|
||||
<div class="a-field"></div>
|
||||
<div class="a-field"></div>
|
||||
<div class="a-btn">Sign in</div>
|
||||
</div>
|
||||
<span class="lint" id="lint">✓ lint_design · 0 issues</span>
|
||||
<span class="flash" id="flash"></span>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="block wrap" id="features">
|
||||
<div class="section-head reveal">
|
||||
<div class="eyebrow">What you get</div>
|
||||
<h2 class="serif">A real design tool, <em>not a chat window</em> with a canvas bolted on.</h2>
|
||||
<p>Frames, auto layout, components, variables and a hand-drawn whiteboard on one GPU-rendered canvas.</p>
|
||||
</div>
|
||||
|
||||
<div class="features">
|
||||
<article class="feature reveal">
|
||||
<div class="copy">
|
||||
<div class="eyebrow">The editor</div>
|
||||
<h3 class="serif">Layers, canvas, inspector. <em>One native window.</em></h3>
|
||||
<p>Built in Rust on egui and wgpu. Cached frames take about 3 ms with ten thousand visible layers.</p>
|
||||
<ul class="ticks">
|
||||
<li>Auto layout with gap, padding, hug, fill, wrap and constraints</li>
|
||||
<li>Pen and Bézier editing, boolean operations, gradients and blend modes</li>
|
||||
<li>A command palette over every action, page and layer</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="tilt"><div class="shot acrylic"><img src="media/hero.png" alt="PaperCraft with a habit-tracker design open: layers on the left, three annotated screens on the canvas, the inspector on the right" loading="lazy"></div></div>
|
||||
</article>
|
||||
|
||||
<article class="feature reveal">
|
||||
<div class="copy">
|
||||
<div class="eyebrow">Chat mode</div>
|
||||
<h3 class="serif">Pick an agent. <em>Describe the screen.</em></h3>
|
||||
<p>A conversation sits next to the canvas. Point at layers with @ mentions or a picked area, and the agent gets a crop with your notes drawn on it.</p>
|
||||
<ul class="ticks">
|
||||
<li>Claude Code and Codex through their CLIs, with your own logins</li>
|
||||
<li>Any ACP agent on your PATH, or the Anthropic API with your key</li>
|
||||
<li>Every run can be reviewed, reverted one change at a time, or accepted</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="tilt"><div class="shot acrylic"><img src="media/chat.png" alt="Chat mode: a conversation with an agent beside the canvas" loading="lazy"></div></div>
|
||||
</article>
|
||||
|
||||
<article class="feature reveal">
|
||||
<div class="copy">
|
||||
<div class="eyebrow">Annotations</div>
|
||||
<h3 class="serif">Annotate <em>in place.</em> Agents read the notes.</h3>
|
||||
<p>Pin typed notes for rules, behaviour, content and data to any layer, with a template per project. They travel with the design into the handoff spec.</p>
|
||||
</div>
|
||||
<div class="tilt"><div class="shot acrylic"><img src="media/annotations.png" alt="The Annotations view listing notes grouped by screen, with their category chips" loading="lazy"></div></div>
|
||||
</article>
|
||||
|
||||
<article class="feature reveal">
|
||||
<div class="copy">
|
||||
<div class="eyebrow">Design systems</div>
|
||||
<h3 class="serif">Tokens out as CSS, DTCG or Tailwind. <em>Code out as JSX.</em></h3>
|
||||
<p>Variables with modes and aliases, components that work across projects, and shared libraries you publish, enable and update.</p>
|
||||
<ul class="ticks">
|
||||
<li>Light and dark are modes on one artboard, never copies</li>
|
||||
<li>Lint for contrast, the 4px grid, type scale and touch targets, with auto-fix</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="tilt"><div class="shot acrylic"><img src="media/variables.png" alt="The Variables modal with Light and Dark values for brand, foreground and background" loading="lazy"></div></div>
|
||||
</article>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="block wrap" aria-labelledby="more-title">
|
||||
<div class="section-head reveal">
|
||||
<div class="eyebrow">And the rest</div>
|
||||
<h2 class="serif" id="more-title">Sketch it, <em>present it,</em> ship it.</h2>
|
||||
</div>
|
||||
<div class="bento stagger">
|
||||
<article class="tile wide acrylic lit reveal">
|
||||
<div class="art">
|
||||
<svg class="sketch" viewBox="0 0 360 92" width="100%" height="92" preserveAspectRatio="xMinYMid meet" aria-hidden="true">
|
||||
<path d="M12 18 C60 12 110 16 140 19 C143 40 141 60 138 76 C96 79 50 78 14 74 C11 55 13 36 12 18Z"/>
|
||||
<path d="M146 46 C180 44 210 46 236 47 M226 38 L238 47 L226 56"/>
|
||||
<rect class="note" x="252" y="14" width="78" height="64" rx="4" transform="rotate(3 291 46)"/>
|
||||
</svg>
|
||||
</div>
|
||||
<h3>Whiteboard mode</h3>
|
||||
<p>Hand-drawn shapes, arrows bound to shapes, elbow connectors, sticky notes, freehand ink and a laser pointer, on the same canvas as your screens.</p>
|
||||
</article>
|
||||
<article class="tile acrylic lit reveal">
|
||||
<div class="art"><span class="fmt in">.fig</span><span class="fmt in">.excalidraw</span><span class="arrow-dash"></span><span class="fmt out">PDF</span></div>
|
||||
<h3>Import and export</h3>
|
||||
<p>Figma, Excalidraw and SVG in. PNG at 1 to 4x, SVG and vector PDF out, for a selection, a frame or a page.</p>
|
||||
</article>
|
||||
<article class="tile acrylic lit reveal">
|
||||
<div class="art"><div class="versions"><div>Agent run · Sign in</div><div>Auto-version · 14:02</div><div>Before handoff</div></div></div>
|
||||
<h3>Versions and runs</h3>
|
||||
<p>Named and automatic versions per page. An agent run saves one before its first edit, so you can always go back.</p>
|
||||
</article>
|
||||
<article class="tile acrylic lit reveal">
|
||||
<div class="art"><span class="fmt">Welcome</span><span class="arrow-dash"></span><span class="fmt">Today</span></div>
|
||||
<h3>Present mode</h3>
|
||||
<p>Prototype links between frames, followed with a camera glide.</p>
|
||||
</article>
|
||||
<article class="tile acrylic lit reveal">
|
||||
<div class="art"><div class="peers"><span style="background:var(--mauve)">M</span><span style="background:var(--blue)">A</span><span style="background:var(--green)">J</span></div></div>
|
||||
<h3>Shared projects</h3>
|
||||
<p>An optional relay merges concurrent edits to a page. Without one, nothing leaves your machine.</p>
|
||||
</article>
|
||||
<article class="tile wide acrylic lit reveal">
|
||||
<div class="art">
|
||||
<div class="swatches" aria-hidden="true">
|
||||
<span style="background:#eff1f5"></span><span style="background:#303446"></span><span style="background:#24273a"></span><span style="background:#1e1e2e"></span><span style="background:#11111b"></span>
|
||||
</div>
|
||||
</div>
|
||||
<h3>Themes</h3>
|
||||
<p>System, Light and Dark, plus the four Catppuccin flavours: Latte, Frappé, Macchiato and Mocha.</p>
|
||||
</article>
|
||||
<article class="tile acrylic lit reveal">
|
||||
<div class="art"><span class="fmt">wasm32</span><span class="arrow-dash"></span><span class="fmt out">browser</span></div>
|
||||
<h3>Web build</h3>
|
||||
<p>The same editor compiled to WebAssembly, served by <code>papercraft-relay</code>.</p>
|
||||
</article>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="block wrap" id="local">
|
||||
<div class="section-head reveal">
|
||||
<div class="eyebrow">Local-first</div>
|
||||
<h2 class="serif">Your project is <em>a folder on your disk.</em></h2>
|
||||
<p>Plain JSON you can back up, diff and commit. No account to make and no server to trust.</p>
|
||||
</div>
|
||||
<div class="local">
|
||||
<div class="tree acrylic reveal">
|
||||
<pre><span class="path">~/Documents/papercraft/</span><span class="d">Pulse/</span>
|
||||
├── project.json <span class="c"># manifest, variables, components</span>
|
||||
├── <span class="d">pages/</span> <span class="c"># one JSON file per page</span>
|
||||
├── <span class="d">versions/</span> <span class="c"># named and automatic versions</span>
|
||||
├── <span class="d">runs/</span> <span class="c"># agent runs, for review and revert</span>
|
||||
└── <span class="d">chats/</span> <span class="c"># chat threads with their tool calls</span></pre>
|
||||
</div>
|
||||
<div class="points stagger">
|
||||
<div class="point acrylic lit reveal"><h3>Atomic autosave</h3><p>Every write is atomic, and older files are migrated forward when they load.</p></div>
|
||||
<div class="point acrylic lit reveal"><h3>Works with the app closed</h3><p><code>papercraft-cli --offline</code> runs the same tools on the project store, screenshots included.</p></div>
|
||||
<div class="point acrylic lit reveal"><h3>Keys stay in your OS</h3><p>API keys live in the system credential store and never in a project file, chat or log.</p></div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="block wrap" id="agents">
|
||||
<div class="section-head reveal">
|
||||
<div class="eyebrow">Connect</div>
|
||||
<h2 class="serif">Same tools, <em>three ways in.</em></h2>
|
||||
<p>The MCP server is built into the app and listens on loopback only. Browser requests and foreign hosts are rejected.</p>
|
||||
</div>
|
||||
<div class="agents stagger">
|
||||
<div class="card acrylic lit reveal">
|
||||
<div class="stat" id="tool-count" data-to="98">98</div>
|
||||
<h3>MCP tools, one undo step each</h3>
|
||||
<div class="ways">
|
||||
<div class="way"><b>MCP over HTTP</b><span>Built into the app at <code>127.0.0.1:29980/mcp</code>.</span></div>
|
||||
<div class="way"><b>MCP over stdio</b><span><code>papercraft-mcp</code> relays to the running app.</span></div>
|
||||
<div class="way"><b>Shell</b><span><code>papercraft-cli</code> calls the same tools, so the agent needs no schemas in context.</span></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card acrylic lit reveal">
|
||||
<h3>Register it once</h3>
|
||||
<p>Start PaperCraft, then add it to your agent.</p>
|
||||
<div class="code">
|
||||
<button class="copy-btn" type="button" data-copy="claude mcp add --transport http --scope user papercraft http://127.0.0.1:29980/mcp">Copy</button>
|
||||
<pre><span class="c"># Claude Code</span>
|
||||
<span class="k">claude</span> mcp add --transport http --scope user \
|
||||
papercraft http://127.0.0.1:29980/mcp</pre>
|
||||
</div>
|
||||
<div class="code">
|
||||
<button class="copy-btn" type="button" data-copy="codex mcp add papercraft --url http://127.0.0.1:29980/mcp">Copy</button>
|
||||
<pre><span class="c"># Codex</span>
|
||||
<span class="k">codex</span> mcp add papercraft --url http://127.0.0.1:29980/mcp</pre>
|
||||
</div>
|
||||
<div class="code">
|
||||
<button class="copy-btn" type="button" data-copy="papercraft-cli call get_screenshot '{"nodeId":"abc123:1"}' --project Demo -o card.png">Copy</button>
|
||||
<pre><span class="c"># No app running</span>
|
||||
<span class="k">papercraft-cli</span> call get_screenshot '{"nodeId":"abc123:1"}' \
|
||||
--project Demo -o card.png</pre>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="block wrap" aria-labelledby="keys-title">
|
||||
<div class="section-head reveal">
|
||||
<div class="eyebrow">Keyboard first</div>
|
||||
<h2 class="serif" id="keys-title">The shortcuts <em>you'll use daily.</em></h2>
|
||||
</div>
|
||||
<div class="keys stagger">
|
||||
<div class="key acrylic lit reveal"><kbd data-keys="mod K"></kbd><span>Command palette</span></div>
|
||||
<div class="key acrylic lit reveal"><kbd data-keys="mod J"></kbd><span>Design or Chat mode</span></div>
|
||||
<div class="key acrylic lit reveal"><kbd data-keys="mod alt shift V"></kbd><span>Variables</span></div>
|
||||
<div class="key acrylic lit reveal"><kbd data-keys="N"></kbd><span>Annotate</span></div>
|
||||
<div class="key acrylic lit reveal"><kbd data-keys="/"></kbd><span>Hide the side panels</span></div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="block wrap" id="download">
|
||||
<div class="dl-head reveal">
|
||||
<div class="section-head">
|
||||
<div class="eyebrow">Download</div>
|
||||
<h2 class="serif">Get the <em>latest build.</em></h2>
|
||||
</div>
|
||||
<a class="release-pill acrylic" id="release-link" href="https://github.com/nxtime/papercraft/releases/latest">
|
||||
<span class="pulse" aria-hidden="true"></span>
|
||||
<span><b data-version>latest</b> · <span id="release-date">GitHub releases</span></span>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div class="platforms stagger" id="platforms">
|
||||
<article class="platform acrylic">
|
||||
<h3>Loading the latest release</h3>
|
||||
<p class="note">All builds are also on the <a href="https://github.com/nxtime/papercraft/releases/latest">GitHub releases page</a>.</p>
|
||||
</article>
|
||||
</div>
|
||||
|
||||
<div class="dl-foot">
|
||||
<div class="card acrylic reveal">
|
||||
<h3>First run</h3>
|
||||
<p>The Windows zip is unsigned, so SmartScreen may ask you to confirm. macOS builds are ad-hoc signed and not notarized: open the app with right-click, Open the first time.</p>
|
||||
</div>
|
||||
<div class="card acrylic reveal">
|
||||
<h3>Build from source</h3>
|
||||
<p>Rust 1.95 or newer, then <code>cargo build --release</code>. Linux needs Vulkan or GL and the usual X11 or Wayland libraries.</p>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="wrap">
|
||||
<div class="status acrylic reveal">
|
||||
<div>
|
||||
<div class="eyebrow">Status</div>
|
||||
<h2 class="serif">Alpha, <em>and used daily.</em></h2>
|
||||
<p>PaperCraft is good for screens, design systems and sketches, and it is not yet a replacement for a mature design tool. The roadmap lists what is missing, in priority order.</p>
|
||||
</div>
|
||||
<div class="actions">
|
||||
<a class="btn btn-ghost" href="https://github.com/nxtime/papercraft/blob/main/ROADMAP.md">Roadmap</a>
|
||||
<a class="btn btn-ghost" href="https://github.com/nxtime/papercraft#status-and-known-limits">Known limits</a>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
</main>
|
||||
|
||||
<footer>
|
||||
<div class="wrap foot">
|
||||
<span>PaperCraft is open source, licensed MIT or Apache-2.0.</span>
|
||||
<nav aria-label="Links">
|
||||
<a href="https://github.com/nxtime/papercraft">GitHub</a>
|
||||
<a href="https://github.com/nxtime/papercraft/releases">Releases</a>
|
||||
<a href="https://github.com/nxtime/papercraft/blob/main/docs/agents.md">Agent guide</a>
|
||||
<a href="https://github.com/nxtime/papercraft/blob/main/CONTRIBUTING.md">Contributing</a>
|
||||
</nav>
|
||||
</div>
|
||||
</footer>
|
||||
|
||||
<div class="toast acrylic" id="toast" role="status" aria-live="polite"></div>
|
||||
|
||||
<script src="site.js"></script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,484 @@
|
||||
/* The landing page sits on the app's own dark canvas: acrylic panels over a dot grid lit by
|
||||
lavender glows, with the palette of the app icon (Catppuccin Mocha). */
|
||||
:root {
|
||||
color-scheme: dark;
|
||||
--crust: #11111b;
|
||||
--base: #181825;
|
||||
--mantle: #1e1e2e;
|
||||
--surface: #313244;
|
||||
--overlay: #45475a;
|
||||
--text: #cdd6f4;
|
||||
--subtext: #a6adc8;
|
||||
--muted: #7f849c;
|
||||
--mauve: #cba6f7;
|
||||
--mauve-hi: #d9bcfa;
|
||||
--mauve-deep: #b48ef0;
|
||||
--on-mauve: #1e1e2e;
|
||||
--green: #a6e3a1;
|
||||
--blue: #89b4fa;
|
||||
--peach: #fab387;
|
||||
--glass: rgb(30 30 46 / 0.55);
|
||||
--glass-strong: rgb(30 30 46 / 0.8);
|
||||
--glass-edge: rgb(205 214 244 / 0.09);
|
||||
--glass-hi: rgb(255 255 255 / 0.06);
|
||||
--glow: rgb(203 166 247 / 0.32);
|
||||
--dot: rgb(205 214 244 / 0.07);
|
||||
--well: rgb(17 17 27 / 0.6);
|
||||
|
||||
--display: "Instrument Serif", "Iowan Old Style", Georgia, serif;
|
||||
--sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
|
||||
--mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
|
||||
|
||||
--r-panel: 22px;
|
||||
--r-control: 12px;
|
||||
--wrap: 1180px;
|
||||
--ease: cubic-bezier(.2, .7, .2, 1);
|
||||
}
|
||||
|
||||
* { box-sizing: border-box; }
|
||||
html { scroll-behavior: smooth; }
|
||||
body {
|
||||
margin: 0;
|
||||
background: var(--crust);
|
||||
color: var(--text);
|
||||
font-family: var(--sans);
|
||||
font-size: 16px;
|
||||
line-height: 1.6;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
overflow-x: hidden;
|
||||
}
|
||||
body::before {
|
||||
content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px);
|
||||
z-index: 30; background: var(--crust);
|
||||
}
|
||||
img { max-width: 100%; }
|
||||
code { font-family: var(--mono); font-size: .92em; }
|
||||
a { color: inherit; }
|
||||
:focus-visible { outline: 2px solid var(--mauve); outline-offset: 3px; border-radius: 6px; }
|
||||
|
||||
/* The canvas behind everything: dot grid, drifting glows and a spotlight that follows the pointer */
|
||||
.stage { position: fixed; inset: 0; z-index: -1; pointer-events: none; background: var(--crust); overflow: hidden; }
|
||||
.stage::before {
|
||||
content: ""; position: absolute; inset: 0;
|
||||
background: radial-gradient(circle at 1px 1px, var(--dot) 1px, transparent 0) 0 0 / 22px 22px;
|
||||
mask-image: radial-gradient(70rem 50rem at 50% 0%, #000 30%, transparent 85%);
|
||||
}
|
||||
.glow { position: absolute; border-radius: 50%; filter: blur(80px); opacity: .55; }
|
||||
.glow.a { width: 52rem; height: 34rem; left: 50%; top: -18rem; margin-left: -26rem; background: rgb(203 166 247 / .32); }
|
||||
.glow.b { width: 34rem; height: 26rem; right: -10rem; top: 45%; background: rgb(137 180 250 / .12); }
|
||||
.glow.c { width: 30rem; height: 24rem; left: -10rem; bottom: -6rem; background: rgb(203 166 247 / .14); }
|
||||
.spot {
|
||||
position: absolute; inset: 0;
|
||||
background: radial-gradient(28rem 28rem at var(--mx, 50%) var(--my, -20%), rgb(203 166 247 / .07), transparent 70%);
|
||||
}
|
||||
|
||||
.wrap {
|
||||
width: 100%; max-width: var(--wrap); margin-inline: auto;
|
||||
padding-left: max(20px, env(safe-area-inset-left, 0px));
|
||||
padding-right: max(20px, env(safe-area-inset-right, 0px));
|
||||
}
|
||||
|
||||
/* Acrylic: translucent fill, backdrop blur, a hairline edge and a top highlight */
|
||||
.acrylic {
|
||||
position: relative;
|
||||
background: linear-gradient(180deg, var(--glass-hi), transparent 40%), var(--glass);
|
||||
backdrop-filter: blur(22px) saturate(160%);
|
||||
-webkit-backdrop-filter: blur(22px) saturate(160%);
|
||||
border: 1px solid var(--glass-edge);
|
||||
box-shadow: 0 1px 0 var(--glass-hi) inset, 0 24px 60px -24px rgb(0 0 0 / .6);
|
||||
}
|
||||
|
||||
/* Cards light up under the pointer, like a hovered panel in the app */
|
||||
.lit::after {
|
||||
content: ""; position: absolute; inset: -1px; border-radius: inherit; pointer-events: none;
|
||||
background: radial-gradient(22rem 22rem at var(--lx, 50%) var(--ly, 50%), rgb(203 166 247 / .14), transparent 60%);
|
||||
opacity: 0; transition: opacity .4s;
|
||||
}
|
||||
.lit:hover::after { opacity: 1; }
|
||||
|
||||
.eyebrow {
|
||||
font-family: var(--mono); font-size: 12px; letter-spacing: .18em;
|
||||
text-transform: uppercase; color: var(--muted);
|
||||
}
|
||||
.serif { font-family: var(--display); font-weight: 400; letter-spacing: -.01em; }
|
||||
em { font-style: italic; color: var(--mauve); }
|
||||
|
||||
/* Nav */
|
||||
header.nav { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; padding-block: 14px; }
|
||||
.nav-bar {
|
||||
display: flex; align-items: center; gap: 16px; padding: 8px 8px 8px 14px; border-radius: 999px;
|
||||
transition: background .3s, box-shadow .3s;
|
||||
}
|
||||
.scrolled .nav-bar { background: var(--glass-strong); }
|
||||
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 600; }
|
||||
.brand img { width: 28px; height: 28px; }
|
||||
.nav-links { display: flex; gap: 4px; margin-left: auto; }
|
||||
.nav-links a {
|
||||
text-decoration: none; color: var(--subtext); font-size: 14px;
|
||||
padding: 6px 12px; border-radius: 999px; transition: color .2s, background .2s;
|
||||
}
|
||||
.nav-links a:hover, .nav-links a.active { color: var(--text); background: var(--glass-hi); }
|
||||
.progress {
|
||||
position: absolute; left: 24px; right: 24px; bottom: -1px; height: 1px; border-radius: 1px;
|
||||
background: linear-gradient(90deg, transparent, var(--mauve), transparent);
|
||||
transform-origin: 0 50%; transform: scaleX(var(--p, 0)); opacity: .7;
|
||||
}
|
||||
|
||||
/* Buttons */
|
||||
.btn {
|
||||
position: relative; overflow: hidden;
|
||||
display: inline-flex; align-items: center; gap: 10px; text-decoration: none;
|
||||
font: 500 15px/1 var(--sans); padding: 13px 20px; border-radius: 999px;
|
||||
border: 1px solid transparent; cursor: pointer; white-space: nowrap;
|
||||
transition: transform .25s var(--ease), box-shadow .25s, background .25s;
|
||||
}
|
||||
.btn-primary {
|
||||
background: linear-gradient(180deg, var(--mauve-hi), var(--mauve-deep)); color: var(--on-mauve);
|
||||
box-shadow: 0 0 0 1px rgb(255 255 255 / .25) inset, 0 10px 30px -8px var(--glow);
|
||||
}
|
||||
.btn-primary::before {
|
||||
content: ""; position: absolute; inset: 0; transform: translateX(-120%);
|
||||
background: linear-gradient(100deg, transparent 30%, rgb(255 255 255 / .45) 50%, transparent 70%);
|
||||
}
|
||||
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 0 0 1px rgb(255 255 255 / .3) inset, 0 16px 40px -8px var(--glow); }
|
||||
.btn-primary:hover::before { transition: transform .8s var(--ease); transform: translateX(120%); }
|
||||
.btn-ghost { background: var(--glass); border-color: var(--glass-edge); color: var(--text); backdrop-filter: blur(12px); }
|
||||
.btn-ghost:hover { background: var(--glass-strong); transform: translateY(-2px); }
|
||||
.btn-sm { padding: 9px 14px; font-size: 14px; }
|
||||
.btn svg { width: 16px; height: 16px; flex: none; }
|
||||
.ver { font-family: var(--mono); font-size: 12px; opacity: .7; }
|
||||
|
||||
/* Hero */
|
||||
.hero { text-align: center; padding-block: clamp(48px, 9vw, 104px) 36px; }
|
||||
.hero-mark { width: 76px; height: 76px; margin: 0 auto 22px; display: block; filter: drop-shadow(0 12px 30px var(--glow)); }
|
||||
.hero h1 { font-size: clamp(44px, 7.4vw, 92px); line-height: 1; margin: 18px auto 0; max-width: 14ch; text-wrap: balance; }
|
||||
.hero h1 .w { display: inline-block; }
|
||||
.lede { max-width: 58ch; margin: 22px auto 0; color: var(--subtext); font-size: clamp(16px, 1.6vw, 18px); text-wrap: pretty; }
|
||||
.cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 32px; }
|
||||
.facts {
|
||||
display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 22px; margin-top: 26px;
|
||||
font-family: var(--mono); font-size: 12px; color: var(--muted); letter-spacing: .04em;
|
||||
}
|
||||
.facts span::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--green); margin-right: 8px; vertical-align: 2px; }
|
||||
|
||||
/* Video window: tilted back until it scrolls into view */
|
||||
.showcase { padding-block: 24px 24px; perspective: 1600px; }
|
||||
.window {
|
||||
border-radius: var(--r-panel); padding: 10px;
|
||||
transform: rotateX(var(--tilt, 10deg)) scale(var(--zoom, .96)); transform-origin: 50% 0;
|
||||
box-shadow: 0 0 0 1px var(--glass-edge), 0 40px 120px -30px var(--glow), 0 30px 80px -30px rgb(0 0 0 / .8);
|
||||
}
|
||||
.chrome { display: flex; align-items: center; gap: 8px; padding: 4px 6px 10px; }
|
||||
.chrome i { width: 11px; height: 11px; border-radius: 50%; background: var(--surface); }
|
||||
.chrome span { margin-inline: auto; font-family: var(--mono); font-size: 12px; color: var(--muted); }
|
||||
.window video { display: block; width: 100%; aspect-ratio: 16 / 9; border-radius: 14px; background: var(--base); }
|
||||
.caption { text-align: center; color: var(--muted); font-size: 14px; margin: 18px 0 0; }
|
||||
|
||||
/* Agents marquee */
|
||||
.marquee { padding-block: 40px 8px; }
|
||||
.marquee p { text-align: center; margin: 0 0 18px; }
|
||||
.track {
|
||||
display: flex; overflow: hidden;
|
||||
mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
|
||||
}
|
||||
.belt { display: flex; gap: 12px; padding-right: 12px; flex: none; animation: belt 48s linear infinite; }
|
||||
.track:hover .belt { animation-play-state: paused; }
|
||||
.chip {
|
||||
display: inline-flex; align-items: center; gap: 9px; padding: 9px 14px; border-radius: 999px;
|
||||
font-size: 14px; color: var(--subtext); white-space: nowrap;
|
||||
}
|
||||
.chip i {
|
||||
width: 16px; height: 16px; flex: none; background: currentColor;
|
||||
-webkit-mask: var(--logo) center / contain no-repeat; mask: var(--logo) center / contain no-repeat;
|
||||
}
|
||||
.chip i.none { -webkit-mask: none; mask: none; border-radius: 4px; background: var(--overlay); }
|
||||
@keyframes belt { to { transform: translateX(-100%); } }
|
||||
|
||||
/* Sections */
|
||||
section.block { padding-block: clamp(56px, 8vw, 96px); }
|
||||
.section-head { max-width: 720px; margin-bottom: 44px; }
|
||||
.section-head h2 { font-size: clamp(36px, 5vw, 60px); line-height: 1.04; margin: 14px 0 0; text-wrap: balance; }
|
||||
.section-head p { color: var(--subtext); margin: 16px 0 0; max-width: 60ch; }
|
||||
|
||||
/* Live agent demo */
|
||||
.live { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 0; border-radius: var(--r-panel); overflow: hidden; }
|
||||
.log { padding: 22px; border-right: 1px solid var(--glass-edge); min-width: 0; display: flex; flex-direction: column; }
|
||||
.log-head { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--subtext); margin-bottom: 14px; }
|
||||
.log-head .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); animation: pulse 2.4s infinite; }
|
||||
.log-head .undo { margin-left: auto; font-family: var(--mono); font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
|
||||
.calls { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font: 13px/1.5 var(--mono); }
|
||||
.call {
|
||||
display: grid; grid-template-columns: 14px minmax(0, 1fr) auto; gap: 4px 10px; align-items: start;
|
||||
padding: 9px 11px; border-radius: 10px; background: var(--well); border: 1px solid var(--glass-edge);
|
||||
opacity: .28; transition: opacity .4s, border-color .4s, transform .4s var(--ease);
|
||||
}
|
||||
.call .st { width: 14px; height: 14px; margin-top: 3px; border-radius: 50%; border: 1.5px solid var(--overlay); }
|
||||
.call b { font-weight: 500; color: var(--text); }
|
||||
.call .arg { grid-column: 2 / span 2; color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
|
||||
.call .ms { color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
|
||||
.call.run { opacity: 1; border-color: rgb(203 166 247 / .5); transform: translateX(4px); }
|
||||
.call.run .st { border-color: var(--mauve); border-top-color: transparent; animation: spin .7s linear infinite; }
|
||||
.call.done { opacity: 1; }
|
||||
.call.done .st { border: 0; background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.5l2.5 2.5L12 5.5' fill='none' stroke='%231e1e2e' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 12px no-repeat; }
|
||||
.call:not(.done) .ms { visibility: hidden; }
|
||||
@keyframes spin { to { transform: rotate(360deg); } }
|
||||
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgb(166 227 161 / .6); } 70%, 100% { box-shadow: 0 0 0 8px rgb(166 227 161 / 0); } }
|
||||
|
||||
.board-area {
|
||||
position: relative; min-width: 0; display: grid; place-items: center; padding: 40px 24px;
|
||||
background: radial-gradient(circle at 1px 1px, var(--dot) 1px, transparent 0) 0 0 / 18px 18px, rgb(17 17 27 / .35);
|
||||
}
|
||||
.board-label { position: absolute; top: 16px; left: 20px; font: 12px var(--mono); color: var(--muted); }
|
||||
.mode-pill {
|
||||
position: absolute; top: 12px; right: 16px; font: 500 12px var(--mono); padding: 4px 10px; border-radius: 999px;
|
||||
background: var(--well); border: 1px solid var(--glass-edge); color: var(--subtext); transition: color .4s;
|
||||
}
|
||||
.board {
|
||||
--a-bg: #1e1e2e; --a-surface: #313244; --a-text: #cdd6f4; --a-sub: #a6adc8; --a-accent: #cba6f7; --a-on: #1e1e2e;
|
||||
width: min(100%, 300px); aspect-ratio: 3 / 4; border-radius: 18px; padding: 26px 22px;
|
||||
display: flex; flex-direction: column; gap: 12px;
|
||||
outline: 1.5px dashed transparent; outline-offset: 6px;
|
||||
background: transparent; transition: background .6s, outline-color .4s, box-shadow .6s;
|
||||
}
|
||||
.board.light { --a-bg: #eff1f5; --a-surface: #dce0e8; --a-text: #4c4f69; --a-sub: #6c6f85; --a-accent: #8839ef; --a-on: #eff1f5; }
|
||||
.board.s1 { outline-color: rgb(203 166 247 / .6); }
|
||||
.board.s2 { background: var(--a-bg); box-shadow: 0 30px 60px -30px rgb(0 0 0 / .8); }
|
||||
.board > * { opacity: 0; transform: translateY(8px); transition: opacity .45s var(--ease), transform .45s var(--ease), background .6s, color .6s; }
|
||||
.board.s3 > * { opacity: 1; transform: none; }
|
||||
.board.s3 > *:nth-child(2) { transition-delay: .06s; } .board.s3 > *:nth-child(3) { transition-delay: .12s; }
|
||||
.board.s3 > *:nth-child(4) { transition-delay: .18s; } .board.s3 > *:nth-child(5) { transition-delay: .24s; }
|
||||
.board.s3 > *:nth-child(6) { transition-delay: .3s; }
|
||||
.a-logo { width: 34px; height: 34px; border-radius: 10px; background: var(--a-surface); }
|
||||
.a-title { font: 600 22px/1.2 var(--sans); color: var(--a-text); }
|
||||
.a-sub { font-size: 12px; color: var(--a-sub); margin-top: -6px; }
|
||||
.a-field { height: 36px; border-radius: 9px; background: var(--a-surface); }
|
||||
.a-btn {
|
||||
height: 38px; border-radius: 10px; margin-top: auto; display: grid; place-items: center;
|
||||
font: 600 13px var(--sans); background: var(--a-surface); color: var(--a-sub);
|
||||
}
|
||||
.board.s4 .a-btn { background: var(--a-accent); color: var(--a-on); }
|
||||
.board.s4 .a-logo { background: var(--a-accent); }
|
||||
.flash { position: absolute; inset: 0; background: #fff; opacity: 0; pointer-events: none; }
|
||||
.flash.on { animation: flash .5s ease-out; }
|
||||
@keyframes flash { 0% { opacity: .35; } 100% { opacity: 0; } }
|
||||
.lint {
|
||||
position: absolute; bottom: 16px; left: 50%; display: inline-flex; align-items: center; gap: 8px;
|
||||
padding: 7px 12px; border-radius: 999px; font: 500 12px var(--mono); color: var(--green);
|
||||
background: var(--glass-strong); border: 1px solid rgb(166 227 161 / .35);
|
||||
opacity: 0; transform: translate(-50%, 10px); transition: opacity .4s, transform .4s var(--ease);
|
||||
}
|
||||
.lint.on { opacity: 1; transform: translate(-50%, 0); }
|
||||
|
||||
/* Feature rows */
|
||||
.features { display: grid; gap: 24px; }
|
||||
.feature {
|
||||
display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(24px, 4vw, 56px);
|
||||
align-items: center; padding-block: 28px;
|
||||
}
|
||||
.feature:nth-child(even) { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
|
||||
.feature:nth-child(even) .copy { order: 2; }
|
||||
.feature h3 { font-size: clamp(30px, 3.6vw, 44px); line-height: 1.06; margin: 12px 0 0; text-wrap: balance; }
|
||||
.feature p { color: var(--subtext); margin: 14px 0 0; }
|
||||
.ticks { margin: 16px 0 0; padding: 0; list-style: none; display: grid; gap: 8px; color: var(--subtext); font-size: 15px; }
|
||||
.ticks li { display: flex; gap: 10px; }
|
||||
.ticks li::before { content: ""; flex: none; width: 6px; height: 6px; margin-top: 10px; border-radius: 2px; background: var(--mauve); }
|
||||
.tilt { perspective: 1200px; }
|
||||
.shot {
|
||||
border-radius: var(--r-panel); padding: 8px;
|
||||
transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform .5s var(--ease);
|
||||
}
|
||||
.shot img { display: block; width: 100%; height: auto; border-radius: 15px; }
|
||||
|
||||
/* Bento grid */
|
||||
.bento { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
|
||||
.tile { border-radius: var(--r-panel); padding: 24px; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
|
||||
.tile.wide { grid-column: span 2; }
|
||||
.tile h3 { margin: 0; font-size: 17px; font-weight: 600; }
|
||||
.tile p { margin: 0; color: var(--subtext); font-size: 15px; }
|
||||
.tile .art { height: 92px; margin-bottom: 8px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
|
||||
.fmt {
|
||||
font: 500 12px var(--mono); padding: 6px 10px; border-radius: 8px; background: var(--well);
|
||||
border: 1px solid var(--glass-edge); color: var(--subtext);
|
||||
}
|
||||
.fmt.in { color: var(--blue); } .fmt.out { color: var(--mauve); }
|
||||
.arrow-dash { flex: 1; min-width: 30px; height: 1px; background: repeating-linear-gradient(90deg, var(--overlay) 0 6px, transparent 6px 12px); background-size: 24px 1px; animation: dash 1.2s linear infinite; }
|
||||
@keyframes dash { to { background-position: 24px 0; } }
|
||||
.swatches { display: flex; gap: 8px; }
|
||||
.swatches span {
|
||||
width: 40px; height: 56px; border-radius: 10px; border: 1px solid var(--glass-edge);
|
||||
transition: transform .4s var(--ease);
|
||||
}
|
||||
.tile:hover .swatches span { transform: translateY(-6px); }
|
||||
.tile:hover .swatches span:nth-child(2) { transition-delay: .04s; } .tile:hover .swatches span:nth-child(3) { transition-delay: .08s; }
|
||||
.tile:hover .swatches span:nth-child(4) { transition-delay: .12s; } .tile:hover .swatches span:nth-child(5) { transition-delay: .16s; }
|
||||
.sketch path { fill: none; stroke: var(--mauve); stroke-width: 2; stroke-linecap: round; stroke-dasharray: 340; stroke-dashoffset: 340; }
|
||||
.sketch .note { fill: var(--peach); opacity: .85; }
|
||||
.in-view .sketch path { animation: draw 1.6s var(--ease) forwards; }
|
||||
.in-view .sketch path:nth-of-type(2) { animation-delay: .4s; }
|
||||
@keyframes draw { to { stroke-dashoffset: 0; } }
|
||||
.versions { display: grid; gap: 6px; width: 100%; font: 12px var(--mono); color: var(--muted); }
|
||||
.versions div { display: flex; gap: 10px; align-items: center; }
|
||||
.versions div::before { content: ""; width: 8px; height: 8px; border-radius: 50%; border: 1.5px solid var(--overlay); flex: none; }
|
||||
.versions div:first-child { color: var(--text); }
|
||||
.versions div:first-child::before { border-color: var(--mauve); background: var(--mauve); }
|
||||
.peers { display: flex; align-items: center; }
|
||||
.peers span {
|
||||
width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; font: 600 13px var(--sans);
|
||||
color: var(--on-mauve); margin-left: -8px; border: 2px solid var(--mantle);
|
||||
}
|
||||
.peers span:first-child { margin-left: 0; }
|
||||
|
||||
/* Local-first */
|
||||
.local { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; align-items: stretch; }
|
||||
.tree { border-radius: var(--r-panel); padding: 22px 24px; font: 13px/2 var(--mono); color: var(--subtext); overflow-x: auto; min-width: 0; }
|
||||
.tree .path { color: var(--muted); }
|
||||
.tree .d { color: var(--mauve); }
|
||||
.tree .c { color: var(--muted); }
|
||||
.tree pre { margin: 0; }
|
||||
.points { display: grid; gap: 14px; align-content: start; }
|
||||
.point { border-radius: 16px; padding: 18px 20px; }
|
||||
.point h3 { margin: 0; font-size: 16px; font-weight: 600; }
|
||||
.point p { margin: 4px 0 0; color: var(--subtext); font-size: 15px; }
|
||||
|
||||
/* Agents */
|
||||
.agents { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; }
|
||||
.card { border-radius: var(--r-panel); padding: 24px; min-width: 0; }
|
||||
.card h3 { margin: 0; font-size: 17px; font-weight: 600; }
|
||||
.card > p { color: var(--subtext); margin: 8px 0 0; font-size: 15px; }
|
||||
.stat { font-family: var(--display); font-size: 72px; line-height: 1; color: var(--mauve); font-variant-numeric: tabular-nums; }
|
||||
.ways { display: grid; gap: 14px; margin-top: 18px; }
|
||||
.way { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 12px; font-size: 14px; }
|
||||
.way b { font-weight: 500; }
|
||||
.way span { color: var(--subtext); }
|
||||
.code {
|
||||
position: relative; margin-top: 14px; border-radius: var(--r-control); background: var(--well);
|
||||
border: 1px solid var(--glass-edge); font: 13px/1.7 var(--mono); color: var(--subtext);
|
||||
}
|
||||
.code pre { margin: 0; padding: 14px 16px; padding-right: 70px; overflow-x: auto; }
|
||||
.code .c { color: var(--muted); }
|
||||
.code .k { color: var(--mauve); }
|
||||
.copy-btn {
|
||||
position: absolute; top: 8px; right: 8px; font: 500 12px var(--sans); color: var(--subtext);
|
||||
background: var(--glass-strong); border: 1px solid var(--glass-edge); border-radius: 8px;
|
||||
padding: 5px 9px; cursor: pointer; transition: color .2s, border-color .2s;
|
||||
}
|
||||
.copy-btn:hover { color: var(--text); border-color: rgb(203 166 247 / .4); }
|
||||
|
||||
/* Shortcuts */
|
||||
.keys { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
|
||||
.key { border-radius: 16px; padding: 18px; display: grid; gap: 12px; justify-items: start; }
|
||||
.key span { font-size: 14px; color: var(--subtext); }
|
||||
kbd {
|
||||
display: inline-flex; gap: 4px; font: 500 14px var(--mono); color: var(--text);
|
||||
}
|
||||
kbd b {
|
||||
min-width: 30px; height: 30px; padding: 0 8px; display: grid; place-items: center; font-weight: 500;
|
||||
border-radius: 8px; background: var(--well); border: 1px solid var(--glass-edge);
|
||||
box-shadow: 0 2px 0 rgb(0 0 0 / .4); transition: transform .15s, box-shadow .15s;
|
||||
}
|
||||
.key:hover kbd b { transform: translateY(2px); box-shadow: 0 0 0 rgb(0 0 0 / .4); }
|
||||
|
||||
/* Download */
|
||||
.dl-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 28px; }
|
||||
.dl-head .section-head { margin: 0; }
|
||||
.release-pill {
|
||||
display: inline-flex; align-items: center; gap: 10px; padding: 8px 14px; border-radius: 999px;
|
||||
font-family: var(--mono); font-size: 13px; color: var(--subtext); text-decoration: none;
|
||||
}
|
||||
.release-pill b { color: var(--text); font-weight: 500; }
|
||||
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--green); animation: pulse 2.4s infinite; }
|
||||
.platforms { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
|
||||
.platform { display: flex; flex-direction: column; gap: 12px; border-radius: var(--r-panel); padding: 22px; min-width: 0; }
|
||||
.platform.mine { box-shadow: 0 0 0 1px rgb(203 166 247 / .55), 0 0 50px -10px var(--glow); }
|
||||
.platform .tag {
|
||||
position: absolute; top: 18px; right: 18px; font: 500 11px var(--mono); letter-spacing: .08em; text-transform: uppercase;
|
||||
color: var(--on-mauve); background: var(--mauve); padding: 3px 8px; border-radius: 999px;
|
||||
}
|
||||
.platform .os { display: flex; align-items: center; gap: 12px; margin-bottom: 4px; }
|
||||
.platform .os svg { width: 28px; height: 28px; color: var(--text); flex: none; }
|
||||
.platform h3 { margin: 0; font-size: 18px; font-weight: 600; }
|
||||
.platform .arch { font-family: var(--mono); font-size: 12px; color: var(--muted); }
|
||||
.file { display: grid; grid-template-columns: minmax(0, 1fr) auto; border-radius: var(--r-control); background: var(--well); border: 1px solid var(--glass-edge); transition: border-color .2s; }
|
||||
.file:hover { border-color: rgb(203 166 247 / .5); }
|
||||
.file a { display: grid; gap: 2px; padding: 12px 14px; text-decoration: none; min-width: 0; }
|
||||
.file .fname { font: 500 14px var(--sans); }
|
||||
.file .fmeta { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; font-family: var(--mono); }
|
||||
.file .sha {
|
||||
align-self: center; margin-right: 8px; font: 500 11px var(--mono); color: var(--muted); cursor: pointer;
|
||||
background: transparent; border: 1px solid var(--glass-edge); border-radius: 7px; padding: 5px 8px;
|
||||
}
|
||||
.file .sha:hover { color: var(--text); }
|
||||
.platform .note { font-size: 13px; color: var(--muted); margin: auto 0 0; }
|
||||
.dl-foot { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; margin-top: 16px; }
|
||||
.dl-foot .card p { margin: 8px 0 0; color: var(--subtext); font-size: 14px; }
|
||||
|
||||
/* Status */
|
||||
.status { border-radius: var(--r-panel); padding: clamp(24px, 4vw, 40px); display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: center; }
|
||||
.status h2 { font-size: clamp(30px, 4vw, 44px); line-height: 1.06; margin: 10px 0 0; }
|
||||
.status p { color: var(--subtext); margin: 12px 0 0; max-width: 62ch; }
|
||||
.status .actions { display: flex; gap: 12px; flex-wrap: wrap; }
|
||||
|
||||
footer { padding-block: 40px; border-top: 1px solid var(--glass-edge); margin-top: 56px; }
|
||||
.foot { display: flex; flex-wrap: wrap; gap: 16px 28px; align-items: center; justify-content: space-between; color: var(--muted); font-size: 14px; }
|
||||
.foot nav { display: flex; gap: 20px; flex-wrap: wrap; }
|
||||
.foot a { text-decoration: none; }
|
||||
.foot a:hover { color: var(--text); }
|
||||
|
||||
.toast {
|
||||
position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); z-index: 40;
|
||||
padding: 10px 16px; border-radius: 999px; font-size: 14px; transform: translate(-50%, 20px); opacity: 0;
|
||||
transition: opacity .3s, transform .3s var(--ease); pointer-events: none;
|
||||
}
|
||||
.toast.on { opacity: 1; transform: translate(-50%, 0); }
|
||||
|
||||
/* Motion. Everything is readable at rest; motion only moves it into place. */
|
||||
@media (prefers-reduced-motion: no-preference) {
|
||||
.glow.a { animation: drift-a 22s ease-in-out infinite alternate; }
|
||||
.glow.b { animation: drift-b 28s ease-in-out infinite alternate; }
|
||||
.glow.c { animation: drift-c 26s ease-in-out infinite alternate; }
|
||||
.hero-mark { animation: float 6s ease-in-out infinite; }
|
||||
.rise { animation: rise .9s var(--ease) both; }
|
||||
.hero h1 .w { animation: word .9s var(--ease) both; animation-delay: calc(var(--i) * 60ms + 120ms); }
|
||||
.d1 { animation-delay: .1s; } .d2 { animation-delay: .45s; } .d3 { animation-delay: .6s; }
|
||||
.js .reveal { opacity: .001; transform: translateY(24px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
|
||||
.js .reveal.in-view { opacity: 1; transform: none; }
|
||||
.js .stagger > .reveal:nth-child(2) { transition-delay: .08s; }
|
||||
.js .stagger > .reveal:nth-child(3) { transition-delay: .16s; }
|
||||
.js .stagger > .reveal:nth-child(4) { transition-delay: .24s; }
|
||||
.js .stagger > .reveal:nth-child(5) { transition-delay: .32s; }
|
||||
.js .stagger > .reveal:nth-child(6) { transition-delay: .4s; }
|
||||
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
|
||||
@keyframes word { from { opacity: 0; transform: translateY(.4em); filter: blur(6px); } to { opacity: 1; transform: none; filter: none; } }
|
||||
@keyframes float { 50% { transform: translateY(-6px); } }
|
||||
@keyframes drift-a { to { transform: translate(6rem, 4rem) scale(1.1); } }
|
||||
@keyframes drift-b { to { transform: translate(-8rem, -6rem) scale(1.15); } }
|
||||
@keyframes drift-c { to { transform: translate(10rem, -4rem); } }
|
||||
}
|
||||
@media (prefers-reduced-motion: reduce) {
|
||||
html { scroll-behavior: auto; }
|
||||
.window { --tilt: 0deg; --zoom: 1; }
|
||||
.belt { animation: none; }
|
||||
.track { overflow-x: auto; }
|
||||
.pulse, .log-head .dot, .arrow-dash { animation: none; }
|
||||
.sketch path { stroke-dashoffset: 0; }
|
||||
}
|
||||
|
||||
@media (max-width: 960px) {
|
||||
.feature, .feature:nth-child(even) { grid-template-columns: minmax(0, 1fr); }
|
||||
.feature:nth-child(even) .copy { order: 0; }
|
||||
.agents, .platforms, .local, .dl-foot, .live { grid-template-columns: minmax(0, 1fr); }
|
||||
.log { border-right: 0; border-bottom: 1px solid var(--glass-edge); }
|
||||
.bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
||||
.keys { grid-template-columns: repeat(3, minmax(0, 1fr)); }
|
||||
.status { grid-template-columns: minmax(0, 1fr); }
|
||||
}
|
||||
@media (max-width: 640px) {
|
||||
.nav-links { display: none; }
|
||||
.nav-bar .btn { margin-left: auto; }
|
||||
.way { grid-template-columns: minmax(0, 1fr); gap: 2px; }
|
||||
.window { --tilt: 0deg; --zoom: 1; padding: 6px; }
|
||||
.chrome { display: none; }
|
||||
.bento { grid-template-columns: minmax(0, 1fr); }
|
||||
.tile.wide { grid-column: auto; }
|
||||
.keys { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
||||
}
|
||||
@@ -0,0 +1,347 @@
|
||||
const REPO = 'nxtime/papercraft';
|
||||
|
||||
const REDUCED = matchMedia('(prefers-reduced-motion: reduce)').matches;
|
||||
|
||||
const ICONS = {
|
||||
windows: '<svg viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M3 5.5 10.5 4.4v7.1H3V5.5Zm0 13 7.5 1.1v-7H3v5.9Zm8.4 1.2L21 21V12.6h-9.6v7.1Zm0-15.4v7.2H21V3l-9.6 1.3Z"/></svg>',
|
||||
macos: '<svg viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M16.4 12.6c0-2.4 2-3.6 2.1-3.7-1.1-1.7-2.9-1.9-3.5-1.9-1.5-.2-2.9.9-3.7.9-.8 0-1.9-.9-3.2-.8-1.6 0-3.1 1-4 2.4-1.7 3-.4 7.3 1.2 9.7.8 1.2 1.8 2.5 3 2.4 1.2 0 1.7-.8 3.1-.8 1.5 0 1.9.8 3.2.8 1.3 0 2.2-1.2 3-2.4.9-1.4 1.3-2.7 1.3-2.8 0 0-2.5-1-2.5-3.8ZM14 5.4c.7-.8 1.1-1.9 1-3-.9 0-2.1.6-2.8 1.4-.6.7-1.2 1.9-1 2.9 1.1.1 2.1-.5 2.8-1.3Z"/></svg>',
|
||||
linux: '<svg viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"><path d="M12 2c-2 0-3.3 1.7-3.3 4.2 0 1.4.4 2.4-.4 3.7C7 12 5.5 14 5.5 16.3c0 .6.1 1.1.4 1.6-.9.4-2 .9-2 1.8 0 1.2 1.9 1.3 3.5 1.8 1.3.4 2 .5 2.6-.3.4.1 1.2.2 2 .2s1.6-.1 2-.2c.6.8 1.3.7 2.6.3 1.6-.5 3.5-.6 3.5-1.8 0-.9-1.1-1.4-2-1.8.3-.5.4-1 .4-1.6 0-2.3-1.5-4.3-2.8-6.4-.8-1.3-.4-2.3-.4-3.7C15.3 3.7 14 2 12 2Zm-1.4 4c.4 0 .7.5.7 1.1s-.3 1-.7 1-.7-.4-.7-1 .3-1.1.7-1.1Zm2.8 0c.4 0 .7.5.7 1.1s-.3 1-.7 1-.7-.4-.7-1 .3-1.1.7-1.1ZM12 9c.9 0 2 .6 2 1s-1.1 1-2 1-2-.6-2-1 1.1-1 2-1Z"/></svg>'
|
||||
};
|
||||
|
||||
const PLATFORMS = [
|
||||
{ key: 'windows', name: 'Windows', arch: 'x86_64', note: 'App, CLI, MCP bridge and relay in one zip.' },
|
||||
{ key: 'macos', name: 'macOS', arch: 'Apple silicon', note: 'PaperCraft.app in a disk image, plus the CLI tools.' },
|
||||
{ key: 'linux', name: 'Linux', arch: 'x86_64 · X11 and Wayland', note: 'Needs Vulkan or GL and the usual X11 libraries.' }
|
||||
];
|
||||
|
||||
const OS = (() => {
|
||||
const ua = navigator.userAgent;
|
||||
|
||||
if (/Windows/i.test(ua)) return 'windows';
|
||||
if (/Macintosh|Mac OS X/i.test(ua) && !/iPhone|iPad/i.test(ua)) return 'macos';
|
||||
if (/Linux/i.test(ua) && !/Android/i.test(ua)) return 'linux';
|
||||
return null;
|
||||
})();
|
||||
|
||||
const toast = message => {
|
||||
const el = document.getElementById('toast');
|
||||
|
||||
el.textContent = message;
|
||||
el.classList.add('on');
|
||||
clearTimeout(toast.timer);
|
||||
toast.timer = setTimeout(() => el.classList.remove('on'), 1800);
|
||||
};
|
||||
|
||||
const copy = (text, label) => navigator.clipboard.writeText(text)
|
||||
.then(() => toast(`${label} copied`))
|
||||
.catch(() => toast('Copy was blocked. Select the text instead.'));
|
||||
|
||||
const escapeHtml = s => s.replace(/[&<>"']/g, c => `&#${c.charCodeAt(0)};`);
|
||||
|
||||
/* Release: release.json is written by the site workflow; the GitHub API is the fallback. */
|
||||
|
||||
const formatSize = bytes => `${(bytes / 1048576).toFixed(1)} MB`;
|
||||
|
||||
const formatDate = iso => new Date(iso).toLocaleDateString('en-GB', { day: 'numeric', month: 'short', year: 'numeric' });
|
||||
|
||||
const fileType = name => (name.endsWith('.tar.gz') ? 'tar.gz' : name.split('.').pop());
|
||||
|
||||
const fileLabel = name => (name.includes('-cli-') ? 'CLI tools' : 'Desktop app');
|
||||
|
||||
const loadRelease = async () => {
|
||||
try {
|
||||
const res = await fetch('release.json', { cache: 'no-cache' });
|
||||
|
||||
if (res.ok) return await res.json();
|
||||
} catch (err) {
|
||||
console.warn('release.json is unavailable, asking the GitHub API', err);
|
||||
}
|
||||
|
||||
const res = await fetch(`https://api.github.com/repos/${REPO}/releases/latest`);
|
||||
|
||||
if (!res.ok) throw new Error(`The GitHub API answered ${res.status}`);
|
||||
const r = await res.json();
|
||||
|
||||
return {
|
||||
tag: r.tag_name,
|
||||
name: r.name,
|
||||
publishedAt: r.published_at,
|
||||
url: r.html_url,
|
||||
assets: r.assets.map(a => ({ name: a.name, size: a.size, url: a.browser_download_url, digest: a.digest || null }))
|
||||
};
|
||||
};
|
||||
|
||||
const renderRelease = release => {
|
||||
const grid = document.getElementById('platforms');
|
||||
|
||||
document.querySelectorAll('[data-version]').forEach(el => { el.textContent = release.tag; });
|
||||
document.getElementById('release-date').textContent = formatDate(release.publishedAt);
|
||||
document.getElementById('release-link').href = release.url;
|
||||
|
||||
grid.innerHTML = PLATFORMS.map(p => {
|
||||
const files = release.assets.filter(a => a.name.includes(`-${p.key}-`));
|
||||
const mine = p.key === OS;
|
||||
const rows = files.map(a => `
|
||||
<div class="file">
|
||||
<a href="${escapeHtml(a.url)}">
|
||||
<span class="fname">${fileLabel(a.name)}</span>
|
||||
<span class="fmeta">${fileType(a.name)} · ${formatSize(a.size)}</span>
|
||||
</a>
|
||||
${a.digest ? `<button class="sha" type="button" data-digest="${escapeHtml(a.digest)}" title="Copy the SHA-256 checksum">SHA-256</button>` : ''}
|
||||
</div>`).join('');
|
||||
|
||||
return `
|
||||
<article class="platform acrylic lit reveal${mine ? ' mine' : ''}">
|
||||
${mine ? '<span class="tag">Your system</span>' : ''}
|
||||
<div class="os">${ICONS[p.key]}<div><h3>${p.name}</h3><div class="arch">${p.arch}</div></div></div>
|
||||
${rows || '<p class="note">No build in this release. Build from source.</p>'}
|
||||
<p class="note">${p.note}</p>
|
||||
</article>`;
|
||||
}).join('');
|
||||
|
||||
grid.querySelectorAll('.sha').forEach(btn => {
|
||||
btn.addEventListener('click', () => copy(btn.dataset.digest.replace(/^sha256:/, ''), 'Checksum'));
|
||||
});
|
||||
grid.querySelectorAll('.reveal').forEach(el => revealer.observe(el));
|
||||
grid.querySelectorAll('.lit').forEach(light);
|
||||
|
||||
const primary = OS && release.assets.find(a => a.name.includes(`-${OS}-`) && !a.name.includes('-cli-'));
|
||||
|
||||
if (primary) {
|
||||
document.getElementById('hero-dl').href = primary.url;
|
||||
document.getElementById('hero-dl-label').textContent = `Download for ${PLATFORMS.find(p => p.key === OS).name}`;
|
||||
}
|
||||
};
|
||||
|
||||
const showReleaseError = err => {
|
||||
console.error(err);
|
||||
document.getElementById('platforms').innerHTML = `
|
||||
<article class="platform acrylic">
|
||||
<h3>The release list did not load</h3>
|
||||
<p class="note">Every build is on the GitHub releases page.</p>
|
||||
<a class="btn btn-ghost" href="https://github.com/${REPO}/releases/latest">Open releases</a>
|
||||
</article>`;
|
||||
};
|
||||
|
||||
/* Motion */
|
||||
|
||||
const revealer = new IntersectionObserver(entries => {
|
||||
entries.forEach(e => {
|
||||
if (!e.isIntersecting) return;
|
||||
e.target.classList.add('in-view');
|
||||
revealer.unobserve(e.target);
|
||||
});
|
||||
}, { rootMargin: '0px 0px -8% 0px' });
|
||||
|
||||
const light = el => {
|
||||
el.addEventListener('pointermove', e => {
|
||||
const r = el.getBoundingClientRect();
|
||||
|
||||
el.style.setProperty('--lx', `${e.clientX - r.left}px`);
|
||||
el.style.setProperty('--ly', `${e.clientY - r.top}px`);
|
||||
});
|
||||
};
|
||||
|
||||
const splitHeadline = () => {
|
||||
const h1 = document.getElementById('headline');
|
||||
let i = 0;
|
||||
|
||||
const wrap = node => {
|
||||
if (node.nodeType === Node.TEXT_NODE) {
|
||||
const frag = document.createDocumentFragment();
|
||||
|
||||
node.textContent.split(/(\s+)/).forEach(part => {
|
||||
if (!part) return;
|
||||
if (/^\s+$/.test(part)) { frag.append(part); return; }
|
||||
const span = document.createElement('span');
|
||||
|
||||
span.className = 'w';
|
||||
span.style.setProperty('--i', i++);
|
||||
span.textContent = part;
|
||||
frag.append(span);
|
||||
});
|
||||
node.replaceWith(frag);
|
||||
return;
|
||||
}
|
||||
[...node.childNodes].forEach(wrap);
|
||||
};
|
||||
|
||||
[...h1.childNodes].forEach(wrap);
|
||||
};
|
||||
|
||||
const onScroll = () => {
|
||||
const y = scrollY;
|
||||
const max = document.documentElement.scrollHeight - innerHeight;
|
||||
const win = document.getElementById('window');
|
||||
const rect = win.getBoundingClientRect();
|
||||
const t = Math.min(1, Math.max(0, 1 - rect.top / (innerHeight * 0.8)));
|
||||
|
||||
document.getElementById('nav').classList.toggle('scrolled', y > 24);
|
||||
document.querySelector('.progress').style.setProperty('--p', max > 0 ? (y / max).toFixed(4) : 0);
|
||||
|
||||
if (!REDUCED && innerWidth > 640) {
|
||||
win.style.setProperty('--tilt', `${(10 * (1 - t)).toFixed(2)}deg`);
|
||||
win.style.setProperty('--zoom', (0.96 + 0.04 * t).toFixed(4));
|
||||
}
|
||||
};
|
||||
|
||||
const tiltShots = () => {
|
||||
document.querySelectorAll('.tilt').forEach(box => {
|
||||
const shot = box.querySelector('.shot');
|
||||
|
||||
box.addEventListener('pointermove', e => {
|
||||
const r = box.getBoundingClientRect();
|
||||
const x = (e.clientX - r.left) / r.width - 0.5;
|
||||
const y = (e.clientY - r.top) / r.height - 0.5;
|
||||
|
||||
shot.style.setProperty('--ry', `${(x * 6).toFixed(2)}deg`);
|
||||
shot.style.setProperty('--rx', `${(-y * 6).toFixed(2)}deg`);
|
||||
});
|
||||
box.addEventListener('pointerleave', () => {
|
||||
shot.style.setProperty('--ry', '0deg');
|
||||
shot.style.setProperty('--rx', '0deg');
|
||||
});
|
||||
});
|
||||
};
|
||||
|
||||
const countUp = el => {
|
||||
const to = Number(el.dataset.to);
|
||||
const start = performance.now();
|
||||
|
||||
const step = now => {
|
||||
const k = Math.min(1, (now - start) / 1200);
|
||||
|
||||
el.textContent = Math.round(to * (1 - Math.pow(1 - k, 3)));
|
||||
if (k < 1) requestAnimationFrame(step);
|
||||
};
|
||||
|
||||
requestAnimationFrame(step);
|
||||
};
|
||||
|
||||
/* The live agent demo: each tool call lights up, then the artboard shows its effect. */
|
||||
const runDemo = () => {
|
||||
const calls = [...document.querySelectorAll('#calls .call')];
|
||||
const board = document.getElementById('board');
|
||||
const pill = document.getElementById('mode-pill');
|
||||
const undo = document.getElementById('undo-count');
|
||||
const flash = document.getElementById('flash');
|
||||
const lint = document.getElementById('lint');
|
||||
const effects = [
|
||||
() => board.classList.add('s1'),
|
||||
() => board.classList.add('s2'),
|
||||
() => board.classList.add('s3'),
|
||||
() => board.classList.add('s4'),
|
||||
() => { board.classList.add('light'); pill.textContent = 'Mode: Light'; },
|
||||
() => { flash.classList.remove('on'); void flash.offsetWidth; flash.classList.add('on'); },
|
||||
() => lint.classList.add('on')
|
||||
];
|
||||
let step = 0;
|
||||
let timer = null;
|
||||
|
||||
const reset = () => {
|
||||
step = 0;
|
||||
calls.forEach(c => c.classList.remove('run', 'done'));
|
||||
board.className = 'board';
|
||||
pill.textContent = 'Mode: Dark';
|
||||
lint.classList.remove('on');
|
||||
undo.textContent = '0 undo steps';
|
||||
};
|
||||
|
||||
const tick = () => {
|
||||
if (step === calls.length) {
|
||||
timer = setTimeout(() => { reset(); tick(); }, 3200);
|
||||
return;
|
||||
}
|
||||
const call = calls[step];
|
||||
|
||||
call.classList.add('run');
|
||||
timer = setTimeout(() => {
|
||||
call.classList.replace('run', 'done');
|
||||
effects[step]();
|
||||
step++;
|
||||
undo.textContent = `${step} undo step${step === 1 ? '' : 's'}`;
|
||||
timer = setTimeout(tick, 380);
|
||||
}, 620);
|
||||
};
|
||||
|
||||
if (REDUCED) {
|
||||
calls.forEach((c, i) => { c.classList.add('done'); effects[i](); });
|
||||
undo.textContent = `${calls.length} undo steps`;
|
||||
return;
|
||||
}
|
||||
|
||||
new IntersectionObserver(([e]) => {
|
||||
if (e.isIntersecting && !timer) tick();
|
||||
if (!e.isIntersecting && timer) { clearTimeout(timer); timer = null; reset(); }
|
||||
}, { threshold: 0.35 }).observe(document.getElementById('live-demo'));
|
||||
};
|
||||
|
||||
const keyLabels = () => {
|
||||
const mac = OS === 'macos';
|
||||
const names = mac ? { mod: '⌘', alt: '⌥', shift: '⇧' } : { mod: 'Ctrl', alt: 'Alt', shift: 'Shift' };
|
||||
|
||||
document.querySelectorAll('kbd[data-keys]').forEach(kbd => {
|
||||
kbd.innerHTML = kbd.dataset.keys.split(' ').map(k => `<b>${names[k] || k}</b>`).join('');
|
||||
});
|
||||
};
|
||||
|
||||
const activeNav = () => {
|
||||
const links = [...document.querySelectorAll('.nav-links a[href^="#"]')];
|
||||
const spy = new IntersectionObserver(entries => {
|
||||
entries.forEach(e => {
|
||||
if (!e.isIntersecting) return;
|
||||
links.forEach(a => a.classList.toggle('active', a.getAttribute('href') === `#${e.target.id}`));
|
||||
});
|
||||
}, { rootMargin: '-45% 0px -50% 0px' });
|
||||
|
||||
links.forEach(a => {
|
||||
const target = document.querySelector(a.getAttribute('href'));
|
||||
|
||||
if (target) spy.observe(target);
|
||||
});
|
||||
};
|
||||
|
||||
/* Boot */
|
||||
|
||||
document.documentElement.classList.add('js');
|
||||
splitHeadline();
|
||||
keyLabels();
|
||||
activeNav();
|
||||
tiltShots();
|
||||
runDemo();
|
||||
|
||||
document.querySelectorAll('.reveal').forEach(el => revealer.observe(el));
|
||||
document.querySelectorAll('.lit').forEach(light);
|
||||
|
||||
document.querySelectorAll('.copy-btn').forEach(btn => {
|
||||
btn.addEventListener('click', () => copy(btn.dataset.copy, 'Command'));
|
||||
});
|
||||
|
||||
const belt = document.querySelector('.belt');
|
||||
|
||||
const twin = belt.cloneNode(true);
|
||||
|
||||
// A second copy makes the loop seamless; screen readers only need the first.
|
||||
twin.setAttribute('aria-hidden', 'true');
|
||||
belt.after(twin);
|
||||
|
||||
const counter = document.getElementById('tool-count');
|
||||
|
||||
new IntersectionObserver(([e], obs) => {
|
||||
if (!e.isIntersecting) return;
|
||||
if (!REDUCED) countUp(counter);
|
||||
obs.disconnect();
|
||||
}, { threshold: 0.6 }).observe(counter);
|
||||
|
||||
addEventListener('scroll', onScroll, { passive: true });
|
||||
addEventListener('resize', onScroll);
|
||||
onScroll();
|
||||
|
||||
addEventListener('pointermove', e => {
|
||||
const spot = document.querySelector('.spot');
|
||||
|
||||
spot.style.setProperty('--mx', `${e.clientX}px`);
|
||||
spot.style.setProperty('--my', `${e.clientY}px`);
|
||||
}, { passive: true });
|
||||
|
||||
loadRelease().then(renderRelease).catch(showReleaseError);
|
||||
@@ -1,180 +1,110 @@
|
||||
---
|
||||
name: papercraft-critique
|
||||
description: Pre-emit critique gate for work built in PaperCraft. Five panels (designer, critic, brand, accessibility, copy) score a screen 0-10 against PaperCraft's own objective evidence (lint_design, verify_code, get_screenshot, get_design_spec, get_variables), the weighted composite must reach 8.0, and a failed gate ships the best round instead of the last one. Use when an agent is about to hand over a PaperCraft screen and wants a tool-backed review instead of a self-praise.
|
||||
description: Critique finished PaperCraft work the way a design team does - against the person's objective, through independent reviewers (the person's vision, UX heuristics, flow across screens, QA states, visual, accessibility, copy, an end user from the audience), each finding rated 0-4 and backed by tool evidence, then fixed, reported and, when the person approves, kept as a lesson. Use when finish_working_on_nodes offers a critique, when asked to review or critique a design, or before handing over a screen or flow.
|
||||
---
|
||||
|
||||
# papercraft-critique
|
||||
|
||||
A gate, not a compliment. Before a screen leaves the app it goes through five panels. Each panel is a rubric pass over the same artifact, and each panel may only cite what a PaperCraft tool actually returned. The panels produce five scores, the scores produce one composite, and the composite decides whether the work ships. Mechanics live in the `papercraft` skill, taste in `papercraft-design`; this skill is the gate.
|
||||
A critique judges a design against what it is for, not against taste. The tool `critique_design`
|
||||
hands you the evidence and the reviewers; this skill is how to run them. Mechanics live in the
|
||||
`papercraft` skill, taste in `papercraft-design`. Per-reviewer checklists:
|
||||
[personas.md](references/personas.md).
|
||||
|
||||
Reference: [panels.md](references/panels.md) (what each panel inspects, which tool backs it, its 0–10 bands).
|
||||
## 1. When
|
||||
|
||||
## 1. When the gate runs
|
||||
* `finish_working_on_nodes` returns `next`: ask the person (`ask_user`) whether to critique now.
|
||||
* The person asks "review this", "is it ready?", "critique it".
|
||||
* Before handing over a whole screen or flow. Not for one component, an early draft or a copy tweak.
|
||||
|
||||
Run it when the resolver (section 2) says on, or when the request is a review of finished work:
|
||||
## 2. Objective first
|
||||
|
||||
* a whole screen is about to be handed over: landing page, dashboard, sign-in, settings, an onboarding flow, a whiteboard plan;
|
||||
* a redesign of an existing screen, after the edits and a clean `lint_design`;
|
||||
* the user asked "does this look right?", "review this", "critique it", "is it ready to ship?".
|
||||
Critique without an objective is opinion. Before judging, have:
|
||||
|
||||
Do not run it for: a single component or icon, an exploratory draft before a direction is chosen (the `papercraft-design` section 0 step), or a one-line copy tweak. The gate costs a lint and a screenshot per round; spend it on work that is finished.
|
||||
* **Objective**: what the work must achieve ("a returning customer reorders in two taps").
|
||||
* **Audience**: who uses it, in what context (phone, in a hurry, first visit, low vision).
|
||||
* **Top tasks**: the two to five things people come to do.
|
||||
|
||||
If the gate is on for a run, it must produce a status. Never skip it silently: report `Degraded` with the reason.
|
||||
Take them from the brief, the spec, the person's notes (`get_feedback`) and references. Missing?
|
||||
Ask with `ask_user` and pass them to `critique_design {objective, audience}`.
|
||||
|
||||
## 2. Enable resolver
|
||||
## 3. The reviewers
|
||||
|
||||
Four levels, highest priority first. Take the first level that gives an explicit answer; "unset" falls through to the next one. A higher level saying *off* is final — a lower level cannot turn the gate back on.
|
||||
|
||||
| Order | Level | PaperCraft equivalent | How to read it |
|
||||
|---|---|---|---|
|
||||
| 1 | Per-task policy | the instruction the agent was given for this run | "run the critique gate before you finish", "review this screen" |
|
||||
| 2 | Per-project setting | a toggle stored in the project's own metadata | **not implemented today** — PaperCraft has no project-level flag. Treat this level as unset and fall through to the environment flag or the per-task instruction |
|
||||
| 3 | Environment flag | `PAPERCRAFT_CRITIQUE_ENABLED` | `1` / `true` / `always` = on, `0` / `false` / `never` = off, unset = fall through |
|
||||
| 4 | Rollout phase | the release phase of the skill itself | off by default: the gate ships disabled until a run or a project turns it on |
|
||||
|
||||
So today the gate turns on in one of two ways: the user asks for it in the run's instructions, or `PAPERCRAFT_CRITIQUE_ENABLED=1` is in the environment. A future project setting — stored with the project, not with the user — would sit between those two and win over the environment, so a project could opt in permanently without an env var.
|
||||
|
||||
## 3. Order of operations
|
||||
|
||||
Objective checks first, subjective panels second. A panel never scores above evidence that contradicts it.
|
||||
|
||||
One round is: **evidence → repair → judge → score**.
|
||||
|
||||
1. **Snapshot.** Note the `pageId` and the artboard `nodeId` under review and keep them for the whole gate. A page switch between rounds invalidates the evidence.
|
||||
2. **Evidence.** `lint_design` (`nodeId`, `pageId`, no `fix` yet) for the raw findings — the payload counts `errors`, `warnings` and `info`, groups them in `byRule`, and lists each issue with its `rule`, `severity`, `node`, `message` and `fix`; `get_screenshot` of the same node (`scale: 2` to read small text); `get_variables` for the token set and the active mode; `get_design_spec` (`nodeId`, `target`) when the design is headed for code. If there is code to check, `verify_code` (`nodeId`, `target`, `code`).
|
||||
3. **Repair the hard evidence.** Fix every `lint_design` error and warning and re-run the lint until it is clean; fix every `verify_code` violation until `passed` is true. A panel cannot be scored on a design that still carries a lint error.
|
||||
4. **Judge the five panels** on the evidence from steps 2–3 plus the screenshot. Every finding cites the tool result or the screenshot region behind it.
|
||||
5. **Score.** Five scores 0–10, then the composite (section 5). Composite ≥ 8.0 → status `Shipped`, stop, `finish_working_on_nodes`.
|
||||
6. **Otherwise fix and go again.** Take the findings in composite-impact order, fix them, run round N+1. Maximum 3 rounds.
|
||||
7. **Ship the best round** if round 3 is still below the threshold (section 6).
|
||||
|
||||
The panels are rubric passes by the agent that holds the tools: one agent, five passes, five different rubrics. A runtime that can spawn subagents may run the panels in parallel, but the evidence vetoes, the composite and the round counter belong to the coordinator.
|
||||
|
||||
## 4. Hard evidence vetoes a panel
|
||||
|
||||
`lint_design` and `verify_code` are not suggestions. Each finding belongs to one panel, and that panel cannot score above the band its evidence forces.
|
||||
|
||||
| Evidence | Rule | Owner panel | Cap |
|
||||
|---|---|---|---|
|
||||
| `lint_design` error | `contrast` | Accessibility (the Critic reads it too) | 3.9 |
|
||||
| `lint_design` warning | `text-size` (under 12px) | Accessibility | 6.9 |
|
||||
| `lint_design` warning | `spacing-grid` (off the 4px grid) | Designer | 6.9 |
|
||||
| `lint_design` warning | `touch-target` (under 44px) | Accessibility | 6.9 |
|
||||
| `lint_design` warning | `layer-name` (default names) | Designer | 6.9 |
|
||||
| `lint_design` warning | `hard-coded-color` | Brand | 6.9 |
|
||||
| `lint_design` info | `type-scale` | Designer | none — must be listed |
|
||||
| `verify_code` error | `missing-text` | Copy | 3.9 |
|
||||
| `verify_code` error | `hardcoded-color` | Brand | 3.9 |
|
||||
| `verify_code` error | `forbidden-absolute` | Designer | 3.9 |
|
||||
| `verify_code` error | `missing-layout` | Designer | 3.9 |
|
||||
| `verify_code` warning | `missing-component` | Brand | 6.9 |
|
||||
| `verify_code` warning | `spacing-drift` | Designer | 6.9 |
|
||||
|
||||
An error caps the owning panel at 3.9 (Blocker band), a warning at 6.9 (Weak band), an `info` item caps nothing but must appear in the panel's notes. `hard-coded-color` arrives in both flavours: a warning when the color equals a variable that exists, an info when it is a literal used several times — the warning caps Brand, the info does not. The cap lifts as soon as the finding is gone; the next round re-scores the panel freely.
|
||||
|
||||
A finding is evidence for its owner and a hint for the others: `contrast` also informs the Critic, `spacing-grid` also informs the Brand (was it the token or the layout?), but only the owner is capped.
|
||||
|
||||
## 5. The panels and the composite
|
||||
|
||||
| Panel | Judges | Weight |
|
||||
| Persona | Asks | Method |
|
||||
|---|---|---|
|
||||
| Designer | layout, composition, hierarchy, spacing rhythm, type scale in use | **0 in v1** — it still scores and its findings still drive the next round |
|
||||
| Critic | does it meet the brief; contrast, weight, readability | 0.4 |
|
||||
| Brand | token compliance, on-brand color, voice | 0.2 |
|
||||
| Accessibility | WCAG, focus rings, semantic structure, alt text | 0.2 |
|
||||
| Copy | voice, tone, terseness, error-message quality | 0.2 |
|
||||
| `vision` | Does it achieve the objective, as the person imagined it? | Objective, element, effect, why (Connor and Irizarry) |
|
||||
| `ux` | Can people use it without help? | Nielsen's 10 heuristics |
|
||||
| `flow` | Do the screens make one coherent journey per task? | Task walkthrough across screens, 4 questions per step |
|
||||
| `qa` | What breaks with real data and states? | State and edge-case matrix, pass/fail/n.a. |
|
||||
| `visual` | Does the eye land right, does it hold together? | Hierarchy, balance, contrast, gestalt, rhythm, tokens |
|
||||
| `accessibility` | Can everyone use it? | W3C POUR applied to a design |
|
||||
| `copy` | Is every word clear and specific? | Plain language, labels, errors, empty states |
|
||||
| `end-user` | Where would this user get stuck or give up? | Persona walkthrough of the top task |
|
||||
|
||||
```
|
||||
composite = critic x 0.4 + brand x 0.2 + accessibility x 0.2 + copy x 0.2
|
||||
```
|
||||
`vision` always runs: the person's intent is the yardstick for the others. Pick the rest with
|
||||
`personas` (default: all). The person's own words outrank any reviewer.
|
||||
|
||||
The weights sum to 1.0, so the composite is also 0–10. The Designer carries weight 0 in v1 on purpose: it is the panel most likely to argue with itself, so its score is reported and its findings are acted on, but it does not move the composite.
|
||||
## 4. Independence
|
||||
|
||||
Each panel scores 0–10 in half-point steps. The composite is the weighted sum, rounded to two decimals.
|
||||
Several reviewers find far more than one, but only when they work apart (Nielsen: one
|
||||
evaluator finds about a third of the problems, three to five most of them). Reviewers who
|
||||
discuss or debate converge and amplify each other's bias.
|
||||
|
||||
| Composite | Verdict |
|
||||
* **With subagents**: one subagent per persona, given only its persona brief, the objective and
|
||||
the evidence. No reviewer sees another's findings before rating.
|
||||
* **Alone**: one pass per persona, in order, writing that persona's findings before reading the
|
||||
next brief. Do not revise earlier personas' findings during later passes.
|
||||
* **You coordinate**: you merge and judge; you never let reviewers argue a finding out.
|
||||
|
||||
## 5. Evidence
|
||||
|
||||
From `critique_design`: lint (fix every error and warning first), the `flow` graph (arrows between
|
||||
screens, `deadEnds`, `unreached`), the lessons. Then `get_screenshot` each artboard at scale 1
|
||||
(2 for small text) in every variable mode, `get_bounds` for overflow, `get_feedback` for the
|
||||
person's notes. Every finding cites one of these: a tool result or a screenshot region. No
|
||||
evidence, no finding.
|
||||
|
||||
## 6. A finding
|
||||
|
||||
`persona`, `heuristic or check`, `element` (layer name), `seen` (the observation), `effect` (on
|
||||
the objective), `evidence`, `severity`, `suggestion`. Keep the observation and the suggestion
|
||||
apart: critique is analysis, not brainstorming. Each persona also names at least one thing that
|
||||
works and should stay.
|
||||
|
||||
Severity (Nielsen), from frequency, impact and persistence:
|
||||
|
||||
| | |
|
||||
|---|---|
|
||||
| ≥ 8.0 | Ship |
|
||||
| < 8.0 | Not shippable as is: fix and re-run, or ship the best round after round 3 |
|
||||
| 0 | not a problem |
|
||||
| 1 | cosmetic: fix if time allows |
|
||||
| 2 | minor: low priority |
|
||||
| 3 | major: fix before handing over |
|
||||
| 4 | catastrophe: blocks the task, fix now |
|
||||
|
||||
The band legend is the same for every panel:
|
||||
Every broken lesson (`lessons`) is a finding of at least 3.
|
||||
|
||||
| Band | Range | Means |
|
||||
|---|---|---|
|
||||
| Blocker | 0.0–2.9 | Broken: the panel's own evidence is violated. Cannot ship |
|
||||
| Poor | 3.0–4.9 | Works against the brief or the brand; ships visible damage |
|
||||
| Weak | 5.0–6.9 | Passable but noticeably off; expect a second round |
|
||||
| Acceptable | 7.0–7.9 | No blocker, but a reviewer would ask for one change |
|
||||
| Good | 8.0–9.4 | Ships as is |
|
||||
| Excellent | 9.5–10.0 | Reference quality for this project |
|
||||
## 7. Merge, fix, report
|
||||
|
||||
What each panel inspects, which tool backs it and where its scores land: [panels.md](references/panels.md).
|
||||
1. **Merge** into one list: join duplicates, count the personas that found each (two or more is
|
||||
confirmed), severity is the mean of their independent ratings.
|
||||
2. **Fix** every 3 and 4 with the smallest edit (`update_styles`, `set_text_content`), then check
|
||||
that finding again with the same evidence. The work is ready when no 3 or 4 is open and lint is
|
||||
clean. Three fix rounds at most; then hand over with the open findings stated.
|
||||
3. **Report** to the person: what works, then findings by severity, each with what was seen, the
|
||||
evidence, the suggestion and whether it was fixed. Phrase open ones as questions about the
|
||||
objective ("How does a first-time user find Reorder from here?"), not verdicts.
|
||||
|
||||
## 6. Rounds and the fallback
|
||||
## 8. Lessons
|
||||
|
||||
* At most **3 rounds** per gate. The counter is per gate, not per panel.
|
||||
* A round ends when the composite is computed.
|
||||
* Rounds 2 and 3 exist to fix what the panels found. Fix in composite-impact order: the panel with the largest `weight x (10 - score)` first.
|
||||
* **`fallbackPolicy: ship_best`.** If the third round is still below 8.0, the status is `Below threshold` and what ships is the best round, not the last one. Best = highest composite; a tie goes to the earlier round (fewer changes). A later round edited the canvas, so put the canvas back into the best round's state before handing over — undo back to it, or re-apply that round's fix list in order.
|
||||
* Ship the best round's artifact and report the failing score. `Below threshold` is a status, not a licence to hide the number.
|
||||
Ask the person with `ask_user` which findings to remember, one question per finding: for every
|
||||
project, for this project, or not. Save only what they approve, with
|
||||
`design_lessons {add: {rule, why, scope}}`: the rule is one line written as an instruction
|
||||
("Screens keep their device height; the main column scrolls"), `why` is what went wrong. Never
|
||||
save a lesson the person did not approve, and never save praise. Lessons come back in
|
||||
`get_basic_info` and in the next `critique_design`; `design_lessons {remove: "L3"}` drops one.
|
||||
|
||||
## 7. Status vocabulary
|
||||
## Sources
|
||||
|
||||
Every gate ends with exactly one status.
|
||||
|
||||
| Status | When | What ships |
|
||||
|---|---|---|
|
||||
| `Shipped` | composite ≥ 8.0 | the reviewed artifact, unchanged |
|
||||
| `Below threshold` | still < 8.0 after round 3 | the best-scoring round's artifact (`ship_best`), with the score reported |
|
||||
| `Timed out` | the gate ran out of its budget (rounds or minutes) before a verdict | the best round so far, with the timeout stated |
|
||||
| `Interrupted` | the user or the session stopped the gate mid-run | the last complete round's artifact |
|
||||
| `Degraded` | a panel could not be judged properly (section 8) | the artifact, but the verdict is provisional and the reason is named |
|
||||
|
||||
`Degraded` outranks `Shipped`: a degraded panel is capped at 6.9, so a degraded run reports `Degraded`, not `Shipped`, even when the composite clears 8.0.
|
||||
|
||||
## 8. Degraded reasons
|
||||
|
||||
A panel that cannot be judged on real evidence is not scored as if it were fine. It is capped at 6.9, the composite is computed with the cap, and the run reports `Degraded` with the reason and the panel it hit.
|
||||
|
||||
| Reason | Cause | Handling |
|
||||
|---|---|---|
|
||||
| `malformed_block` | a tool returned something the gate could not parse (lint payload in an unexpected shape, a truncated screenshot answer) | retry the tool once; if it still fails, judge the panel on the evidence you do have and name the missing part |
|
||||
| `oversize_block` | the evidence was too big to read whole (a screenshot scaled down past legibility, a tree deeper than the context, a lint payload whose `truncated` flag is set) | narrow the scope: screenshot or lint a subtree, split the screen into regions and judge region by region |
|
||||
| `adapter_unsupported` | the requested target or format is not supported here (a `verify_code` target the project does not build) | drop that check; the panel falls back to the screenshot plus the design rules |
|
||||
| `protocol_version_mismatch` | the MCP server exposes a different tool set than the gate expects (a tool renamed, an argument changed) | stop using the broken tool, finish what you can, report `Degraded`; do not guess the schema |
|
||||
| `missing_artifact` | the thing under review is gone (artboard deleted, page switched, stale node id) | re-snapshot with `get_basic_info` and restart the gate; if the artifact is truly gone, report `Degraded` |
|
||||
|
||||
Degradation is a report, not an excuse: name the reason, the panel and the evidence you lost.
|
||||
|
||||
## 9. What the gate reports
|
||||
|
||||
End the gate with the status, the numbers and the findings, in that order:
|
||||
|
||||
```
|
||||
Critique gate - Sign in (page p1, artboard 3fa9c1:7)
|
||||
Round 2 of 3 - composite 8.44 / threshold 8.00 - status Shipped
|
||||
Designer 7.5 (weight 0) | Critic 8.5 | Brand 8.5 | Accessibility 8.5 | Copy 8.2
|
||||
Composite = 8.5x0.4 + 8.5x0.2 + 8.5x0.2 + 8.2x0.2 = 8.44
|
||||
```
|
||||
|
||||
Then, per finding: the panel, what was seen, the evidence behind it (tool and finding, or the region of the screenshot), the fix, and whether it was fixed in this round or is still open.
|
||||
|
||||
Machine-readable form, when the caller wants JSON:
|
||||
|
||||
```json
|
||||
{
|
||||
"status": "Shipped",
|
||||
"threshold": 8.0,
|
||||
"composite": 8.44,
|
||||
"round": 2,
|
||||
"rounds": [{ "round": 1, "composite": 7.35 }, { "round": 2, "composite": 8.44 }],
|
||||
"scores": { "designer": 7.5, "critic": 8.5, "brand": 8.5, "accessibility": 8.5, "copy": 8.2 },
|
||||
"weights": { "designer": 0.0, "critic": 0.4, "brand": 0.2, "accessibility": 0.2, "copy": 0.2 },
|
||||
"degraded": [],
|
||||
"findings": [{ "panel": "critic", "evidence": "get_screenshot: headline at 16px over a photo", "severity": "warning", "state": "fixed" }]
|
||||
}
|
||||
```
|
||||
|
||||
## 10. Attribution
|
||||
|
||||
The five-panel critique contract — the roles, the weights, the composite, the 8.0 threshold, the three rounds and the `ship_best` fallback — is inspired by OpenDesign's Critique Theater (https://github.com/nexu-io/open-design, Apache-2.0). The contract is re-implemented here in PaperCraft's own words and against PaperCraft's own tools; no text was copied.
|
||||
Adam Connor and Aaron Irizarry, *Discussing Design* (objective, element, effect, rationale);
|
||||
Nielsen Norman Group: 10 usability heuristics, severity ratings, cognitive walkthroughs, design
|
||||
critiques, visual design principles; W3C WAI accessibility principles (POUR); work on panels of
|
||||
independent LLM judges (debate amplifies bias, a coordinating judge resists it).
|
||||
|
||||