Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
629620e
refactor(theme): make themes.ts the one source for dark and light themes
nodemode-ai Nov 27, 2026
de249a1
feat(theme): port every form.md and formportal theme as token sets
nodemode-ai Nov 27, 2026
ef4f1fb
fix(review): float the notice so the lists have no blank row
nodemode-ai Nov 27, 2026
9e41260
fix(connections): match the library empty state in the lists
nodemode-ai Nov 27, 2026
037f39d
feat(side): live dot and version in the sidebar head
nodemode-ai Nov 27, 2026
517ca32
feat(preferences): show dark and light theme grids with swatches
nodemode-ai Nov 27, 2026
e099f6d
docs(cite-service): record the real paired run and the host error map…
nodemode-ai Nov 27, 2026
fbe38c0
docs(hashout): log the real paired cite service run
nodemode-ai Nov 27, 2026
99e27e1
docs(hashout): log the light review of duplicates, trash and connections
nodemode-ai Nov 27, 2026
95ae447
feat(splash): family splash with the formcite icon and the saved theme
nodemode-ai Nov 27, 2026
8348e79
fix(shell): build the main window on the splash's light or dark ground
nodemode-ai Nov 27, 2026
d0cd2cb
docs(hashout): log the ported themes and the old value move
nodemode-ai Nov 27, 2026
b6c8107
feat(detail): wrap a long title in a textarea that grows with its text
nodemode-ai Nov 27, 2026
6b4ccdc
docs(hashout): log the live dot, the splash and the shared ground
nodemode-ai Nov 27, 2026
eec4d8f
feat(add): shape the add dialog as head, body and foot with the prima…
nodemode-ai Nov 27, 2026
5e3ebad
feat(shell): open the new splash page in the desktop shell
nodemode-ai Nov 27, 2026
6ea4610
refactor(side): give the sidebar head its third column in the shell s…
nodemode-ai Nov 27, 2026
19a0cb6
docs(hashout): say one data folder was shared across the two runs
nodemode-ai Nov 27, 2026
4caf1cf
docs(log): add the title wrap and add dialog frame entry
nodemode-ai Nov 27, 2026
f4eb879
docs(notice): credit the themes, the dot, the splash and the dialog s…
nodemode-ai Nov 27, 2026
273aae3
chore(release): 0.12.0
nodemode-ai Nov 27, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,35 @@
# Changelog

## 0.12.0

FormCite gets the Form family's themes, a reshaped Add dialog, a live dot in the sidebar head and a new splash page.

### New
- **Themes:** every theme from form.md and FormPortal. Preferences keeps System, Light and Dark and adds a grid of 15 dark themes (Default, Studio, Night, Graphite, Midnight, Forest, Ember, Violet, Slate, Mono, Ocean, Rose, Terminal, AMOLED, High contrast) and 6 light themes (Default, Paper, Sand, Sage, Mist, High contrast). The theme is set before the first paint.
- **The sidebar head** shows a dot for the engine (live, reconnecting, down) and the version.
- **A splash page** with FormCite's own icon, in dark and light, for the desktop app.

### Improved
- **The Add dialog** has the family's shape: a head, tabs, a body of fixed height and a foot with the main button at the end. Escape closes it from anywhere and focus returns to the Add button.
- **A long title wraps** in the details pane and no longer runs off its row.
- **Duplicates, Trash and Connections** show their empty and error notes the way the library does, with no blank band above the first row.

### Changed
- A theme saved by an older version is moved to the matching new one on first load. The old light value that showed as dark now opens as Light with Mist.
- Enter and Shift+Enter both save a title.

### Fixed
- On Linux and Windows the desktop window's own background follows the light or dark setting, so a light page no longer sits on a dark frame. Written and read against FormLedger's shell, not compiled for this version.

### Known issues
- In the desktop app the splash follows the system's light or dark setting, not a named theme.
- Merging a duplicate set or restoring from Trash moves the rows below up to close the gap.
- Choosing an item with a much longer or shorter title moves the fields below the title by the difference in the title's height.

### Under the hood
- `docs/CITE_SERVICE.md` records a run of the cite service against a real engine: a stand-in client paired, a person's approval was clicked in Connections, and search, get, cite, bibliography, add and import answered; all six were refused before approval and after access was removed. The caller was not form.ext's hello example.
- Not run for this version: the desktop shell was not compiled, and nothing ran on macOS or Windows.

## 0.11.0

### New
Expand Down
3 changes: 3 additions & 0 deletions NOTICE.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ A file brought over from another Form repository gets a row here with its source
| formvfx v0.60.0 (`nodemode-dev/formvfx`) | Apache-2.0 | The way a Rust crate is built into a Python module (`native/fvx-core` and `setup/build_native`), followed in `native/formcite-style` and `setup/build_style`; rewritten, not copied |
| formtxt v0.38.0 (`nodemode-dev/formtxt`), since 0.6.0 | Apache-2.0 | `setup/agents.py`: the install half of FormTxt's `setup/agents.py` (the four agent clients, each config file's format, the timestamped backup, the skill copy), rewritten from it with the sync, manifest and dock parts left out. `backend/app/mcp/stdio.py`: the shape of FormTxt's `setup/mcp_stdio.py` (one JSON-RPC message a line, logs on stderr, the parse error), with the library opened in-process instead of forwarding to a running engine |
| form.md (`nodemode-dev/form.md`) at its `main` of 2026-11-27, since 0.11.0 | Apache-2.0 | The pre-paint theme script in `frontend/index.html`, adapted to FormCite's stored key |
| form.md (`nodemode-dev/form.md`) at its `main` of 2026-11-27, since 0.12.0 | Apache-2.0 | The theme values in `frontend/src/styles/themes.css` and the theme picker's shape in `frontend/src/ui/themes.ts` and `ui/preferences.ts`, from `web/src/ui/theme/tokens.css`, `web/src/ui/theme.ts` and `web/src/ui/preferences.ts`. The live dot and version in the sidebar head, from `web/index.html`, `web/src/styles/pages.css` and `web/src/ui/status.ts`. The splash card in `frontend/public/splash/index.html`, from `src-tauri/splash/index.html`. The Add dialog's structure, after the patterns in `web/src/styles/overlays.css`, `web/src/styles/panels.css` and `web/src/ui/dialog.ts` |
| FormPortal (`nodemode-dev/formportal`) at its `main` of 2026-11-27, since 0.12.0 | See that repository's `LICENSE`; same owner | Theme values in `frontend/src/styles/themes.css`, from `design/tokens.css` and `frontend/src/extensions/theme/index.ts` |
| FormLedger v0.11.0 (`nodemode-dev/formledger`), since 0.12.0 | Apache-2.0 | The splash card's shape, from `src-tauri/splash/index.html`, and the shape of `src-tauri/src/reveal.rs` |
| FormLedger v0.10.0 (`nodemode-dev/formledger`), since 0.11.0 | Apache-2.0 | The token names and values for the dark and light themes in `frontend/src/styles/tokens.css` |
| formcompiler and formslot (`nodemode-dev/formcompiler`, `nodemode-dev/formslot`) at their `main` of 2026-11-27, since 0.11.0 | GPL-3.0-only | Patterns, adapted and not copied: the registry entry shape of `apps/formrig.json` behind `packaging/formcompiler/apps/formcite.json`, the five build runners in the `style` CI job, and the prebuilt-before-source order of formslot's installer in `setup/build_style` |

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
</p>

<p align="center">
<img alt="version 0.11.0" src="https://img.shields.io/badge/version-0.11.0-eef0f4?style=flat-square">
<img alt="version 0.12.0" src="https://img.shields.io/badge/version-0.12.0-eef0f4?style=flat-square">
<img alt="Python 3.12 or later" src="https://img.shields.io/badge/Python-3.12%2B-3776ab?style=flat-square&logo=python&logoColor=white">
<img alt="License: GPL-3.0-only" src="https://img.shields.io/badge/license-GPL--3.0--only-3a3a3a?style=flat-square">
<img alt="Status: early" src="https://img.shields.io/badge/status-early-d69e2e?style=flat-square">
Expand Down
6 changes: 5 additions & 1 deletion backend/HASHOUT_LOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Living log of all comment content, explainers, rationale, TODOs, & removed (hashed-out) code for this side of the repo. Source files stay comment-free per dev-rules `sub-skills/hashout-log/SUB-SKILL.md`; everything they would have said lives here, indexed. This file is also the compressed contextual map of this side: read it first, then edit code surgically.

Current build version: v0.11.0
Current build version: v0.12.0
Last updated: 2026-11-27 (US Eastern) · the lean rows route for the window's list and opening an attachment

---
Expand Down Expand Up @@ -1681,3 +1681,7 @@ New in v0.10.0 (2026-11-27). "Untitled" is a live item whose `title`, trimmed of
## app/services/opener.py {#app-open-in-formpdf}

Opening a stored PDF attachment now hands it to FormPDF by launching the install with the file path as its argument, an argv list and never a shell string. FormPDF 0.61 supports exactly this: its desktop shell reads `.pdf` paths from its command line (`src-tauri/src/main.rs` `from_args`), forwards the arguments of a second launch to the running window through the single-instance plugin, and on macOS receives them from `open -a` as `RunEvent::Opened`. Its HTTP `open-path` route is not used: `WindowKeyGuard` refuses every write without the window key, which is why FormTxt's hand-off to port 8198 gets a 403. The launch waits two seconds; an exit with a non-zero code, or a launch that fails, falls back to the system viewer and says why in `formpdf.reason`. Only copied or moved PDFs go: a linked file lives outside the library and a non-PDF is not something FormPDF opens, so both use the system viewer with a reason. `opened_with` is now `formpdf` or `system`. Run with stand-in scripts for FormPDF (one logging its argument, one exiting 3): the PDF reached the logging script as the stored path, the other cases fell back with the right reason. Not run: a real FormPDF, macOS `open -a`, Windows.

## app/routers/pair.py, app/routers/service.py, app/routers/cite_read.py, app/routers/cite_write.py, app/service/ {#app-cite-service-real-run}

Run in v0.12.0 work (2026-11-27), no code changed. A stand-in Python client asked to pair with scope `write`, a click on Approve in the Connections view in headless Chrome approved it, the client collected the token and ran search, get, cite (apa), bibliography (ieee), add and import against a 2,000-item library: 200, 200, 200, 200, 201, 201. Before approval every call was 403 (`none was sent` without a token, `not known` with a made-up one); after Remove access, 403 `was revoked`. Writes by a revoked token are refused in `auth.check` before `_write`, so they are not in `service-log.jsonl`; that matches the rule that a refusal without a valid holder is not logged. An unknown route under `/api/cite/v1` answers Starlette's 404 `Not Found` to GET and 405 to POST; the 405 is a route outside this slice matching the path for GET only. FormCite answers no JSON-RPC codes; -32001 and -32601 belong to the host that wraps these calls. One data folder was shared across the two runs, so the first click on Remove access in the first run hit the older token row; the revoke result above is from a second run aimed at the live token's row by `data-key`.
2 changes: 1 addition & 1 deletion backend/app/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.11.0"
__version__ = "0.12.0"
17 changes: 17 additions & 0 deletions docs/CITE_SERVICE.md
Original file line number Diff line number Diff line change
Expand Up @@ -291,3 +291,20 @@ Every write by a token holder is recorded, whether it succeeded or was refused,
```

The JSON on stdout is `{"file", "entries": [{"time", "host", "name", "token_id", "route", "created", "changed", "outcome", "error"}]}`.

## What a host maps, and what FormCite itself answers

The cite service speaks plain HTTP with JSON bodies, not JSON-RPC. A host that offers its add-ons a JSON-RPC call into FormCite (form.ext's `fcite.call`) turns these answers into its own error codes: a refusal (403) into its "denied" code, and a method the host does not know into -32601. FormCite never answers a JSON-RPC code. For a route it does not have it answers Starlette's own 404 `{"detail":"Not Found"}` to a `GET` and 405 `{"detail":"Method Not Allowed"}` to a `POST`, with or without a token.

The consent sentence the owner approved for form.ext's `fcite.addon` permission is "Let {Name} search, cite and add to your FormCite library?". That sentence is the host's own prompt. FormCite's approval is a second, separate consent in its Connections view, which shows the request as "Asks to read and add to your library" with Approve, Approve reading only and Deny.

## Run against a real engine (2026-11-27)

Run once end to end on FormCite 0.11.0 (branch `feat/themes-polish-pairing-0.12.0`): a built window served by the engine on port 8515 with its own data folder, 2,000 BibTeX items imported, style engine hayagriva 0.10.1. The caller was a stand-in client, a Python script making the same loopback HTTP calls a host makes; it was not form.ext's hello example, because form.ext's `fcite.call` is not on form.ext's main. The approval and the revoke were clicks in the window in headless Chrome.

- Before pairing, no token: search, get, cite, bibliography, add and import each answered 403 `This needs a FormCite service token, and none was sent.`
- `POST /pair` `{"host":"standin","name":"Stand-in Host","scope":"write"}` answered 200 with a request id and secret; a poll answered `"status":"pending"`. While pending, a made-up token got 403 `This service token is not known to FormCite.` on all six.
- After the click on Approve, the next poll answered `"status":"approved"` with the token, scope `write`.
- With the token: `GET /search?q=consequences&limit=2` 200, total 2000, two items; `GET /items/{id}` 200; `POST /cite` apa 200, `(Author0 & Writer0, 1980; Author1 & Writer1, 1981)`; `POST /bibliography` ieee 200, two entries; `POST /items` 201, a new book; `POST /import` 201, one added (a second run of the same text skipped it as a duplicate). The four writes are in the write log under the token's holder.
- After the click on Remove access, then Remove: all six answered 403 `This service token was revoked by the person who uses FormCite.`
- Layout shift at CPU 4x and 400 ms, 50,000 bytes per second: 0 for opening Connections with the request waiting and 0 for the approval, with and without input.
Loading
Loading