mirror of
https://github.com/kiddin9/op-packages.git
synced 2026-11-16 21:43:33 +08:00
🎉 Sync 2026-10-14 03:01:37
This commit is contained in:
1 parent
57ac656612
commit
ef45574e85
78 files changed
+2683
-3911
No files matched your search
@@ -186,6 +186,14 @@ function headingKey(text) {
|
||||
return String(text || '').replace(/\s+/g, ' ').replace(/[\s:]+$/, '').trim().toLowerCase();
|
||||
}
|
||||
|
||||
/* Does a heading only repeat the breadcrumb? A page title (h2) may repeat
|
||||
any crumb; a card heading (h3) only the page's or the tab's, never the
|
||||
category's: on Services > Dynamic DNS the "Services" table is content. */
|
||||
function repeatsTrail(key, tag, trail) {
|
||||
if (!key) return false;
|
||||
return (tag === 'H2' ? trail.all : trail.page).has(key);
|
||||
}
|
||||
|
||||
/* ---------------------------------------------------------------------------
|
||||
* Stock-page enhancers, only where CSS cannot restructure LuCI's markup
|
||||
* (Status -> Overview: fused memory bar, per-mount storage bars, radio band
|
||||
@@ -587,7 +595,7 @@ return baseclass.extend({
|
||||
this.closeTimer = null;
|
||||
this.openTimer = null;
|
||||
this.entries = [];
|
||||
this.trailKeys = new Set();
|
||||
this.trail = { all: new Set(), page: new Set() };
|
||||
|
||||
this.setupTheme();
|
||||
this.setupIndicators();
|
||||
@@ -670,8 +678,11 @@ return baseclass.extend({
|
||||
link.lastChild.setAttribute('class', 'vt-rail-caret');
|
||||
|
||||
link.addEventListener('click', ev => this.handleRailClick(ev, cat, li, link));
|
||||
/* hover opens a category; an open page switcher was opened on
|
||||
purpose, so passing over the rail leaves it be (a click on a
|
||||
category still swaps it) */
|
||||
li.addEventListener('pointerenter', ev => {
|
||||
if (ev.pointerType !== 'mouse' || this.isPinned() || this.mqMobile.matches) return;
|
||||
if (ev.pointerType !== 'mouse' || this.isPinned() || this.mqMobile.matches || this.switchOpen()) return;
|
||||
this.cancelClose();
|
||||
window.clearTimeout(this.openTimer);
|
||||
this.openTimer = window.setTimeout(() => this.openFlyout(cat, li, link, false), this.fly.hidden ? 90 : 0);
|
||||
@@ -679,6 +690,7 @@ return baseclass.extend({
|
||||
li.addEventListener('pointerleave', ev => {
|
||||
if (ev.pointerType !== 'mouse') return;
|
||||
window.clearTimeout(this.openTimer);
|
||||
if (this.isPinned() || this.switchOpen()) return;
|
||||
this.scheduleClose();
|
||||
});
|
||||
|
||||
@@ -701,13 +713,16 @@ return baseclass.extend({
|
||||
list.addEventListener('keydown', ev => this.handleRailKeys(ev, list));
|
||||
|
||||
fly.addEventListener('pointerenter', () => this.cancelClose());
|
||||
fly.addEventListener('pointerleave', ev => { if (ev.pointerType === 'mouse') this.scheduleClose(); });
|
||||
fly.addEventListener('pointerleave', ev => { if (ev.pointerType === 'mouse' && !fly.classList.contains('is-switch')) this.scheduleClose(); });
|
||||
fly.addEventListener('keydown', ev => this.handleFlyKeys(ev));
|
||||
/* the switcher closes once focus moves on past it (a null target is
|
||||
a click on nothing focusable, which the document click handles) */
|
||||
fly.addEventListener('focusout', ev => this.leaveSwitch(ev.relatedTarget));
|
||||
if (this.scrim) this.scrim.addEventListener('click', () => this.closeFlyout(false));
|
||||
|
||||
document.addEventListener('click', ev => {
|
||||
if (fly.hidden) return;
|
||||
if (ev.target.closest('#vt-flyout') || ev.target.closest('#vt-rail')) return;
|
||||
if (ev.target.closest('#vt-flyout') || ev.target.closest('#vt-rail') || ev.target.closest('.vt-crumb-switch')) return;
|
||||
this.closeFlyout(false);
|
||||
});
|
||||
|
||||
@@ -777,7 +792,8 @@ return baseclass.extend({
|
||||
handleFlyKeys(ev) {
|
||||
const links = Array.prototype.slice.call(this.fly.querySelectorAll('a'));
|
||||
const i = links.indexOf(document.activeElement);
|
||||
if (ev.key === 'Escape' || (ev.key === 'ArrowLeft' && !this.mqMobile.matches)) {
|
||||
const isSwitch = this.switchOpen();
|
||||
if (ev.key === 'Escape' || (ev.key === 'ArrowLeft' && !isSwitch && !this.mqMobile.matches)) {
|
||||
ev.preventDefault();
|
||||
this.closeFlyout(true);
|
||||
}
|
||||
@@ -787,15 +803,57 @@ return baseclass.extend({
|
||||
links[(i + d + links.length) % links.length].focus();
|
||||
}
|
||||
else if (ev.key === 'Tab' && links.length) {
|
||||
/* leaving the panel returns to the rail */
|
||||
const edge = ev.shiftKey ? 0 : links.length - 1;
|
||||
if (i === edge) { ev.preventDefault(); this.closeFlyout(true); }
|
||||
if (i !== edge) return;
|
||||
ev.preventDefault();
|
||||
/* the switcher reads as part of the top bar, after its crumb:
|
||||
Tab goes on to the next control there, Shift+Tab back to the
|
||||
crumb. The rail's flyout returns to its rail button. */
|
||||
if (isSwitch && !ev.shiftKey) {
|
||||
const btn = this.switchBtn;
|
||||
this.closeFlyout(false);
|
||||
this.focusAfter(btn);
|
||||
}
|
||||
else this.closeFlyout(true);
|
||||
}
|
||||
},
|
||||
|
||||
/* keys on the crumb switch: arrows open it (or enter it) at the current
|
||||
page; Tab from the open switch goes into its list */
|
||||
handleSwitchKeys(ev, cat, page, btn) {
|
||||
const down = ev.key === 'ArrowDown', up = ev.key === 'ArrowUp';
|
||||
if (!down && !up && !(ev.key === 'Tab' && !ev.shiftKey && this.switchOpen())) return;
|
||||
ev.preventDefault();
|
||||
if (!this.switchOpen()) { this.openSwitch(cat, page, btn, true); return; }
|
||||
const links = this.fly.querySelectorAll('a');
|
||||
const target = (ev.key === 'Tab' ? null : this.fly.querySelector('a[aria-current]')) ||
|
||||
(up ? links[links.length - 1] : links[0]);
|
||||
if (target) target.focus();
|
||||
},
|
||||
|
||||
switchOpen() {
|
||||
return !!(this.fly && !this.fly.hidden && this.fly.classList.contains('is-switch'));
|
||||
},
|
||||
|
||||
/* focus moved from the switch or its list to `to` */
|
||||
leaveSwitch(to) {
|
||||
if (!to || !this.switchOpen()) return;
|
||||
if (this.fly.contains(to) || to === this.switchBtn) return;
|
||||
this.closeFlyout(false);
|
||||
},
|
||||
|
||||
/* the control after `el` in tab order, outside the flyout */
|
||||
focusAfter(el) {
|
||||
const all = Array.prototype.filter.call(document.querySelectorAll('a[href], button, input, select, textarea, [tabindex]'), n =>
|
||||
n.tabIndex >= 0 && !n.disabled && n.type !== 'hidden' && !this.fly.contains(n) && n.getClientRects().length > 0);
|
||||
const next = all[all.indexOf(el) + 1];
|
||||
(next || el).focus();
|
||||
},
|
||||
|
||||
openFlyout(cat, li, link, focusFirst) {
|
||||
const fly = this.fly;
|
||||
this.cancelClose();
|
||||
this.endSwitch();
|
||||
if (fly.getAttribute('data-cat') !== cat.name || fly.hidden) {
|
||||
fly.textContent = '';
|
||||
const total = cat.pages.length;
|
||||
@@ -851,6 +909,7 @@ return baseclass.extend({
|
||||
this.cancelClose();
|
||||
this.fly.hidden = true;
|
||||
if (this.scrim) this.scrim.hidden = true;
|
||||
this.endSwitch();
|
||||
document.querySelectorAll('.vt-rail-item.is-open').forEach(n => {
|
||||
n.classList.remove('is-open');
|
||||
const b = n.querySelector('.vt-rail-link[aria-expanded]');
|
||||
@@ -859,6 +918,54 @@ return baseclass.extend({
|
||||
if (refocus && this.openLink) this.openLink.focus();
|
||||
},
|
||||
|
||||
/* the flyout, filled with a page's tabs: a dropdown under the crumb, the
|
||||
same bottom sheet as the rail's on phones */
|
||||
openSwitch(cat, page, btn, focusFirst) {
|
||||
const fly = this.fly;
|
||||
if (!fly) return;
|
||||
/* a rail hover may have left a timer behind; closeFlyout() skips
|
||||
cancelling it when the panel is hidden, so cancel both here */
|
||||
this.cancelClose();
|
||||
window.clearTimeout(this.openTimer);
|
||||
this.openTimer = null;
|
||||
this.closeFlyout(false);
|
||||
fly.textContent = '';
|
||||
const total = page.subs.length;
|
||||
fly.appendChild(E('div', { 'class': 'vt-fly-head' }, [
|
||||
svg(cat.icon, 18),
|
||||
E('span', { 'class': 'vt-fly-title', 'id': 'vt-fly-title' }, [ page.title ]),
|
||||
E('span', { 'class': 'vt-fly-count' }, [ '%d %s'.format(total, total === 1 ? _('page') : _('pages')) ])
|
||||
]));
|
||||
const ul = E('ul', { 'class': 'vt-fly-list', 'role': 'list' });
|
||||
for (const s of page.subs)
|
||||
ul.appendChild(E('li', {}, E('a', {
|
||||
'class': 'vt-fly-link', 'href': L.url('admin', cat.name, page.name, s.name), 'aria-current': this.dp[3] === s.name ? 'page' : null
|
||||
}, [ E('span', {}, [ s.title ]) ])));
|
||||
fly.appendChild(ul);
|
||||
fly.setAttribute('data-cat', '');
|
||||
fly.setAttribute('role', 'region');
|
||||
fly.setAttribute('aria-labelledby', 'vt-fly-title');
|
||||
|
||||
const x = Math.max(8, Math.min(btn.getBoundingClientRect().left - 8, window.innerWidth - 328));
|
||||
fly.style.setProperty('--x', x.toFixed(0) + 'px');
|
||||
fly.classList.add('is-switch');
|
||||
btn.setAttribute('aria-expanded', 'true');
|
||||
this.switchBtn = btn;
|
||||
this.openLink = btn;
|
||||
fly.hidden = false;
|
||||
if (this.scrim) this.scrim.hidden = !this.mqMobile.matches;
|
||||
|
||||
if (focusFirst) {
|
||||
const first = fly.querySelector('a[aria-current]') || fly.querySelector('a');
|
||||
if (first) first.focus();
|
||||
}
|
||||
},
|
||||
|
||||
endSwitch() {
|
||||
if (this.fly) this.fly.classList.remove('is-switch');
|
||||
if (this.switchBtn) this.switchBtn.setAttribute('aria-expanded', 'false');
|
||||
},
|
||||
|
||||
scheduleClose() {
|
||||
this.cancelClose();
|
||||
this.closeTimer = window.setTimeout(() => this.closeFlyout(false), 220);
|
||||
@@ -883,17 +990,43 @@ return baseclass.extend({
|
||||
}
|
||||
if (!parts.length) return;
|
||||
|
||||
/* a page with page tabs: its current crumb switches between them,
|
||||
from the top bar, which stays in view while the tabs scroll away */
|
||||
const cat = this.cats.find(c => c.name === this.dp[1]);
|
||||
const page = cat && this.dp.length > 3 ? cat.pages.find(p => p.name === this.dp[2]) : null;
|
||||
const siblings = page && page.subs.length > 1 ? page : null;
|
||||
|
||||
nav.textContent = '';
|
||||
parts.forEach((p, i) => {
|
||||
const last = i === parts.length - 1;
|
||||
if (i) nav.appendChild(E('span', { 'class': 'vt-crumb-sep', 'aria-hidden': 'true' }, [ '›' ]));
|
||||
nav.appendChild(last
|
||||
if (last && siblings && parts.length === 3) {
|
||||
/* a disclosure (aria-expanded + aria-controls): the panel is a
|
||||
region of links, not a menu, so no aria-haspopup */
|
||||
const btn = E('button', {
|
||||
'type': 'button', 'class': 'vt-crumb vt-crumb-current vt-crumb-switch', 'aria-current': 'page',
|
||||
'aria-expanded': 'false', 'aria-controls': 'vt-flyout',
|
||||
'title': _('Other pages in %s').format(siblings.title)
|
||||
}, [ E('span', {}, [ p.title ]), svg('caret', 14) ]);
|
||||
btn.addEventListener('click', ev => {
|
||||
if (this.switchOpen()) this.closeFlyout(true);
|
||||
else this.openSwitch(cat, siblings, btn, ev.detail === 0);
|
||||
});
|
||||
btn.addEventListener('keydown', ev => this.handleSwitchKeys(ev, cat, siblings, btn));
|
||||
btn.addEventListener('focusout', ev => this.leaveSwitch(ev.relatedTarget));
|
||||
nav.appendChild(btn);
|
||||
}
|
||||
else nav.appendChild(last
|
||||
? E('span', { 'class': 'vt-crumb vt-crumb-current', 'aria-current': 'page' }, [ p.title ])
|
||||
: E('a', { 'class': 'vt-crumb', 'href': L.url.apply(L, p.segs) }, [ p.title ]));
|
||||
});
|
||||
|
||||
this.pageTitle = parts[parts.length - 1].title;
|
||||
parts.forEach(p => this.trailKeys.add(headingKey(p.title)));
|
||||
parts.forEach((p, i) => {
|
||||
this.trail.all.add(headingKey(p.title));
|
||||
/* the category, unless it is the page itself */
|
||||
if (i || parts.length === 1) this.trail.page.add(headingKey(p.title));
|
||||
});
|
||||
this.updateTitle();
|
||||
},
|
||||
|
||||
@@ -906,17 +1039,16 @@ return baseclass.extend({
|
||||
const tabs = ui.menu.getChildren(page);
|
||||
if (tabs.length < 2) return;
|
||||
|
||||
bar.textContent = '';
|
||||
const seg = E('div', { 'class': 'vt-pagetabs' });
|
||||
for (const t of tabs) {
|
||||
const cur = this.dp[3] === t.name;
|
||||
bar.appendChild(E('a', {
|
||||
seg.appendChild(E('a', {
|
||||
'class': 'vt-tab', 'href': L.url('admin', this.dp[1], this.dp[2], t.name), 'aria-current': cur ? 'page' : null
|
||||
}, [ _(t.title) ]));
|
||||
}
|
||||
bar.textContent = '';
|
||||
bar.appendChild(seg);
|
||||
bar.hidden = false;
|
||||
const active = bar.querySelector('[aria-current]');
|
||||
if (active && active.scrollIntoView && bar.scrollWidth > bar.clientWidth)
|
||||
bar.scrollLeft = active.offsetLeft - 16;
|
||||
},
|
||||
|
||||
/* ------------------------------------------------------ palette */
|
||||
@@ -954,8 +1086,11 @@ return baseclass.extend({
|
||||
|
||||
openPalette() {
|
||||
if (this.pal) return;
|
||||
/* focus inside the flyout goes back to what opened the flyout, since
|
||||
closing it hides the element that had focus */
|
||||
const from = document.activeElement;
|
||||
this.palReturn = (this.fly && this.fly.contains(from)) ? this.openLink : from;
|
||||
this.closeFlyout(false);
|
||||
this.palReturn = document.activeElement;
|
||||
|
||||
const input = E('input', {
|
||||
'class': 'vt-pal-input', 'type': 'text', 'role': 'combobox', 'aria-expanded': 'true',
|
||||
@@ -1238,7 +1373,7 @@ return baseclass.extend({
|
||||
setupForms() {
|
||||
this.formsQueued = false;
|
||||
this.helpSeq = 0;
|
||||
this.helpSizes = window.ResizeObserver ? new ResizeObserver(entries => entries.forEach(e => this.fitHelp(e.target))) : null;
|
||||
this.helpSizes = window.ResizeObserver ? new ResizeObserver(entries => this.fitHelps(entries.map(e => e.target))) : null;
|
||||
if (window.MutationObserver)
|
||||
new MutationObserver(() => this.queueForms()).observe(document.body, { childList: true, subtree: true });
|
||||
this.decorateForms();
|
||||
@@ -1319,14 +1454,26 @@ return baseclass.extend({
|
||||
not displayed (another tab, an unmet dependency) measures 0 and waits
|
||||
for the next resize notification. */
|
||||
fitHelp(desc) {
|
||||
if (!desc.isConnected) {
|
||||
if (this.helpSizes) this.helpSizes.unobserve(desc);
|
||||
return;
|
||||
this.fitHelps([ desc ]);
|
||||
},
|
||||
|
||||
/* all sizes are read before any button changes: a write between two
|
||||
reads forced a layout per field (66 when the Wireless modal opened) */
|
||||
fitHelps(descs) {
|
||||
const fits = [];
|
||||
for (const desc of descs) {
|
||||
if (!desc.isConnected) {
|
||||
if (this.helpSizes) this.helpSizes.unobserve(desc);
|
||||
continue;
|
||||
}
|
||||
const h = desc._vtHelp;
|
||||
if (!h || !h.btn.isConnected || !desc.clientHeight) continue;
|
||||
fits.push([ h, desc.scrollHeight > desc.clientHeight + 1 ]);
|
||||
}
|
||||
for (const [ h, cut ] of fits) {
|
||||
const hide = !cut && h.holder.getAttribute('data-v-help') !== 'open';
|
||||
if (h.btn.hidden !== hide) h.btn.hidden = hide;
|
||||
}
|
||||
const h = desc._vtHelp;
|
||||
if (!h || !h.btn.isConnected || !desc.clientHeight) return;
|
||||
const cut = desc.scrollHeight > desc.clientHeight + 1;
|
||||
h.btn.hidden = !cut && h.holder.getAttribute('data-v-help') !== 'open';
|
||||
},
|
||||
|
||||
/* A page title or card heading that only repeats the breadcrumb, the
|
||||
@@ -1338,7 +1485,7 @@ return baseclass.extend({
|
||||
document.querySelectorAll('#maincontent > h2, #view h2, #view .cbi-section > h3:first-child').forEach(h => {
|
||||
if (h.closest('.vt-app') || h.querySelector('a, button, input, select, [data-clickable], [tabindex]')) return;
|
||||
const key = headingKey(h.textContent);
|
||||
let repeat = this.trailKeys.has(key);
|
||||
let repeat = repeatsTrail(key, h.tagName, this.trail);
|
||||
if (!repeat && h.tagName === 'H3') {
|
||||
const map = h.closest('.cbi-map');
|
||||
const mapTitle = map && map.querySelector(':scope > h2');
|
||||
|
||||
@@ -69,14 +69,17 @@
|
||||
--warn-soft: rgba(214, 138, 0, .15);
|
||||
--err: #c42b2b;
|
||||
--err-soft: rgba(196, 43, 43, .1);
|
||||
--err-ink: #ffffff; /* text on an --err / --info fill, >= 4.5:1 */
|
||||
--info: #1c64c4;
|
||||
--info-ink: #ffffff;
|
||||
--ok-text: #0a7262; /* --ok as text on control fills (s3, s4) */
|
||||
--info-soft: rgba(28, 100, 196, .1);
|
||||
--scrim: rgba(20, 23, 26, .38);
|
||||
--shadow-pop: 0 12px 32px rgba(20, 23, 26, .16), 0 2px 6px rgba(20, 23, 26, .08);
|
||||
--zone-mix: .22;
|
||||
--seg-bg: var(--s3); /* segmented control: track, selected segment */
|
||||
--seg-on: var(--s2);
|
||||
--seg-on-ring: 0 0 0 1px var(--line), var(--v-shadow);
|
||||
--seg-on-ring: inset 0 0 0 1px var(--line); /* inset: drawn at the segment's padding edge */
|
||||
}
|
||||
|
||||
html[data-darkmode="true"] {
|
||||
@@ -107,14 +110,17 @@ html[data-darkmode="true"] {
|
||||
--warn-soft: rgba(245, 184, 74, .13);
|
||||
--err: #ff6b6b;
|
||||
--err-soft: rgba(255, 107, 107, .12);
|
||||
--err-ink: #1a0505; /* white on the light dark-mode red was 2.8:1 */
|
||||
--info: #6cb4ff;
|
||||
--info-ink: #0d0e10;
|
||||
--ok-text: var(--ok);
|
||||
--info-soft: rgba(108, 180, 255, .12);
|
||||
--scrim: rgba(0, 0, 0, .58);
|
||||
--shadow-pop: 0 16px 40px rgba(0, 0, 0, .55), 0 0 0 1px rgba(255, 255, 255, .02);
|
||||
--zone-mix: .2;
|
||||
--seg-bg: var(--bg);
|
||||
--seg-on: var(--s3);
|
||||
--seg-on-ring: 0 0 0 1px var(--line-2);
|
||||
--seg-on-ring: inset 0 0 0 1px var(--line-2);
|
||||
}
|
||||
|
||||
/* touch: controls are sized by the pointer, not the screen width */
|
||||
@@ -161,7 +167,7 @@ html[data-darkmode="true"] {
|
||||
--v-r-lg: var(--r-lg);
|
||||
--v-ctl-h: var(--ctl-h); /* every control: 36px, 44px on touch */
|
||||
--v-shadow: 0 1px 2px rgba(20, 23, 26, .06), 0 1px 0 rgba(20, 23, 26, .03);
|
||||
/* where sticky content may start: below the top bar and page tabs */
|
||||
/* where sticky content may start: below the top bar (page tabs scroll) */
|
||||
--v-stick-top: var(--stick-top);
|
||||
|
||||
/* charts (stock realtime graphs, channel analysis, the dashboard app).
|
||||
@@ -429,7 +435,7 @@ html[data-rail="pinned"] .vt-frame { margin-left: var(--rail-w-pinned); }
|
||||
.vt-fly-list > li + li { margin-top: 1px; }
|
||||
.vt-fly-link {
|
||||
display: flex; align-items: center; gap: var(--sp-2);
|
||||
min-height: 34px; padding: 6px 10px;
|
||||
min-height: var(--ctl-h); padding: 6px 10px;
|
||||
border-radius: var(--r);
|
||||
color: var(--text);
|
||||
text-decoration: none !important;
|
||||
@@ -475,16 +481,49 @@ html[data-rail="pinned"] .vt-frame { margin-left: var(--rail-w-pinned); }
|
||||
|
||||
.vt-crumbs {
|
||||
display: flex; align-items: center; gap: 6px;
|
||||
min-width: 0; flex: 1 1 auto;
|
||||
min-width: 0; flex: 1 .001 auto; /* gives way last: see .vt-top-actions */
|
||||
align-self: stretch; /* the bar's height: room for focus rings */
|
||||
margin-inline: -8px; padding-inline: 8px; /* room for the switch's ring (it sits 6px out) */
|
||||
font-size: var(--fs-base);
|
||||
white-space: nowrap; overflow: hidden;
|
||||
}
|
||||
.vt-crumb { color: var(--text-2); overflow: hidden; text-overflow: ellipsis; text-decoration: none !important; }
|
||||
/* a link crumb is a control high to click; the padding adds no height to the bar */
|
||||
a.vt-crumb { padding-block: calc((var(--ctl-h) - 1.5em) / 2); }
|
||||
a.vt-crumb:hover { color: var(--text); }
|
||||
.vt-crumb-current { color: var(--text); font-weight: 600; }
|
||||
.vt-crumb-sep { color: var(--text-3); flex: none; font-family: var(--mono); font-size: var(--fs-sm); }
|
||||
/* the current crumb of a page with page tabs: opens its sibling pages.
|
||||
A control high; the ring sits on its edge, inside the crumbs' clip. */
|
||||
.vt-crumb-switch {
|
||||
display: inline-flex; align-items: center; gap: 4px;
|
||||
min-width: 0; min-height: var(--ctl-h); margin: 0 -6px; padding: 0 6px;
|
||||
border: 0; border-radius: var(--r);
|
||||
background: none;
|
||||
font: inherit; font-weight: 600; color: var(--text);
|
||||
cursor: pointer;
|
||||
}
|
||||
.vt-crumb-switch > span { overflow: hidden; text-overflow: ellipsis; }
|
||||
.vt-crumb-switch > svg { flex: none; width: 14px; height: 14px; color: var(--text-3); transition: transform .15s; }
|
||||
.vt-crumb-switch:hover, .vt-crumb-switch[aria-expanded="true"] { background: var(--s3); }
|
||||
.vt-crumb-switch:focus-visible { outline-offset: 0; }
|
||||
.vt-crumb-switch[aria-expanded="true"] > svg { transform: rotate(90deg); }
|
||||
@media (width > 720px) {
|
||||
/* the flyout as a dropdown under the crumb (left: set from the crumb) */
|
||||
.vt-flyout.is-switch {
|
||||
top: calc(var(--top-h) - 4px); bottom: auto; left: var(--x, var(--rail-w));
|
||||
width: auto; min-width: 240px; max-width: 320px;
|
||||
max-height: calc(100vh - var(--top-h) - var(--sp-4));
|
||||
border: 1px solid var(--line-2); border-radius: var(--r-lg);
|
||||
animation: vt-drop-in .12s ease-out;
|
||||
}
|
||||
}
|
||||
@keyframes vt-drop-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
|
||||
|
||||
.vt-top-actions { display: flex; align-items: center; gap: var(--sp-2); flex: none; }
|
||||
/* when the bar is short of room, the host chip gives way first, then the
|
||||
search field's label, and only then the crumbs */
|
||||
.vt-top-actions { display: flex; align-items: center; gap: var(--sp-2); flex: 0 1 auto; min-width: 0; }
|
||||
.vt-top-actions > :not(.vt-host, .vt-search) { flex: none; }
|
||||
|
||||
.vt-search {
|
||||
display: inline-flex; align-items: center; gap: var(--sp-2);
|
||||
@@ -522,6 +561,7 @@ a.vt-crumb:hover { color: var(--text); }
|
||||
.vt-host {
|
||||
display: inline-flex; align-items: center; gap: 6px;
|
||||
height: 28px; max-width: 300px;
|
||||
flex: 0 1000 auto; min-width: 0; overflow: hidden;
|
||||
padding: 0 10px;
|
||||
border: 1px solid var(--line); border-radius: 999px;
|
||||
background: var(--s1);
|
||||
@@ -547,18 +587,30 @@ a.vt-crumb:hover { color: var(--text); }
|
||||
}
|
||||
#indicators > span[data-clickable] { cursor: pointer; }
|
||||
#indicators > span[data-clickable]:hover { border-color: var(--text-3); color: var(--text); }
|
||||
#indicators > span[data-indicator="poll-status"][data-style="active"] { position: relative; isolation: isolate; }
|
||||
#indicators > span[data-indicator="poll-status"][data-style="active"]::before {
|
||||
content: ""; width: 7px; height: 7px; border-radius: 50%;
|
||||
background: var(--accent-text);
|
||||
box-shadow: 0 0 0 0 var(--accent-line);
|
||||
}
|
||||
/* the pulse is a ring of its own that scales and fades: the compositor
|
||||
runs it, where an animated box-shadow repainted the page every frame.
|
||||
It sits behind the dot (z-index -1 in the pill's isolated stack), so
|
||||
the dot never lightens, and is invisible unless animated: with reduced
|
||||
motion the one near-instant run ends on opacity 0. */
|
||||
#indicators > span[data-indicator="poll-status"][data-style="active"]::after {
|
||||
content: ""; position: absolute; z-index: -1; left: 10px; top: calc(50% - 3.5px);
|
||||
width: 7px; height: 7px; border-radius: 50%;
|
||||
background: var(--accent-line);
|
||||
opacity: 0;
|
||||
pointer-events: none;
|
||||
animation: vt-live 2s ease-out infinite;
|
||||
}
|
||||
#indicators > span[data-indicator="poll-status"][data-style="inactive"]::before {
|
||||
content: ""; width: 7px; height: 7px; border-radius: 1px; background: var(--text-3);
|
||||
}
|
||||
@keyframes vt-live {
|
||||
0% { box-shadow: 0 0 0 0 var(--accent-line); }
|
||||
70%, 100% { box-shadow: 0 0 0 6px transparent; }
|
||||
0% { transform: scale(1); opacity: 1; }
|
||||
70%, 100% { transform: scale(2.7); opacity: 0; }
|
||||
}
|
||||
/* "Unsaved Changes: N" -> label + prominent count (text node stays for LuCI) */
|
||||
#indicators > span[data-indicator][data-count] {
|
||||
@@ -580,35 +632,14 @@ a.vt-crumb:hover { color: var(--text); }
|
||||
}
|
||||
#indicators > span[data-indicator="media_error"] { color: var(--err); border-color: var(--err); background: var(--err-soft); }
|
||||
|
||||
/* level-3 page tabs */
|
||||
/* level-3 page tabs: on the content column, drawn as every other tab
|
||||
level (.vt-pagetabs shares the .cbi-tabmenu rules below). They scroll with
|
||||
the page; the current crumb in the top bar switches between them. */
|
||||
.vt-tabs {
|
||||
position: sticky; top: var(--top-h); z-index: 190;
|
||||
display: flex; gap: var(--sp-1);
|
||||
padding: 0 var(--sp-5);
|
||||
background: color-mix(in srgb, var(--bg) 92%, transparent);
|
||||
backdrop-filter: blur(10px);
|
||||
-webkit-backdrop-filter: blur(10px);
|
||||
border-bottom: 1px solid var(--line);
|
||||
overflow-x: auto;
|
||||
scrollbar-width: none;
|
||||
}
|
||||
.vt-tabs::-webkit-scrollbar { display: none; }
|
||||
.vt-tab {
|
||||
position: relative;
|
||||
display: inline-flex; align-items: center;
|
||||
height: var(--ctl-h); padding: 0 var(--sp-3);
|
||||
color: var(--text-2);
|
||||
font-weight: 500;
|
||||
white-space: nowrap;
|
||||
text-decoration: none !important;
|
||||
}
|
||||
.vt-tab:hover { color: var(--text); }
|
||||
.vt-tab[aria-current] { color: var(--text); font-weight: 600; }
|
||||
.vt-tab[aria-current]::after {
|
||||
content: ""; position: absolute; left: var(--sp-3); right: var(--sp-3); bottom: -1px;
|
||||
height: 2px; border-radius: 2px 2px 0 0;
|
||||
background: var(--accent-text);
|
||||
width: 100%; max-width: calc(var(--content-max) + 2 * var(--sp-6));
|
||||
margin: 0 auto; padding: var(--sp-6) var(--sp-6) 0;
|
||||
}
|
||||
.vt-tabs:not([hidden]) + .vt-main { padding-top: var(--sp-5); }
|
||||
|
||||
/* content column */
|
||||
.vt-main {
|
||||
@@ -712,7 +743,6 @@ a.vt-crumb:hover { color: var(--text); }
|
||||
/* page = title block + a stack of cards. Cards carry a full-bleed header
|
||||
row (h3) and full-bleed tables; nested sections lose their chrome. */
|
||||
:root { --card-px: 20px; --card-py: 16px; --stick-top: var(--top-h); }
|
||||
html:has(.vt-tabs:not([hidden])) { --stick-top: calc(var(--top-h) + var(--ctl-h) + 1px); }
|
||||
|
||||
.cbi-map { margin-bottom: var(--sp-6); }
|
||||
.cbi-map > h2, .vt-main > h2, #view > h2, #view > div > h2:first-child, .cbi-map > h2:first-child {
|
||||
@@ -884,6 +914,8 @@ legend { font-size: var(--fs-md); font-weight: 600; padding: 0; margin-bottom: v
|
||||
.cbi-section-create > * { margin: 0; }
|
||||
.cbi-section-create > .cbi-section-create-name { max-width: 240px; }
|
||||
.cbi-section-remove { text-align: right; padding: var(--sp-2) 0; }
|
||||
/* several nodes of one typed section in a card: a rule between them */
|
||||
.cbi-section-node + :is(.cbi-section-node, .cbi-section-remove) { margin-top: var(--sp-5); padding-top: var(--sp-5); border-top: 1px solid var(--line); }
|
||||
|
||||
/* page actions: a floating command bar docked to the bottom right */
|
||||
.cbi-page-actions {
|
||||
@@ -905,6 +937,13 @@ legend { font-size: var(--fs-md); font-weight: 600; padding: 0; margin-bottom: v
|
||||
.cbi-page-actions .cbi-button-save { order: 2; }
|
||||
.cbi-page-actions .cbi-button-apply, .cbi-page-actions .cbi-dropdown { order: 3; }
|
||||
.cbi-page-actions:empty { display: none; }
|
||||
/* the bar sits at the bottom of the view (docked, or the page's end), so
|
||||
its Save & Apply menu opens upwards; LuCI's touch branch would open it
|
||||
down, under the phone's bottom bar and past the screen */
|
||||
.cbi-page-actions .cbi-dropdown[open] > ul.dropdown {
|
||||
top: auto !important; bottom: 100% !important;
|
||||
max-height: 50vh !important;
|
||||
}
|
||||
|
||||
/* ------------------------------------------------------------ 6. widgets */
|
||||
|
||||
@@ -929,6 +968,8 @@ input, select, textarea, button { font: inherit; color: inherit; }
|
||||
transition: border-color .12s, box-shadow .12s;
|
||||
}
|
||||
.vt-main textarea, .cbi-input-textarea, .modal textarea { max-width: calc(2 * var(--field-max)); min-height: 88px; font-family: var(--mono); font-size: var(--fs-sm); resize: vertical; }
|
||||
/* read-only text (System and Kernel log) is a viewer, not a field: full width */
|
||||
.vt-main textarea[readonly] { max-width: none; }
|
||||
.vt-main select, .cbi-input-select, .modal select {
|
||||
appearance: none; -webkit-appearance: none;
|
||||
padding-right: 30px;
|
||||
@@ -953,6 +994,15 @@ input:focus, select:focus, textarea:focus {
|
||||
box-shadow: 0 0 0 3px var(--accent-soft);
|
||||
}
|
||||
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: none; }
|
||||
/* fields in pages, modals and the login: the rules above lose to the field
|
||||
rules' (0,2,1), so hover and focus are restated at their weight. Focus:
|
||||
a --focus border plus a 1px ring of it (>= 3:1 against the field and
|
||||
the card in both modes) and the soft halo. The dashboard styles its own. */
|
||||
:is(input, select, textarea):not([type="checkbox"], [type="radio"], [type="range"], .vt-pal-input, .vt-app *):hover { border-color: var(--text-3); }
|
||||
:is(input, select, textarea):not([type="checkbox"], [type="radio"], [type="range"], .vt-pal-input, .vt-app *):focus {
|
||||
border-color: var(--focus);
|
||||
box-shadow: 0 0 0 1px var(--focus), 0 0 0 4px var(--accent-soft);
|
||||
}
|
||||
input[disabled], select[disabled], textarea[disabled], input[readonly] { opacity: .6; cursor: not-allowed; }
|
||||
input[readonly] { cursor: default; }
|
||||
|
||||
@@ -975,6 +1025,9 @@ input[readonly] { cursor: default; }
|
||||
.control-group > :not(:last-child) { border-top-right-radius: 0 !important; border-bottom-right-radius: 0 !important; }
|
||||
.control-group > :not(:first-child) { border-top-left-radius: 0 !important; border-bottom-left-radius: 0 !important; }
|
||||
.control-group > .btn, .control-group > .cbi-button { flex: none; }
|
||||
/* in LuCI's unclassed field wrapper (a flex row) the group sized to its
|
||||
content, 254px for a password with its reveal button: as wide as a field */
|
||||
.cbi-value-field > div:not([class]) > .control-group { flex: 1 1 auto; }
|
||||
|
||||
/* checkbox */
|
||||
.cbi-checkbox { display: inline-flex; align-items: center; min-height: var(--ctl-h); gap: var(--sp-2); }
|
||||
@@ -1054,7 +1107,7 @@ input[type="button"], input[type="reset"], input[type="submit"]) {
|
||||
vertical-align: middle;
|
||||
}
|
||||
.cbi-dropdown:hover { border-color: var(--text-3); }
|
||||
.cbi-dropdown:focus, .cbi-dropdown[open] { border-color: var(--accent-line); box-shadow: 0 0 0 3px var(--accent-soft); }
|
||||
.cbi-dropdown:focus, .cbi-dropdown[open] { border-color: var(--focus); box-shadow: 0 0 0 1px var(--focus), 0 0 0 4px var(--accent-soft); }
|
||||
.cbi-dropdown:focus-visible { outline: none; }
|
||||
.cbi-dropdown[disabled] { opacity: .55; pointer-events: none; }
|
||||
|
||||
@@ -1229,15 +1282,15 @@ input[type="button"], input[type="reset"], input[type="submit"]) {
|
||||
}
|
||||
.cbi-value-field :is(.btn, .cbi-button).cbi-button-apply:hover,
|
||||
.td :is(.btn, .cbi-button).cbi-button-apply:hover { background: color-mix(in srgb, var(--accent) 20%, transparent); color: var(--accent-text); }
|
||||
:is(.btn, .cbi-button).cbi-button-positive:not(.important) { color: var(--ok); }
|
||||
:is(.btn, .cbi-button).cbi-button-positive:not(.important) { color: var(--ok-text); }
|
||||
:is(.btn, .cbi-button, .cbi-dropdown):is(.cbi-button-negative, .cbi-button-remove) {
|
||||
background: transparent;
|
||||
color: var(--err);
|
||||
border-color: color-mix(in srgb, var(--err) 40%, var(--line-2));
|
||||
}
|
||||
:is(.btn, .cbi-button, .cbi-dropdown):is(.cbi-button-negative, .cbi-button-remove):hover { background: var(--err-soft); border-color: var(--err); }
|
||||
:is(.btn, .cbi-button, .cbi-dropdown).cbi-button-negative.important { background: var(--err); border-color: var(--err); color: #fff; }
|
||||
:is(.btn, .cbi-button, .cbi-dropdown).cbi-button-negative.important:hover { background: color-mix(in srgb, var(--err) 85%, #000); color: #fff; }
|
||||
:is(.btn, .cbi-button, .cbi-dropdown).cbi-button-negative.important { background: var(--err); border-color: var(--err); color: var(--err-ink); }
|
||||
:is(.btn, .cbi-button, .cbi-dropdown).cbi-button-negative.important:hover { background: color-mix(in srgb, var(--err) 88%, var(--err-ink)); color: var(--err-ink); }
|
||||
:is(.btn, .cbi-button).cbi-button-reset { background: transparent; color: var(--text-2); }
|
||||
:is(.btn, .cbi-button).cbi-button-reset:hover { color: var(--text); }
|
||||
|
||||
@@ -1397,119 +1450,45 @@ div.right, div.left { display: block; }
|
||||
div.right { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: var(--sp-2); margin-top: var(--sp-4); }
|
||||
div.right > .btn, div.right > .cbi-button, div.right > button { margin-left: 0; }
|
||||
|
||||
/* Tabs inside a page (ui.tabs), one look per level:
|
||||
- tabs standing at page level (not inside a form section or another
|
||||
tab) are the page's sub-pages when the menu shows no page tabs: they
|
||||
take the page-tab underline, like .vt-tabs (Interfaces / Devices /
|
||||
..., DHCP's Leases / dnsmasq, Channel Analysis's radios). Under
|
||||
.vt-tabs they are the first level inside the page instead;
|
||||
- the first level inside a page, form or modal: a segmented control;
|
||||
- tabs inside a tab: a side list where the pane is wide enough
|
||||
(container query on the pane, so modals and pages alike), chips
|
||||
where it is not and at every deeper level.
|
||||
A level is a pane of a section's option tabs (.cbi-section-node-tabbed);
|
||||
map-level panes are not counted, so a page's sub-pages add no level. */
|
||||
.cbi-tabmenu {
|
||||
display: flex; flex-wrap: nowrap; align-items: center; gap: 2px;
|
||||
/* Tabs: one segmented control for every level, the menu's page tabs
|
||||
(.vt-pagetabs in #vt-tabs), ui.tabs at page level, in a form or modal,
|
||||
and tabs inside a tab. Nesting shows by where a control sits, not by
|
||||
another look. It wraps its segments instead of hiding them. Every
|
||||
segment is a whole control high (--ctl-h, 36px / 44px on touch) to
|
||||
click or tap: the 3px between the track's edge and the drawn segment
|
||||
is the segment's own transparent border, so the track is one control
|
||||
high as well. */
|
||||
.cbi-tabmenu, .vt-tabs > .vt-pagetabs {
|
||||
display: flex; flex-wrap: wrap; align-items: stretch;
|
||||
width: fit-content; max-width: 100%; min-height: var(--ctl-h);
|
||||
margin: 0 0 var(--sp-5); padding: 2px;
|
||||
margin: 0 0 var(--sp-5); padding: 0;
|
||||
list-style: none;
|
||||
background: var(--seg-bg);
|
||||
border: 1px solid var(--line);
|
||||
border-radius: var(--r-lg);
|
||||
overflow-x: auto;
|
||||
scrollbar-width: none;
|
||||
box-shadow: inset 0 0 0 1px var(--line);
|
||||
}
|
||||
.cbi-tabmenu::-webkit-scrollbar { display: none; }
|
||||
.cbi-tabmenu > li { position: relative; flex: none; }
|
||||
.cbi-tabmenu > li > a {
|
||||
.vt-tabs > .vt-pagetabs { margin: 0; }
|
||||
.cbi-tabmenu > li { position: relative; flex: none; display: flex; max-width: 100%; }
|
||||
.cbi-tabmenu > li > a, .vt-pagetabs > .vt-tab {
|
||||
flex: 1 1 auto;
|
||||
display: flex; align-items: center; gap: 6px;
|
||||
height: calc(var(--ctl-h) - 6px); padding: 0 var(--sp-3);
|
||||
border-radius: var(--r);
|
||||
min-height: var(--ctl-h); padding: 0 10px;
|
||||
border: 3px solid transparent; background-clip: padding-box;
|
||||
border-radius: calc(var(--r) + 3px);
|
||||
color: var(--text-2);
|
||||
font-weight: 500;
|
||||
white-space: nowrap;
|
||||
text-decoration: none !important;
|
||||
}
|
||||
.cbi-tabmenu > li > a:hover { color: var(--text); }
|
||||
.cbi-tabmenu > li.cbi-tab > a { background: var(--seg-on); color: var(--text); font-weight: 600; box-shadow: var(--seg-on-ring); }
|
||||
|
||||
html:not(:has(.vt-tabs:not([hidden]))) #view .cbi-tabmenu:not(.cbi-section *, [data-tab-title] *) {
|
||||
gap: var(--sp-1);
|
||||
width: auto; padding: 0;
|
||||
background: none; border: 0; border-bottom: 1px solid var(--line); border-radius: 0;
|
||||
}
|
||||
html:not(:has(.vt-tabs:not([hidden]))) #view .cbi-tabmenu:not(.cbi-section *, [data-tab-title] *) > li > a { height: var(--ctl-h); border-radius: 0; }
|
||||
html:not(:has(.vt-tabs:not([hidden]))) #view .cbi-tabmenu:not(.cbi-section *, [data-tab-title] *) > li.cbi-tab > a { background: none; box-shadow: none; }
|
||||
html:not(:has(.vt-tabs:not([hidden]))) #view .cbi-tabmenu:not(.cbi-section *, [data-tab-title] *) > li.cbi-tab::after {
|
||||
content: ""; position: absolute; left: var(--sp-3); right: var(--sp-3); bottom: 0;
|
||||
height: 2px; background: var(--accent-text); border-radius: 2px 2px 0 0;
|
||||
}
|
||||
|
||||
.cbi-section-node-tabbed > [data-tab-title] { container-type: inline-size; }
|
||||
.cbi-section-node-tabbed > [data-tab-title] .cbi-tabmenu {
|
||||
flex-wrap: wrap; gap: var(--sp-2);
|
||||
width: auto; margin-bottom: var(--sp-4); padding: 0;
|
||||
background: none; border: 0; border-radius: 0;
|
||||
overflow: visible;
|
||||
}
|
||||
.cbi-section-node-tabbed > [data-tab-title] .cbi-tabmenu > li > a {
|
||||
height: var(--ctl-h); padding: 0 14px;
|
||||
border: 1px solid var(--line-2); border-radius: 999px;
|
||||
}
|
||||
.cbi-section-node-tabbed > [data-tab-title] .cbi-tabmenu > li.cbi-tab > a {
|
||||
background: var(--accent-soft); border-color: var(--accent-line);
|
||||
color: var(--accent-text); box-shadow: none;
|
||||
}
|
||||
@container (min-width: 640px) {
|
||||
.cbi-section-node-tabbed > [data-tab-title] :has(> .cbi-tabmenu) {
|
||||
display: grid;
|
||||
grid-template-columns: 168px minmax(0, 1fr);
|
||||
column-gap: var(--sp-6);
|
||||
align-items: start;
|
||||
}
|
||||
.cbi-section-node-tabbed > [data-tab-title] :has(> .cbi-tabmenu) > * { grid-column: 1 / -1; }
|
||||
.cbi-section-node-tabbed > [data-tab-title] :has(> .cbi-tabmenu) > .cbi-tabmenu + * { grid-column: 2; }
|
||||
.cbi-section-node-tabbed > [data-tab-title] .cbi-tabmenu {
|
||||
grid-column: 1;
|
||||
flex-direction: column; flex-wrap: nowrap; align-items: stretch; gap: 2px;
|
||||
margin: 0;
|
||||
}
|
||||
.cbi-section-node-tabbed > [data-tab-title] .cbi-tabmenu > li > a {
|
||||
justify-content: space-between;
|
||||
padding: 0 var(--sp-3);
|
||||
border: 0; border-radius: var(--r);
|
||||
white-space: normal; line-height: 1.25;
|
||||
}
|
||||
.cbi-section-node-tabbed > [data-tab-title] .cbi-tabmenu > li > a:hover { background: var(--s3); }
|
||||
.cbi-section-node-tabbed > [data-tab-title] .cbi-tabmenu > li.cbi-tab > a { background: var(--accent-soft); box-shadow: inset 2px 0 0 var(--accent-line); }
|
||||
/* beside the list there is no card edge to bleed to: table sections and
|
||||
tables fit the column */
|
||||
.cbi-section-node-tabbed > [data-tab-title] :has(> .cbi-tabmenu) > .cbi-tabmenu + * .cbi-tblsection { margin-left: 0; margin-right: 0; padding-left: 0; padding-right: 0; }
|
||||
.cbi-section-node-tabbed > [data-tab-title] :has(> .cbi-tabmenu) > .cbi-tabmenu + * .table { width: 100% !important; margin-left: 0; margin-right: 0; }
|
||||
.cbi-section-node-tabbed > [data-tab-title] :has(> .cbi-tabmenu) > .cbi-tabmenu + * .table .tr > :is(.th, .td):first-child { padding-left: 0; }
|
||||
.cbi-section-node-tabbed > [data-tab-title] :has(> .cbi-tabmenu) > .cbi-tabmenu + * .table .tr > :is(.th, .td):last-child { padding-right: 0; }
|
||||
/* deeper levels: back to the chips above */
|
||||
.cbi-section-node-tabbed > [data-tab-title] .cbi-section-node-tabbed > [data-tab-title] :has(> .cbi-tabmenu) { display: block; }
|
||||
.cbi-section-node-tabbed > [data-tab-title] .cbi-section-node-tabbed > [data-tab-title] .cbi-tabmenu {
|
||||
flex-direction: row; flex-wrap: wrap; align-items: center; gap: var(--sp-2);
|
||||
margin: 0 0 var(--sp-4);
|
||||
}
|
||||
.cbi-section-node-tabbed > [data-tab-title] .cbi-section-node-tabbed > [data-tab-title] .cbi-tabmenu > li > a {
|
||||
justify-content: normal;
|
||||
padding: 0 14px;
|
||||
border: 1px solid var(--line-2); border-radius: 999px;
|
||||
white-space: nowrap; line-height: inherit;
|
||||
}
|
||||
.cbi-section-node-tabbed > [data-tab-title] .cbi-section-node-tabbed > [data-tab-title] .cbi-tabmenu > li > a:hover { background: none; }
|
||||
.cbi-section-node-tabbed > [data-tab-title] .cbi-section-node-tabbed > [data-tab-title] .cbi-tabmenu > li.cbi-tab > a { border-color: var(--accent-line); box-shadow: none; }
|
||||
}
|
||||
:is(.cbi-tabmenu > li > a, .vt-pagetabs > .vt-tab):hover { color: var(--text); }
|
||||
:is(.cbi-tabmenu > li > a, .vt-pagetabs > .vt-tab):focus-visible { outline-offset: -1px; border-radius: calc(var(--r) + 3px); }
|
||||
.cbi-tabmenu > li.cbi-tab > a, .vt-pagetabs > .vt-tab[aria-current] { background-color: var(--seg-on); color: var(--text); font-weight: 600; box-shadow: var(--seg-on-ring); }
|
||||
.cbi-tabmenu > li[data-errors] > a::after {
|
||||
content: attr(data-errors);
|
||||
display: inline-flex; align-items: center; justify-content: center;
|
||||
min-width: 18px; height: 18px; padding: 0 5px;
|
||||
border-radius: 999px;
|
||||
background: var(--err); color: #fff;
|
||||
background: var(--err); color: var(--err-ink);
|
||||
font: 700 var(--fs-micro)/1 var(--mono);
|
||||
}
|
||||
.cbi-tabmenu > li.cbi-tab-disabled[data-errors] > a { color: var(--err); }
|
||||
@@ -1554,21 +1533,27 @@ html:not(:has(.vt-tabs:not([hidden]))) #view .cbi-tabmenu:not(.cbi-section *, [d
|
||||
/* "<strong>Label:</strong> value<br>" dumps (LuCI itemlist) -> aligned
|
||||
label/value grid. Each span.nowrap becomes a subgrid row: the <strong>
|
||||
is the label cell, the contiguous value run the anonymous value cell. */
|
||||
/* LuCI's " | " separators between the items are bare text, so each would
|
||||
be a grid row of its own: no text size, line or row gap for them; the
|
||||
items keep their own size and space */
|
||||
:is(.ifacebox-body, .ifacebadge) > span:has(> .nowrap) {
|
||||
display: grid;
|
||||
grid-template-columns: max-content minmax(0, 1fr);
|
||||
column-gap: 14px; row-gap: 3px;
|
||||
column-gap: 14px; row-gap: 0;
|
||||
align-items: baseline;
|
||||
min-width: 0;
|
||||
white-space: normal;
|
||||
text-align: left;
|
||||
font-size: 0; line-height: 0;
|
||||
}
|
||||
:is(.ifacebox-body, .ifacebadge) > span:has(> .nowrap) > br { display: none; }
|
||||
:is(.ifacebox-body, .ifacebadge) > span:has(> .nowrap) > :not(.nowrap) { font-size: var(--fs-sm); line-height: 1.55; }
|
||||
:is(.ifacebox-body, .ifacebadge) > span:has(> .nowrap) > .nowrap {
|
||||
grid-column: 1 / -1;
|
||||
display: grid; grid-template-columns: subgrid;
|
||||
align-items: baseline;
|
||||
min-width: 0;
|
||||
margin-block: 1.5px;
|
||||
white-space: normal; overflow-wrap: anywhere;
|
||||
color: var(--text);
|
||||
font: 400 var(--fs-sm)/1.55 var(--mono);
|
||||
@@ -1680,7 +1665,8 @@ html:not(:has(.vt-tabs:not([hidden]))) #view .cbi-tabmenu:not(.cbi-section *, [d
|
||||
.zonebadge[style*="--zone-color-rgb"] { box-shadow: inset 3px 0 0 rgb(var(--zone-color-rgb)); padding-left: 10px; }
|
||||
.ifacebox-head[style*="--zone-color-rgb"] { box-shadow: inset 0 3px 0 rgb(var(--zone-color-rgb)); border-bottom-color: rgba(var(--zone-color-rgb), .4) !important; }
|
||||
.ifacebox-head[style*="background-color:#"], .ifacebox-head[style*="background-color: #"] { color: #111 !important; }
|
||||
.zonebadge > em { font-style: normal; color: var(--text-3); }
|
||||
/* muted, but on the zone tint: --text-3 fell to 3.1:1 there in dark mode */
|
||||
.zonebadge > em { font-style: normal; color: color-mix(in srgb, var(--text) 78%, transparent); }
|
||||
.zonebadge .ifacebadge { padding: 0 4px; border: 0; background: transparent; }
|
||||
.zone-forwards { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
|
||||
.zone-forwards > span { color: var(--text-3); }
|
||||
@@ -1774,9 +1760,9 @@ html:not(:has(.vt-tabs:not([hidden]))) #view .cbi-tabmenu:not(.cbi-section *, [d
|
||||
transition: opacity .15s;
|
||||
pointer-events: none;
|
||||
}
|
||||
.cbi-tooltip.error { background: var(--err); border-color: var(--err); color: #fff; }
|
||||
.cbi-tooltip.error { background: var(--err); border-color: var(--err); color: var(--err-ink); }
|
||||
.cbi-tooltip.warning { background: var(--warn); border-color: var(--warn); color: #1a1200; }
|
||||
.cbi-tooltip.info { background: var(--info); border-color: var(--info); color: #fff; }
|
||||
.cbi-tooltip.info { background: var(--info); border-color: var(--info); color: var(--info-ink); }
|
||||
.cbi-tooltip-container { position: relative; cursor: help; }
|
||||
.cbi-tooltip-container > .cbi-tooltip { left: -10000px; top: auto; margin-top: 6px; white-space: normal; }
|
||||
.cbi-tooltip-container:hover > .cbi-tooltip { left: 0; top: 100%; opacity: 1; }
|
||||
@@ -1813,6 +1799,10 @@ body.modal-overlay-active #modal_overlay { display: block; }
|
||||
}
|
||||
#modal_overlay > .modal.cbi-modal { width: min(960px, 100%); }
|
||||
#modal_overlay > .modal .cbi-section { background: none; border: 0; padding: 0; margin: 0; box-shadow: none; }
|
||||
/* a modal's sections have no card padding, so nothing in them bleeds out
|
||||
by it: tables keep the modal's width (a bleed scrolled the section
|
||||
sideways) and their first and last cells line up with the fields */
|
||||
#modal_overlay > .modal .cbi-section { --card-px: 0px; --card-py: 0px; }
|
||||
#modal_overlay > .modal .cbi-section > h3:first-child { margin: 0 0 var(--sp-3); padding: 0; min-height: 0; border: 0; }
|
||||
.uci-dialog > .cbi-section > br, .uci-change-list > br:last-child { display: none; }
|
||||
.uci-dialog > .cbi-section > strong { display: block; margin-bottom: var(--sp-2); color: var(--text-3); font-size: var(--fs-micro); letter-spacing: .08em; text-transform: uppercase; }
|
||||
@@ -2215,7 +2205,12 @@ html:not([data-darkmode="true"]) .vt-login-page::before {
|
||||
color: var(--text-3);
|
||||
font-size: var(--fs-micro); font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
|
||||
}
|
||||
.vt-live-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent-text); animation: vt-live 2s ease-out infinite; }
|
||||
.vt-login-sub { isolation: isolate; }
|
||||
/* the ring as on the poll pill: behind the dot (the dot itself makes no
|
||||
stacking context, so z-index -1 lands under its background), opacity 0
|
||||
unless animated */
|
||||
.vt-login-dot { position: relative; width: 6px; height: 6px; border-radius: 50%; background: var(--accent-text); }
|
||||
.vt-login-dot::after { content: ""; position: absolute; z-index: -1; inset: 0; border-radius: 50%; background: var(--accent-line); opacity: 0; animation: vt-live 2s ease-out infinite; }
|
||||
.vt-login-error {
|
||||
margin: 0 0 var(--sp-4);
|
||||
padding: var(--sp-2) var(--sp-3);
|
||||
@@ -2229,7 +2224,7 @@ html:not([data-darkmode="true"]) .vt-login-page::before {
|
||||
.vt-field { display: flex; flex-direction: column; gap: 6px; }
|
||||
.vt-field-label { color: var(--text-3); font-size: var(--fs-micro); font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
|
||||
.vt-field input {
|
||||
width: 100%; height: 38px;
|
||||
width: 100%; height: var(--ctl-h);
|
||||
padding: 0 12px;
|
||||
background: var(--s2);
|
||||
color: var(--text);
|
||||
@@ -2238,7 +2233,7 @@ html:not([data-darkmode="true"]) .vt-login-page::before {
|
||||
font-size: var(--fs-md);
|
||||
}
|
||||
.vt-field input[name="luci_username"] { font-family: var(--mono); }
|
||||
.vt-login-submit { height: 38px; margin-top: var(--sp-2); font-size: var(--fs-md) !important; width: 100%; }
|
||||
.vt-login-submit { height: var(--ctl-h); margin-top: var(--sp-2); font-size: var(--fs-md) !important; width: 100%; }
|
||||
.vt-login-foot { margin: var(--sp-4) 0 0; text-align: center; color: var(--text-3); font: var(--fs-micro)/1.4 var(--mono); letter-spacing: .03em; }
|
||||
|
||||
/* ------------------------------------------------ 9. stock page layouts */
|
||||
@@ -2359,9 +2354,19 @@ html:not([data-darkmode="true"]) .vt-login-page::before {
|
||||
a non-scrolling ancestor, so status tables only scroll when narrow. */
|
||||
.cbi-tblsection, .cbi-section:has(> .cbi-tblsection) { overflow-x: auto; }
|
||||
.cbi-section:has(.cbi-dropdown[open]), .cbi-tblsection:has(.cbi-dropdown[open]) { overflow: visible; }
|
||||
@media (max-width: 1180px) and (min-width: 721px) {
|
||||
@media (720px < width <= 1180px) {
|
||||
.cbi-section { overflow-x: auto; }
|
||||
.cbi-section:has(.cbi-dropdown[open]) { overflow: visible; }
|
||||
/* a free-standing table card (Processes, Wireless's stations) has no
|
||||
section to scroll in: the card itself scrolls, its rows held in one
|
||||
table box (LuCI puts every row, titles too, in the tbody, so the
|
||||
columns stay aligned), its header static as in sections */
|
||||
:is(#view, #view > div, .cbi-map, #view > div > div > [data-tab-title]:not(.cbi-section)) > .table:not(:has(> thead)) {
|
||||
display: block; overflow-x: auto;
|
||||
}
|
||||
:is(#view, #view > div, .cbi-map, #view > div > div > [data-tab-title]:not(.cbi-section)) > .table:not(:has(> thead)) > tbody { display: table; width: 100%; }
|
||||
:is(#view, #view > div, .cbi-map, #view > div > div > [data-tab-title]:not(.cbi-section)) > .table:has(.cbi-dropdown[open]) { overflow: visible; }
|
||||
:is(#view, #view > div, .cbi-map, #view > div > div > [data-tab-title]:not(.cbi-section)) > .table .tr > .th.th { position: static; }
|
||||
}
|
||||
|
||||
|
||||
@@ -2370,6 +2375,18 @@ html:not([data-darkmode="true"]) .vt-login-page::before {
|
||||
.cbi-tblsection .table .tr > .th.th, .cbi-section:has(> .cbi-tblsection) .table .tr > .th.th { position: static; }
|
||||
@media (max-width: 1180px) { .cbi-section .table .tr > .th.th { position: static; } }
|
||||
|
||||
/* add-ons: adblock and banIP inject status palettes keyed on the OS
|
||||
colour scheme (@media prefers-color-scheme), so with the theme toggle
|
||||
set the other way their text fell to 1.7-3:1. Their own two palettes,
|
||||
picked by the toggle instead (html[data-darkmode] outweighs their #id
|
||||
rules); nothing else of theirs is touched. */
|
||||
html[data-darkmode="false"] #adb-status { --adb-ok: #1f8a5f; --adb-warn: #a8760a; --adb-err: #c0392b; --adb-info: #2f6fb0; }
|
||||
html[data-darkmode="true"] #adb-status { --adb-ok: #63c79b; --adb-warn: #d9ab4e; --adb-err: #e8897e; --adb-info: #7fb3e8; }
|
||||
html[data-darkmode="false"] #adb-dash { --adb-blocked: #c0392b; --adb-allowed: #1f8a5f; --adb-neutral: #2f6fb0; --adb-warn: #a8760a; }
|
||||
html[data-darkmode="true"] #adb-dash { --adb-blocked: #e8897e; --adb-allowed: #63c79b; --adb-neutral: #7fb3e8; --adb-warn: #d9ab4e; }
|
||||
html[data-darkmode="false"] :is(#ban-status, #ban-report) { --ban-ok: #1f8a5f; --ban-err: #c0392b; --ban-info: #2f6fb0; }
|
||||
html[data-darkmode="true"] :is(#ban-status, #ban-report) { --ban-ok: #63c79b; --ban-err: #e8897e; --ban-info: #7fb3e8; }
|
||||
|
||||
/* ----------------------------------------------------- responsive */
|
||||
|
||||
@media (max-width: 1100px) {
|
||||
@@ -2380,6 +2397,13 @@ html:not([data-darkmode="true"]) .vt-login-page::before {
|
||||
|
||||
@media (max-width: 900px) {
|
||||
.vt-host { display: none !important; }
|
||||
/* indicators go compact (dot, count) before the crumbs get cut; the
|
||||
label stays as text for screen readers and as the title */
|
||||
#indicators > span[data-indicator] { height: 28px; padding: 0 8px; }
|
||||
#indicators > span[data-indicator="poll-status"] { font-size: 0; gap: 0; width: 28px; justify-content: center; padding: 0; }
|
||||
#indicators > span[data-indicator="poll-status"][data-style="active"]::after { left: calc(50% - 3.5px); }
|
||||
#indicators > span[data-indicator][data-count] { padding: 0 3px; gap: 0; }
|
||||
#indicators > span[data-indicator][data-count]::before { content: none; }
|
||||
html[data-rail="pinned"] .vt-rail { width: var(--rail-w); }
|
||||
html[data-rail="pinned"] .vt-frame { margin-left: var(--rail-w); }
|
||||
html[data-rail="pinned"] body.vt-auth .vt-shell::before { width: var(--rail-w); }
|
||||
@@ -2405,22 +2429,29 @@ html:not([data-darkmode="true"]) .vt-login-page::before {
|
||||
.vt-rail > .vt-brand, .vt-rail-foot { display: none; }
|
||||
body.vt-auth .vt-shell::before { display: none; }
|
||||
.vt-rail-list {
|
||||
flex-direction: row; justify-content: space-around;
|
||||
flex-direction: row; justify-content: flex-start;
|
||||
gap: 0; padding: 0 var(--sp-1);
|
||||
overflow-x: auto; overflow-y: hidden;
|
||||
}
|
||||
.vt-rail-item { flex: 1 0 60px; padding: 6px 2px; }
|
||||
/* the buttons stay a centred group on wider screens. Centred with auto
|
||||
margins, not justify-content: center, which would push an overflowing
|
||||
list's first items past the scroll start where nothing reaches them;
|
||||
auto margins drop to 0 when the list overflows. */
|
||||
.vt-rail-item { flex: 1 0 60px; max-width: 104px; padding: 6px 2px; }
|
||||
.vt-rail-item:first-child { margin-inline-start: auto; }
|
||||
.vt-rail-item:last-child { margin-inline-end: auto; }
|
||||
.vt-rail-link, html[data-rail="pinned"] .vt-rail-link {
|
||||
flex-direction: column; justify-content: center; gap: 3px;
|
||||
height: 48px; padding: 0 4px;
|
||||
}
|
||||
.vt-rail-link .vt-rail-label, html[data-rail="pinned"] .vt-rail-link .vt-rail-label {
|
||||
display: block !important;
|
||||
flex: none; /* the rail's label grows; here it would push the icon up */
|
||||
max-width: 100%;
|
||||
font-size: var(--fs-micro); font-weight: 500;
|
||||
text-align: center;
|
||||
}
|
||||
.vt-rail-item.is-active > .vt-rail-link::before { left: 14px; right: 14px; top: -6px; bottom: auto; width: auto; height: 2px; border-radius: 0 0 2px 2px; }
|
||||
.vt-rail-item.is-active > .vt-rail-link::before { left: calc(50% - 10px); top: -6px; bottom: auto; width: 20px; height: 3px; border-radius: 0 0 3px 3px; }
|
||||
.vt-frame, html[data-rail="pinned"] .vt-frame { margin-left: 0; padding-bottom: calc(var(--bar-h) + env(safe-area-inset-bottom)); }
|
||||
|
||||
.vt-flyout {
|
||||
@@ -2447,11 +2478,8 @@ html:not([data-darkmode="true"]) .vt-login-page::before {
|
||||
.vt-crumbs .vt-crumb-current { font-size: var(--fs-md); }
|
||||
.vt-top-actions { gap: 2px; }
|
||||
.vt-search { border-color: transparent; background: none; color: var(--text-2); width: 32px; height: 32px; }
|
||||
#indicators > span[data-indicator] { height: 28px; padding: 0 8px; }
|
||||
#indicators > span[data-indicator="poll-status"] { font-size: 0; gap: 0; width: 28px; justify-content: center; padding: 0; }
|
||||
#indicators > span[data-indicator][data-count] { padding: 0 3px; gap: 0; }
|
||||
#indicators > span[data-indicator][data-count]::before { content: none; }
|
||||
.vt-tabs { padding: 0 var(--sp-2); }
|
||||
.vt-tabs { padding: var(--sp-4) var(--sp-4) 0; }
|
||||
.vt-tabs:not([hidden]) + .vt-main { padding-top: var(--sp-4); }
|
||||
|
||||
.vt-main { padding: var(--sp-4); }
|
||||
.vt-foot { padding-bottom: var(--sp-4); }
|
||||
@@ -2462,7 +2490,14 @@ html:not([data-darkmode="true"]) .vt-login-page::before {
|
||||
width: auto;
|
||||
margin: var(--sp-4) 0 0;
|
||||
}
|
||||
.cbi-page-actions > * { flex: 1 1 auto; }
|
||||
/* one row: the buttons share the bar from a zero basis, so the row only
|
||||
breaks when their longest words no longer fit, and a long label
|
||||
wraps inside its button instead of taking the bar to a second row */
|
||||
.cbi-page-actions > *, .cbi-page-actions > form > * { flex: 1 1 0; }
|
||||
.cbi-page-actions :is(.btn, .cbi-button, button, input[type="button"], input[type="submit"]):not(.cbi-dropdown) {
|
||||
padding: 4px 8px;
|
||||
white-space: normal; text-align: center; line-height: 1.15;
|
||||
}
|
||||
.cbi-section { overflow-x: visible; }
|
||||
.cbi-tblsection, .cbi-section:has(> .cbi-tblsection) { overflow-x: visible; }
|
||||
.network-status-table .ifacebox-head, .network-status-table .ifacebox-body { padding-left: 12px; padding-right: 12px; }
|
||||
@@ -2490,38 +2525,36 @@ html:not([data-darkmode="true"]) .vt-login-page::before {
|
||||
.cbi-value:has(> .cbi-value-field > .cbi-checkbox) > .cbi-value-title { grid-row: 1; grid-column: 2; padding: 0; }
|
||||
.cbi-value:has(> .cbi-value-field > .cbi-checkbox) > .vt-help { grid-row: 1; grid-column: 3; }
|
||||
.cbi-value:has(> .cbi-value-field > .cbi-checkbox) > .cbi-value-field > :not(.cbi-checkbox) { grid-column: 1 / -1; }
|
||||
/* a segmented control wraps its segments instead of hiding them */
|
||||
.cbi-tabmenu:not(.cbi-section-node-tabbed > [data-tab-title] *) { flex-wrap: wrap; width: auto; }
|
||||
.cbi-tabmenu:not(.cbi-section-node-tabbed > [data-tab-title] *) > li { flex: 1 1 auto; }
|
||||
.cbi-tabmenu:not(.cbi-section-node-tabbed > [data-tab-title] *) > li > a { justify-content: center; }
|
||||
/* ... while an underline strip scrolls, like the page tabs */
|
||||
html:not(:has(.vt-tabs:not([hidden]))) #view .cbi-tabmenu:not(.cbi-section *, [data-tab-title] *) { flex-wrap: nowrap; }
|
||||
html:not(:has(.vt-tabs:not([hidden]))) #view .cbi-tabmenu:not(.cbi-section *, [data-tab-title] *) > li { flex: none; }
|
||||
html:not(:has(.vt-tabs:not([hidden]))) #view .cbi-tabmenu:not(.cbi-section *, [data-tab-title] *) > li > a { justify-content: normal; }
|
||||
/* a segmented control spans the width and its segments share each row */
|
||||
.cbi-tabmenu, .vt-tabs > .vt-pagetabs { width: auto; }
|
||||
.cbi-tabmenu > li, .vt-pagetabs > .vt-tab { flex: 1 1 auto; }
|
||||
.cbi-tabmenu > li > a, .vt-pagetabs > .vt-tab { justify-content: center; }
|
||||
.cbi-dropdown, .vt-main input, .vt-main select, .control-group, .cbi-dynlist { max-width: none; }
|
||||
|
||||
/* tables become cards */
|
||||
/* tables become cards, in pages and in modals alike. Header rows go
|
||||
(LuCI also puts .cbi-section-table-titles on each row's name cell,
|
||||
which stays); every cell drops the fixed row height. */
|
||||
.hide-xs { display: none !important; }
|
||||
.vt-main .table, .vt-main .table > tbody, .vt-main .table > thead, .modal .table, .modal .table > tbody { display: block; width: 100%; }
|
||||
.vt-main .table > .tr.table-titles, .vt-main .table > thead > .tr.table-titles, .vt-main .table > tbody > .tr.table-titles,
|
||||
.vt-main .cbi-section-table-titles, .vt-main .cbi-section-table-descr, .modal .table-titles { display: none !important; }
|
||||
.vt-main .table .tr, .modal .table .tr {
|
||||
:is(.vt-main, .modal) .table, :is(.vt-main, .modal) .table > :is(tbody, thead) { display: block; width: 100%; }
|
||||
:is(.vt-main, .modal) .table :is(tr, .tr):is(.table-titles, .cbi-section-table-titles, .cbi-section-table-descr) { display: none !important; }
|
||||
:is(.vt-main, .modal) .table .tr {
|
||||
display: flex; flex-wrap: wrap;
|
||||
padding: 6px 0;
|
||||
border-bottom: 1px solid var(--line);
|
||||
}
|
||||
.vt-main .table .tr:last-child { border-bottom: 0; }
|
||||
.vt-main .table .tr > .td, .modal .table .tr > .td {
|
||||
:is(.vt-main, .modal) .table .tr:last-child { border-bottom: 0; }
|
||||
:is(.vt-main, .modal) .table .tr > .td {
|
||||
display: block;
|
||||
flex: 1 1 100%;
|
||||
min-width: 0;
|
||||
width: auto !important;
|
||||
height: auto;
|
||||
padding: 4px 10px;
|
||||
border: 0;
|
||||
text-align: left !important;
|
||||
}
|
||||
.vt-main :is(.cbi-section, .cbi-value) .table .tr > .td:nth-child(n) { padding: 4px var(--card-px); height: auto; }
|
||||
.vt-main .table .tr > .td[data-title]::before, .modal .table .tr > .td[data-title]::before {
|
||||
:is(.vt-main, .modal) :is(.cbi-section, .cbi-value) .table .tr > .td:nth-child(n) { padding: 4px var(--card-px); }
|
||||
:is(.vt-main, .modal) .table .tr > .td[data-title]::before {
|
||||
content: attr(data-title);
|
||||
display: block;
|
||||
margin-bottom: 2px;
|
||||
@@ -2529,18 +2562,20 @@ html:not([data-darkmode="true"]) .vt-login-page::before {
|
||||
color: var(--text-3);
|
||||
font-size: var(--fs-micro); font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
|
||||
}
|
||||
.vt-main .table:not(:has(.table-titles)) .tr > .td:first-child:nth-last-child(2) {
|
||||
:is(.vt-main, .modal) .table:not(:has(.table-titles)) .tr > .td:first-child:nth-last-child(2) {
|
||||
width: auto !important; padding-bottom: 0;
|
||||
color: var(--text-3); font-size: var(--fs-micro); font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
|
||||
}
|
||||
.vt-main .table .tr > .td[data-title]:not(:only-child) { flex-basis: 50%; }
|
||||
.vt-main .table .tr > .td[data-title]:last-child:nth-child(odd) { flex-basis: 100%; }
|
||||
.vt-main .table .tr > .td.cbi-section-actions { flex-basis: 100%; text-align: left !important; }
|
||||
.vt-main .table .tr > .td[data-name="_ifacebox"], .vt-main .table .tr > .td[data-name="_ifacestat"] { flex-basis: 100%; }
|
||||
:is(.vt-main, .modal) .table .tr > .td[data-title]:not(:only-child) { flex-basis: 50%; }
|
||||
:is(.vt-main, .modal) .table .tr > .td[data-title]:last-child:nth-child(odd) { flex-basis: 100%; }
|
||||
:is(.vt-main, .modal) .table .tr > .td.cbi-section-actions { flex-basis: 100%; text-align: left !important; }
|
||||
/* a named grid section's name cell heads its card */
|
||||
:is(.vt-main, .modal) .table .tr > .td.cbi-section-table-titles { flex-basis: 100%; color: var(--text); font-weight: 600; }
|
||||
:is(.vt-main, .modal) .table .tr > .td:is([data-name="_ifacebox"], [data-name="_ifacestat"]) { flex-basis: 100%; }
|
||||
.cbi-section-table .td[data-name="_ifacebox"] .ifacebox { width: 100%; }
|
||||
.vt-main .table .tr > .td.cbi-section-actions > div { flex-wrap: wrap; }
|
||||
.vt-main .table .tr > .td.cbi-section-actions::before { display: none !important; }
|
||||
.vt-main .table .tr:hover > .td { background: none; }
|
||||
:is(.vt-main, .modal) .table .tr > .td.cbi-section-actions > div { flex-wrap: wrap; }
|
||||
:is(.vt-main, .modal) .table .tr > .td.cbi-section-actions::before { display: none !important; }
|
||||
:is(.vt-main, .modal) .table .tr:hover > .td { background: none; }
|
||||
.cbi-section .table, .cbi-section .cbi-section-table { border: 0; }
|
||||
.cbi-progressbar { max-width: none; }
|
||||
.network-status-table > .ifacebox { max-width: none; }
|
||||
@@ -2563,6 +2598,10 @@ html:not([data-darkmode="true"]) .vt-login-page::before {
|
||||
}
|
||||
@media (pointer: coarse) {
|
||||
input[type="checkbox"], input[type="radio"] { width: 20px; height: 20px; }
|
||||
/* top-bar buttons: a touch control high, at every width */
|
||||
.vt-icon-btn, .vt-search { min-width: var(--ctl-h); height: var(--ctl-h); }
|
||||
/* dropdown choices (Save & Apply's too) are touch targets */
|
||||
.cbi-dropdown[open] > ul.dropdown > li { min-height: var(--ctl-h); }
|
||||
.cbi-value { padding: 8px 0; }
|
||||
}
|
||||
|
||||
@@ -2592,6 +2631,7 @@ html:not([data-darkmode="true"]) .vt-login-page::before {
|
||||
/* ui.Dropdown moves focus on transitionend: keep a (near-instant) transition */
|
||||
.cbi-dropdown[open] > ul.dropdown { transition-duration: .01s; }
|
||||
.cbi-progressbar > div { transition: none; }
|
||||
.vt-crumb-switch > svg, .vt-rail-caret, .vt-rail-pin svg { transition: none; }
|
||||
}
|
||||
|
||||
@media print {
|
||||
|
||||
Reference in new issue
Block a user