Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
12 changes: 12 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
# Changelog

## v0.13.0 · 2026-11-30

The menus in the window fit the window and say when there is more below.

- **Fixed:** on Windows, Linux and in the browser demo, a menu in the window's menu bar had no height limit, so in a short window its last items ran off the bottom of the window and could not be reached. A menu is now at most three quarters of the window tall, never reaches past its bottom edge, and scrolls the rest. It still opens just under its name in the bar.
- **New:** a menu that is cut off fades out its last rows and shows a small pill with a down arrow at its bottom while items remain below. Both go away at the last item and come back when you scroll up. A menu that fits shows nothing, and with reduced motion turned on the hint appears and goes without a fade.
- **Changed:** an open menu now closes when the window is resized, as it already did when the window lost focus.
- The macOS menu bar, which is the system's, is unchanged. form.ext has no right-click menus, so nothing else changed.
- **The browser demo** in `demo/` is rebuilt and says 0.13.0.
- Checked here, on Linux, in the rebuilt browser demo in headless Chrome with the CPU slowed 4 times: every menu at 1280 by 800, 1000 by 480 and 800 by 320 opened 2 px under its name, inside the window and within three quarters of its height; at 800 by 320, File and Project were cut to 240 px and showed the hint, which was gone at their last item. The interface tests (268) and the frontend build passed.
- Not run for this version: the engine tests, the desktop shell, anything on macOS or Windows, the hint's fade timings, keyboard use and the 1871 by 1080 and 1280 by 720 sizes.

## v0.12.2 · 2026-11-29

The engine tests pass again. Nothing a person uses changed.
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
</p>

<p align="center">
<img alt="version 0.12.2" src="https://img.shields.io/badge/version-0.12.2-4f6bff?style=flat-square">
<img alt="version 0.13.0" src="https://img.shields.io/badge/version-0.13.0-4f6bff?style=flat-square">
<img alt="Python FastAPI engine" src="https://img.shields.io/badge/Python-FastAPI%20engine-3776ab?style=flat-square&logo=python&logoColor=white">
<img alt="TypeScript" src="https://img.shields.io/badge/TypeScript-interface-3178c6?style=flat-square">
<img alt="Tauri 2" src="https://img.shields.io/badge/Tauri-2-24C8DB?style=flat-square">
Expand Down
2 changes: 1 addition & 1 deletion backend/app/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.12.2"
__version__ = "0.13.0"
4 changes: 2 additions & 2 deletions demo/HASHOUT_LOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

Living log of the offline browser demo. Source files stay comment-free; what they would have said lives here.

Current build version: v0.10.0
Last updated: 2026-11-20 · v0.10.0 rebuilt from the tip with the repository's own build (README "Rebuild"): it carries everything since v0.4.1 and the version 0.10.0, and the page no longer asks for a window key. Before: v0.4.1 rebuilt: `engine/kit.ts` refuses an `entry.ui` whose last segment is empty or `.` (`ui/index.html/`, `ui/index.html/.`), and its `problems` refuses a backslash, as the kit's `formpkg.py` and `formext_host.py` now do. Before: v0.4.0 rebuilt: the Publish pane's Open pull request answers that it needs form.ext on the computer, the Studio's source row reads "Source: desktop app" (the sources routes are not ported), and starter READMEs carry Permissions and Screenshot as the engine's do. Before: v0.3.1 the version only (the bundle's two version strings edited by hand). Before: v0.3.0 the page engine moved to frontend/src/demo and the app opens this demo in its window. Before: v0.2.1 the version only
Current build version: v0.13.0
Last updated: 2026-11-30 · v0.13.0 rebuilt with the repository's own build (README "Rebuild"): the in-window menus take the three-quarter cap and the more-below hint (`frontend/HASHOUT_LOG.md#menu-cap`, `#menu-more`), and the page says 0.13.0. Before: v0.10.0 rebuilt from the tip with the repository's own build (README "Rebuild"): it carries everything since v0.4.1 and the version 0.10.0, and the page no longer asks for a window key. Before: v0.4.1 rebuilt: `engine/kit.ts` refuses an `entry.ui` whose last segment is empty or `.` (`ui/index.html/`, `ui/index.html/.`), and its `problems` refuses a backslash, as the kit's `formpkg.py` and `formext_host.py` now do. Before: v0.4.0 rebuilt: the Publish pane's Open pull request answers that it needs form.ext on the computer, the Studio's source row reads "Source: desktop app" (the sources routes are not ported), and starter READMEs carry Permissions and Screenshot as the engine's do. Before: v0.3.1 the version only (the bundle's two version strings edited by hand). Before: v0.3.0 the page engine moved to frontend/src/demo and the app opens this demo in its window. Before: v0.2.1 the version only

---

Expand Down
2 changes: 1 addition & 1 deletion demo/assets/formext.css

Large diffs are not rendered by default.

206 changes: 106 additions & 100 deletions demo/assets/formext.js

Large diffs are not rendered by default.

41 changes: 41 additions & 0 deletions frontend/HASHOUT_LOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -242,3 +242,44 @@ Checked in headless Chrome (1440 by 900, 4x CPU throttle, cache off) against Vit
- logged: unreleased

Preferences has an About section with one group, Licences and notices: a note that form.ext is GPL-3.0-only while the contract kit, the SDK and the starters are Apache-2.0, and a closed `details` row, Third-party notices, whose `pre` is in its final box from the first paint. Opening it the first time asks `GET /api/notices` (plain text) once and fills the `pre` in place; a failure names `THIRD-PARTY-NOTICES.txt` beside the app and the next open asks again. Closed, it asks nothing. The About dialog and the native About item now say GPL-3.0-only, as `LICENSE` and `tauri.conf.json` do; before they said Apache-2.0.

## In-window menus keep under the bar and take a cap {#menu-cap}

- refers-to: src/shell/menubar.ts :: menuCap, mountMenubar > open · src/styles/settings.css :: .fx-menu
- kind: removed-code
- logged: v0.13.0 · 2026-11-30

FORM-MENU-OVERLAP-FIX 1.2.0, group C. The in-window menus already opened at the button's bottom edge plus 2 px and never moved up, but `.fx-menu` had no height limit, so a menu longer than the room under the bar ran off the bottom of the window. `open()` now sets an inline `max-height` of `menuCap(top)`, the smaller of three quarters of the window and the room down to 4 px above its bottom, while the card is `visibility: hidden`, before it shows; the rest scrolls. The top stays the button's bottom plus 2 px. The menu closes on `resize` as it does on `blur`, so the cap never goes stale. The macOS system menu (`native-menu.ts`) is untouched.

Removed from `open()`:

```ts
pop.style.left = `${r.left}px`;
pop.style.top = `${r.bottom + 2}px`;
pop.hidden = false;
```

## The more-below hint on the in-window menus {#menu-more}

- refers-to: src/shell/menubar.ts :: mountMenubar (card markup, showMore, list scroll) · src/styles/settings.css :: .fx-menu-list, .fx-menu-more
- kind: removed-code
- logged: v0.13.0 · 2026-11-30

A menu cut off by the cap shows a fade on its last rows and a 56 by 12 px pill with a down chevron 6 px above its bottom edge while rows remain below (guide rule 8). The card is built once with two children, `.fx-menu-list` (the rows, which scrolls) and `.fx-menu-more` (the pill, `aria-hidden`, no pointer events), so the mask goes on the list and the rows fade into the card's own background; a mask on the card would fade its border and shadow too. `open()` fills the list, not the card, and `max-height` stays on the card. `showMore(true)` runs while the card is still hidden, with `no-fade` on for one style read, so the hint is in place on the first painted frame and never fades in on opening; the list's `scroll` runs `showMore()`, so the hint leaves in 160 ms at the last row and comes back over 490 ms (the timing belongs to the state being entered). `--fx-menu-more` is a registered `@property` so the mask can animate. The pill uses the card's own tokens, `--bar` and `--edge-strong`, and `--ink-soft` for the chevron. Reduced motion shows and hides with no fade. Nothing outside `menubar.ts` reads the card's children or `scrollTop`. form.ext has no right-click or other point-anchored menu (searched `contextmenu`, `openAt(`, `place(`, `popover`, `role="menu"` under `src/`): the dock's `.ft-dock-menu` is a CSS-placed panel inside the shared module `src/dock/`, which is never edited here, and the palette is a dialog, so section 3b of the guide has nothing to change.

Removed from `open()`, the rows now go into the list:

```ts
pop.innerHTML = def.items.map(entry).join('');
```

```ts
pop.scrollTop = 0;
```

Removed from `.fx-menu`, the list scrolls instead of the card:

```css
overflow-y: auto;
overscroll-behavior: contain;
```
4 changes: 2 additions & 2 deletions frontend/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion frontend/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "formext",
"private": true,
"version": "0.12.2",
"version": "0.13.0",
"description": "form.ext: the Form family's extension studio",
"license": "GPL-3.0-only",
"type": "module",
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/demo/engine/router.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ function decodeFiles(rawFiles: Json): Record<string, Uint8Array> {
return out;
}

on('GET', '/api/health', () => ({ ok: true, app: 'formext', version: '0.12.2 in this page', api: '1', pid: 0, python: null, frozen: false, home: DATA, contract: 'bundled', uptime: Math.round(performance.now() / 100) / 10, live_clients: 0, routers: ['health', 'settings', 'projects', 'live', 'library', 'package', 'preview', 'publish', 'runapp', 'templates', 'validate'], router_errors: {}, frontend: 'demo', demo: true }));
on('GET', '/api/health', () => ({ ok: true, app: 'formext', version: '0.13.0 in this page', api: '1', pid: 0, python: null, frozen: false, home: DATA, contract: 'bundled', uptime: Math.round(performance.now() / 100) / 10, live_clients: 0, routers: ['health', 'settings', 'projects', 'live', 'library', 'package', 'preview', 'publish', 'runapp', 'templates', 'validate'], router_errors: {}, frontend: 'demo', demo: true }));
on('GET', '/api/settings', () => ({ ...settings.get(), home: DATA }));
on('PUT', '/api/settings', (_m, r) => {
const patch = { ...json(r) };
Expand Down
28 changes: 26 additions & 2 deletions frontend/src/shell/menubar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,19 @@ import { get, run } from './commands';
import { esc, keyLabel } from './dom';
import { APP_MENU, MENUS, SEP, SYSTEM_ITEMS } from './menus';

const MENU_SHARE = 0.75, MENU_PAD = 4;
const menuCap = (top: number): number => Math.max(0, Math.min(Math.floor(window.innerHeight * MENU_SHARE), Math.floor(window.innerHeight - top - MENU_PAD)));

export function mountMenubar(bar: HTMLElement): void {
const all = [APP_MENU, ...MENUS];
bar.innerHTML = all.map((m) => `<button type="button" aria-haspopup="menu" aria-expanded="false" data-menu="${esc(m.label)}">${esc(m.label)}</button>`).join('');
const pop = document.createElement('div');
pop.className = 'fx-menu';
pop.setAttribute('role', 'menu');
pop.hidden = true;
pop.innerHTML = '<div class="fx-menu-list" role="none"></div><div class="fx-menu-more" aria-hidden="true"><svg viewBox="0 0 12 8"><path d="M1.5 1.5 6 6l4.5-4.5" fill="none" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round"/></svg></div>';
const list = pop.firstElementChild as HTMLElement;
const more = pop.lastElementChild as HTMLElement;
document.body.append(pop);
let openBtn: HTMLElement | null = null;

Expand All @@ -18,6 +24,16 @@ export function mountMenubar(bar: HTMLElement): void {
openBtn = null;
}

function showMore(instant = false): void {
const rest = !pop.hidden && list.scrollHeight - list.clientHeight - list.scrollTop > 1;
if (instant) pop.classList.add('no-fade');
pop.classList.toggle('has-more', rest);
if (instant) {
void getComputedStyle(more).opacity;
pop.classList.remove('no-fade');
}
}

function entry(id: string): string {
if (id === SEP) return '<div class="fx-menu-sep" role="separator"></div>';
const sys = SYSTEM_ITEMS[id];
Expand All @@ -32,11 +48,17 @@ export function mountMenubar(bar: HTMLElement): void {
const def = all.find((m) => m.label === btn.dataset.menu);
if (!def) return;
close();
pop.innerHTML = def.items.map(entry).join('');
list.innerHTML = def.items.map(entry).join('');
const r = btn.getBoundingClientRect();
const top = r.bottom + 2;
pop.style.visibility = 'hidden';
pop.style.left = `${r.left}px`;
pop.style.top = `${r.bottom + 2}px`;
pop.style.top = `${top}px`;
pop.style.maxHeight = `${menuCap(top)}px`;
pop.hidden = false;
list.scrollTop = 0;
showMore(true);
pop.style.visibility = '';
btn.setAttribute('aria-expanded', 'true');
openBtn = btn;
}
Expand All @@ -61,6 +83,7 @@ export function mountMenubar(bar: HTMLElement): void {
else void run(id);
});
pop.addEventListener('mousedown', (ev) => ev.preventDefault());
list.addEventListener('scroll', () => showMore(), { passive: true });
document.addEventListener('pointerdown', (ev) => {
if (!openBtn) return;
const t = ev.target as HTMLElement;
Expand All @@ -70,4 +93,5 @@ export function mountMenubar(bar: HTMLElement): void {
if (ev.key === 'Escape' && openBtn) close();
});
window.addEventListener('blur', close);
window.addEventListener('resize', close);
}
2 changes: 1 addition & 1 deletion frontend/src/shell/version.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export const VERSION = '0.12.2';
export const VERSION = '0.13.0';
9 changes: 9 additions & 0 deletions frontend/src/styles/settings.css
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,15 @@
box-shadow: var(--shadow-lg);
}
.fx-menu[hidden] { display: none; }
@property --fx-menu-more { syntax: '<number>'; inherits: false; initial-value: 0; }
.fx-menu:not([hidden]) { display: flex; flex-direction: column; overflow: hidden; }
.fx-menu-list { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; --fx-menu-more: 0; -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - min(88px, 40%)), rgb(0 0 0 / calc(1 - var(--fx-menu-more))) calc(100% - min(22px, 10%))); mask-image: linear-gradient(to bottom, #000 calc(100% - min(88px, 40%)), rgb(0 0 0 / calc(1 - var(--fx-menu-more))) calc(100% - min(22px, 10%))); transition: --fx-menu-more 160ms ease-out; }
.fx-menu-more { position: absolute; left: 50%; bottom: 6px; width: 56px; height: 12px; margin-left: -28px; display: flex; align-items: center; justify-content: center; border: 1px solid var(--edge-strong); border-radius: var(--radius-pill); background: var(--bar); color: var(--ink-soft); pointer-events: none; opacity: 0; transition: opacity 160ms ease-out; }
.fx-menu-more svg { width: 12px; height: 8px; }
.fx-menu.has-more > .fx-menu-list { --fx-menu-more: 1; scroll-padding-block-end: min(88px, 40%); transition-duration: 490ms; }
.fx-menu.has-more > .fx-menu-more { opacity: 1; transition-duration: 490ms; }
.fx-menu.no-fade > .fx-menu-list, .fx-menu.no-fade > .fx-menu-more { transition: none; }
@media (prefers-reduced-motion: reduce) { .fx-menu-list, .fx-menu-more { transition: none; } }
.fx-menu button { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4); width: 100%; height: var(--ctl-md); padding: 0 var(--sp-3); border: 0; border-radius: var(--radius); background: transparent; color: var(--ink); font: inherit; font-size: var(--fs-13); text-align: left; cursor: pointer; }
.fx-menu button:hover { background: var(--accent-color); color: var(--text-on-accent); }
.fx-menu kbd { color: var(--ink-faint); font: inherit; font-size: var(--fs-12); }
Expand Down
2 changes: 1 addition & 1 deletion src-tauri/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "formext"
version = "0.12.2"
version = "0.13.0"
description = "form.ext desktop shell"
authors = ["NodeAgentc, Inc."]
license = "GPL-3.0-only"
Expand Down
2 changes: 1 addition & 1 deletion src-tauri/tauri.conf.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"$schema": "https://schema.tauri.app/config/2",
"productName": "form.ext",
"mainBinaryName": "formext",
"version": "0.12.2",
"version": "0.13.0",
"identifier": "ai.nodemode.formext",
"build": {
"frontendDist": "../frontend/dist",
Expand Down
Loading