Centralize shared WebUI structural primitives

This commit is contained in:
2026-08-18 13:17:31 +02:00
parent ee5c881df9
commit 7685a103e8
26 changed files with 767 additions and 81 deletions
+75 -3
View File
@@ -51,7 +51,7 @@
.titlebar-icon-link.is-context-active { background: var(--accent-hover-bg); color: var(--accent); }
.titlebar-icon-link.is-context-active:hover { background: color-mix(in srgb, var(--accent) 16%, transparent); color: var(--accent); }
.titlebar-notification-button { position: relative; }
.titlebar-notification-badge { position: absolute; top: 4px; right: 3px; min-width: 16px; height: 16px; box-sizing: border-box; display: inline-flex; align-items: center; justify-content: center; padding: 0 4px; border: 2px solid var(--titlebar-bg); border-radius: 999px; background: var(--red); color: var(--on-accent); font-size: 10px; font-weight: 800; line-height: 1; transform: translate(35%, -35%); }
.titlebar-notification-badge { position: absolute; top: 4px; right: 3px; border: 2px solid var(--titlebar-bg); transform: translate(35%, -35%); }
.account-pill { color: var(--text); }
.maintenance-topbar-link,
.backend-offline-topbar-alert { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); min-height: 32px; max-width: min(560px, calc(100vw - 24px)); box-sizing: border-box; border-radius: 6px; display: inline-flex; align-items: center; justify-content: center; padding: 0 14px; overflow: hidden; font: inherit; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; box-shadow: 0 1px 2px var(--hover-tint); z-index: 1; }
@@ -83,11 +83,17 @@
.action-toolbar { min-width: 0; display: flex; align-items: center; gap: 10px; }
.action-toolbar-density-compact { gap: 7px; }
.action-toolbar-surface-subtle { padding: 10px 12px; border: var(--border-line); border-radius: var(--radius); background: var(--panel-soft); }
.action-toolbar-surface-panel-header { min-height: 54px; flex: 0 0 auto; justify-content: space-between; padding: 9px 12px; border-bottom: var(--border-line); background: var(--panel-header); }
.action-toolbar-surface-section-header { min-height: 44px; flex: 0 0 auto; justify-content: space-between; padding: 7px 10px; border-bottom: var(--border-line); background: var(--panel-header); }
.action-toolbar-surface-section-header > h2,
.action-toolbar-surface-section-header > h3 { margin: 0; color: var(--text-strong); font-size: 13px; }
.action-toolbar-wrap-always { flex-wrap: wrap; }
.action-toolbar-wrap-never { flex-wrap: nowrap; overflow-x: auto; }
.action-toolbar-group { min-width: 0; display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.action-toolbar-group-center { justify-content: center; }
.action-toolbar-group-end { justify-content: flex-end; margin-inline-start: auto; }
.action-toolbar-justify-between { justify-content: space-between; }
.action-toolbar-justify-end { justify-content: flex-end; }
.action-toolbar-group-grow { flex: 1 1 auto; }
.action-toolbar-spacer { flex: 1 1 auto; min-width: 8px; }
.app-content { min-height: 0; overflow: hidden; }
@@ -102,6 +108,16 @@
.workspace-layout-split { grid-template-columns: minmax(280px, 360px) minmax(0, 1fr); }
.workspace-layout-split.workspace-layout-primary-compact { grid-template-columns: minmax(250px, 320px) minmax(0, 1fr); }
.workspace-layout-split.workspace-layout-primary-wide { grid-template-columns: minmax(340px, 440px) minmax(0, 1fr); }
.workspace-layout-surface-contained { width: 100%; min-width: 0; overflow: hidden; border: var(--border-line); background: var(--panel); }
.workspace-layout-surface-contained > .workspace-layout-primary { display: flex; flex-direction: column; overflow: hidden; border-right: var(--border-line); background: var(--panel-soft); }
.workspace-layout-surface-contained > .workspace-layout-content { position: relative; display: flex; flex-direction: column; overflow: hidden; background: var(--bg); }
.workspace-frame { box-sizing: border-box; display: flex; width: 100%; height: 100%; min-width: 0; min-height: 0; flex-direction: column; overflow: hidden; }
.workspace-frame *,
.workspace-frame *::before,
.workspace-frame *::after { box-sizing: border-box; }
.workspace-frame-height-viewport { position: relative; height: calc(100vh - 115px); height: calc(100dvh - 115px); padding: 0; }
.workspace-frame-surface-panel { background: var(--panel); }
.workspace-frame-surface-plain { background: var(--bg); }
.section-sidebar { background: var(--sidebar-bg); border-right: var(--border-line-dark); padding: 18px 0; border-left: 3px solid var(--sidebar-border); box-shadow: var(--shadow-chrome); z-index: 80; overflow-y: scroll; }
.section-title { font-size: 12px; font-weight: 800; color: var(--muted); padding: 0 22px 14px; letter-spacing: .06em; }
.section-title-lower { margin-top: 28px; }
@@ -164,6 +180,14 @@
.ui-no-sticky-section-sidebars .workspace-content { overflow: visible; }
.ui-no-sticky-section-sidebars .workspace-layout-primary { overflow: visible; }
.content-pad { min-width: 0; max-width: 100%; box-sizing: border-box; padding: 28px 34px; }
.content-section { min-width: 0; border: var(--border-line); }
.content-section-layout-stack { display: grid; gap: 6px; }
.content-section-density-compact { padding: 10px; border-radius: var(--radius-sm); }
.content-section-density-default { padding: 18px; border-radius: var(--radius); }
.content-section-spacing-block { margin-bottom: 14px; }
.content-section-spacing-none { margin-bottom: 0; }
.content-section-surface-panel { background: var(--panel); }
.content-section-surface-subtle { background: var(--panel-soft); }
.page-heading { margin-bottom: 22px; }
.page-heading h1 { margin: 0; font-size: 26px; color: var(--text-strong); font-weight: 600; }
.page-heading p { margin: 6px 0 0; color: var(--muted); }
@@ -239,6 +263,12 @@
.metric-group-minimum-default { --metric-group-column-minimum: 140px; }
.metric-group-minimum-wide { --metric-group-column-minimum: 180px; }
.metric-card { background: var(--panel); border: var(--border-line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); border-top: 4px solid var(--line-dark); }
.metric-card-density-compact { padding: 10px 12px; border-top-width: 1px; box-shadow: none; }
.metric-card-density-compact .metric-label { font-size: 11px; }
.metric-card-density-compact .metric-value { margin-top: 5px; font-size: 16px; }
.metric-card-density-compact .metric-detail { font-size: 12px; }
.metric-card-surface-subtle { background: var(--panel-soft); }
.metric-card-surface-flat { border-radius: 0; box-shadow: none; }
.metric-good { border-top-color: var(--green); } .metric-warning { border-top-color: var(--amber); } .metric-danger { border-top-color: var(--red); } .metric-info { border-top-color: var(--blue); }
.metric-label { color: var(--muted); font-size: 12px; text-transform: uppercase; font-weight: 800; letter-spacing: .05em; }
.metric-value { margin-top: 7px; font-size: 30px; color: var(--text-strong); font-weight: 700; }
@@ -297,6 +327,7 @@
.workspace { grid-template-columns: 1fr; }
.workspace-layout-navigation > .workspace-layout-primary { display: none; }
.workspace-layout-split { grid-template-columns: 1fr; grid-template-rows: minmax(160px, 34%) minmax(0, 1fr); }
.workspace-layout-surface-contained > .workspace-layout-primary { border-right: 0; border-bottom: var(--border-line); }
.section-sidebar { display: none; }
.wizard-card { grid-template-columns: 1fr; }
.metric-group-collapse-workspace { grid-template-columns: minmax(0, 1fr); }
@@ -319,6 +350,9 @@
.action-toolbar-wrap-responsive { align-items: stretch; flex-wrap: wrap; }
.action-toolbar-wrap-responsive > .action-toolbar-group { flex: 1 1 100%; }
.action-toolbar-wrap-responsive > .action-toolbar-group-end { margin-inline-start: 0; justify-content: flex-start; }
.filter-bar-wrap-responsive.filter-bar-layout-row { align-items: stretch; flex-wrap: wrap; }
.filter-bar-wrap-responsive.filter-bar-layout-row > input:not([type="checkbox"]):not([type="radio"]),
.filter-bar-wrap-responsive.filter-bar-layout-row > select { flex-basis: 100%; }
}
@@ -359,7 +393,46 @@
.empty-state { min-height: 220px; display: grid; place-items: center; text-align: center; padding: 32px; }
.empty-state h2 { margin: 0; color: var(--text-strong); }
.empty-state p { max-width: 520px; margin: 8px auto 18px; color: var(--muted); }
.docs-workspace { grid-template-columns: 292px minmax(0, 1fr); background: var(--panel); }
.state-panel { box-sizing: border-box; min-width: 0; display: grid; justify-items: center; align-content: center; gap: 8px; color: var(--muted); text-align: center; }
.state-panel-size-inline { min-height: 0; padding: 8px 10px; }
.state-panel-size-compact { min-height: 110px; padding: 18px; }
.state-panel-size-default { min-height: 180px; padding: 28px; }
.state-panel-size-fill { width: 100%; height: 100%; min-height: 100%; padding: 32px; }
.state-panel-surface-subtle { border: var(--border-line); border-radius: var(--radius-sm); background: var(--panel-soft); }
.state-panel-surface-dashed { border: 1px dashed var(--line-dark); border-radius: var(--radius-sm); background: var(--panel-soft); }
.state-panel-align-start { justify-items: start; text-align: start; }
.state-panel-tone-info { color: var(--info-text); }
.state-panel-tone-warning { color: var(--warning-text); }
.state-panel-tone-danger { color: var(--danger-text); }
.state-panel-icon { display: grid; place-items: center; color: currentColor; }
.state-panel-title { margin: 0; color: var(--text-strong); font-size: 18px; letter-spacing: 0; }
.state-panel-description,
.state-panel-content { max-width: 520px; line-height: 1.45; }
.state-panel-description > :first-child,
.state-panel-content > :first-child { margin-top: 0; }
.state-panel-description > :last-child,
.state-panel-content > :last-child { margin-bottom: 0; }
.state-panel-actions { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.state-panel-align-start .state-panel-actions { justify-content: flex-start; }
.filter-bar { box-sizing: border-box; min-width: 0; gap: 8px; }
.filter-bar-layout-row { display: flex; align-items: center; }
.filter-bar-layout-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr)); align-items: center; }
.filter-bar-layout-stack { display: grid; }
.filter-bar-width-auto { width: auto; }
.filter-bar-width-compact { width: min(420px, 100%); }
.filter-bar-width-default { width: min(560px, 100%); }
.filter-bar-width-wide { width: min(680px, 100%); }
.filter-bar-width-full { width: 100%; }
.filter-bar-surface-panel { padding: 9px 10px; border-bottom: var(--border-line); background: var(--panel); }
.filter-bar-surface-control { min-height: 36px; padding: 5px 9px; border: var(--border-line); border-radius: var(--radius-sm); background: var(--surface); }
.filter-bar-surface-control:focus-within { border-color: var(--accent); box-shadow: var(--accent-ring-soft); }
.filter-bar-layout-row > input:not([type="checkbox"]):not([type="radio"]),
.filter-bar-layout-row > select { min-width: 120px; flex: 1 1 auto; }
.filter-bar-surface-control > input:not([type="checkbox"]):not([type="radio"]),
.filter-bar-surface-control > select { min-width: 0; min-height: 0; padding-block: 1px; border: 0; background: transparent; box-shadow: none; }
.filter-bar-wrap-always { flex-wrap: wrap; }
.filter-bar-wrap-never { flex-wrap: nowrap; overflow-x: auto; }
.docs-workspace { background: var(--panel); }
.docs-workspace-content { background: var(--panel); }
.docs-outline { padding-top: 22px; }
.docs-sidebar-header { padding: 0 16px 16px; }
@@ -414,7 +487,6 @@
margin-left: 0;
}
.summary-grid { grid-template-columns: 1fr; }
.docs-workspace { grid-template-columns: 1fr; }
.docs-outline { display: none; }
.docs-content { grid-template-columns: 1fr; }
.docs-page-outline-box { display: none; }