fix(ui): migrate channels.nostr btn-sm reference to btn--sm — cluster 3 (#2510)#2512
Merged
alexey-pelykh merged 1 commit intomainfrom Apr 23, 2026
Merged
Conversation
… 3 of #2502 CSS class drift audit (#2510) Upstream `21ac4b9a8a` (style(ui) clarity pass, openclaw#53272) migrated `.btn-sm` to `.btn--sm` under the BEM modifier convention. The fork's `ui/src/ui/views/channels.nostr.ts:131` still referenced the pre-rename `btn-sm` token; the CSS rule `.btn--sm` is defined at `ui/src/styles/components.css:625`. The stale reference was surfaced as cluster 3 (1 orphan) by the CSS class drift audit introduced in #2507. Post-fix audit: orphans 36 → 35, clusters 3 → 2, cluster 3 eliminated entirely. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
10 tasks
alexey-pelykh
added a commit
that referenced
this pull request
Apr 24, 2026
…am-sync class renames from silently desyncing (#2503) Adds lint:ui:no-css-class-drift pnpm script invoking the existing scripts/audit-css-class-drift.mjs (#2502), and appends it to the pnpm check chain so the lint CI job now fails on any template-string class reference in ui/src/**/*.{ts,tsx,html} that has no matching rule in the CSS files reachable from ui/src/styles.css. Baseline on main: 0 orphans / 403 references / 733 defined classes (cluster fixes from #2506, #2512, #2513, #2514, #2515 already resolved all existing drift before this gate is wired, per the #2503 AC "All findings from D-1 resolved BEFORE this check is wired into CI"). Script name adapted from the issue's suggested lint:css-classes to lint:ui:no-css-class-drift — matches the lint:<area>:no-<thing> pattern used by lint:ui:no-raw-window-open, lint:tmp:no-random-messaging, and lint:plugins:no-monolithic-plugin-sdk-entry-imports. Documented in CLAUDE.md § Formatting & Linting (local-dev orientation) and § Fork-integrity gates (CI/fork-lifecycle orientation, cross-referenced with the existing rebrand / zombie-import / stub-debt / throwing-stub-callers / obsolescence-audit gates). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
7 tasks
alexey-pelykh
added a commit
that referenced
this pull request
Apr 24, 2026
…am-sync class renames from silently desyncing (#2503) (#2516) Adds lint:ui:no-css-class-drift pnpm script invoking the existing scripts/audit-css-class-drift.mjs (#2502), and appends it to the pnpm check chain so the lint CI job now fails on any template-string class reference in ui/src/**/*.{ts,tsx,html} that has no matching rule in the CSS files reachable from ui/src/styles.css. Baseline on main: 0 orphans / 403 references / 733 defined classes (cluster fixes from #2506, #2512, #2513, #2514, #2515 already resolved all existing drift before this gate is wired, per the #2503 AC "All findings from D-1 resolved BEFORE this check is wired into CI"). Script name adapted from the issue's suggested lint:css-classes to lint:ui:no-css-class-drift — matches the lint:<area>:no-<thing> pattern used by lint:ui:no-raw-window-open, lint:tmp:no-random-messaging, and lint:plugins:no-monolithic-plugin-sdk-entry-imports. Documented in CLAUDE.md § Formatting & Linting (local-dev orientation) and § Fork-integrity gates (CI/fork-lifecycle orientation, cross-referenced with the existing rebrand / zombie-import / stub-debt / throwing-stub-callers / obsolescence-audit gates). Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
3 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
.btn-smreference inui/src/ui/views/channels.nostr.ts:131to.btn--sm(BEM modifier convention).21ac4b9a8a(style(ui) clarity pass, upstream style(ui): continue ui clarity pass across theme, config, and usage openclaw/openclaw#53272)..btn--smis already defined atui/src/styles/components.css:625; all other fork-owned call-sites (app-render, agents, nodes, config, etc.) were already migrated. This was the last remaining holdout.Evidence
Baseline audit (pre-fix):
.btn-smatchannels.nostr.ts:131) attributed to21ac4b9a8aPost-fix audit:
Reproduce:
node scripts/audit-css-class-drift.mjs.Diff scope
1 file, 1 line changed —
btn-sm→btn--smon line 131 only.Test plan
pnpm check(format + tsgo + lint + linter guards) — PASSnode scripts/audit-css-class-drift.mjs— cluster 3 absent from reportpnpm dev: nostr channel settings "Edit Profile" button renders with small-variant styling (deferred to reviewer — pure CSS class rename; structurally equivalent to the 20+ sibling call-sites already usingbtn--sm)References
21ac4b9a8a(style(ui): continue ui clarity pass across theme, config, and usage openclaw/openclaw#53272, style(ui) clarity pass)Closes #2510.
🤖 Generated with Claude Code