// ───────────────────────────────────────────────────────────────────────────── // Component: Symbol Detail (.sd-* prefix) // File: src/scss/components/_symbol_detail.scss // // Phase 2 — Health Dimensions Strip // Phase 3 — Identity Banner 2-column restructure // Phase 7 — Timeline refactor overlay tags + styled gap dividers // ───────────────────────────────────────────────────────────────────────────── // ── Timeline lineage boundary (renamed-from divider) ───────────────────────── .sym2-tl-lineage-break { display: flex; align-items: center; gap: 0.5rem; padding: 0.5rem 0; margin: 0.35rem 0 0.1rem; &::before, &::after { content: ''; flex: 1; height: 1px; background: var(--color-purple); opacity: 0.25; } svg { color: var(--color-purple); opacity: 0.7; flex-shrink: 0; } span { font-family: var(--font-mono); font-size: 0.6rem; color: var(--color-purple); opacity: 0.8; white-space: nowrap; letter-spacing: 0.04em; } .sym2-tl-lineage-addr { color: var(--color-purple); text-decoration: none; opacity: 1; &:hover { text-decoration: underline; } } } // ── Timeline gap divider (detail-page override) ─────────────────────────────── .sym2-detail-page .sym2-tl-gap { display: flex; align-items: center; gap: 0.5rem; padding: 0.3rem 0; opacity: 0.5; &::before, &::after { content: ''; flex: 1; height: 1px; background: var(--border-default); } span { font-family: var(--font-mono); font-size: 0.58rem; color: var(--text-muted); letter-spacing: 0.06em; white-space: nowrap; } } // ── Timeline readability overrides (detail-page scoped) ────────────────────── // // Each entry needs enough vertical room to be scanned without feeling cramped. // The epoch break is the "chapter heading" — it should breathe above it. // The commit message is the WHY — it should be readable, not truncated. .sym2-detail-page { .sym2-tl-content { padding: 0.15rem 0 0.85rem 0.65rem; } .sym2-tl-message-row { display: flex; align-items: baseline; gap: 0.4rem; margin-top: 0.15rem; } .sym2-tl-branch-row { display: flex; align-items: baseline; gap: 0.4rem; margin-top: 0.2rem; } .sym2-tl-message { white-space: normal; font-size: 0.82rem; color: var(--text-secondary); line-height: 1.4; } .sym2-tl-header { gap: 0.35rem; margin-bottom: 0; } } // ── Op label — plain colored ALL CAPS text, no pill chrome ──────────────────── .sd-op-badge { background: none; border: none; border-radius: 0; padding: 0; font-size: 0.68rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; font-family: var(--font-mono); &.sd-op--add { color: var(--color-success); } &.sd-op--mod { color: var(--color-accent); } &.sd-op--del { color: var(--color-danger); } &.sd-op--move { color: var(--color-orange); } &.sd-op--rename { color: var(--color-purple); } } // ── Cohen-transform diff block ──────────────────────────────────────────────── .sd-body-diff { margin: 0.5rem 0 0.25rem; padding: 0.5rem 0.6rem; background: var(--bg-elevated); border-radius: 4px; font-family: var(--font-mono); font-size: 0.7rem; line-height: 1.5; overflow-x: auto; white-space: pre; color: var(--text-secondary); .sd-diff-hunk { color: var(--color-accent); opacity: 0.8; } .sd-diff-add { color: var(--color-success); display: block; } .sd-diff-del { color: var(--color-danger); display: block; } .sd-diff-trunc { color: var(--text-muted); font-style: italic; } } .sym2-detail-page { .sym2-tl-line { opacity: 0.45; } // Epoch break — more air above; feels like a section heading .sym2-tl-epoch { margin: 1.1rem 0 0.35rem; padding: 0.4rem 0.75rem; } } // ── Coupling heat fill — solid tier colour (replaces gradient) ──────────────── .sym2-heat-fill { background: var(--color-accent); // default / low &--high { background: var(--color-orange); } &--critical { background: var(--color-danger); } &--low { background: color-mix(in srgb, var(--text-muted) 60%, transparent); } } // ── Identity banner right column ────────────────────────────────────────────── .sym2-hero-right { display: flex; flex-direction: column; align-items: flex-end; gap: 0.75rem; flex-shrink: 0; @media (max-width: 768px) { align-items: flex-start; width: 100%; } } // ── Health dimensions strip ─────────────────────────────────────────────────── .sd-health-strip { display: flex; flex-wrap: wrap; gap: 0; // Pull edge-to-edge and butt up against the hero's bottom border margin-left: calc(-1 * var(--space-4)); margin-right: calc(-1 * var(--space-4)); margin-top: -0.75rem; // cancel the .sym2-detail-page flex gap border-bottom: 1px solid var(--border-default); } .sd-health-card { flex: 1; min-width: 9rem; background: var(--bg-page); border-right: 1px solid var(--border-default); padding: 0.75rem calc(1rem + var(--space-4)) 0.8rem; display: flex; flex-direction: column; gap: 0.35rem; transition: background 0.12s ease; &:last-child { border-right: none; } &:hover { background: var(--bg-surface); } } .sd-health-label { font-size: 0.6rem; font-weight: 700; letter-spacing: 0.09em; text-transform: uppercase; color: var(--text-muted); display: flex; align-items: center; gap: 0.3rem; } // Fill bar — CSS-only, driven by inline style="--pct:N" .sd-health-bar-wrap { position: relative; height: 4px; background: color-mix(in srgb, var(--border-default) 60%, transparent); border-radius: 2px; overflow: hidden; } .sd-health-bar { position: absolute; inset: 0 auto 0 0; width: var(--pct, 0%); border-radius: 2px; transition: width 0.4s ease; .sd-health-card--stability & { background: var(--color-teal); } .sd-health-card--type & { background: var(--color-purple); } .sd-health-card--blast & { background: var(--color-danger); } .sd-health-card--gravity & { background: var(--color-orange); } .sd-health-card--api & { background: var(--color-success); } } .sd-health-score { font-size: 1.1rem; font-weight: 700; font-family: var(--font-mono); line-height: 1; .sd-health-card--stability & { color: var(--color-teal); } .sd-health-card--type & { color: var(--color-purple); } .sd-health-card--gravity & { color: var(--color-orange); } .sd-health-card--api & { color: var(--color-success); } // Blast risk gets tier-specific colour .sd-health-card--blast.sd-blast--critical & { color: var(--color-danger-critical); } .sd-health-card--blast.sd-blast--high & { color: var(--color-danger); } .sd-health-card--blast.sd-blast--medium & { color: var(--color-orange); } .sd-health-card--blast.sd-blast--low & { color: var(--color-success); } .sd-health-card--blast.sd-blast--none & { color: var(--text-muted); } } .sd-health-sub { font-size: 0.62rem; color: var(--text-muted); font-family: var(--font-mono); line-height: 1.3; } // ── Vitals quad (2×2 grid of key numbers in identity strip) ────────────────── .sd-vitals-quad { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem 0.75rem; min-width: 9rem; flex-shrink: 0; } .sd-vitals-cell { display: flex; flex-direction: column; gap: 0.15rem; } .sd-vitals-num { font-size: 1.25rem; font-weight: 700; font-family: var(--font-mono); color: var(--color-accent); line-height: 1; } .sd-vitals-key { font-size: 0.58rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); } // ── Narrative line ──────────────────────────────────────────────────────────── .sd-narrative { font-size: 0.78rem; color: var(--text-secondary); font-family: var(--font-mono); margin: 0.4rem 0 0; line-height: 1.5; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } // ── Blast radius card (Zone 3 right column) ─────────────────────────────────── .sd-blast-radius { display: grid; grid-template-columns: 1fr 1fr; gap: 0.4rem 0.75rem; margin: 0.5rem 0; } .sd-blast-metric { display: flex; flex-direction: column; gap: 0.1rem; } .sd-blast-metric-val { font-size: 1rem; font-weight: 700; font-family: var(--font-mono); color: var(--text-primary); } .sd-blast-metric-lbl { font-size: 0.6rem; font-weight: 600; letter-spacing: 0.07em; text-transform: uppercase; color: var(--text-muted); } .sd-blast-top-list { list-style: none; padding: 0; margin: 0.5rem 0 0; display: flex; flex-direction: column; gap: 0.2rem; } .sd-blast-top-item { font-size: 0.7rem; font-family: var(--font-mono); color: var(--text-secondary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; a { color: var(--color-accent-link); text-decoration: none; &:hover { text-decoration: underline; } } } // ── Refactoring history (Zone 4) ────────────────────────────────────────────── .sd-refactor-section { margin-top: 1.5rem; } .sd-section-title { font-size: 0.65rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); margin: 0 0 0.6rem; display: flex; align-items: center; gap: 0.4rem; } .sd-refactor-list { display: flex; flex-direction: column; gap: 0; border: 1px solid var(--border-default); border-radius: 6px; overflow: hidden; } .sd-refactor-row { display: grid; grid-template-columns: 6rem 1fr auto auto; gap: 0 0.75rem; align-items: center; padding: 0.5rem 0.75rem; background: var(--bg-page); border-bottom: 1px solid var(--border-default); transition: background 0.1s ease; &:last-child { border-bottom: none; } &:hover { background: var(--bg-surface); } @media (max-width: 900px) { grid-template-columns: 5rem 1fr; .sd-refactor-detail { display: none; } } } .sd-refactor-detail { font-size: 0.7rem; font-family: var(--font-mono); color: var(--text-secondary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .sd-refactor-time { font-size: 0.65rem; font-family: var(--font-mono); color: var(--text-muted); white-space: nowrap; } // ── Type health section (Zone 5) ────────────────────────────────────────────── .sd-type-section { margin-top: 1.5rem; } .sd-type-card { background: var(--bg-page); border: 1px solid color-mix(in srgb, var(--color-purple) 25%, transparent); border-radius: 8px; padding: 1rem 1.25rem; display: flex; flex-direction: column; gap: 0.6rem; } .sd-type-row { display: flex; align-items: center; gap: 0.75rem; } .sd-type-label { font-size: 0.65rem; font-weight: 600; letter-spacing: 0.07em; text-transform: uppercase; color: var(--text-muted); min-width: 5rem; } .sd-type-val { font-size: 0.78rem; font-family: var(--font-mono); color: var(--text-secondary); } .sd-type-return { font-family: var(--font-mono); font-size: 0.78rem; color: var(--color-purple); background: color-mix(in srgb, var(--color-purple) 10%, transparent); padding: 1px 6px; border-radius: 4px; } // ── API surface badge ───────────────────────────────────────────────────────── .sd-api-card { background: color-mix(in srgb, var(--color-success) 6%, transparent); border: 1px solid color-mix(in srgb, var(--color-success) 25%, transparent); border-radius: 6px; padding: 0.5rem 0.75rem; display: flex; align-items: center; gap: 0.5rem; font-size: 0.72rem; font-family: var(--font-mono); color: var(--color-success); margin-top: 0.75rem; } // ── Stable card ─────────────────────────────────────────────────────────────── .sd-stable-card { background: color-mix(in srgb, var(--color-teal) 6%, transparent); border: 1px solid color-mix(in srgb, var(--color-teal) 25%, transparent); border-radius: 6px; padding: 0.5rem 0.75rem; display: flex; align-items: center; gap: 0.5rem; font-size: 0.72rem; font-family: var(--font-mono); color: var(--color-teal); margin-top: 0.75rem; } // ── Dead code card ──────────────────────────────────────────────────────────── .sd-dead-card { background: color-mix(in srgb, #79c0ff 6%, transparent); border: 1px solid color-mix(in srgb, #79c0ff 25%, transparent); border-radius: 6px; padding: 0.5rem 0.75rem; font-size: 0.72rem; font-family: var(--font-mono); color: #79c0ff; margin-top: 0.75rem; } // ── Timeline refactor overlay tag ───────────────────────────────────────────── .sd-tl-refactor-tag { display: inline-flex; align-items: center; font-size: 0.58rem; font-weight: 700; letter-spacing: 0.04em; padding: 1px 5px; border-radius: 3px; text-transform: lowercase; white-space: nowrap; background: color-mix(in srgb, var(--color-purple) 12%, transparent); color: var(--color-purple); border: 1px solid color-mix(in srgb, var(--color-purple) 30%, transparent); } // ── Pagination controls ─────────────────────────────────────────────────────── .sym2-pagination { display: flex; align-items: center; gap: 0.15rem; padding: 0.5rem 0 0.2rem; justify-content: flex-start; } .sym2-page-btn { display: inline-flex; align-items: center; justify-content: center; width: 1.5rem; height: 1.5rem; border-radius: 4px; background: transparent; color: var(--color-accent-link); font-size: 0.8rem; text-decoration: none; border: none; transition: color 0.15s, background 0.15s; line-height: 1; cursor: pointer; &:hover { background: var(--bg-elevated); color: var(--text-primary); } &--off { color: var(--text-disabled); cursor: default; pointer-events: none; } } .sym2-page-indicator { font-size: 0.7rem; color: var(--text-muted); padding: 0 0.4rem; white-space: nowrap; }