Skip to content

Add Ctrl/Cmd+A to select all visible timeline tracks - #6371

Open
minwookshin wants to merge 1 commit into
firefox-devtools:mainfrom
minwookshin:fix/select-all-timeline-tracks
Open

minwookshin wants to merge 1 commit into
firefox-devtools:mainfrom
minwookshin:fix/select-all-timeline-tracks

Conversation

@minwookshin

@minwookshin minwookshin commented Oct 2, 2026 •

Copy link
Copy Markdown

Main | Deploy preview

Fixes #6237.

Add Ctrl/Cmd+A to select all visible thread tracks from anywhere in the profile view. Hidden tracks stay hidden and unselected; text fields and composition retain their normal behavior. Keep the current thread panel where possible, including returning from the network chart to the last thread panel.

@codecov

codecov Bot commented Oct 2, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 92.85714% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 84.13%. Comparing base (6221821) to head (a79da3a).
⚠️ Report is 3 commits behind head on main.

Files with missing lines Patch % Lines
src/actions/profile-view.ts 84.61% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6371      +/-   ##
==========================================
+ Coverage   84.12%   84.13%   +0.01%     
==========================================
  Files         356      356              
  Lines       38445    38472      +27     
  Branches    10787    10914     +127     
==========================================
+ Hits        32340    32369      +29     
+ Misses       5676     5674       -2     
  Partials      429      429              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@fatadel fatadel left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you very much for your contributions, @minwookshin, and sorry for the late review! The patch looks good overall, however, I would address the following before merging:

  1. Non-Latin keyboard layouts: the shortcut checks the typed character, so it doesn't fire on layouts like Russian. Checking the physical key (event.code === 'KeyA') would fix that.
  2. If you press ? on the keyboard, you will see the list of all the shortcuts. Can you add this one there too, please?

@fatadel

fatadel commented Oct 14, 2026

Copy link
Copy Markdown
Contributor

And please remove this AI-generated fluff from the PR description :) Otherwise, it can pollute the git tree.

Validated 270 timeline/track tests (2 todo), 57 snapshots, TypeScript, changed-file ESLint, formatting, and the development build. Checked the shortcut with an imported profile in Chromium, Firefox, and WebKit, including normal text selection in the search field.

@minwookshin

Copy link
Copy Markdown
Author

Switched the shortcut to the physical A key and added it to the keyboard shortcut help.

@canova
canova requested a review from fatadel October 28, 2026 16:14

@fatadel fatadel left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR, @minwookshin! And sorry it took this much to review.

  1. I've played around with the deploy preview and I was able to accidentally select all the UI text instead of triggering ctrl+A. And this happened multiple times. I think it would be better to bind the shortcut to window - the same way / and ? are bound.

  2. After a careful consideration, I think your original approach with checking against event.key was better. It's also how most of the shortcuts are handler in this repo apart from WASD/HJKL. So, it would be nice to revert this - sorry I should have reviewed this properly from the beginning.

And I've left some inline comments that would be nice to address too. Thanks a lot for your contribution once again!

Comment thread src/actions/profile-view.ts Resolved
@minwookshin

minwookshin commented Nov 5, 2026 •

Copy link
Copy Markdown
Author

Moved the handler to window and restored event.key, using getTrackSelectionModifiers and the same tag-name guards as the other shortcuts. Added coverage for the unavailable-tab fallback and global/input behavior. yarn test-all passes; also checked selection and text-input behavior in Chrome.

Could a maintainer approve the new CI run?

@fatadel
fatadel self-requested a review November 5, 2026 08:51

@fatadel fatadel left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for addressing the review comments so promptly!

  1. I left one last clean-up comment below.
  2. It would be nice if you can squash the commits. There is no need to keep the implementation back-and-forth in the tree.

Comment thread src/test/components/Timeline.test.tsx Resolved
@minwookshin
minwookshin force-pushed the fix/select-all-timeline-tracks branch from 2288d2e to ee0016e Compare November 6, 2026 19:04
@minwookshin

Copy link
Copy Markdown
Author

Removed the five unused code fields and squashed the commits. yarn test-all passes, including 2,627 browser tests and 325 CLI tests.

@fatadel
fatadel self-requested a review November 9, 2026 12:13

@fatadel fatadel left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for addressing the issues! One last nit - please wrap the commit msg the same way they are wrapped in the tree.

Handle the shortcut globally while preserving text input selection and
selecting a useful panel for the resulting tracks.
@minwookshin
minwookshin force-pushed the fix/select-all-timeline-tracks branch from ee0016e to ddbfe37 Compare November 9, 2026 16:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add a cmd+a keyboard shortcut to select all tracks

2 participants