MediaWiki:Common.css: Difference between revisions

Content deleted Content added
No edit summary
Tag: Manual revert
No edit summary
Line 1,148:
table.wikitable:has(.col, .col-wide) td:not(:first-child) { min-width: var(--wt-s); }
 
/* frozen row-label column. */white-space:normal (NOT nowrap) with a max-width
cap: a normal label keeps to one line as long as it fits (auto table layout
sizes the column to its content), but a runaway label — e.g. a long note
that ends up in the cell — WRAPS at ~2/3 of the table instead of forcing a
giant one-line column that pushes the data off-screen. overflow-wrap breaks
an unbreakable token. min-width keeps it from collapsing too narrow. */
table.wikitable.fintable th:first-child,
table.wikitable.fintable td:first-child,
table.wikitable:has(.col, .col-wide) th:first-child,
table.wikitable:has(.col, .col-wide) td:first-child {
white-space: nowrapnormal;
max-width: min(24rem, 90vw)66%; /* hard cap: never overflowhog themore viewportthan ~2/3 */
overflow-wrap: anywhere;
min-width: 16em;
position: sticky;
Line 1,840 ⟶ 1,847:
(Docling parses the DOM, not the rendered layout) — readers and
RAG see different things from one markup.
Common.js addsonly TOGGLES .ed-fn-flipopen near(one thecard rightat edgea (cardtime); opensthe leftward)card's
andposition keepsis only100% oneCSS card openno atJS acoordinates timeto go wrong. ── */
.ed-fn { position: relative; } /* the popover's anchor */
.ed-fn-chip { cursor: pointer; white-space: nowrap; }
.ed-fn-chip::after {
Line 1,860 ⟶ 1,866:
.ed-fn-body { display: none; }
 
/* theThe popover card */— a FIXED bottom-centre panel, positioned entirely in
CSS. position:fixed escapes the frozen first column's sticky stacking
context and the table's overflow clip (an absolute/JS-placed card kept
getting trapped or mis-placed → invisible). Because the position is pure
CSS, opening the card can never show "nothing": the JS just adds the
.ed-fn-open class. Width clamps to the viewport so it works on mobile too. */
.ed-fn.ed-fn-open > .ed-fn-body {
display: block;
position: absolutefixed;
left: 50%;
top: 1.6em; /* just below the chip's line */
leftbottom: 01.5rem;
transform: translateX(-50%);
z-index: 30;
topz-index: 1.6em1100; /* justabove belowsticky thecells chip's+ linechrome */
width: max-content;
width: min(32rem, calc(100vw - 2rem));
max-width: min(24rem, 90vw); /* never overflow the viewport */
max-height: 60vh;
padding: 0.7em 0.9em;
overflow-y: auto;
padding: 0.7em8em 0.9em1em;
background: #fff;
border: 1px solid var(--ed-hairline-strong);
border-left: 3px solid var(--ed-accent); /* house coral spine */
border-radius: 2px4px;
box-shadow: 0 6px8px 22px30px rgba(43, 41, 38, 0.1418);
font-family: var(--ed-serif);
font-size: 0.9rem92rem;
font-weight: 400;
font-style: normal;
Line 1,889 ⟶ 1,902:
.ed-fn.ed-fn-open > .ed-fn-body::before,
.ed-fn.ed-fn-open > .ed-fn-body::after { content: none; }
/* near the right edge, open the card leftward (JS sets .ed-fn-flip) */
.ed-fn.ed-fn-open.ed-fn-flip > .ed-fn-body { left: auto; right: 0; }
 
/* no-JS safety net: if site JS ever fails to load, notes stay readable */
Line 1,902 ⟶ 1,913:
h1#firstHeading, .mw-first-heading { font-size: 1.7rem; }
.mw-body-content h2, .mw-body-content .mw-heading2 { font-size: 1.22rem; }
/* footnote card → fixed bottom sheet so it can never clip off-screen */
.ed-fn.ed-fn-open > .ed-fn-body {
position: fixed;
left: 1rem; right: 1rem; bottom: 1rem;
top: auto; width: auto; max-width: none;
box-shadow: 0 -4px 22px rgba(43, 41, 38, 0.18);
}
.ext-aiassistant-prompt-composer { border-bottom: 1px solid var(--ed-hairline) !important; }
}