Skip to content

fix(chips,code): no white square behind a favicon, and an untitled code block's buttons float over its corner - #492

Merged
vite-hub[bot] merged 7 commits into
mainfrom
fix/chips-favicon-code-floating-actions
Nov 27, 2026
Merged

vite-hub[bot] merged 7 commits into
mainfrom
fix/chips-favicon-code-floating-actions

Conversation

@onmax

@onmax onmax commented Nov 27, 2026 •

Copy link
Copy Markdown
Owner

Two fixes for things that looked off on rendered pages.

Chips: no white square around a favicon in the light theme

The default favicon source is Google's s2 service, and it returns opaque PNGs: vite.dev's icon comes on #fafafa, github.com's on white. On the light chip (#f5f5f5-ish) that shows as a lighter square around the icon.

In the light theme the favicon now blends with mix-blend-mode: darken. Darken keeps the darker of the icon and the chip per channel, so any part of the icon lighter than the chip takes the chip's fill and the square goes away, whatever the source and whether the icon has transparency. I tried multiply first: it left a square about 2% darker than the chip, because Google's background is #fafafa, not pure white (measured at 4x: the chip is 245, multiply left the square at 241, darken at 246). Switching the source wasn't an option: DuckDuckGo's icon service returns 404 for vitehub.dev and models.dev.

The dark theme keeps its white plate under the favicon and sets mix-blend-mode: normal, so a dark icon still reads on a dark chip.

Code: buttons float over the corner instead of a header bar

A block without a title used to get a header bar and an empty row above its first line. Now:

  • Only a block with a title ([file.ts] or title="...") gets the header. The language alone no longer makes one, so ts and sh blocks lose the language label they showed in that bar.
  • A block without a title makes no room. Its buttons float in the top right corner over the code, shown on hover and focus-within, and always where there is no hover (@media (hover: none)). While Copy's status ("Copied", "Couldn't copy…") is up, the buttons stay shown after the pointer leaves.
  • The fade is opacity only, so the buttons stay focusable and Tab brings them back.
  • The floating buttons sit on --ck-surface, a new variable that defaults to --comark-accent, the background comark-ui's typeset gives pre. It's laid on --comark-background, so a translucent surface still hides the code, and it runs to the block's top and right edges, so no code shows between the buttons and the edge.
  • data-code-header containers (code groups, tabs, magic move) and titled blocks keep their header as before.

The docs site needed two lines of its own: @vite-hub/docs paints the block's surface on a frame and leaves pre transparent, with the frame's ring as an inset box-shadow. docs/app/assets/landing.css sets --ck-surface to the frame's color and draws the ring on a ::after above the block, so the floating surface doesn't cover it. The code docs say the same for other hosts.

Evidence

Before/after of /chips and /code in light and dark, from https://comark-ui.onmax.me (main) and this branch's docs build: https://drop.vitehub.dev/d/aafr9nw3pcwh/comark-ui-492-before-after

Checks

  • Unit tests for code, chips, tabs, magic-move, motion and styles (218 passed). New: the light-theme darken rule and the dark plate's normal, the titled-only header padding, the floating bar's surface.
  • Browser tests for code, chips, motion, motion-press, tabs, magic-move, tabs-magic and contrast (57 passed). New: an untitled block has no title or border, its line starts at the host's padding, Copy sits 6px from the corner, the surface reaches the block's top and right edges, opacity goes 0 → hover 1 → leave 0 → Tab to Run 1, and with no script hover shows nothing; Copy's status keeps the buttons shown after the pointer leaves, under Copy and aligned to its right edge.
  • pnpm docs:generate (links of 441 pages checked), doctor for code and chips, lint:docs, vp fmt, vp lint, typecheck.
  • Checked by eye in Chromium, light and dark, on the docs build and on a plain page: hover, keyboard focus, the copy-failed status, a code group's header.

Not covered: the hover: none rule has no browser test, only the CSS.

🤖 Generated with Claude Code

… and run it to the block's edges, so no code shows through or beside them
@vite-hub

vite-hub Bot commented Nov 27, 2026 •

Copy link
Copy Markdown
Contributor
Session Status Started Duration
Pending Completed Not started —
View session Completed 2026-11-27T12:38:30.445Z 1m 2s
View session Starting Not started —

Latest result

Pull request merged.

Final answers

Session

Pull request merged.

View session

PR #492 is ready to merge. The clipped-grid toolbar fix passed hosted E2E, all current-head checks passed, and all review threads are resolved. All 49 focused unit tests passed locally, and running the linter directly produced warnings only. No new commit was needed.

Session

Pushed c3fac28 to fix the P1 grid-frame height oscillation and resolved the review thread. The sizing model confirmed that the frame stays stable while the toolbar wraps and shrinks when it unwraps. All 24 focused unit tests passed, and lint completed with warnings only. The sandbox blocked the local browser test server, so the new Chromium regression awaits hosted CI.

Session

Pushed c3fac28 to fix the P1 grid-frame height oscillation and resolved the review thread. The sizing model confirmed that the frame stays stable while the toolbar wraps and shrinks when it unwraps. All 24 focused unit tests passed, and lint completed with warnings only. The sandbox blocked the local browser test server, so the new Chromium regression awaits hosted CI.

Session

Pushed c3fac28 to fix the P1 grid-frame height oscillation and resolved the review thread. The sizing model confirmed that the frame stays stable while the toolbar wraps and shrinks when it unwraps. All 24 focused unit tests passed, and lint completed with warnings only. The sandbox blocked the local browser test server, so the new Chromium regression awaits hosted CI.

Session

Pushed c3fac28 to fix the P1 grid-frame height oscillation and resolved the review thread. The sizing model confirmed that the frame stays stable while the toolbar wraps and shrinks when it unwraps. All 24 focused unit tests passed, and lint completed with warnings only. The sandbox blocked the local browser test server, so the new Chromium regression awaits hosted CI.

Session

Pushed c3fac28 to fix the P1 grid-frame height oscillation and resolved the review thread. The sizing model confirmed that the frame stays stable while the toolbar wraps and shrinks when it unwraps. All 24 focused unit tests passed, and lint completed with warnings only. The sandbox blocked the local browser test server, so the new Chromium regression awaits hosted CI.

@chatgpt-codex-connector

Copy link
Copy Markdown
Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ❌ Failed 2026-11-27T09:24:04.721033Z
We couldn’t complete this review. Comment @codex review to try again.
3079f65 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@pkg-pr-new

pkg-pr-new Bot commented Nov 27, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

comark-annotate

pnpm add https://pkg.pr.new/comark-annotate@492

comark-badge

pnpm add https://pkg.pr.new/comark-badge@492

comark-bundle

pnpm add https://pkg.pr.new/comark-bundle@492

comark-cards

pnpm add https://pkg.pr.new/comark-cards@492

comark-carousel

pnpm add https://pkg.pr.new/comark-carousel@492

comark-cast

pnpm add https://pkg.pr.new/comark-cast@492

comark-charts

pnpm add https://pkg.pr.new/comark-charts@492

comark-chat

pnpm add https://pkg.pr.new/comark-chat@492

comark-chips

pnpm add https://pkg.pr.new/comark-chips@492

comark-cjk

pnpm add https://pkg.pr.new/comark-cjk@492

comark-code

pnpm add https://pkg.pr.new/comark-code@492

comark-code-notes

pnpm add https://pkg.pr.new/comark-code-notes@492

comark-colors

pnpm add https://pkg.pr.new/comark-colors@492

comark-comments

pnpm add https://pkg.pr.new/comark-comments@492

comark-critic

pnpm add https://pkg.pr.new/comark-critic@492

comark-deflist

pnpm add https://pkg.pr.new/comark-deflist@492

comark-details

pnpm add https://pkg.pr.new/comark-details@492

comark-diagrams

pnpm add https://pkg.pr.new/comark-diagrams@492

comark-diff

pnpm add https://pkg.pr.new/comark-diff@492

comark-embed

pnpm add https://pkg.pr.new/comark-embed@492

comark-fields

pnpm add https://pkg.pr.new/comark-fields@492

comark-figure

pnpm add https://pkg.pr.new/comark-figure@492

comark-file-tree

pnpm add https://pkg.pr.new/comark-file-tree@492

comark-footnotes

pnpm add https://pkg.pr.new/comark-footnotes@492

comark-git-graph

pnpm add https://pkg.pr.new/comark-git-graph@492

comark-github

pnpm add https://pkg.pr.new/comark-github@492

comark-icon

pnpm add https://pkg.pr.new/comark-icon@492

comark-include

pnpm add https://pkg.pr.new/comark-include@492

comark-keys

pnpm add https://pkg.pr.new/comark-keys@492

comark-links

pnpm add https://pkg.pr.new/comark-links@492

comark-linter

pnpm add https://pkg.pr.new/comark-linter@492

comark-magic-move

pnpm add https://pkg.pr.new/comark-magic-move@492

comark-mark

pnpm add https://pkg.pr.new/comark-mark@492

markdown-it-to-comark

pnpm add https://pkg.pr.new/markdown-it-to-comark@492

marked-to-comark

pnpm add https://pkg.pr.new/marked-to-comark@492

comark-mathml

pnpm add https://pkg.pr.new/comark-mathml@492

comark-media

pnpm add https://pkg.pr.new/comark-media@492

comark-metrics

pnpm add https://pkg.pr.new/comark-metrics@492

migrate-to-comark

pnpm add https://pkg.pr.new/migrate-to-comark@492

comark-motion

pnpm add https://pkg.pr.new/comark-motion@492

comark-outline

pnpm add https://pkg.pr.new/comark-outline@492

comark-properties

pnpm add https://pkg.pr.new/comark-properties@492

comark-qr

pnpm add https://pkg.pr.new/comark-qr@492

comark-quiz

pnpm add https://pkg.pr.new/comark-quiz@492

comark-reading-time

pnpm add https://pkg.pr.new/comark-reading-time@492

remark-to-comark

pnpm add https://pkg.pr.new/remark-to-comark@492

comark-sources

pnpm add https://pkg.pr.new/comark-sources@492

comark-steps

pnpm add https://pkg.pr.new/comark-steps@492

comark-table

pnpm add https://pkg.pr.new/comark-table@492

comark-tabs

pnpm add https://pkg.pr.new/comark-tabs@492

comark-tests

pnpm add https://pkg.pr.new/comark-tests@492

comark-time

pnpm add https://pkg.pr.new/comark-time@492

comark-ui

pnpm add https://pkg.pr.new/comark-ui@492

comark-xref

pnpm add https://pkg.pr.new/comark-xref@492

comark-zoom

pnpm add https://pkg.pr.new/comark-zoom@492

commit: c3fac28

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Important

The floating toolbar can permanently hide code on touch screens, clip Copy feedback in the docs frame, and intercept text selection when scripts are disabled.

Approach: CSS blending is a direct fix for light-theme favicon backgrounds, and a floating toolbar makes sense when readers can uncover the code and still see Copy feedback.

Reviewed changes across the shared renderers and the docs host styles. All 49 focused unit tests and 25 Chromium E2E tests passed; separate Chromium checks with the docs styles reproduced the three issues below.

  • Favicon blending: Light-theme favicons blend into the chip tint; the dark theme keeps its white plate.
  • Code layout: Standalone untitled fences get floating controls; titled fences and grouped code keep their header layouts.
  • Host styling and coverage: --ck-surface themes the overlay, the docs redraw the frame above it, and the new tests cover desktop hover, focus, and Copy feedback.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using gpt-6.2-sol(high) | 𝕏

Comment thread packages/code/src/styles.ts Resolved
Comment thread packages/code/src/styles.ts Resolved
Comment thread packages/code/src/styles.ts Resolved
Keeps the base version over this PR's changes:
- e2e/code.e2e.ts: The short clipped-frame cases replace the long-block Copy status test, retaining its pointer-leave and alignment assertions and extending them to both statuses.
- packages/code/docs/index.md: The toolbar description retains the floating and titled layouts and documents the intentional no-hover exception that prevents the controls from covering code.
- packages/code/src/styles.ts: The always-visible no-hover overlay is intentionally replaced with an in-flow toolbar while preserving the PR’s floating hover and focus behavior.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Important

A tap on a wrapped touch toolbar can invoke the wrong action, and showing Copy feedback can move the toolbar away from the code’s corner.

Reviewed changes in 7b4a263 since the previous Pullfrog review. All 49 focused unit tests passed; 23 of 24 Chromium code E2E tests passed. The remaining test uses Wrap’s old coordinates after wrapping moves the footer; a separate Chromium probe confirmed the extra tap area works when measured at its new position.

  • Moved untitled controls below the code on screens without hover and let the actions wrap.
  • Made the uninitialized overlay ignore pointer events so readers can select text beneath it.
  • Kept Copy feedback inside short clipped frames and added browser coverage for confirmation and manual-copy instructions.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using gpt-6.2-sol(high) | 𝕏

Comment thread packages/code/src/styles.ts Resolved
Comment thread packages/code/src/styles.ts Resolved

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Important

The new desktop wrapping rule can put Copy and other actions outside a short, clipped code block.

Reviewed changes in 907a1ab since the previous Pullfrog review. All 49 focused unit tests and 25 Chromium code E2E tests passed; a separate Chromium mouse test reproduced the clipping below.

  • Kept the floating toolbar anchored to pre during Copy feedback and measured the height needed to show either message.
  • Separated wrapped touch targets and updated the Wrap test to remeasure the button after the footer moves.
  • Enabled wrapping on hover-capable screens before Copy feedback appears.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using gpt-6.2-sol(high) | 𝕏

Comment thread packages/code/src/styles.ts Resolved

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Important

The standard clipped frame now keeps wrapped actions clickable, but a grid-styled frame can resize continuously while the toolbar is wrapped.

Reviewed changes in f16dea0 since the previous Pullfrog review. All 49 focused unit tests and 48 Chromium E2E tests passed. A separate Chromium check with the docs frame styles confirmed that all four custom actions and Copy were clickable at 390px.

  • Reserved room for the anchored toolbar before and during Copy feedback, while keeping the no-hover footer in flow.
  • Added a desktop regression for wrapped actions in a clipped frame, including clicks, Copy feedback, and the return to the original height after widening.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using gpt-6.2-sol(high) | 𝕏

Comment thread packages/code/src/client.ts Resolved

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found. No P0 or P1 findings remain.

Reviewed changes in c3fac28 since the previous Pullfrog review. All 49 focused unit tests and 49 Chromium E2E tests passed.

  • Stabilized floating toolbar sizing: The frame minimum now comes from the toolbar’s bottom, not the height of the pre it can stretch. I verified that both grid and flex frames stay at 88px at a 390px viewport instead of alternating between 46px and 88px.
  • Added a clipped-grid regression: The test checks that wrapped actions keep the frame at one height, Copy works, and the frame shrinks after widening.

Pullfrog  | View workflow run | Using gpt-6.2-sol(high) | 𝕏

@vite-hub
vite-hub Bot merged commit c8639c3 into main Nov 27, 2026
7 checks passed
@vite-hub
vite-hub Bot deleted the fix/chips-favicon-code-floating-actions branch November 27, 2026 12:39
@github-actions github-actions Bot mentioned this pull request Nov 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant