Commit graph pcb-retrace/docs/studio.js
Author SHA1 Message Date
Stuart
8bf5fd3a9a CMMS fork: embedding hooks (window.PCBRETRACE_CONFIG)
New docs/cmms-bridge.js — inert unless window.PCBRETRACE_CONFIG is present
(only public/vendor/pcb-retrace/edit.php in the CMMS sets it). When set:
- injects "Save" / "Save & close" into the top bar; hides the standalone
  import/export/share buttons.
- on boot, if config.loadUrl is set, pulls the project .pcbretrace.zip
  from the CMMS and restores it silently (reuses processUrlImport).
- Save builds the whole-device ZIP in memory and POSTs it multipart to
  the CMMS attachment endpoint (action/csrf/job_id/id/original_name/file,
  same contract as circuit-edit.php); first save of a new board switches
  to in-place updates.

studio.js:
- exportDeviceZIP() split into buildDeviceZIP(pass, forCmms) -> {blob,
  filename} + a thin exportDeviceZIP() wrapper. forCmms adjusts the
  embedded README + manifest.source.
- importFile/processZIP/processUrlImport take an opts arg; opts.silent
  skips the restore/import confirms and re-throws instead of alert().
- init() awaits window.CMMS.init() at the end when present.

studio.html: loads cmms-bridge.js (defer, after studio.js).

Standalone pcb.etaras.com / local use is unchanged — every new path is
gated on the config object or opts.silent, both absent by default.
Dark mode: config.dark is recorded as data-theme="dark" but studio.html
is light-only today; CMMS-theme-follow is a later task.
2026-09-03 14:16:42 +10:00
Taras Greben
ff4ac844d0 Navigation (history) from modal boxes fixed. 2026-07-10 13:45:28 +03:00
Taras Greben
114c983b08 Fixed the sticky node name validator issue, where a validator used once was incorrectly reused for all input text dialogs. Added a new feature: the Inspector view now shows calculated routes for nets, including inactive ones. 2026-07-01 17:38:52 +03:00
Taras Greben
f3bb3b4408 make sure await is prior to .length 2026-06-26 14:53:45 +03:00
dev-lab
55236223f8 chore: automatically enrich source files with copyright headers 2026-05-23 09:09:46 +00:00
Taras Greben
0a0f9ff9fd AES-256 encryption option for project files, progress on importing KiCad symbols 2026-05-23 11:18:19 +03:00
dev-lab
995a5d178c chore: automatically enrich source files with copyright headers 2026-05-07 14:47:37 +00:00
Taras Greben
df5607bfa8 Nets validator added. 2026-04-27 18:02:04 +03:00
Taras Greben
d7b4a6c499 Schema ReTrace added (create schematic diagrams from netlists). 2026-04-24 17:28:59 +03:00
Taras Greben
8266a8e81f Major upgrate to Inspector/Netlist workflow: the tool now intelligently suggests node names if components defined, also added collapsible cheat sheet for pins numbering 2025-12-26 14:55:08 +02:00
Taras Greben
d69d18d797 Manual stitching default point locations fixed in Flip Target mode 2025-12-22 18:45:13 +02:00
Taras Greben
0022cb6a3a Inspector layout improved, Deep Linking implemented 2025-12-22 16:56:46 +02:00
Taras Greben
ca9fe52db5 Fixed manual image stitching and Inspector view for mobiles, other minor fixes/improvements. 2025-12-21 18:45:40 +02:00
Taras Greben
f06b8a68b8 PCB ReTrace initial 2025-12-21 00:31:26 +02:00