Skip to content

Quantum 0.16.0 ​

Added ​

  • quantum desktop (UI-4): the application in a desktop window. It starts the application's server on a free local port and opens a native window (pywebview) on it — the same pages, actions and session as the web, with no logic translated. quantum desktop /some/page --width 800 opens a given page and size. Needs the new extra: pip install "quantum-framework[desktop]"; without it the command says so.

  • Tables and lists from data (UI-5): <ui:table source="{rows}"> draws one row per record — <ui:column key="name"> shows a field, a column with content draws it per row (<ui:button on-click="delete" with="id={row.id}">) — and <ui:list source="{items}" as="item"> repeats its content. Until now a table's body was empty and the whole data source was written into the page as an HTML comment; a list showed {item.x} raw. A source that is not a list, or a column key the row lacks, is an error.

  • Form fields open with a value (UI-6): value= on ui:input, ui:select, ui:radio; checked= on ui:checkbox, ui:switch. Edit forms were not possible.

  • The core set of ui:* (UI-7): 37 elements drawn with the same meaning in the browser, the console and the desktop, checked by one script run in a real browser and in the console (tests/apps/test_ui_paridade.py). The console now draws grids, tabs, cards, tables, lists, checkboxes, switches, radios, progress bars and images; for a tag outside the set it says it cannot draw it, instead of drawing something else.

  • Guide: One App, Many Screens (docs/guide/ui.md), every screen in it served by a test and checked in the browser's text and the console's.

  • Guide: How a Page Runs (docs/guide/how-a-page-runs.md) and SPEC section EXEC-: the order of a GET and of a POST, and how long a page variable, flash, session.x and application.x live (application.x is per server process: gone on restart, not shared between gunicorn workers). The errors for a statement inside markup (PARSE-2), a page variable read in an action (ACT-9) and a guard that reads the page (AUTH-6) link to it.

  • CI: the Laboratório tests (games, Godot, React Native) run in a job of their own, still required.

Breaking ​

  • quantum run --target desktop was removed (UI-8). It generated a pywebview app with a JavaScript bridge that translated q:set and q:function on its own — a second implementation of the language. Use quantum desktop, which opens the same pages in a window.
  • Standalone UI builds are layout only (UI-8): a q:set, q:function or any command inside <q:application type="ui"> built with --target html or --target textual is an error. It used to be dropped without a word ({count} came out raw; buttons called functions that did not exist). Write screens as pages.
  • Browser state persistence was removed (SET-2): persist, persistKey, persistTtl, persistEncrypt on q:set, and the q:persist tag. They only did anything in the standalone HTML build, and nothing in a page; they are now errors that say to use session.x or the database.
  • --target mobile (React Native) is Laboratório: it warns once.

Changed ​

  • A page's title is the same in the browser, the console and the desktop window: the first ui:window's title, else the component's name (UI-4). Pages served in HTML used to be titled <path> - Quantum.
  • In a page, ui:section is a titled group, always open (it was a collapsed <details>: its content was hidden in the browser); a ui:card's title shows next to a ui:card-header too.

Fixed ​

  • examples/python-data-processing.q used <ui:code>, which never existed, and examples/state_persistence_demo.q used <ui:form-item>; neither page opened. The first is fixed; the second is removed with the feature it showed. examples/dashboard-ui.q is now a page; examples/task-manager-desktop.q (the desktop bridge's demo) is removed.

  • docs/tools/cli.md told to run python src/cli/runner.py, a path that no longer exists.

  • Text directly inside a ui:* container vanished: <ui:card-header>Summary</ui:card-header> came out empty (UI-1).


← 0.15.0 · All versions · 0.17.0 →

MIT Licensed · Built with VitePress