Per-space quota UI: X of Y meter, Edit quota dialog, selection-bar action (#803) #809

Merged
Cordy merged 2 commits from feat-803 into main 2026-09-28 15:32:37 +00:00
Owner

Closes #803; implements the reviewed in-app mockup (mockup-803-space-quota.html) with the decisions from the #803 comment.

  • Meter: spqMeter(used, cap, cls, key) renders "X of Y" + a 3px bar. spqLevel: amber (--warn) at ≥ 90 %, --danger when over. Used in the overview Storage-used cell, the tiles, and the space header's right column (7b, the new .sphside column: Members button, then the meter). Uncapped spaces unchanged. The overview reads quota/quotaUsed from /meta; the size sort follows the displayed figure.
  • Edit quota:
    • Admin-only menu entry right after Edit image (new MI.gauge icon).
    • Selection-bar action #spsel-quota: admin-only, follows the selection.
    • One dialog #spacequotadlg for one or several spaces: number + MB/GB/TB (binary, GB default, prefilled from the cap), current usage + live bar (including the "already above this limit" hint), No limit → DELETE, Save → PUT {bytes}, disabled until the number is positive.
  • spq* class prefix; the mockup showed the app already has .qrow.
  • i18n ×4 for all 16 keys.
  • qa769 census 4 → 5 (the quota dialog refreshes the overview like the other kebab dialogs).

Tests: RED 9111e2a6 → green 290/290; the extracted JS passes node --check.

Amber note: the mockup used an ad-hoc amber; the code uses the app's --warn token, which is slightly deeper and theme-aware.

Closes #803; implements the reviewed in-app mockup (`mockup-803-space-quota.html`) with the decisions from the #803 comment. - **Meter:** `spqMeter(used, cap, cls, key)` renders "X of Y" + a 3px bar. `spqLevel`: amber (`--warn`) at ≥ 90 %, `--danger` when over. Used in the overview Storage-used cell, the tiles, and the space header's right column (**7b**, the new `.sphside` column: Members button, then the meter). Uncapped spaces unchanged. The overview reads `quota`/`quotaUsed` from `/meta`; the size sort follows the displayed figure. - **Edit quota:** - Admin-only menu entry right after Edit image (new `MI.gauge` icon). - Selection-bar action `#spsel-quota`: admin-only, follows the selection. - One dialog `#spacequotadlg` for one or several spaces: number + MB/GB/TB (binary, GB default, prefilled from the cap), current usage + live bar (including the "already above this limit" hint), **No limit** → DELETE, **Save** → PUT `{bytes}`, disabled until the number is positive. - `spq*` class prefix; the mockup showed the app already has `.qrow`. - i18n ×4 for all 16 keys. - `qa769` census 4 → 5 (the quota dialog refreshes the overview like the other kebab dialogs). Tests: RED 9111e2a6 → green 290/290; the extracted JS passes `node --check`. Amber note: the mockup used an ad-hoc amber; the code uses the app's `--warn` token, which is slightly deeper and theme-aware.
Cordy merged commit a667f5c916 into main 2026-09-28 15:32:37 +00:00
Cordy deleted branch feat-803 2026-09-28 15:32:39 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: Cordy/Cairn#809
No description provided.