blocky-writer is a Mozilla Firefox extension for block-based PDF
form filling.
Extension UI: AffineScript + React
Background/content scripts: AffineScript
Core processing: Rust compiled to WebAssembly (WASM)
Local storage: IndexedDB
src/— AffineScript sources for popup UI, background script, content script, and core modulespublic/— static extension files (manifest.json, popup HTML, icons)rust/pdftool_core/— Rust WASM crate for block detection and PDF operationsscripts/— build helpers for WASM and extension bundles
Install dependencies (Deno-first):
deno install
Build AffineScript output and bundle extension assets:
deno task build
Build the Rust WASM package:
deno task build:wasm
Run the extension in Firefox via
web-ext:deno task dev
Run core fill fixture tests (error taxonomy + AcroForm writeback):
deno task test:core-fill
Rust
fill_blocksnow performs AcroForm-aware writeback for text/select and button widgets, and emits structured taxonomy errors (code,message,context).Popup/background/content surfaces preserve taxonomy codes from the Rust WASM boundary.
Source files include SPDX headers targeting MPL-2.0.
If
denotaskdevfails withECONNREFUSED127.0.0.1:<port>, verify Firefox is installed and runnable.Close stale Firefox instances launched by prior
web-extsessions, then retrydenotaskdev.You can run
web-extdirectly with an explicit binary when needed:deno run -A npm:web-ext run --source-dir dist --firefox /usr/bin/firefox
See TOPOLOGY for a visual architecture map and completion dashboard.
Wondering how this works? See EXPLAINME.adoc.