diff --git a/.gitignore b/.gitignore index 84a7f19..62ffbc7 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,4 @@ doc/html .DS_Store +node_modules +.dev diff --git a/boostlook-v3.css b/boostlook-v3.css index 00479a8..3843fbd 100644 --- a/boostlook-v3.css +++ b/boostlook-v3.css @@ -127,7 +127,12 @@ * 6. Responsive Design - Mobile-first breakpoint variables */ -:root:has(.boostlook) { +/* Core design tokens. Scoped to the .boostlook subtree (not the page root) so a + component island on a v3 site page cannot redefine the host page's tokens + (which caused the hero heading to shift). The :root:not(.v3) branch keeps them + page-level for full-page docs, whose html has no .v3. */ +:root:not(.v3):has(.boostlook), +.boostlook { /* General Variables - Core design tokens for all themes */ --bl-primary-color: rgb(255, 159, 0); /* Boost's signature orange color */ @@ -207,7 +212,7 @@ --colors-secondary-950: #000d14; /* Atom One Dark Theme Colors */ - --atom-one-dark-bg: #282c34; + --atom-one-dark-bg: #1A1C29; /* code block surface — Figma 2.0 dark (= primary-850) */ --atom-one-dark-text: #FFFFFF; --atom-one-dark-keyword: #c678dd; --atom-one-dark-operator: #e06c75; @@ -215,7 +220,7 @@ --atom-one-dark-class: #e6c07b; /* Atom One Light Theme Colors */ - --atom-one-light-bg: #fafafa; + --atom-one-light-bg: #ffffff; /* code block surface — Figma 2.0 (#116-5) */ --atom-one-light-text: #050816; --atom-one-light-keyword: #a626a4; --atom-one-light-operator: #e45649; @@ -426,7 +431,8 @@ /*----------------- New Look Responsive Desktop Start -----------------*/ @media (min-width: 768px) { - :root:has(.boostlook) { + :root:not(.v3):has(.boostlook), + .boostlook { /* Spacing — Metalab 2.0 (desktop) */ --spacing-xs: 0.125rem; --spacing-s: 0.25rem; @@ -489,15 +495,17 @@ --typography-line-height-4xl: var(--font-line-height-4xl); /* Heading — Metalab 2.0 (desktop) */ - --typography-font-size-h1: var(--font-size-4xl); - --typography-font-size-h2: var(--font-size-lg); - --typography-font-size-h3: var(--font-size-md); - --typography-font-size-h4: var(--font-size-sm); + --typography-font-size-h1: 3rem; /* 48px — Figma Title / 2XL */ + --typography-font-size-h2: var(--font-size-xl); /* 24px — Figma Large */ + --typography-font-size-h3: var(--font-size-md); /* 18px */ + --typography-font-size-h4: var(--font-size-sm); /* 16px */ } } @media (min-width: 990px) { - :root:has(.boostlook) { + /* Doc-layout widths, read by ancestors outside .boostlook, so they stay on + :root. Gated :not(.v3) so they don't land on a v3 site page. */ + :root:not(.v3):has(.boostlook) { --main-max-width-leftbar: 21.25rem; --main-margin: 8.625rem; } @@ -517,8 +525,12 @@ * 2. Dark Theme (activated by html.dark class) */ -/* Light Theme (Default) Configuration */ -html:has(.boostlook) { +/* Light Theme (Default) Configuration. + Defined on the .boostlook scope (not the page root) so a component island on + a v3 site page does not push these theme vars onto the host :root. The + :root:not(.v3) branch keeps them page-level for full-page docs. */ +:root:not(.v3):has(.boostlook), +.boostlook { color-scheme: light; /*----------------- New Look Variables Start -----------------*/ --icon-anchor: var(--icon-anchor-light); @@ -633,7 +645,7 @@ html:has(.boostlook) { --surface-icons-icon-blue: var(--colors-secondary-600); --surface-icons-icon-blue-light: var(--colors-secondary-200); - --border-border-primary: var(--colors-primary-100); + --border-border-primary: rgba(5, 8, 22, 0.1); /* Figma 2.0 standard 1px border (light) */ --border-border-secondary: var(--colors-primary-150); --border-border-tetriary: var(--colors-primary-300); --border-border-quaternary: var(--colors-primary-600); @@ -649,13 +661,15 @@ html:has(.boostlook) { --surface-weak: var(--colors-primary-0); --stroke-strong: rgba(5 8 22 / 0.25); --stroke-mid: rgba(5 8 22 / 0.17); - --stroke-weak: rgba(13 14 15 / 0.1); + --stroke-weak: rgba(5 8 22 / 0.1); /* Figma 2.0 standard 1px stroke (light) */ /*----------------- New Look Variables End -----------------*/ } -/* Dark Theme Configuration */ -html.dark:has(.boostlook) { +/* Dark Theme Configuration. Scoped like the light theme above so dark theme + vars land on the .boostlook subtree, not the host :root, on v3 site pages. */ +html.dark:not(.v3):has(.boostlook), +html.dark .boostlook { color-scheme: dark; /*----------------- New Look Variables Dark Mode Start -----------------*/ --icon-anchor: var(--icon-anchor-dark); @@ -769,7 +783,7 @@ html.dark:has(.boostlook) { --surface-icons-icon-blue: var(--colors-secondary-400); --surface-icons-icon-blue-light: var(--colors-secondary-700); - --border-border-primary: var(--colors-primary-850); + --border-border-primary: rgba(247, 247, 248, 0.1); /* Figma 2.0 standard 1px border (dark) */ --border-border-secondary: var(--colors-primary-800); --border-border-tetriary: var(--colors-primary-700); --border-border-quaternary: var(--colors-primary-500); @@ -785,15 +799,18 @@ html.dark:has(.boostlook) { --surface-weak: var(--colors-primary-850); --stroke-strong: rgba(247 247 248 / 0.21); --stroke-mid: rgba(247 247 248 / 0.17); - --stroke-weak: rgba(255 255 255 / 0.1); + --stroke-weak: rgba(247 247 248 / 0.1); /* Figma 2.0 standard 1px stroke (dark) */ /*----------------- New Look Variables Dark Mode Start -----------------*/ } /*----------------- HTML Variables - End -----------------*/ -/* Override for Antora default styles */ -html:has(.boostlook) { +/* Override for Antora default styles. + Gated :not(.v3): page-level html props (root font-size, height, scroll) must + not apply when .boostlook is only a component island on a v3 site page. Docs + render in an iframe whose html has no .v3, so they keep this. */ +html:not(.v3):has(.boostlook) { -webkit-box-sizing: border-box; box-sizing: border-box; font-size: 1rem; @@ -1048,13 +1065,20 @@ html:has(.boostlook) { } /* Heading Sizes — Metalab 2.0 */ -/* h1: Display/Desktop/Medium/3XL */ +/* h1: Title / 2XL (48px desktop) */ .boostlook h1, .boostlook .doc h1 { font-size: var(--typography-font-size-h1, 2rem); letter-spacing: -0.01em; } +/* Antora pins its page title via .doc>h1.page:first-child (0,3,1), which beats + .boostlook .doc h1 (0,2,1); restate the global h1 size at higher specificity + (0,4,1) so the title matches across Antora + AsciiDoctor. */ +.boostlook .doc > h1.page:first-child { + font-size: var(--typography-font-size-h1, 3rem); +} + /* h2: Display/Desktop/Medium/Large */ .boostlook h2, .boostlook .doc h2 { @@ -1324,6 +1348,40 @@ html:has(.boostlook) { margin-top: var(--padding-padding-md, 1rem); } +/* Markdown paragraphs — plain

siblings rendered by markdown (site + components, READMEs) that lack Antora's .paragraph wrapper, so the rule + above never matches them. Scoped :not(:has(.doc)) so Antora doc content + keeps its own structure-based spacing below. */ +/* The :not(...) guards are wrapped in :where() so they add no specificity: + this bare-markdown layer is a low baseline (.boostlook + element level) that + component rules (e.g. .boostlook.markdown-content ul) can override cleanly. */ +.boostlook:where(:not(:has(.doc))) p + p { + margin-top: var(--padding-padding-md, 1rem); +} + +/* Markdown lists — bare