fix(desktop): respect preset execution mode when using hotkeys#999
Conversation
Preset hotkeys (Ctrl+1-9) now correctly execute commands in parallel when the preset's executionMode is set to "parallel", matching the behavior of the dropdown menu.
Consolidate preset-opening logic (execution mode handling, tab creation, renaming) into a shared openPreset function to reduce duplication between hotkey handler and dropdown menu.
📝 WalkthroughWalkthroughThe PR introduces an Changes
Sequence DiagramsequenceDiagram
actor User
participant WorkspacePage/GroupStrip as Component:<br/>WorkspacePage/<br/>GroupStrip
participant openPreset as openPreset Method
participant storeActions as Store Actions:<br/>storeAddTab/<br/>storeAddTabWithMultiplePanes
participant renameTab as renameTab
User->>WorkspacePage/GroupStrip: Select preset
WorkspacePage/GroupStrip->>openPreset: openPreset(workspaceId, preset)
alt preset.executionMode === "parallel"<br/>AND commands.length > 1
openPreset->>storeActions: storeAddTabWithMultiplePanes(...)
else Single pane mode
openPreset->>storeActions: storeAddTab(...)
end
storeActions-->>openPreset: tabId
alt preset.name provided
openPreset->>renameTab: renameTab(tabId, preset.name)
renameTab-->>openPreset: ✓
end
openPreset-->>WorkspacePage/GroupStrip: { tabId }
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~22 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing touches
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 |
Code reviewNo issues found. Checked for bugs and CLAUDE.md compliance. 🤖 Generated with Claude Code |
- native addon: drop the VDBG macro, #include <stdio.h>, and all
dispatch_block stderr traces so the macOS binary no longer writes to
stderr on every setWindowBlurRadius call (rv-pr items [2][3][7])
- @superset/macos-window-blur/index.js: remove the success-path
console.log added while debugging the initial integration
- main/lib/vibrancy/index.ts: delete the vdbg() helper and every
console.log call site; keep the scheduleNativeBlur retry loop
otherwise unchanged
- main/windows/main.ts: subscribe to nativeTheme.on("updated") so
macOS dark/light appearance changes re-run applyVibrancy against
the latest isDark; the previous implementation pinned the
BrowserWindow background color to whatever isDark was at the last
mutation, which left the tint stale on system theme transitions
when the user picked the "system" theme (rv-pr item [13])
- SpreadsheetViewer / SpreadsheetDiffViewer: replace the remaining
hardcoded #d0d0d0 / #f5f5f5 / #c0c0c0 / #f0f0f0 / superset-sh#666 / superset-sh#999 /
#fafafa / #e0e0e0 / #f8f8f8 / superset-sh#888 cells, borders, and text colors
with var(--border) / var(--muted) / var(--muted-foreground) so the
spreadsheet grid honours both dark mode and the vibrancy overlay
(rv-pr item [15] plus the neighbouring SpreadsheetViewer cells
found while fixing it)
Summary
executionModeis set to"parallel", matching the behavior of the dropdown menuopenPresetfunction intouseTabsWithPresetshook to consolidate preset-opening logicProblem
The hotkey handler always called
addTabwhich creates a single pane and joins commands with&&(sequential execution), ignoring the preset'sexecutionModesetting. The dropdown menu correctly handled this by checking the execution mode and callingaddTabWithMultiplePanesfor parallel presets.Test plan
executionMode: "parallel"Summary by CodeRabbit
Improvements
Refactor
✏️ Tip: You can customize this high-level summary in your review settings.