mirror of
https://github.com/caiwx86/small-packages.git
synced 2026-11-03 04:53:56 +08:00
2.8 KiB
2.8 KiB
admin-services-dockerman
info-table-entry-column — value cells break only words that do not fit
- page: admin-services-dockerman-overview · Services → Dockerman JS → Overview
- package: luci-app-dockerman (openwrt/luci, the JS rewrite)
- dom:
.cbi-section.cbi-tblsection > table.table.cbi-section-table > tr.cbi-section-table-row > td.td.cbi-value-field[data-name=entry|value]—docker inforendered as two-column TableSections; the value column holds multi-KB JSON with no spaces (Runtimes, Plugins) - symptom: the entry column collapsed to ~42px and showed one character per line (
MemoryLimitover 7–8 lines) beside the JSON values - cause:
.td.cbi-value-fieldcarriedword-break: break-allat every width (added in 50c2b84 as an overflow guard).break-alldrops every cell's min-content to about one character; auto table layout then hands spare width out by max-content, so the JSON took nearly all of it. bootstrap sets no word-break on desktop cells — its labels stay whole but the JSON stretches the table to ~3.5k px and the page scrolls sideways. - fix:
components/_table.css& td, & .td { &.cbi-value-field { wrap-anywhere md:max-w-prose } }—wrap-anywherekeeps break-all's min-content (same overflow guard) but only breaks a word that does not fit;md:max-w-prosecaps each cell's intrinsic contribution so one huge value cannot starve the other columns (the used width may still exceed it: 944px measured) · a2d110a · 1.3.2. Lineage: 50c2b84 2025-10-12 (0.5.8_beta) added&.cbi-value-field { break-all }for "System => (Software, Mount Points): Fix overflow when td text is too long" and "Network => Wireless host: Fix overflow when td text is too long", replacing the globaltd max-w-94it removed for passwall (seeadmin-services-passwall.md); 031283c 2026-07-09 added the mobile-card utilities on the same rule (max-md:mb-1 max-md:basis-full max-md:self-start max-md:text-leftand the[data-widget=…] max-md:basis-1/2sub-rule) - verified: device, Chromium, Environment table before → after: entry column 42 → 260px at 1440, 42 → 196 at 1024, 41 → 152 at 800; short words split across lines 41 → 0 / 0 / 2; mobile cards unchanged; section height 8301 → 3797px at 1440; firewall zone and rule GridSections kept identical column widths at 1440/1024/800/390; a file:// fixture gave the same result in Chromium, WebKit and Firefox. Side effect noted, not measured: on admin-system-mounts the GridSection value cells take the 65ch cap instead of the page's
max-w-104(same specificity, later rule). - fixture: fixtures/admin-services-dockerman-overview--info-table.html (entry column
nowrapat 1440/1024/390 — at 800 two short words still split, so that width is not asserted) - issue: #96 · mirror: shadcn f4d7219 · status: active