fix(ui): ratchet-clean apps/ui components batch 1/5 (17 files, 43 violations)#8181
Conversation
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
…lations) Converts each no-restricted-syntax violation to its named token per the eslint message, mirroring the recipe merged in JSONbored#8177 for packages/ui-kit: - text-[9-13px] one-offs -> mg-type-caption / mg-type-data-sm (+ the existing mg-type-micro/label idioms), dropping the now-redundant font-mono where the token supplies it. Non-uppercase mono numeric sites (uptime-timeline, coverage/registry/schema-drift) snap to mg-type-data-sm (nearest non-uppercase mono step); sans <12px prose/labels snap to mg-type-caption. This homogenizes a few previously-differentiated sizes onto the scale -- the batch's explicit intent, same as JSONbored#8177. - account-history-chart's bg-card/95 KPI shell -> .mg-glass (its exact 95% translucency tier, packages/ui-kit styles.css). - drift-activity's hand-rolled tablist shell -> <Panel as="div" flush>, same recipe JSONbored#8177 used for ActionBar/SegmentedToggle. As there, Panel's default `rounded` replaces the original `rounded-md` (a subtle 2px corner tightening on this small toggle). - 6 GitHub/Discord/RSS/openapi/api/raw external links -> <ExternalLink bare> (the icon-only opt-in prop JSONbored#8177 added), preserving their exact rendering while routing through safeExternalUrl; the schema-drift evidence link keeps its raw anchor (documented) because it needs onClick stopPropagation, which <ExternalLink> doesn't forward. Genuinely-missing-token residuals are documented eslint-disable, not forced onto a wrong token (per JSONbored#8172's own guidance): the heatmap/mosaic per-cell rounded-[1px]/[2px] micro-radii (CONTRIBUTING's documented viz residual -- the smallest named step, rounded/4px, would materially change these grids), the two 14px block-number displays (no mg-type-body utility exists), and the JSONbored#7842 bg-card/80 toggle track (no clean glass tier). This batch does not touch RATCHETED_DIRS (per the issue -- the ratchet-list update belongs to whichever batch clears the last file in the directory). Closes JSONbored#8167
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #8181 +/- ##
=======================================
Coverage 97.82% 97.82%
=======================================
Files 415 415
Lines 28893 28893
Branches 10850 10850
=======================================
Hits 28265 28265
Misses 141 141
Partials 487 487 🚀 New features to boost your workflow:
|
|
Warning ⏸️ LoopOver review result - manual review recommendedReview updated: 2026-07-26 00:31:44 UTC
Review summary Nits — 7 non-blocking
Decision drivers
Context & advisory signals — never blocks the verdict
Linked issue satisfactionAddressed Review context
Contributor next steps
Signal definitions
🧪 Chat with LoopOverAsk LoopOver a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.
Full command reference: https://loopover.ai/docs/loopover-commands 🧪 Experimental — new and may change. Visual preview
Click any thumbnail to open the full-size screenshot. Before = production · After = this PR's preview deploy · Diff highlights exactly what changed. Scroll preview
A short scroll-through clip (desktop) — click either thumbnail to open the full animation. Evidence for scroll-linked behavior a single screenshot can't show. 🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by LoopOver, a quiet PR intelligence layer for OSS maintainers.
|
|
This pull request changes UI/visual code but its screenshot evidence is incomplete. Every required viewport × theme combination needs its own before/after image pair in a labeled table row (e.g. "Desktop · Light | before | after"). Still missing: Desktop · Light, Desktop · Dark, Tablet · Light, Tablet · Dark, Mobile · Light, Mobile · Dark. Please resubmit with the remaining rows filled in. See https://github.com/JSONbored/metagraphed/blob/main/.claude/skills/metagraphed/SKILL.md for the exact format and examples. This is an automated maintenance action. |




Closes #8167
Mirrors the recipe merged in #8177 (packages/ui-kit) for the apps/ui half. Every
no-restricted-syntaxwarning in the 17 listed files is converted to its named token per the eslint message; the handful with no existing token equivalent are documentedeslint-disable(per #8172's "flag, don't invent ad hoc" guidance), not forced onto a wrong token. This batch does not touchRATCHETED_DIRS— per the issue, that belongs to whichever batch clears the last file insrc/components/metagraphed/**.npx eslint <each file>now reports 0no-restricted-syntax;tsc --noEmit,prettier --check, and the existing vitest suite are clean (the 4 pre-existingstake-unstake-modal/take-management-modalfocus-test failures reproduce onmainunchanged — jsdom/Sheet, unrelated to this diff).What changed, by category
Text sizes →
mg-type-*(23 sites). Per the eslint message, dropping the now-redundantfont-monowhere the token supplies it:<12pxprose/labels →mg-type-caption(incidents-timeline, api-drawer, api-keys-manager, api-source-footer, app-shell, author-share-panel, neighbor-compare, activity-heatmap, uptime-timeline tooltip).mg-type-data-sm(coverage-matrix, drift-activity, registry-depth, schema-drift-matrix, uptime-timeline, activity-heatmap legend) — the nearest non-uppercase mono step (microwould force uppercase onto numbers).<ExternalLink bare>(6 sites) + 1 documented residual. GitHub/Discord/RSS icons, footeropenapi, the API-status link, and api-drawer's "Open raw" icon →<ExternalLink bare>(the icon-only opt-in prop #8177 added), preserving their exact rendering while routing throughsafeExternalUrl. The schema-drift-matrix evidence link keeps its raw anchor (documentedeslint-disable) because it needsonClickstopPropagation on a clickable row, which<ExternalLink>doesn't forward.<Panel flush>(1) + glass tier (1).<Panel as="div" flush>, the same recipe fix(ui-kit): ratchet-clean src/components (16/19 files, 38/43 violations) #8177 used for ActionBar/SegmentedToggle.roundedreplaces the originalrounded-md— a subtle 2px corner tightening on this small toggle.bg-card/95KPI shell →.mg-glass(its exact 95% translucency tier).Documented
eslint-disablefor genuinely-missing tokens (6+2+1+1):rounded-[1px]/[2px]— CONTRIBUTING's documented viz residual (the smallest named step,rounded/4px, would materially change these dense grids).mg-type-bodyutility exists (--mg-type-bodyis a reserved CSS var, not a class).bg-card/80toggle track (no clean glass tier — already documented in-file).Note on the ui-kit dist
This uses
<ExternalLink bare>, added to ui-kit source in #8177.packages/ui-kit/dist/index.d.tsis gitignored and rebuilt in CI, so apps/ui typechecks against the fresh types — no dist changes are (or should be) committed here.