Commit Graph
18 Commits
Author SHA1 Message Date
Lauri Ojansivu e34a488617 Phone, foldable, tablet, laptop and 55" touchscreen: the new UI checked upright and on its side.
tests/playwright/specs/viewport-matrix.e2e.js opens WeKan as an iPhone 15,
an unfolded Galaxy Z Fold 7, an iPad Pro 11, a 1366x768 laptop and a 55"
4K touch panel, each upright and on its side, and checks the board header,
board menu -> Original positions, Problems -> Memory Usage and Disk usage,
the Table, Calendar Mode, Time, Timeline and Map views, and dragscroll by
mouse or by finger. It measures that icons and texts are on screen and not
drawn in the colour behind them, that the page never scrolls sideways, that
every column can be reached and stays readable; screenshots of each step go
to .tools/log/viewports/. What it found, fixed:

- iPhone: the header bar was width: 100% plus its side padding as a content
  box, 24px wider than the screen, and the sidebar hamburger sat past the
  right edge. It measures its padding inside now.
- Admin Panel left menu on a phone: the list's disc bullets showed as a dot
  after every entry, and a rule between groups shrank to a dash beside an
  entry. No bullets, and each group starts a row of its own.
- Admin tables: 13 equal columns were 25px each on a phone and 42px on an
  upright iPad, every header one letter per line. Up to 1024px a column keeps
  a readable floor and the table scrolls sideways in its wrapper.
- Table view: the title-wrap and swimlane-group toggles were white icons on
  white - two empty squares - stretched to 72px by the global button padding.
  And on an upright iPad or foldable, Members, Labels and the date columns lay
  past the edge of an overflow-hidden board with nothing to scroll; the view
  scrolls sideways itself now.

A swipe that starts beside a list's resize handle resizes the list, as it
should, so the dragscroll check starts where a person pans. The file runs in
Chromium only: device emulation and the touch swipe exist only there.

Thanks to xet7 !
2026-10-17 04:05:49 +03:00
Lauri Ojansivu b7589737f5 File docs/Features the way the WeKan menus are.
A feature's guide now sits under the menu it is used from, read from the
templates rather than from where somebody once put it: Header-Bar,
All-Boards, Pages, Board-Header (search and every Board View), Board-Sidebar
(Board Settings, Filter, Members, Labels, Archive), Rules, Swimlanes, Lists,
Cards, Member-Settings, Admin-Panel and Login-Page. Topics used from several
menus (editor, history, theme, translations, email, troubleshooting) are in
General.

- Each area has a README mapping its menu entries to their guides and to the
  template or server module that implements them. Board-Header/README.md
  lists all 40 Board View entries with the template boardBody.jade renders;
  five views (Table, Calendar Mode, Time, Timeline, Map) have no guide of
  their own yet and say so.
- Board-View.md listed 25 views while BOARD_VIEWS has 40; it now lists all
  of them with their English labels.
- Pages keep their file names. Where a released changelog links an old path,
  a "# Moved" page stays there and points to the new one; test-menu.sh skips
  folders holding only those.
- Undo was filed under Login; it is General/Undo now.
- Every link in docs, code comments, scripts and tests follows the move;
  docsLinksResolve checks them all.

Tests that read a doc follow it to its new place. boardViewSettings now fails
when Board-View.md or Board-Header/README.md differs from BOARD_VIEWS, or
names a template boardBody.jade does not render.

Thanks to xet7 !
2026-10-16 23:45:35 +03:00
Lauri Ojansivu e4ae7c2829 Show image previews on cards again: a real cover picture, and a neutral attachment tile.
Reported by email against v12.12: "Preview of Images is gone". On the board
a card with an image cover showed a flat coloured band, and in the open card
the attachment row showed a small mark on a blue bar instead of the picture.
Two separate faults:

- The minicard cover() helper loaded the attachment and then returned only
  a wrapper with link(). attachmentPreviewUrl() needs the attachment's _id,
  so it returned '' and the cover became url('?dummyReload...') - a request
  for the page itself. The helper now returns the attachment, as
  models/cards.js cover() does, keeping the linked-card lookup and the
  soft-delete check.
- The attachment thumbnail is a <button> (the keyboard control with its
  aria-label), and forms.css fills every button with the theme accent at
  rest and on hover, focus and active. The local override only cleared
  padding, border and font. Every state is now reset: a fixed 144x96 frame
  (96x64 below 800px) on #f4f5f7, the whole picture shown with object-fit
  contain, a 2px focus outline. My Attachments, which uses the same classes
  on a div, keeps its previous sizing.

The board cover and the open-card cover are now img elements of the
thumbnail, drawn only when there is a URL: cover-fitted 120px bands on the
board (100px on the modern theme) and 180px in the open card, which used the
full original before. A thumbnail that fails to load falls back to the
original once and stops, without logging. The invalid `border-radius: top`
is gone. The table page's attachment preview is out of the accent-filled
action buttons and gets the same neutral frame in every state. forms.css,
the cover options' defaults, the /thumbnail route and SVG handling are
unchanged.

Tests: the fallback executed as written (once, no loop, originals left
alone) and source guards for the cover helper, templates and every reset
state; two guards that pinned the old cover background and the preview's
accent fill are updated with the reason. A new Playwright spec checks a
real cover image, the tile's neutral colour and size at rest and on hover,
the open-card banner, the once-only fallback and the cover option off - it
passes in Chromium and WebKit, with the thumbnail, admin preview,
attachments and board-attachment specs (21 tests) still passing.

Thanks to xet7 !
2026-10-01 17:56:49 +03:00
Lauri Ojansivu f03463e7de Fix administrator attachment previews and downloads in Files Report
Resolve the site administrator role from the authenticated download token so the Files Report can open private-board attachments without requiring board membership. Keep ordinary private-board readers subject to membership checks.

Wrap the shared attachment controls inside narrow table cells so neighboring cells cannot intercept the download button.

Verify DOCX, image and PDF preview/download flows in Firefox and Chromium, plus negative authorization cases and eight focused Node suites.

Thanks to xet7 !
2026-09-25 02:13:25 +03:00
Lauri Ojansivu ba4637e558 Show initials for missing impersonated users 2026-09-22 18:40:36 +03:00
Lauri Ojansivu d43968d888 Clarify file scans and show location in address reports
Show when a partial file audit stopped before inspecting storage, allow larger bounded inventories, and avoid orphan findings from truncated metadata. Restore available locations in Offices and People, wrap long report cells, and theme report action buttons.
2026-09-22 18:37:38 +03:00
Lauri Ojansivu 2248c012c8 Add card-style previews to Files Report 2026-09-06 10:45:35 +03:00
Lauri Ojansivu 37b7eb06aa Show wrapping names in Admin Panel user cells 2026-09-06 10:35:23 +03:00
Lauri Ojansivu 3539f2bbf3 Group Admin Panel Offices login addresses by person.
Show each person's successful-login addresses together, with separate IPv4 and IPv6 columns, the latest country flag and city supplied by Cloudflare or another supported proxy, and that person's login count for each address.

Search continues to match usernames, full names, addresses and locations. Address metadata for each page is fetched in one batch, and people sharing an address remain separate groups with their own counts.

Focused coverage checks grouping, shared addresses, both address families, proxy location headers, missing locations and the person-first server response.

Thanks to xet7 !
2026-08-18 22:48:26 +03:00
Lauri Ojansivu 7a0b7b7cdb Audit failed permanent-delete attempts with status and address.
Record successful, failed, and unauthorized permanent-delete attempts in Recovery with Boolean Done and deleted-data fields, actor ID and username, proxy-aware IPv4 or IPv6, and requested board IDs and titles. Render Done first with green success, red failure, and yellow deletion icons. Preserve original errors after recording failed attempts.

Thanks to xet7 !
2026-08-17 23:54:36 +03:00
Lauri Ojansivu 580b03e172 Admin Panel avatars are avatar-sized, and All Boards tiles fill their row.
Three places, one cause each, all visible as soon as the page was opened.

ADMIN PANEL / PROBLEMS drew a user's photograph at its NATURAL size - a 300px
portrait in a table row, a screen tall, with the login counts scattered around
it. Reported for Offices and for the Impersonation Report, and it was every pane
that names a user. Every avatar rule in userAvatar.css is scoped to `.member`,
which is what makes an avatar 24px and round and crops the image to fill it, and
the shared table page's cells had no such box: the image and the initials had
been copied, and the thing they belong in had not. The cells use `.member` now
rather than a fourth private copy of "how big is an avatar" - there were already
three, which is how the three came to disagree - with the two board-specific
declarations it carries (a float and a sidebar margin) turned off for a table.
That covers every Problems pane at once, because they all draw users through the
same table page and none has avatar markup of its own.

ALL BOARDS / STARRED: the grey "+ Add Board" tile hung short of the boards
beside it. `min-height: 114px` is a FLOOR, and a board whose title wraps to
three lines grows past it; the grid stretches every other tile in the row to
match, but the grey comes from the `.label` INSIDE the li rather than from the
li itself, so it kept its 114px while its li grew. The li is a flex box now and
the label grows into it.

ALL BOARDS / HOME: "Drag a board here to open it after login" was padding around
a line of text, about 85px, on a page whose entire content is that box. It
stands where a board tile will be, so it is a board tile's height.

CHECKED AND ALREADY RIGHT, rather than changed: Templates and the workspaces.
Every view - Starred, Remaining, Home, Templates, Archive and each workspace -
is the SAME `ul.board-list` with a different set of boards in it, so they share
one rule, and every tile variant computes to the same 114px border-box floor.
A test now pins that there is one list and that no variant sets a height of its
own, so "do the workspace tiles match" keeps having one answer instead of six.

tests/adminPanelAvatars.test.cjs verified to fail on the real fault: dropping
`.member` reports "these avatar links are not `.member`, so the image has no
size and renders at whatever the file is".

Thanks to xet7 !
2026-08-16 20:57:12 +03:00
Lauri Ojansivu ebe985d453 A location in an Admin Panel table opens a map, through the card's own chooser.
Admin Panel / Problems / Offices names the places accounts log in from -
"London", with the country's flag - and a name is only useful if it leads
somewhere. Clicking one now asks which map to open it at, from the same eleven
providers a card's location offers.

THE SAME CHOOSER, not a second one. The provider list was eleven options inside
cardDetails.jade; it is client/components/main/mapProvider.jade now, and both
callers include it. Two lists would be eleven places to add a provider instead
of one, and they would disagree the first time only one was edited. The
isMapProvider helper moves with it, so neither caller needs its own copy, and so
do its styles - they were scoped to .js-card-location-form, which stopped being
true the moment a second template used them.

What the two do NOT share is the rest. A card's popup EDITS a location - name,
address, coordinates, delete - and none of that applies to an office: its
location arrived in a CDN header, WeKan did not ask for it and cannot correct
it. So tablePageMapPopup is the map half alone: where this is, the link, the
chooser, and a save that makes the choice the default for cards too, because
profile.mapProvider is the one setting both read.

A cell is a link only when the row HAS coordinates. A city name is not a
position, and a map URL built from one would either search for the word or
invent a place, so buildRows drops a location without lat/lon and the cell stays
plain text. The link follows the selection BEFORE it is saved: choosing a
provider and finding the link still pointing at the old one reads as broken.

The handler lives on the shared table page, not on the report. That is also
where the "clicking a user opens the Edit user popup" handler goes: three
reports each had their own identical copy, because each was written where its
own page was. A Blaze event bubbles through the template hierarchy, so one
handler on tablePage reaches every report - and a report added later gets both
without being told.

Two things the guards caught, both worth naming. The popup had no title, which
in WeKan means no header and so no close button; it opens with
titleKey: 'location-open-map-at' - the phrase the chooser is already labelled
with in every language - rather than adding a key to 154 files. And a comment
between an `if` and its `else if` breaks jade nesting, which
tests/jadeCompiles.test.cjs has a negative test for; the comments sit above the
chain.

Thanks to xet7 !
2026-08-16 17:33:09 +03:00
Lauri Ojansivu daaf563910 Docs: implemented designs move to docs/Features, filed the way the menu is.
A design that describes what WeKan already DOES belongs with the feature it
describes, not in the folder for things being proposed. Fifteen docs move:

  Design/Accessibility.md      -> Features/Accessibility/Accessibility-Improvements.md
  Design/Original-Positions.md -> Features/Board/Original-Positions.md
  Design/Page/*                -> Features/Page/*   (thirteen pages that exist)
  Design/AdminPanelProblems.md -> Features/Admin-Panel/Problems/Design.md

What stays in docs/Design is what the folder is for: the principles
(Design-Principles, Monkey-Proof-Software), the comparisons, the roadmap
(Multiverse), and the proposals not yet built (Multitenancy, Autoupdate).

The Admin Panel Problems design is new and covers six changes - summaries, the
per-actor tally, IPv4/IPv6 columns, an API report, a per-address login tally,
and blocking with increasing delays. Three are shipped and three are planned;
it is filed under the feature because the pane exists, with each planned item
marked so it can become plain description as it lands.

Every reference in the repository is rewritten - 152 files, including the CSS
comments that point at the table-page design, which a first pass over .md and
.js alone missed. Two suites asserted the old paths and now assert the new
ones. A moved doc whose links nobody fixed is worse than one nobody moved.

Thanks to xet7 !
2026-08-16 15:15:01 +03:00
Lauri Ojansivu d232194070 Admin Panel: the tables fit, every pane has a title, and Version opens first.
Reported one after another, all in the Admin Panel, and they turned out to share
two causes: a stylesheet deciding a table's width from outside the design that
owns it, and a pane having to write for itself what every pane needs.

The tables

* Admin Panel / People / People rendered NOTHING - no table, no search box, no
  pager. `buildFilters` and `buildActions` were used in peopleTablePageData but
  never imported. That is not a build error: it is a ReferenceError thrown inside
  a helper while rendering, which Blaze answers by rendering nothing at all.
  Organizations, Teams and Domains use neither function, so they drew normally,
  which is what made it look like a People-only problem.

* The right-hand side of a table was off screen - reported on Domains, and just
  as true of Admin Panel / Version, where the value column was cut off at the
  window edge. Two admin stylesheets forced `min-width: 1200px !important;
  width: max-content !important` with nowrap cells on a bare `table` selector.
  peopleBody.css had no page in the selector at all, so it reached every table in
  WeKan, and `!important` beat the shared table page's own width:100% +
  table-layout:fixed. The same rules also made a SHORT table shrink to its
  content, which is why Domains sat at a third of the panel on a narrow window.
  No admin table is forced wide any more: it fits its panel and its cells wrap,
  and the phone-width exception that used to undo the floor is simply the rule at
  every width. The shared table page's width and wrapping are `!important` now -
  a guarantee a stylesheet in another folder can silently override is not a
  guarantee.

* An empty table page rendered no table at all, and the "New" link of
  Organizations, Teams, People and Translation is a column HEADER - so an empty
  pane had no way to create the first row. The table always renders now; the
  "no items" message moved below it.

* The controls row: every control shares one height and no margin. forms.css is
  `button { display: block; margin-bottom: 14px }`, written for stacked form
  buttons, so a button that kept that margin was centred higher than one that did
  not - "Unlock all users" sat lower and shorter than "Teams" beside it, since it
  also carried a 20px margin and a 28px height from the old hand-written header.
  Action buttons are themed with the pager, in the one stylesheet that owns those
  colours, every state spelled out, or a bare <button> falls through to the
  forms.css fallback, which is literally black.

Admin Panel / Settings / Translation now renders through the shared table page
(docs/Design/Page/Table.md) instead of a hand-written table: four columns, an
interactive row, the "New" link as a column header. It pages ONE page of 25
server-side with limit/skip and a count method, where it used to grow a window by
infinite scroll; the publication publishes the field it is sorted by, so the
client's sort matches the server's page.

The pane title

Every Admin Panel pane opens with the same heading, and the heading is the ACTIVE
LEFT MENU ENTRY's own label - `paneTitle()` in models/lib/leftMenu.js, one class
`.admin-pane-title`, which the shared table page's own title carries too. Before
this only the paginated table pages had a title at all: Domains said "Domains"
while Login, Announcement, Accessibility, PWA and Version opened with no heading.
Deriving it from the menu is what keeps them identical - a pane cannot end up with
a title of a different size or none at all - and it is why a table page inside the
Admin Panel now passes no titleKey: the section already rendered the heading.

The menus

* Version is the FIRST pane of Admin Panel / Settings and the one that opens with
  the page, so what an admin sees first is the version, database and system
  information they usually came for. Its page, its one-entry menu and its tab are
  gone - a page whose menu had a single entry was a page in name only - and
  /information redirects to Settings, the same move Translation made.
* Admin Panel / People: Domains moves up beside E-mail, the settings it is about.
* Admin Panel / Attachments: Backup moves to the top.

Tests: tests/tablePage.test.cjs gains the Translation conversion, the empty-table
header, the one-height controls row, the themed actions and a guard that no admin
stylesheet may force a table's width; tests/leftMenu.test.cjs gains the pane title
(helper, template, every page renders it, one shared size) and Version as the
first Settings pane; tests/translationPane.test.cjs is rewritten for the pane that
is left once the shared design owns the table.

Thanks to xet7 !
2026-07-26 01:36:15 +03:00
Lauri Ojansivu 7e2f33387e Table page: adopt People's filter, actions and total into the shared controls row.
The three features that kept Admin Panel / People off this design are now part of
it, and they are ON by default - there is no enabling flag. A page that supplies a
filter or an action gets it rendered, and the total is shown whenever the page
knows one:

  filters: buildFilters([{ id, labelKey, options: [{ value, labelKey }] }], current)
  actions: buildActions([{ id, labelKey, icon, cls }])
  total:   <number>   (+ optional totalLabelKey)

They are general - a Boards or Cards report wants a filter and a total as much as
People does - so they belong in the one template rather than in a per-page copy.
The controls row now reads: search, filters, actions, total, pagination.

A page identifies which control was used by its data attribute (data-filter,
data-action), so this adds no new handler pattern: the same one-handler-per-page
rule as the search and the pager.

The option matching `current` is selected as STRINGS, so a numeric filter value
still selects. The total sits with the controls, not in the table, because it
counts the whole result set rather than the page, and inherits its colour so it
stays readable on a dark theme.

Tests: the two new helpers (including junk input - a filter with no options
renders an empty select rather than crashing), that the four parts appear in
reading order between the search field and the pagination, that there is NO
opt-in flag, and that the doc says so.

One earlier guard needed fixing rather than the code: "the table page stylesheet
does not restate button colours" sliced the CSS by POSITION, so the new rules
landed inside the slice and tripped it. It now matches by selector, which is what
it always meant.

NOT done: People itself still renders its own markup. Its seven panes
(Organizations, Teams, People, Domains, Locked users, Roles, Shared templates)
are seven tables with their own columns and handlers, and converting them is a
larger piece of work than adding these features was. The blocker recorded in
Table.md is now gone, so that conversion is unblocked - the "Pages that do not
use this design" entry stays until it is actually done.

Thanks to xet7 !
2026-07-25 18:45:49 +03:00
Lauri Ojansivu 33a0cf6160 Design docs: move Table-Page.md under Design/Page/, and add Left-Menu.md.
docs/Design/Table-Page.md -> docs/Design/Page/Table.md, with every reference
updated: the three design docs that link to it (History, CPU-usage, Recovery),
the code comments in the shared template, stylesheet and helpers, and the four
test suites that read it. Its own link to History.md is re-based, since the file
is one level deeper now.

docs/Design/Page/Left-Menu.md is the second page design: the menu beside the
content on every Admin Panel page. It records what those seven menus share, which
pages use it, the entry shape, and how a page adds one.

Which side it is on is part of the design, not an accident of the markup: for a
left-to-right language the menu is on the LEFT with the content to its right; for
a right-to-left language the whole panel MIRRORS - the menu is on the right, the
content to its left, and inside each entry the icon and label mirror too. That
works only through the document direction plus logical CSS, so the doc says to
never write left/right/margin-left/padding-left for this menu.

Checking that turned up two places where the current CSS did exactly that:

- .side-menu had `box-shadow: inset -0.2vh ...`. An inset shadow offset on the X
  axis is a PHYSICAL direction and does not mirror, so it shaded the wrong inner
  edge once the menu moved to the right. The X offset is dropped.
- the entries used `padding: 1.3vh 0 1.3vh 1.3vw`, i.e. padding-LEFT, so under an
  RTL language the indent stayed on the left - the outer edge of a right-hand
  menu. Now padding-block + padding-inline-start.

Theme: the menu was entirely hard-coded greys. Most of it stays neutral on
purpose - it is chrome, and tinting the whole card would fight the content beside
it - but the entry you are ON now takes the per-user theme accent (Member
Settings -> Change color sets --theme-accent on :root), with `inherit` as the
fallback so the WeKan default look is byte-for-byte unchanged when no colour is
chosen. No brand colour is hard-coded in the menu.

The shared pieces are in place: client/components/settings/leftMenu.jade renders
the menu from an item list, and models/lib/leftMenu.js turns (items, activeId)
into it - marking exactly ONE entry active, dropping conditional holes, and
supporting group separators.

Tests: tests/leftMenu.test.cjs is the one suite for this design - the pure
helpers, the template, the mirroring, the theming, the shared narrow-window
stacking, and that every path in the doc's related-files table exists.

NOT done yet: the seven Admin Panel templates still render their own copy of the
menu markup. Converting them to +leftMenu is the next step; the design, the
template, the helpers and the tests it will be checked against are ready.

Thanks to xet7 !
2026-07-25 16:49:19 +03:00
Lauri Ojansivu cb07a54f56 Table pages: take the pager colours from the one themed pager stylesheet.
Checking how the table page's buttons are themed turned up two problems.

First, a bug I introduced with the shared table page: tablePage.css restated the
pagination button colours itself, and only for the base state, :hover and
.disabled. WeKan already has ONE stylesheet for every prev/next pager in the app,
client/components/main/paginationControls.css, and it spells out :hover, :focus,
:active AND :active:hover deliberately - because the global button rules in
forms.css set those same states from --theme-accent with a BLACK / dark-grey
fallback, at equal or higher specificity:

  button              { background: var(--theme-accent, #000) }
  button:focus        { background: var(--theme-accent, #222) }
  button:active       { background: var(--theme-accent, #111) }
  button:active:hover { background: #e6e6e6 }

A partial copy looks right until the button is CLICKED and then loses: pressing
"next" on a table page would have left a black button sitting there until it lost
focus - exactly the regression that stylesheet was written to prevent.
.table-page-pagination / .table-page-page-info are now listed in it, and
tablePage.css carries layout only.

Second, trimming adminReports.css in the previous commit removed the
.admin-report-controls layout, which Archived boards also used - so its search +
pagination row lost its flex layout. Archived boards now uses the shared controls
classes (its js- handlers are unchanged), which restores the layout and gives it
the same themed pager. .admin-report-pagination / .admin-event-pagination had no
users left afterwards and are gone from the pager stylesheet.

So a table page never invents a colour: the buttons and the "3 / 42" counter
follow the per-user theme (Member Settings -> Change color sets --theme-accent on
:root) and fall back to the WeKan default blue #01628c when no custom colour is
chosen, and the counter uses color: inherit so it stays readable on a dark theme.

Docs: Table-Page.md gains a Theme section saying exactly that, with the forms.css
specificity trap written down so the colours are not copied back into a page
stylesheet, and paginationControls.css + forms.css are added to the related-files
table.

Tests: the shared pager must cover the table page class in all five states with
the accent + WeKan-blue fallback; tablePage.css must not set background, color or
border on the pager; and the design doc must document the theming.

Thanks to xet7 !
2026-07-25 16:22:10 +03:00
Lauri Ojansivu 9791993d59 Table pages: one design, one implementation, and a layout that fits the window.
Files, Rules, Boards, Cards, Impersonation, Recovery and the four event streams
(Security, Speed, Tests, CPU usage) were ten copies of the same page: the same
title + search + prev/next markup, the same currentPage/totalPages helper pair,
and the same click/keydown handlers, retyped with a different js- prefix each
time. They had drifted apart, and any layout fix had to be made ten times.

They now render through ONE template and differ only in a column list:

  { label | labelKey, value(doc), align, nowrap, cls, userId(doc), data(doc) }

- client/components/settings/tablePage.jade - title, optional status row,
  controls, table. The row ORDER is defined here once.
- client/components/settings/tablePage.css - the layout.
- models/lib/tablePage.js - pure pageInfo() / buildRows() / buildHeader() /
  columnWidthPercent(), unit-tested without a browser or a database.

adminReports.jade 349 -> 112 lines, its CSS 134 -> 53, ten templates -> four,
twelve page/total helpers -> none, twenty-four control handlers -> four.

Layout fixes, now made once and reaching every page:

- The table is width:100% with table-layout:fixed, so every column gets the SAME
  percentage of the width and the table can never grow wider than the panel. With
  the default auto layout one long id or file name widened the table past the
  panel and pushed its right-hand columns outside the browser window.
- Cells wrap: overflow-wrap:anywhere breaks even an unbroken id, URL or file name
  inside its column. Datetime columns opt out with nowrap.
- .table-page has min-width:0 / max-width:100% so it can shrink inside the flex
  .main-body instead of setting a min-content floor; only the table's own wrapper
  may scroll sideways, never the page.
- At <= 800px the side menu goes full width on top and the table sits BELOW it.
  This deliberately overrides the older "always side by side, even on narrow
  windows" rule, which on a phone left the table a few dozen pixels wide with its
  right-hand columns unreachable. Above that width the menu keeps its place and
  the table sits beside it.
- Rows top to bottom: title, status (the live CPU figure on the CPU usage page),
  controls, table.

Paging still loads only the current page - the publications apply limit/skip -
and loadReport now takes that window from the SAME pageInfo() call that renders
"page X / N", so what is fetched and what is displayed cannot drift apart.

Docs: the shared design moves out of the History design doc into
docs/Design/Table-Page.md, which lists every page that uses it (table name, menu
path, description) per group. History.md, CPU-usage.md and Recovery.md now link
to it and keep only what is specific to them.

Tests: tests/tablePage.test.cjs (18) covers the pure helpers - including a page
that no longer exists clamping to a real one, and a short row never shifting the
columns - plus the layout rules the doc promises and the "one implementation"
guarantee. Four existing tests that pinned the old per-report markup were updated
to the new mechanism, same intent.

Thanks to xet7 !
2026-07-25 16:22:10 +03:00