diff options
| author | Martin Ridgers <[email protected]> | 2024-11-28 15:07:16 +0100 |
|---|---|---|
| committer | GitHub Enterprise <[email protected]> | 2024-11-28 15:07:16 +0100 |
| commit | e697b522f2d869f335aa8db074b43362aff1e29a (patch) | |
| tree | 57ecb83feea76bdb3daeff598b062d5e952d433c /src/zenserver/frontend/html/util | |
| parent | set content type correctly for getchunkrange (#241) (diff) | |
| download | zen-e697b522f2d869f335aa8db074b43362aff1e29a.tar.xz zen-e697b522f2d869f335aa8db074b43362aff1e29a.zip | |
Dashboard CSS fixes and archival of a partial treemap view (#242)
* Input boxes' text was unreadable when using the dark theme
* Change from margins to padding top/bottom - easier to reason about vertical styling.
* A treemap. Not used anywhere and not finished. Submitting so it isn't lost
* Prevent tables' first content columns from collapsing
* Dashboardk .zip archive update
Diffstat (limited to 'src/zenserver/frontend/html/util')
| -rw-r--r-- | src/zenserver/frontend/html/util/widgets.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/zenserver/frontend/html/util/widgets.js b/src/zenserver/frontend/html/util/widgets.js index e567a7a00..78998b7ff 100644 --- a/src/zenserver/frontend/html/util/widgets.js +++ b/src/zenserver/frontend/html/util/widgets.js @@ -60,10 +60,12 @@ export class Table extends Widget var root = parent.tag().classify("zen_table"); super(root); + const column_width = 0 | (100 / column_names.length); + var column_style; if (flags & Table.Flag_FitLeft) column_style = "max-content"; - else if (flags & Table.Flag_BiasLeft) column_style = "2fr"; - else column_style = "1fr"; + else if (flags & Table.Flag_BiasLeft) column_style = `minmax(${column_width * 2}%, 2fr)`; + else column_style = `minmax(${column_width}%, 1fr)`; for (var i = 1; i < column_names.length; ++i) { const style = (flags & Table.Flag_PackRight) ? " auto" : " 1fr"; |