feat(api-table): use macos-text icon for macOS column#1043
Conversation
The compat table previously reused the Apple logo for both iOS and macOS (clay_macos) header columns, making them visually indistinguishable. Map clay_macos to its own macos-text icon — the same one APISummary already uses for the macOS platform badge — so the two columns can be told apart at a glance. Change-Id: If9b313a1aab2619e421ef885414e6ff7d45bccf2
✅ Deploy Preview for lynx-doc ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
WalkthroughThe PR differentiates platform-specific icon handling for Apple by separating iOS and macOS into distinct icons. ChangesApple Platform Icon Differentiation
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Suggested reviewers
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ESLint
ESLint skipped: no ESLint configuration detected in root package.json. To enable, add Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Pull request overview
Updates the API compatibility table’s platform-to-icon mapping so the macOS column no longer reuses the iOS Apple logo, aligning the table’s macOS badge with the icon already used elsewhere (e.g., APISummary).
Changes:
- Map
clay_macosto the dedicatedmacos-texticon instead ofapple. - Register
macos-textin the compat table icon mask CSS soicon-macos-textresolves to the correct SVG asset.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/components/api-table/compat-table/ui/_icon.scss | Adds macos-text to the generated .icon-* mask-image rules so the new class resolves to an SVG. |
| src/components/api-table/compat-table/headers.tsx | Updates platform-name→icon-name mapping so the macOS column uses macos-text while iOS continues using apple. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Summary
clay_macos) header columns, making the two visually indistinguishableclay_macosto a dedicatedmacos-texticon — the same one<APISummary />already uses for the macOS platform badgeios,clay_ios) continues to use the Apple logoBefore / After
Before: macOS column shows the Apple logo (same as iOS)
After: macOS column shows the rounded-square
macos-texticon, matching how APISummary renders the macOS badgeTest plan
<APITable />(e.g./guide/devtool) — confirm the macOS column header now shows the macos-text icon instead of the Apple logocurrentColormask treatment as the other platform icons)Use dedicated
macos-texticon for macOS columnDifferentiate the platform icons in the API table compatibility table by mapping
clay_macosto themacos-texticon instead of the Apple logo. This aligns the macOS column with the icon used in<APISummary />for the macOS platform badge, whileclay_ioscontinues to use the Apple logo.Changes:
clay_macostomacos-textandclay_iostoapplein the platform icon mappingmacos-textto the SCSS icon mask classes in the compat table stylingThe icon uses
currentColormasking, ensuring correct recoloring across light and dark modes.