UI: fix chat context notice icon sizing#45533
Merged
Conversation
Contributor
Greptile SummaryThis PR adds the missing CSS rules for Key changes:
Confidence Score: 3/5
Prompt To Fix All With AIThis is a comment left during a code review.
Path: ui/src/ui/views/chat.browser.test.ts
Line: 81
Comment:
**Test assertion will always fail in Chromium**
The `.context-notice` rule uses `display: inline-flex` (see `layout.css` line 153), but the test asserts `display === "flex"`. In a real browser (this test runs on Chromium via Playwright, per `vitest.config.ts`), `getComputedStyle(el).display` returns `"inline-flex"` — never just `"flex"` — so this assertion fails on every run, making the regression guard inoperative.
```suggestion
expect(noticeStyle.display).toBe("inline-flex");
```
How can I resolve this? If you propose a fix, please make it concise.Last reviewed commit: b53dfa9 |
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
frankekn
pushed a commit
to xinhuagu/openclaw
that referenced
this pull request
Mar 14, 2026
* UI: fix chat context notice icon sizing * Update ui/src/ui/views/chat.browser.test.ts Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com> * UI: tighten chat context notice regression test --------- Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
2 tasks
18 tasks
ecochran76
pushed a commit
to ecochran76/openclaw
that referenced
this pull request
Mar 14, 2026
* UI: fix chat context notice icon sizing * Update ui/src/ui/views/chat.browser.test.ts Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com> * UI: tighten chat context notice regression test --------- Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Describe the problem and fix in 2–5 bullets:
.context-notice/.context-notice__iconstyles and a browser regression test that asserts the icon stays badge-sized.Change Type (select all)
Scope (select all touched areas)
Linked Issue/PR
None.
User-visible / Behavior Changes
The chat context usage warning now renders as a compact warning pill with a correctly sized icon instead of an oversized triangle covering the chat pane.
Security Impact (required)
No)No)No)No)No)Yes, explain risk + mitigation:Repro + Verification
Environment
inputTokens=3800andcontextTokens=4000Steps
Expected
Actual
Evidence
Attach at least one:
Human Verification (required)
What you personally verified (not just CI), and how:
16px × 16pxwith the corrected pill layout.pnpm test:uisuite both passed.Review Conversations
Compatibility / Migration
Yes)No)No)Failure Recovery (if this breaks)
96e07fe0b.ui/src/styles/chat/layout.css,ui/src/ui/views/chat.browser.test.tsRisks and Mitigations
.context-noticeonly, andpnpm test:uiplus a live dev verification both passed.