Commit graph

408 commits

Author SHA1 Message Date
Gergő Törcsvári
a77f7ae346
fix(standalone): bump KICAD_VERSION_DIR 9.99 -> 10.0 so seeded lib tables are read
After the kicad fork was rebased onto KiCad 10.0.4, GetMajorMinorVersion() (and
thus PATHS::GetUserSettingsPath()'s version subdir) became "10.0", but the
standalone still seeded the global sym-lib-table / config under
~/.config/kicad/kicad/9.99/. The WASM read .../10.0/ and found nothing, so
LIBRARY_MANAGER loaded 0 symbol-table rows and the Add Symbol / Add Power
choosers came up empty ("0 items loaded") with no library list requests.

Aligning KICAD_VERSION_DIR with the build's version makes the chooser load all
222 CDN libraries (19,779 symbols) again. Verified in the local demo against live
R2 (libs/kicad/10.0.3). The footprint editor / pcbnew read the same dir, so this
fixes their libraries too.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 13:50:55 +02:00
Gergő Törcsvári
e8d964d871
feat(demo): local dev-demo runner — R2 libs + example gallery, no backend/partykit
scripts/deploy/dev-demo.mjs (+ `pnpm dev:demo`) is the dev sibling of
build-demo.mjs: it runs the standalone via `vite dev` in the no-backend demo
configuration so a local WASM build can be exercised against the live R2 CDN.

  - libraries: live R2 CDN (VITE_LIBS_SOURCE=cdn, libs/kicad/<lib-tag>, default
    10.0.3) — IDB-cached, read-only; the lazy/fat lib-load path
  - projects: the read-only example gallery (deploy/demo/gallery.json → the same
    "Demo Board") built locally via publish-content.mjs and served same-origin at
    /content/<gallery-tag>/; --content-tag pins the live CDN gallery instead;
    --no-gallery falls back to local-folder + IDB only
  - no partykit (VITE_YJS_PROVIDER=broadcastchannel), no REST backend
    (offline.invalid → local-folder loader), browser-local IDB projects
  - WASM: local fresh build at /wasm (default) or --wasm r2

The generated gallery (public/content symlink, web/standalone/.demo-cdn) is
gitignored, mirroring the public/wasm dev symlink.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 08:16:43 +02:00
Gergő Törcsvári
d6ce380458
fix(wasm): add MODEL_SUBSTITUTION no-op stub for 3D-disabled pcbnew/footprint build
Provides wasm/stubs/model_substitution_stub.cpp — no-op IsWrlExtension /
STEP_CATALOG::Build / FindMatchFor — so pcbnew and footprint_editor link when the
3D viewer is off (KICAD_BUILD_3D_VIEWER_WASM=OFF). The KiCad 10 rebase made
dialog_migrate_3d_models.cpp reference these, which live in the unlinked 3D
library. The browser build has no 3D viewer, so model migration finds no
substitutions. Bumps kicad to the matching CMake wiring (fef0343).

Verified: pcbnew + footprint_editor compile and link clean (eeschema/symbol_editor
unaffected).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 08:14:47 +02:00
Gergő Törcsvári
30645dbae5
feat(libs): fat-list provider + getAllItems + parallel lib pre-sync; re-land onto KiCad 10 wasm-port
Replays the symbol-editor fast-lib-load work after the kicad fork was rebased
onto KiCad 10.0.4 and wasm-port was force-pushed. Carries the standalone libs
TS code (fat-list provider, getAllItems, parallel lib pre-sync) and bumps the
submodule pointers to the re-applied tips:

- kicad      -> c63009046 (lazy load on expand + chooser preview + fat-load enumerate)
- wxwidgets  -> 5d40228   (flush events + repaint after modal button click)
- pcbjam-shared -> c6a7e00 (bulk readAll for fat-load lib warm-up)

The 824e8cc build-kicad-target.sh sym-converter-contamination fix is omitted:
the KiCad 10 integration (ce344da) already pins KICAD_SYM_CONVERTER_WASM=OFF for
non-sym_convert targets. Verified: eeschema WASM kiface compiles + links; libs
unit tests 10/10.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-25 20:31:25 +02:00
Istvan Matejcsok
ce344da2dc upgrade: ⬆️ bump kicad 2026-06-25 09:57:42 +02:00
Istvan Matejcsok
a7cdafbb39 upgrade: ⬆️ bump kicad + wxwidgets 2026-06-25 09:33:04 +02:00
Istvan Matejcsok
40629fe9b5 test(eeschema): drop obsolete test.fail on crosshair cycle
The crosshair toolbar group-cycle (ACTION_TOOLBAR::onToolEvent) was
expected-to-fail because the kicad submodule was a pre-10.0 (9.99.0)
snapshot that lacked it. The KiCad 10.0.4 rebase on this branch restores
the behavior, so the test now passes and Playwright flagged it as
"Expected to fail, but passed". Remove the test.fail annotation as the
test's own comment instructed.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-24 10:31:22 +02:00
Istvan Matejcsok
ddd2c4f5cc fix(test): match KiCad 10 FONT::Draw signature in gal-webgl stub
KiCad 10.0.4 added two trailing optional params (std::optional<VECTOR2I>
aMousePos, wxString* aActiveUrl) to the out-of-line FONT::Draw declaration
in font/font.h. The hand-written stub in the GAL WebGL test app still
declared the old 6-arg form, so it matched no declaration and failed the
CI "Build GAL WebGL test app" step. Update the stub signature to match.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-24 10:30:25 +02:00
Istvan Matejcsok
cdaa96250d fix(wasm): KiCad 10 kiplatform/libgit2 stubs, e2e fixtures, asyncify -g hook
- wasm/kiplatform: add EnableDarkMode, IO::TimestampDir, UI::AllowNetworkFileSystems,
  UI::CancelPendingScroll, SECRETS::DeleteSecret (new KiCad 10 functions).
- wasm/stubs/libgit2_stub.c: ~156 no-op stubs for KiCad 10's restructured git
  backend + git-backed local history + text_eval VCS.
- tests/kicad: bump the demo project dir 9.99 -> 10.0 (KiCad 10 stores projects
  under /home/kicad/documents/kicad/10.0/) — fixes load-pcb + 3d-viewer e2e.
- scripts/common/apply-asyncify.sh: ASYNCIFY_EXTRA_OPTS hook (e.g. -g for
  symbolizable wasm traces).
- kicad submodule -> ef00c2d3 (KiCad 10 link + runtime adaptations).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-24 10:30:25 +02:00
Istvan Matejcsok
3e3e97aec7 wasm-port-rebase: KiCad 10.0.4 rebase + WASM build adaptations
Root-side changes for the wasm-port-rebase work:
- kicad submodule bumped to wasm-port-rebase (43-commit rebase onto KiCad 10.0.4
  + the KiCad-10 WASM source adaptations)
- wasm/kiplatform/policy.cpp: GetPolicyEnumUInt -> std::optional (KiCad 10 API)
- wasm/stubs/api_plugin_stub.cpp: API_PLUGIN_MANAGER signature sync (KiCad 10 API)

Compiles 100% for pcbnew (3D viewer on, -O1); WASM link + e2e parity still pending.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-24 10:30:25 +02:00
Istvan Matejcsok
129f9496ce fix: 🐛 init window context unconditionally in setWindowRect 2026-06-23 16:15:03 +02:00
Istvan Matejcsok
a4dd0eaf3b fix: 🐛 wxWdigets popup position 2026-06-23 14:32:38 +02:00
Istvan Matejcsok
6493f8fe00 fix: 🐛 remove css duplication 2026-06-23 13:00:08 +02:00
Istvan Matejcsok
c35005589d refactor(cmake): batch F (gerbview/pl_editor #5 + navlib #6) + docs
Bumps kicad to 6f82742e68 (in-place CMake de-dup pass A-F complete) and updates
the fork-cleanup docs: CMake churn 1,702 -> 1,019, build-graph proven byte-identical
pre/post (zero behavior change), only Phase-B cmake/wasm relocation remaining.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-22 18:50:08 +02:00
Istvan Matejcsok
a3478fe3a5 refactor(cmake): de-churn batches A-E (fork-cleanup doc 02)
- KICAD_WASM_LAYER cache var replaces 25 ${CMAKE_SOURCE_DIR}/../wasm reach-outs
- pcbnew Python install: wrap-and-reindent -> early-return guard
- list(REMOVE_ITEM) for PCBNEW_IO_LIBRARIES (cache-FORCE), eeschema importers, GAL_SRCS
- add_shader redefined via wasm/cmake/WasmShaderOverride.cmake (upstream calls reused)
- additive BUILD_KIWAY_DLL property overrides; api kiapi type var
- pcb_calculator whole-file fork -> wasm block + guarded native body

Upstream-byte-identical where possible. WASM build + e2e (9/9, -O1) verified.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-22 18:50:08 +02:00
Gergő Törcsvári
913bc90fa0
ci: single build recipe (reusable) + ordered tag release pipeline; two-tier opt cache
Fixes two coupled bugs: (1) a tag deployed the demo by snapshotting the STALE registry with no build/publish, so v0.1.1 shipped v0.1.0-era wasm; (2) publish-wasm built -O1/3D-off while ci-ubicloud built -O1/3D-on — two diverging recipes.

wasm-build.yml (reusable workflow_call): THE single build+test recipe, parameterized by opt_level / build_3d_viewer / run_tests / no_cache / upload_output. Two-tier output cache around build.sh's new --compile-only/--postprocess-only split: a BASE cache keyed opt-INDEPENDENTLY (compile output + sysroot headers, shared across -O1/-O2) and a FINAL cache keyed opt-SPECIFICALLY. final-hit ⇒ skip all; final-miss+base-hit ⇒ restore base, run only the asyncify/-O tail; full-miss ⇒ compile then postprocess. Both keys now include the 3D flag, closing the cache-poisoning divergence.

ci-ubicloud.yml: thin caller (main/PR/dispatch) → wasm-build at -O1. release.yml (tag v*): meta → build (wasm-build at -O2 + e2e gate, uploads output, reuses main's base cache so only the -O2 tail rebuilds) → publish-wasm (content-addressed push + manifest-<tag>.json) → deploy-demo (build-demo pinned to that manifest + libs/kicad/$LIB_TAG → Pages). So the shipped build is exactly the tested build, and the demo can never point at stale wasm.

deploy-demo.yml: demoted to manual dispatch-only re-deploy (keeps the --from-registry snapshot for re-shipping an already-published tag). publish-wasm.yml: deleted (folded into release.yml + wasm-build.yml).

Validated: actionlint clean (bar the known ubicloud custom-label note), YAML + needs-graph + reusable-path checks pass. NOT runtime-tested — the build can't run locally; needs a CI smoke (a PR exercises ci-ubicloud→wasm-build; a throwaway tag exercises release.yml) before relying on it.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-22 16:23:33 +02:00
Gergő Törcsvári
80ee95a785
build: split build.sh into --compile-only / --postprocess-only phases
The container compile produces an OPT-INDEPENDENT base wasm; the only opt-dependent work is the final 'wasm-opt -O$LEVEL' shrink in apply-asyncify (host post-process). Splitting the build at that boundary lets CI cache the expensive compile ONCE (shared across -O1/-O2) and re-run only the asyncify/-O tail per opt level.

--compile-only: in-container compile → output/ base wasm (no post-process). --postprocess-only: pure host dyncall+finalize+asyncify+wasm-opt -O on the existing base (no container; get-wasm-opt self-provisions Binaryen). Default 'both' is unchanged. Phase flags are extracted before ARGS so they are not forwarded to inner build-<app>.sh. bash -n + shellcheck -S error clean; extraction unit-checked incl. the empty-after-filter case.

Enables the two-tier CI cache (opt-independent base + opt-specific final) so an -O2 demo release reuses main's compiled base and only runs asyncify+O2.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-22 16:23:30 +02:00
Istvan Matejcsok
6bbd211c4a fix: 🐛 modal border + background after dnd
 Closes: #22
2026-06-22 13:41:01 +02:00
Istvan Matejcsok
fdfabea6c8 chore: 🔧 fork-cleanup tooling + bump kicad submodule
- kicad → a2c634f2: drop redundant wasm guards, restore upstream
  (modified upstream files 95→86, churn 3180→3104)
- kicad-diff-stats.sh: fix fork-point detection (add missing commit authors
  + an @emergence-engineering.com domain net) so it reports the real
  divergence instead of 0
- build-kicad-target.sh: drop dead -DKICAD_PCM and -DBUILD_GITHUB_PLUGIN
  flags (not options in this KiCad version); keep -DKICAD_SPICE=OFF, which is
  read by wasm/cmake/Findngspice.cmake

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-22 12:17:46 +02:00
Istvan Matejcsok
cee569dc5d fix: 🐛 kicad aui resize
 Closes: #20
2026-06-22 08:49:22 +02:00
Gergő Törcsvári
6b737f95ed
feat(deploy): publish-libs CI + full clone (C1.3)
publish-libs.ts: --clone <dir> shallow-clones kicad-symbols + kicad-footprints at --lib-tag (full, all libs) and uses them as sources, so CI publishes the whole set with one command.

publish-libs.yml: decoupled workflow_dispatch (mirrors publish-wasm.yml) — lib_tag input (default 10.0.3) + force; clones + publishes to R2, skip-if-exists keyed by the tag. Dependency-free import chain ⇒ no workspace install (just node + npx tsx + git + wrangler).

deploy-demo.yml: LIB_TAG=10.0.3 → build-demo --lib-tag, so the demo serves the full library set from libs/kicad/<LIB_TAG>. Validated locally over .cache: publish then skip-if-exists; both workflows valid YAML.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-20 12:47:38 +02:00
Gergő Törcsvári
55f8d79a78
feat(deploy): publish-libs (C1.2) — full KiCad set as r2-idb-sync static origins
extract-libs.ts gains extractAllLibs(): enumerate EVERY <Lib>.kicad_symdir / <Lib>.pretty under the source dirs into in-memory self-contained bodies (reuses the curated path's parse + extends resolution). At KiCad 10.0.x symbols already ship the one-symbol-per-file .kicad_symdir layout, so no split needed.

publish-libs.ts (tsx): per lib, build a SyncManifest (sha256 per item) + encodeBundle, write libs/kicad/<libTag>/<lib>/{manifest,bundle} (immutable) + a top manifest.json listing every lib. Keyed by upstream KiCad lib tag, skip-if-exists (HEAD the top manifest; --force overrides) so it is decoupled from the app deploy. Local + r2 drivers via cdn-store.

Validated over web/backend/.cache: 8 libs / 2154 items; Device bundle decodes to 537 bodies, its /manifest matches the bundle, and symbol/R body hash matches its manifest entry (warm-sync diff stays empty). Same wire format cdn-source.test reads, so publish and client are pinned to one format.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-20 11:04:49 +02:00
Gergő Törcsvári
307a66dd77
feat(standalone): cdn libs source (C1.1) — full KiCad set from R2 static origins
Backendless, read-only LibsSource that serves the full default symbol+footprint set from versioned immutable CDN snapshots. Each lib is an r2-idb-sync static origin opened as a one-layer SyncStack (1 bundle cold, 0 fetches warm, IDB-cached, offline) — the layer descriptor is built locally from lib id + tag, no resolve endpoint in the loop.

Wired via VITE_LIBS_SOURCE=cdn + VITE_LIBS_MANIFEST_URL; build-demo gains --lib-tag (points the demo at libs/kicad/<tag>/manifest.json; omitted keeps offline static). Unit-tested against a fake CDN built with the real encodeBundle/sha256Hex codecs, pinning the publish format.

Next: publish-libs.mjs (C1.2) emits this format over the full set; CI keyed by lib tag (C1.3).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-20 10:30:18 +02:00
Gergő Törcsvári
142e2d4e5e
feat(standalone): project-centric new-file flow + fork gallery; clean idb key-sep source
Mirrors the closed app: create a templated file then open it, so you always edit a real file that saves back.

- lib/new-file.ts: minimal valid KiCad templates (pcbnew/eeschema/pl_editor, from the e2e fixtures) + document-tool helpers.

- NewFileDialog: in-project mode (file name) and home mode (pick/create a browser-local project + file name); writes via the active source uploadFileBytes (local IDB or remote-rw backend), then opens by path.

- HomePage: a document tool from the grid (local store on) opens the dialog instead of booting a throwaway blank doc.

- ProjectView: project-centric New-file row (writable projects) + Save-a-copy-to-browser fork for read-only gallery projects (copies into editable IDB), alongside files/export.

Also replaces a stray NUL byte that had been written into idb-project-store.ts in place of a space (made the file parse as binary) with an explicit unicode escape for the key separator (NUL, sorts below every slug char so project key ranges cannot collide) and the range upper bound. Runtime behavior unchanged.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-20 10:02:36 +02:00
Gergő Törcsvári
4839a9d73a
polish(standalone): unify home Projects list + solid source chips
Home page feedback: merge "Your projects" (local) and the gallery/backend list
into one "Projects" section where each ROW carries its own source chip (instead
of a per-section header chip). Sections are now Open → Projects → Tools →
Libraries. Local rows keep open/export/rename/delete; remote rows just open.
LocalProjectsSection → ProjectsSection.

Source chips were too pale on the editor canvas — switch from translucent pastel
to solid fills with white text + an inset ring, so they read on any backdrop
(home, dark boot screen, light editor canvas).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-20 08:53:16 +02:00
Gergő Törcsvári
ce9ede1e9e
feat(standalone): browser-local (IndexedDB) virtual projects
Loading a folder now imports a COPY into a browser-local IndexedDB project with
its own /p/:slug URL (original disk files untouched): edits persist to IDB across
visits, and the project exports via Download .zip or per-file. Gated by
VITE_LOCAL_PROJECTS=idb (on for the demo; off keeps the File System Access
write-back flow), so it's configurable per deployment.

Modular, swappable project sources behind the shared ProjectSource interface,
each self-describing via a SourceDescriptor whose kind is shown verbatim in the
UI — "Local (this browser)", "Remote · read-only", "Remote · editable" — on the
home page, the project view, and inside the editor, so the user always knows
whether/how Save persists:
  - remote      → REST backend (remote-rw)
  - static      → CDN gallery (remote-ro), saves download
  - local (new) → idbProjectStore, writable IDB store
A composite layers the local store over the configured remote/gallery source,
routing per slug so imported/saved projects and the gallery share one namespace.

New, dependency-free (matching sync-client's raw-IDB ethos):
  - lib/idb-project-store.ts  raw IndexedDB store + create/delete/rename/export
  - lib/zip.ts                store-only ZIP writer (verified via system unzip)
  - lib/import-folder.ts      FSA/webkitdirectory folder → in-memory bytes
  - lib/project-source-shared.ts  source descriptors + deterministic uuid
  - components/SourceChip, components/LocalProjectsSection
Home lists local projects (open/export/rename/delete). Verified: typecheck,
project-source tests, prod build, and IDB key-range project isolation in-browser
(prefix-colliding slugs don't leak).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-20 08:24:14 +02:00
Gergő Törcsvári
0f53984407
feat(standalone): bottom-right version + source badge
A small fixed bottom-right overlay (VersionBadge) shown app-wide — on the home
page AND inside the loaded editor — surfacing this build's release tag and a
link to the source. The tag links to the exact commit when known (the pcbjam
commit pins the kicad + wxwidgets submodule revisions → our GPLv3
corresponding-source pointer, mirroring site Footer's BUILD_SHA), else the tag's
release page, else the repo root.

build-demo.mjs injects VITE_APP_TAG / VITE_GIT_SHA / VITE_REPO_URL (new --repo
flag, defaults to github.com/emergence-engineering/pcbjam).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-20 08:01:50 +02:00
Gergő Törcsvári
e94f5b31be ci: cache KiCad WASM build output to skip Docker on unchanged sources
Add an output-cache layer to ci-ubicloud.yml so a build whose inputs are
unchanged (typical when only tests/ or web/ change) skips the in-Docker
compile + the 1-2h host asyncify/wasm-opt chain — the bulk of the ~1h52m
run. On a hit, output/ and the GAL sysroot headers are restored from cache
and the deps restore/seed, build.sh, and sysroot export are all gated on a
miss, so Docker is never started.

Key: kwasm-<os>-bin<ver><opt>-k<kicad-sha>-wx<wx-sha>-sc<hash>-e<epoch>.
The "sc" hash (scripts/deploy/wasm-cache-hash.mjs) folds in just the
build-logic files that shape the wasm bytes (host post-processing,
per-tool compile recipes, scripts/deps, docker/Dockerfile+build.sh) plus
itself; it is content-based, order-independent, and identical on macOS/CI.
*.wasm.debug.wasm (5+ GB, unused by tests) is excluded -> ~0.5 GB entry on
Ubicloud's transparent 30 GB/repo/week cache.

Invalidation:
- bump .ci-cache-epoch in a commit for durable busts (inputs the sc-hash
  can't see: base-image/apt drift, a bad cache);
- [no-cache] or [rebuild-wasm] in the commit message / PR title, or
  workflow_dispatch no_cache=true, for a one-off rebuild (split
  restore/save so the bypass still refreshes the entry).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-19 14:51:33 +02:00
Istvan Matejcsok
4c199dff9f fix: 🐛 tooltip + test cases
 Closes: #18, #16
2026-06-19 14:32:09 +02:00
Gergő Törcsvári
8069688b52
fix(demo): resolve tag from input first (workflow_dispatch ref_name is the branch)
GITHUB_REF_NAME is 'main' on workflow_dispatch, so the old ${REF:-input} order
labeled every dispatched deploy 'main'. Prefer github.event.inputs.tag.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-19 13:45:41 +02:00
Gergő Törcsvári
f3683bda39
ci(demo): auto-create Pages project on first deploy (idempotent)
Project not found errors when pcbjam-demo doesn't exist yet; create it (with the
production branch matching --branch) before deploying so the pipeline is
self-contained.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-19 13:37:43 +02:00
Gergő Törcsvári
4261d90683
ci(demo): pin pnpm 10.33.0 in deploy-demo
The repo root has no package.json, so pnpm/action-setup can't infer the version
(it lives in web/package.json). Pin it explicitly.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-19 13:34:28 +02:00
Gergő Törcsvári
5248f3a464
fix(demo): default WRANGLER_CMD to npx + silence expected R2 not-found probes
The publish scripts shelled bare `wrangler` (ENOENT without a global install)
and the existence probes (registry.json / per-tool meta.json) printed wrangler's
'key does not exist' on a fresh bucket. Default to `npx wrangler@4` and capture
stderr on probes.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-19 13:31:06 +02:00
Istvan Matejcsok
e8cef07f7f ci: 🎡 add 3d viewer on 2026-06-19 12:14:52 +02:00
Gergő Törcsvári
5aae2a0d16
feat(demo): demo.pcbjam.com deploy — versioned WASM CDN + static gallery + tag CI
Cross-origin WASM CDN (cdn.pcbjam.com, R2): per-tool content-addressed,
immutable folders + a per-release runtime manifest (snapshot from registry).
boot.ts loads pthread workers cross-origin via a same-origin blob shim.
Static no-backend project source (demo gallery; Save downloads to local),
api.uploadFileBytes kept and config-gated. demo.pcbjam.com on Cloudflare Pages.
deploy-demo.yml (tag v*) snapshots WASM + content + builds + deploys;
publish-wasm.yml builds on Ubicloud. Design/spec docs live in pcbjam-private.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-19 11:39:09 +02:00
Istvan Matejcsok
5ff9f1c7b8 test: 💍 fix raytracer test cases 2026-06-19 10:43:35 +02:00
Istvan Matejcsok
5c6e426b00 fix: 🐛 hide print preview 2026-06-19 10:25:14 +02:00
Istvan Matejcsok
5d18bd0c45 test: 💍 deadlock test + readme update 2026-06-19 09:22:58 +02:00
Istvan Matejcsok
1b1e7884ee test: 💍 wxWidgets secondary canvas 2026-06-19 09:22:58 +02:00
Istvan Matejcsok
77a04821ef test: 💍 multithread nested asyncify 2026-06-19 09:22:56 +02:00
Istvan Matejcsok
0195ff0941 feat: enable WASM 3D viewer build — FFP link stubs, drop glemu shim
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-19 09:21:37 +02:00
Istvan Matejcsok
68c711e633 feat: enable the 3D viewer in the WASM port (WIP)
Builds KiCad's 3D viewer for the browser (opt in with BUILD_3D_VIEWER=ON) and
wires up the legacy-GL emulation it needs.

- build-kicad-target.sh / docker/build.sh: BUILD_3D_VIEWER →
  -DKICAD_BUILD_3D_VIEWER_WASM=ON + -sLEGACY_GL_EMULATION + the GL js-library.
- wasm/shims/gl_immediate_shim.js: display-list emulation (record/replay board
  layers), fixed-function + GLU stubs, throw-guards for unsupported pnames, and
  per-context GLImmediate init for the viewer's SECOND WebGL context.
- tests/kicad/3d-viewer.spec.ts + utils/pcbnew-ready.ts: open View → 3D Viewer.
- bumps the kicad submodule (EMSCRIPTEN-guarded GL changes).

WIP: the viewer window + UI render and geometry draws (glError=0x0), but the
board is not yet visibly rendered — GLImmediate's FFP shader program isn't
linked on the viewer's 2nd WebGL context. Full status + next steps in
features/feat/add-3d-view/notes.md.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-19 09:13:41 +02:00
Viktor Vaczi
61760ea155 Updated vercel.json blog url. 2026-06-18 15:46:08 +02:00
Viktor Vaczi
91cb62ffc1 Rename blogpost. 2026-06-18 15:29:07 +02:00
Viktor Vaczi
429ac206f9 fix: 🐛 Gerber demo: survive a stale cross-origin-isolation state
The demo showed "Live demo unavailable in this browser" on fully capable
browsers (e.g. Chrome) whenever a page load wasn't cross-origin isolated —
a soft SPA navigation, or a visit cached from before the COOP/COEP headers
went live. The old reload guard used a sticky sessionStorage flag that, once
set during a non-isolated load, never cleared, so it skipped the recovery
reload and showed a misleading "unsupported browser" message.

- Reload guard now uses a timestamp, not a sticky flag: a stale flag from an
  earlier visit no longer permanently strands the demo (reload loop still
  prevented within a 10s debounce).
- Non-isolated pages now open the standalone viewer (/gerber-demo/, isolated
  on its own and always works) in a new tab instead of dead-ending.
- The "needs a recent browser" note only shows when provably incapable
  (isolated but missing SharedArrayBuffer/WebGL2).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-18 14:33:55 +02:00
Viktor Vaczi
8b438b48b2 feat: WebGL graphics blog post, Gerber demo on landing page, open-source license notices
- Blog: porting-kicad-graphics-to-webgl post + GAL native/WebGL comparison images and <GalCompare>
- Landing page: embed lazily-loaded Gerber demo section + footer "Live demo" link
- Licensing: /licenses page (GPLv3 + wxWindows/LGPL-v2 breakdown, ahilss credit, corresponding-source offer) and a footer build-SHA link
- Docs: CLAUDE.md + README note to bump the hardcoded footer BUILD_SHA on each release

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-18 14:06:37 +02:00
Gergő Törcsvári
698f6d7cb7
feat(libs): standalone .lib→.kicad_sym wasm converter (sym_convert)
Headless node-WASM CLI that converts legacy symbol libraries to .kicad_sym via
SCH_IO_MGR::ConvertLibrary. Adds wasm/cli/sym_convert_main.cpp + sym_convert_pre.js
(in-memory localStorage + wxConfig JS-hook shim), registers sym_convert as a
docker/build.sh app (own kicad-sym_convert tree, real wasm-opt/finalize in-container,
skip host postprocess), and bumps the kicad pointer for the matching target.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-18 12:21:15 +02:00
Gergő Törcsvári
b1320afab9
feat(eeschema): hierarchical subschema collaboration — per-sheet rooms, lazy seed, save flow, embind + e2e
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-17 17:55:30 +02:00
Viktor Vaczi
695a46015c Updated cleanup docs. 2026-06-17 17:42:40 +02:00
Istvan Matejcsok
5f02608a91 fix: 🐛 wxWidgets text ellipsis 2026-06-17 14:26:03 +02:00