fix(marketing): show platform-appropriate commit shortcut on the website#3644
fix(marketing): show platform-appropriate commit shortcut on the website#3644VedankPurohit wants to merge 5 commits into
Conversation
The hero's "Commit & push" button hardcoded the macOS shortcut (⌘⏎), so Windows and Linux visitors saw the wrong keys. Reuse the existing client-side platform detection in index.astro to swap the label to "Ctrl ⏎" when the detected OS is not macOS. The server-rendered default stays ⌘⏎. Fixes pingdotgg#3526
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
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 |
ApprovabilityVerdict: Approved Simple marketing website UI fix that shows platform-appropriate keyboard shortcuts (⌘ for Mac, Ctrl for others). No product runtime impact - just display text on the website. You can customize Macroscope's approvability policy. Learn more. |
Dismissing prior approval to re-evaluate c9d5d02
Dismissing prior approval to re-evaluate 8155288
Summary
Ctrl ⏎on the marketing demo button for detected Windows and Linux visitors.⌘⏎default unchanged for macOS and unsupported platforms.UI Changes
Before (Windows):

After (Windows):

After (macOS, unchanged):

Test plan
vp checkvp run typecheckNote
Low Risk
Marketing-only copy on the homepage; no auth, data, or product runtime behavior changes.
Overview
The marketing homepage Commit & push demo no longer always shows the Mac shortcut. The keyboard hint span is given an
idso client-side code can update it after the existingdetectPlatform()logic runs.On Windows and Linux, the label is set to
Ctrl ⏎. macOS (and visitors with no detected platform) still get the server-rendered⌘⏎default.Reviewed by Cursor Bugbot for commit c84f374. Bugbot is set up for automated code reviews on this repo. Configure here.
Note
Show platform-appropriate keyboard shortcut on the marketing site commit button
The commit & push button on the marketing site homepage previously always showed the Mac keyboard shortcut. A script now detects the user's OS at runtime and sets the label to "Ctrl ⏎" for non-Mac platforms.
Macroscope summarized c84f374.