Move the card-form geometry (type_toggle_rect / field_input_rect /
form_actions_y / form_card_h + their constants) into the
agent_settings_acp_helpers sibling so agent_settings_acp.rs drops back
under the 800-line cap (829 -> 784). A saved card being edited shows no
Save/Cancel row, so card_height wraps just the fields (form_actions_y),
not the draft's action-row tail — restoring the Local saved-edit height
(332) the previous commit inflated to 370.
The ACP draft/editing card height + Save/Cancel row position now derive
from the connection type's field set, so a Remote agent (Display name +
URL) no longer leaves a tall empty gap below the URL field that Local's
(Command/Args/Env) layout reserved. The disabled Save button renders as a
neutral Outline (white in light mode) instead of a washed-out pale-primary
fill.
The TopBar globe + file-menu SelectTriggers now pass bordered:false (no
Outline box, just the icon+chevron with a hover wash); the form-field
dropdowns keep the border. The git commit-message TextArea (ready +
status panels) now paints through BaselineAdjustingBackend so its text
sits on the baseline instead of clipping at the top. Bumps vendor/jian.
jian a53a61c: ColorPicker's box-centered labels now route through
centered_text_baseline_y like every other component; non-box-centered
placements (RGB captions, Dialog title) and the host-baselined input
glyph layers are documented exceptions.
jian dc15ea7: component labels (buttons, tabs, toggles, badges, menus,
dropdowns, tooltips, accordions) now position text by the BASELINE
(center + font_size*0.35) instead of the (height - font_size)/2 top-left
form, so they no longer render ~font_size too high in the editor chrome.
Input glyph layers stay top-relative (the host's BaselineAdjustingBackend
handles their baseline).
The Design-MD panel's markdown parser (block structure + inline
bold/code/#HEX styling + run wrapping) moves to jian components::markdown;
design_md_markdown.rs becomes a thin re-export so the panel's block
renderer is unchanged. ~300 fewer lines of OP-domain parsing. Bumps
vendor/jian to 94f8315.
The floating color picker's rendering, layout, hit-test and HSV<->RGB
math now live in jian ColorPicker; color_picker.rs shrinks to a wrapper
that owns the property-panel-relative anchor (rect), the EditorState
plumbing and the drag dispatch, re-exporting hsv_to_rgb / rgb_to_hsv /
ColorPickerHit / PICKER_* so the hosts import them unchanged. ~330 fewer
lines of OP-specific paint. Bumps vendor/jian to 9580247.
Review found the axis-tab paint (jian content_rects, advance = width+gap)
drifted 6px from the hit walker (theme_tab_advance_width) for tabs to the
right of an inline-renaming axis, where the two advances differ. Feed
content_rects the host's per-tab advances (theme_tab_advance_width for
variables; width+CHIP_GAP for the framework chip) so paint and hit share
the same advance source and can't drift in any state. Bumps vendor/jian
to f0fbf70.
The theme-axis tab strip renders through jian Tabs content-width mode
(Text active style + trailing chevron on the active axis, which doubles
as the axis-value dropdown trigger) instead of a hand-rolled label loop.
The host keeps the inline-rename overlay (an opaque input over the
renaming tab), the +Add / Preset / Close buttons, and the theme_tab_rect
hit walker — whose geometry matches content_rects for normal tabs.
The scrollable, variable-width framework chip carousel now lays out via
jian Tabs::content_rects and renders via Tabs::paint_content (PrimaryPill
active style) instead of a hand-rolled chip loop; the host keeps its
deterministic width fn, scroll state, clip band and chevrons. Both paint
and hit go through the jian layout, so they stay aligned. Bumps
vendor/jian to ed15b1e (Tabs content-width flexibility).
paint_section_divider (11 call sites), paint_hairline (4), and the two
paint_divider helpers (7) now draw through jian Separator — the canonical
1px-line primitive — instead of ad-hoc fill_rect; the top-bar one is a
vertical separator. First OP consumer of jian Separator; ~22 dividers
share one primitive with no caller changes.
The IconButton migration pushed ai_chat_panel.rs to 801 lines (over the
repo's 800-line cap). Move draw_label / chat_neutral_hover_color /
chat_neutral_feedback_color into the ai_chat_panel_controls sibling
(backend trait already in scope there) and re-export them, so callers
and tests are unchanged. ai_chat_panel.rs is now 780 lines.
The AI-chat header (New Chat / maximize), component-browser header
(close + export/import kit), icon-picker close, and figma-import close
buttons now render through jian IconButton instead of hand-rolled
paint_ghost_button_feedback + draw_icon. Drops the now-orphaned
paint_header_btn_bg helper; host hit-tests are unchanged.
The gradient-stop and shadow-color swatches now paint through jian
Swatch (alpha-aware checker + fill) instead of the local paint_alpha_checker
+ separate fill; drops paint_alpha_checker and its public re-export.
Bumps vendor/jian to 9c13e8d (checker now theme-independent, so the
transparency pattern stays visible in dark mode).
Codex/multi-agent review found the text h/v-align ToggleGroup hit rects
sat 14px (LH_LS_LABEL_H) above where they paint: text_action_rects
omitted the 行高/字间距 caption row that paint_text_section and
push_text_input_rects both include, so the bottom half of each align
toggle was a dead zone and the band above misfired. Add the missing
LH_LS_LABEL_H term. Also refresh two tests left stale by the jian Button
migration (kit-dropdown pressed-feedback radius 4→6; code Export-bundle
hover wash now jian Ghost's button_hover, not a boosted alpha).
The widget + size-section check rows and the flex gap-alignment radio
now paint through jian Checkbox / Radio (first consumers) instead of
hand-rolled box+check / ring+dot; row hit-tests are unchanged.
property_panel_sections::paint_flex_section was an unreferenced leftover
from when the flex section moved to property_panel_flex (the only wired
paint_flex_section). Removes the stale gapped-cell duplicate.
The Free/Vertical/Horizontal layout-direction icon selector renders
through jian ToggleGroup (icon segments, font_size 14 → 18px icons) over
the same footprint; its hit walker switches to the continuous even cells
ToggleGroup paints so paint + hit stay aligned.
The horizontal/vertical text-align icon selectors render through jian
ToggleGroup (icon segments, font_size 12 → 16px icons); their hit cells
switch from gapped to the continuous even cells ToggleGroup paints so
paint + hit stay aligned.
The Auto/Fixed-width/Fixed-width+height text-growth selector renders
through jian ToggleGroup; its hit walker switches from gapped cells to
the continuous even cells ToggleGroup paints, so paint + hit stay aligned
with no inter-cell dead zones.
The Contain/Cover/Stretch mode selector renders through jian ToggleGroup
(even cells aligned with its existing full-cell hit walker) instead of a
hand-rolled muted track + inset chip loop; active cell fills primary.
The Anthropic/OpenAI kind segmented control now renders + hit-tests
through jian ToggleGroup (segment_at) instead of a hand-rolled cell
loop + kind_option_rect. Drops the KindOption.slot indirection and the
kind_option_rect helper; single-option presets render full-width.
Bumps vendor/jian to 3b5db91.
All op-editor-ui jian Button call sites move from icon_d to icon_paths.
The code panel's Generate / Export-bundle icon+label buttons and the
Design-MD action buttons now render through jian Button with full
multi-subpath icons (sparkles / braces / wand), dropping the local
paint_centered_icon_label hand-rolling + paint_primary_hover_overlay.
Bumps vendor/jian to 9998df9.
Export-section, export-dialog (Cancel→Outline, Export→Primary), image
generate-popover (Apply→Primary, Retry→Outline) and the code-panel
full-width action button now render through jian Button instead of
hand-rolled fill_round_rect + hover overlay + centered draw_text. The
solid-fill hover-darken now lives in the component, so per-button hover
state threads straight through. Bumps vendor/jian to 330feb4.
Connect renders through jian Button Primary (centered label, primary
fill) and Disconnect through the new DestructiveOutline variant (red
border + red label) instead of hand-rolled fill_round_rect + centered
draw_text. Bumps vendor/jian to 9e47bd3.
Fill section head-row fill-type dropdown now renders through jian
SelectTrigger (Outline box + chevron + own hover/press feedback)
instead of a hand-rolled label+glyph; the Design-MD empty-state action
buttons render through jian Button (Secondary, muted fill) so the CTA
affordance and feedback are the component's concern, not the panel's.
Drops the now-dead label_char_w helper.
The kit-filter dropdown trigger (feedback wash + border + truncated label + chevron) now renders via jian SelectTrigger — one component call, feedback/label/chevron all internal. Demonstrates the dropdown 收口 pattern. Bumps vendor/jian to 144eb50.
top_bar paint_icon_button, design_md icon_button, and the align-toolbar align-icon row now render via jian IconButton instead of hand-rolling feedback + draw_icon. Their hover/active rendering is now the component's concern. align-toolbar idle icons go muted_foreground (shadcn toolbar look). Left compound (icon+chevron/brand-logo), labelled, and text-glyph buttons untouched — they aren't single lucide-icon buttons.
toolbar's paint_button now renders jian IconButton (icon.paths() -> generic d-strings); removed the OP-local IconButton struct + paint_icon_button helpers from button.rs (the component now lives in jian). Bumps vendor/jian to 346eeb3. Other scattered icon buttons migrate next.
Adds button::paint_icon_button (full icon button = hover/pressed/active feedback on jian Button + centred icon) and paint_icon_button_feedback (the bg+active funnel). toolbar's paint_button now delegates to it instead of hand-rolling active-fill + ghost-feedback + draw_icon separately. All toolbar icon buttons (tool buttons + shape slot) now funnel hover/active rendering through one place. Active highlight now jian Button Primary (r6). Removed dead BUTTON_RADIUS.
agent_settings_acp.rs was over the 800-line cap (817 after the Card sink; ~812 before); moved draw_text + ellipsize into agent_settings_acp_helpers.rs. File now 798 lines, op-editor-ui clean.
agent_settings_mcp client-config card (card fill, r8) + agent_settings_system auto-update card (muted fill, r10) now route their chrome through jian Card, looks preserved. Three agent-settings cards now share the canonical primitive.
paint_agent_card's hand-rolled conditional fill_round_rect + stroke_round_rect chrome now goes through jian Card; the fill choice (outlined ClaudeCode -> muted, hover -> accent, else transparent) stays caller-side so the look is preserved exactly (radius 10, border). Bumps vendor/jian to 5f903d6. Demonstrates the enhance-jian-then-sink pattern.
Codex review of the web twin flagged a Ref-anchor mismatch: set_selected_color
is a no-op on a Ref (it carries no fill/stroke slot), so the doc write does not
land — yet the scene patch would still mutate the Ref's scene node, briefly
showing a colour the document never received (snapping back on release). Native
caught the common case via its instance-write redirect, but a non-redirected
Ref (and any gradient-only / slotless node) slipped through on both paths.
Gate both try_patch_color_drag paths on the freshly-written hex actually being
present (first_solid_fill_hex / first_solid_stroke_hex); absent → the write did
not land → fall back to the full rebuild. Same conservative guard on native +
web.
Web twin of 8b457a50/9056458c: a colour-picker drag rebuilt the whole layout
per mouse-move (doc fill changed → scene cache miss → taffy + reshape) though
a solid colour touches no layout. try_patch_color_drag patches the anchor's
resolved scene fill / stroke via LayoutScene::set_node_fill /
set_node_stroke_color (folding paint-body + node opacity) and invalidates the
cache. The patch path still flags doc_sync_dirty (live-canvas push) but skips
the scene rebuild — reachable from this descendant module without touching the
spine. Variable-mode / gradient-stop / effect / new-stroke fall back to rebuild.
Codex review caught a BLOCKER: the loader folds TWO opacity factors into
resolved scene paint alpha — the fill/stroke body's own opacity (apply_alpha
in style_payload) AND node cumulative opacity — but the colour-drag fast path
only baked node opacity, so a fill/stroke authored below 100% painted too
opaque on every drag frame until release reconciled. Fold the body opacity in
host-side via first_solid_fill_opacity / new first_solid_stroke_opacity before
the patch; jian-scene still bakes node opacity on top, matching scene-build.
+unit test for the new stroke-opacity accessor.
A colour-picker drag rewrites doc fill on every mouse-move, so the scene
build cache (which compares the doc) rebuilt the whole layout — taffy + a
full SceneNode reshape — per drag frame, even though a solid colour change
touches no layout. Mirror the node-drag fast path: patch the anchor's
resolved scene fill / stroke via LayoutScene::set_node_fill /
set_node_stroke_color and invalidate the cache, skipping mark_dirty so the
patch survives the frame. Variable-mode, instance redirects, gradient-stop /
effect targets, and brand-new strokes fall back to the full rebuild.
Bumps vendor/jian to a86832d (the scene-patch methods). Native only; the
web host's live-sync push gate needs the same wiring once its spine settles.
paint_settings_switch dropped its hand-rolled track+thumb paint and now delegates to jian Switch (geometry identical: knob 16, inset 2). Removes the duplicated switch paint; off-track is now the shadcn input token. Hit stays host-side rect.contains (behavior-identical on desktop). Bumps vendor/jian to 2708666. First Phase A component sink.
Theme gains the canonical shadcn fields; button::tokens_from_theme maps them into jian Tokens (+ radius 6.0). Unblocks the Switch off-track=input reconciliation and Button secondary variant. Bumps vendor/jian to 9cd5d50.
6 git_panel modules each duplicated fn alpha (RELATIVE: multiplies c.a*factor) and git_panel_empty duplicated over(). Hoisted to util::alpha / util::over (single source); locals now delegate. NOTE: align_toolbar::alpha SETS absolute alpha (Color{a,..}) — a different op (= Color::with_alpha), deliberately left separate. Part of atomic-sink Phase 0.4.