@enigmax/dashboard 0.1.94 → 0.1.96

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/assets/index.html +25 -3
  2. package/package.json +1 -1
package/assets/index.html CHANGED
@@ -52,7 +52,9 @@
52
52
  two-class form to win: a bare .side-x would lose to it on source order. */
53
53
  .iconbtn.side-x { display: none; }
54
54
  .side-foot { margin-top: auto; padding: 12px 6px 0; border-top: 1px solid var(--border-soft); }
55
- .content { flex: 1; min-width: 0; padding: 30px 30px 48px; max-width: 1560px; }
55
+ /* Auto side margins, not just a max-width: past 1560px + the rail the column would
56
+ otherwise stay glued to the sidebar with all the empty space piled on the right. */
57
+ .content { flex: 1; min-width: 0; padding: 30px 30px 48px; max-width: 1560px; margin-inline: auto; }
56
58
  .iconbtn.nav-burger { display: none; }
57
59
  .nav-scrim { position: fixed; inset: 0; z-index: 25; background: rgba(0,0,0,0.6); }
58
60
  a { color: var(--accent2); }
@@ -168,6 +170,8 @@
168
170
  .set-cat { margin-bottom: 18px; }
169
171
  .set-cat:last-child { margin-bottom: 0; }
170
172
  .set-cat-h { font-family: var(--mono); color: var(--accent); font-size: 12px; text-transform: uppercase; letter-spacing: 0.7px; margin-bottom: 4px; }
173
+ /* A path in a header is a literal: uppercasing it prints something that does not exist. */
174
+ .set-cat-h code { text-transform: none; letter-spacing: 0; }
171
175
  .set-cat-b { color: var(--muted); font-size: 12px; margin-bottom: 8px; }
172
176
  .set-row { display: flex; align-items: center; gap: 14px; padding: 9px 0; border-bottom: 1px solid var(--surface2); }
173
177
  .set-row:last-child { border-bottom: none; }
@@ -194,6 +198,7 @@
194
198
  .fld-err { color: var(--bad); font-size: 11px; min-height: 0; }
195
199
  .fld-err:empty { display: none; }
196
200
  .linput.bad { border-color: var(--bad); }
201
+ .tbl-scroll { overflow-x: auto; }
197
202
  .tun-table { width: 100%; border-collapse: collapse; }
198
203
  .tun-table th { text-align: left; font-size: 12px; color: var(--muted); font-weight: 500; padding: 6px 10px; border-bottom: 1px solid var(--border); }
199
204
  .tun-table td { padding: 8px 10px; border-bottom: 1px solid var(--border); vertical-align: middle; }
@@ -336,7 +341,10 @@
336
341
  }
337
342
  @media (prefers-reduced-motion) { .etoast, .etoast > * { transition: opacity .2s !important; } }
338
343
  /* Settings: two-column grid of rows on wide screens, so a long config list stays compact. */
339
- .set-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(420px, 1fr)); gap: 0 32px; }
344
+ /* min(420px, 100%) rather than a bare 420px: a fixed track floor never shrinks below
345
+ itself, so on a narrow viewport the row would keep claiming 420px and push the page
346
+ sideways. The min() lets the single column collapse to whatever space there is. */
347
+ .set-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(420px, 100%), 1fr)); gap: 0 32px; }
340
348
  .set-grid .set-row { padding: 10px 0; }
341
349
  .panel > .set-cat-h { margin-top: 0; }
342
350
  .tag {
@@ -510,6 +518,18 @@
510
518
  .grid { grid-template-columns: repeat(2, 1fr); }
511
519
  header { gap: 12px; }
512
520
  .nav { margin-left: auto; flex-wrap: wrap; gap: 10px; }
521
+ /* A settings row is label + controls side by side, and the control cluster is
522
+ flex-shrink: 0 so a wide one (account actions, a select plus three buttons)
523
+ pushes the row past the viewport. Here the row wraps and the cluster is
524
+ allowed to shrink and wrap its own buttons instead. */
525
+ /* A heading and its action cluster sit side by side; on a phone the cluster
526
+ drops below instead of pushing the page sideways. */
527
+ .page-head, .panel-head { flex-wrap: wrap; }
528
+ /* A data table cannot fold, so below this width it scrolls inside its own box.
529
+ `display: block` is what gives the table element its own scroll container. */
530
+ .tbl { display: block; overflow-x: auto; white-space: nowrap; }
531
+ .set-row { flex-wrap: wrap; align-items: flex-start; }
532
+ .set-ctl { flex-shrink: 1; min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
513
533
  }
514
534
  /* Pretty scrollbars across the whole dashboard (thin, rounded, themed). */
515
535
  * { scrollbar-width: thin; scrollbar-color: #2b3340 transparent; }
@@ -4509,7 +4529,9 @@ export {
4509
4529
  + ' ' + ibtn('data-tun-remove="' + esc(t.name) + '"', 'danger', ICO.trash, 'Delete') + '</td>'
4510
4530
  + '</tr>';
4511
4531
  }).join("");
4512
- body.innerHTML = '<table class="tun-table"><thead><tr><th>Name</th><th>Server</th><th>Forward</th><th>Status</th><th>Actions</th></tr></thead><tbody>' + rows + '</tbody></table>';
4532
+ // The table has five columns and cannot fold; it scrolls inside its own box so the
4533
+ // page never scrolls sideways with it.
4534
+ body.innerHTML = '<div class="tbl-scroll"><table class="tun-table"><thead><tr><th>Name</th><th>Server</th><th>Forward</th><th>Status</th><th>Actions</th></tr></thead><tbody>' + rows + '</tbody></table></div>';
4513
4535
  }
4514
4536
  async function loadSsh() {
4515
4537
  setNote("sshNote", "");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@enigmax/dashboard",
3
- "version": "0.1.94",
3
+ "version": "0.1.96",
4
4
  "description": "Local browser dashboard UI for enigma: the static page and chart assets enigma serves on its loopback dashboard (savings, real tool usage, in-browser settings). Installed on demand by enigma-cli; not a runtime dependency.",
5
5
  "type": "module",
6
6
  "files": [