mirror of
https://github.com/kiddin9/op-packages.git
synced 2026-10-29 10:15:13 +08:00
🚀 Sync 2026-08-11 09:19:39
This commit is contained in:
1 parent
2b7ce8baae
commit
bb66713991
3 files changed
+28
-8
No files matched your search
@@ -17,7 +17,7 @@ LUCI_NAME:=luci-theme-footstrap
|
||||
FOOTSTRAP_VERSION?=
|
||||
ifneq ($(FOOTSTRAP_VERSION),)
|
||||
PKG_VERSION:=$(FOOTSTRAP_VERSION)
|
||||
PKG_RELEASE:=10
|
||||
PKG_RELEASE:=11
|
||||
endif
|
||||
|
||||
LUCI_TITLE:=Footstrap Theme
|
||||
|
||||
@@ -390,6 +390,17 @@ function seed() {
|
||||
function documentHasSheet(css) {
|
||||
const want = '/' + css.replace(/^\/+/, '');
|
||||
for (const link of document.querySelectorAll('link[rel~="stylesheet"][href]')) {
|
||||
/* A <link> INSIDE the view tree dies with the swap — it is the one shape fs-sheets.js needs
|
||||
* no handling for, and every scan there skips it for the same reason (VIEW_SHEETS, and the
|
||||
* `closest('#view')` guards in documentPoisoned/scopeToCurrentPage/dedupeViewSheets).
|
||||
* Counting it here would answer the wrong question: `luci-app-nlbwmon` returns
|
||||
* `E('link', { rel: 'stylesheet', href: L.resource('view/nlbw.css') })` from render(), so
|
||||
* standing on that page its sheet IS in the document — and it is exactly the sheet the next
|
||||
* dom.content() throws away. An app in that shape moving to a menu.d `css` is the migration
|
||||
* #8920 was written for, so the guard has to survive it: leaving from that page must be a
|
||||
* full load, not a swap into an unstyled document. */
|
||||
if (link.closest('#view'))
|
||||
continue;
|
||||
const href = (link.getAttribute('href') || '').split('?')[0];
|
||||
if (href.endsWith(want))
|
||||
return true;
|
||||
|
||||
@@ -45,9 +45,13 @@
|
||||
}
|
||||
/* a checkbox is not a field: left to its own 16px, it would otherwise flex to fill the line. */
|
||||
#content_syslog > div:has(> label) > input[type="checkbox"] { flex: 0 0 auto; }
|
||||
/* the two numeric-ish fields keep a sane ceiling: a max-rows box as wide as the filter reads as
|
||||
* a second search field. */
|
||||
#logMaxRows { flex-basis: 6ch; max-width: 12ch; }
|
||||
/* The max-rows box keeps a sane ceiling: as wide as the free-text filter it reads as a second
|
||||
* search field. Selected as the row's `number` input, not by its id: `#logMaxRows` alone is
|
||||
* (1,0,0) and the field rule above is (1,0,3), so the id LOSES — and re-anchoring it under
|
||||
* `#content_syslog` would put two ids in one selector, [2,0,x], past the [1,7,0] ceiling
|
||||
* `npm run css-metrics` holds this sheet to. `[type="number"]` is the only one in either log's
|
||||
* filter bar and it out-specifies at (1,1,3). */
|
||||
#content_syslog > div:has(> label) > input[type="number"] { flex-basis: 6ch; max-width: 12ch; }
|
||||
|
||||
/* ON A PHONE, ONE FILTER PER LINE. Wrapping alone still fills each line greedily, so the second
|
||||
* `Не` rode the end of the first line while the `уровень:` it inverts opened the next one. The
|
||||
@@ -63,10 +67,15 @@
|
||||
* those on as many lines as it needs, which is all the grid was ever for; the grid is worth its
|
||||
* one selector only where the alternation is exact. */
|
||||
@container fs-view (max-width: 560px) {
|
||||
/* the id alone, without `#content_syslog >` in front of it: two ids in one selector is
|
||||
* [2,0,1], past the [1,7,0] ceiling `npm run css-metrics` holds the sheet to, and the row is
|
||||
* already pinned down by the only id LuCI puts on that select. */
|
||||
div:has(> #logFacilitySelect) {
|
||||
/* THE ROW WITH TWO SELECTS, which is the same row `#logFacilitySelect` names — by shape
|
||||
* because neither spelling of the id survives the arithmetic: `div:has(> #logFacilitySelect)`
|
||||
* is (1,0,1) and loses to the flex rule above at (1,0,2), while `#content_syslog >` in front
|
||||
* of it is two ids, [2,0,1], past the [1,7,0] ceiling `npm run css-metrics` holds. Two
|
||||
* sibling selects is what the `auto auto auto minmax(0, 1fr)` template is sized for — eight
|
||||
* children, two filters — and it is unique to the System Log's first row: the Kernel Log's
|
||||
* severity row carries one select, its range row two time fields. (1,0,4) beats the flex
|
||||
* rule on specificity, not on source order. */
|
||||
#content_syslog > div:has(> label):has(> select ~ select) {
|
||||
display: grid;
|
||||
grid-template-columns: auto auto auto minmax(0, 1fr);
|
||||
column-gap: var(--fs-space-1);
|
||||
|
||||
Reference in new issue
Block a user