Commit Graph

9 Commits

Author SHA1 Message Date
浅念 c318829ff3 feat: port cms home layout into trade-pro (hero/features/cards/cta + reveal JS)
Task 10a (Phase 3 first layout task). home.html now mirrors the cms
astro-site-runtime homepage section sequence: full-bleed hero (single
active slide; the platform has no multi-slide config, so the carousel
dots/JS are not ported), trustbar, two-col about with floating stats,
soft products band (4-card grid), dark applications band (2x2 case
tiles), advantages feature grid, soft news band (3-card grid), and the
closing cta band. Data maps to SiteForge context (page.cover/summary,
showcase, cases, stories, category/brand counts); empty sections hide
instead of rendering shells. All new component classes are sf-tp-*
prefixed and compose on the Task 8 base utilities in theme.css
(.wrap/.section/.eyebrow/.icon-circle/.sf-tp-btn).

CSS: the five cms components' scoped styles (PageHero, FeatureGrid,
CardGrid, Cta, SectionHead + the inline homepage bands) are extracted
into pro.css as the sf-tp-* component layer, tokens rewritten to
--sf-tp-*, breakpoints 900/767/620 preserved. theme.css accordingly
drops the superseded generic .cards/.card/.feature mobile baselines
and the .pro-home-hero em bridge, and retargets the dark-surface ghost
button hook from .cta-band to .sf-tp-cta.

Reveal: cms uses data-reveal everywhere; a ~15-line inline script at
the pro.html tail adds html.js + an IntersectionObserver that toggles
is-visible (the reduced-motion/no-JS exemptions already live in
theme.css from Task 8).

Tests: test_theme_registry gains test_trade_pro_home_layout_structure
(preview-render contract: sf-tp-hero, card grid, feature grid, cta,
no pro-industrial-hero residue, reveal script). The distinct-markup
tripwire in test_theme_pro_v3 is legitimately updated 4 -> 5 (renamed
to drop the stale "four"): with trade-pro now carrying its own
sf-tp-hero class, five themes yield five distinct hero signatures,
which is what the test always meant to enforce.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-10-23 09:23:30 +08:00
浅念 1dd510285a polish: icon sizing hardened for cross-browser (review I-1/M2/M3/M4)
- .sf-tp-icon CSS width/height (Safari doesn't support var() in SVG
  presentation attributes); --sm variant class replaces size= call sites
- search icon centered via translateY, decoupled from input height
- bare-arrow test: full charset (→←↗↘⌕▾) + line-level › whitelist
- new test: site.html tp_arrow must stay in sync with macro library path

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-10-23 09:00:50 +08:00
浅念 22b614118b feat: SVG icon macro library replaces bare text arrows in trade-pro
Task 9 (new design, not a cms port): _professional_components.html gains
an icon(name, size, cls) macro — 10 inline line-style glyphs (arrow-right,
arrow-left, chevron-down, check, phone, mail, location, download, search,
quote), 24x24 viewBox, stroke=currentColor, stroke-width 1.5, round
caps/joins, decorative aria-hidden + focusable=false, default size
var(--sf-tp-icon-size-md, 20px), unknown names fall back to arrow-right.
Every glyph is a single <path> so the d attribute needs no |safe.

All bare text arrows (->, <-, ↗, ▾, ⌕) in the macro library, pro.html,
site.html and pages/* are replaced with macro calls (site.html keeps a
self-contained copy of the arrow glyph because its rendering envs cannot
import the macro library); the filters macro search box gains an inline
search icon; footer links gain small arrows. theme.css adds .sf-tp-icon
alignment, in-button icon spacing, and search-box icon positioning.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-10-23 08:35:52 +08:00
浅念 afecc10aad fix: scope trade-pro element baselines to body class (review I-1/I-2/I-3)
- body/h1-h4/p/a/:focus-visible/label/input/details/summary now under
  .sf-theme-trade-pro so they win the cascade over platform pro-base.css
  (cms typography actually applies now)
- same scoping inside the 620px mobile block to keep overrides effective
- data-reveal gated behind html.js + comment states Task 10 JS dependency

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-10-23 08:22:41 +08:00
浅念 0859893e65 feat: port cms design tokens and base styles into trade-pro theme.css
Full port of astro-site-runtime tokens.css (183 tokens, V2 bright-blue)
and base.css (element baseline, layout utilities, forms, FAQ, reveal
motion, 620px mobile block) into the trade-pro theme. All cms variables
renamed with the --sf-tp- prefix keeping semantic names; button system
rebuilt as sf-tp-btn with sm/lg sizes and ghost/outline/round variants
so platform custom.css (.btn/.primary/.request/.button/.nav-btn) can
never restyle it. Phase-2 short token aliases (--sf-tp-primary etc.)
and .pro-* bridge rules retained, now driven by the cms tokens.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-10-23 08:07:34 +08:00
浅念 2527f7ced9 feat: register trade-pro in theme color map and all six frontend entry points
Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-10-22 18:51:27 +08:00
浅念 2a2f943bf4 fix: trade-pro review fixes — drop shadow blocks.css, English presets, 7-item fallback nav
- remove themes/trade-pro/blocks.css (52-byte placeholder shadowed the
  platform 7KB block stylesheet via copy_blocks_css) and drop it from
  manifest styles; Phase 3 brings real component styles
- page-presets.json: all editor/bootstrap copy translated to trade B2B
  English; ids, block types, structure and hrefs identical to industrial
- fallback nav widened to all 7 default sections (Brands/Cases restored)
  so the documented false-positive window only relabels, never drops
  coverage; comment added next to the tp_needs_en_nav set
- test anchors '>Products<' on the built home page

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-10-22 18:40:49 +08:00
浅念 5797638caf feat: trade-pro skeleton theme package (Phase 2)
Fifth built-in theme: English-first international B2B skeleton registered
via manifest discovery, builds real sites end-to-end. pro.html derives
from industrial with lang=en, href-set value-comparison English fallback
nav (header + footer), sf-tp-* button classes and hard-coded #0b3d91
theme-color until the map entry lands. pages/ ships all 14 kinds; macro
library is an English passthrough copy pending the Phase 3 cms port.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-10-22 18:19:30 +08:00
浅念 8cea7dee20 chore: baseline V8.10.0-dev.1 with v8_workflows type-mapping fix and trade-pro spec
- SiteForge Enterprise V8.10.0-dev.1 upstream source (210 tests)
- Fix: v8_workflows._mapped_input now reads both 类型/分类 columns so WXR
  imports keep post/product types instead of collapsing to page
- Docs: trade-pro theme port spec (R3) and implementation plan

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-10-22 16:49:25 +08:00