Fix: Use with modern dialog store for firmwareUpgradeRequired, update warning content#5081
Fix: Use with modern dialog store for firmwareUpgradeRequired, update warning content#5081VitroidFPV wants to merge 2 commits intobetaflight:masterfrom
Conversation
|
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)
✅ Files skipped from review due to trivial changes (1)
WalkthroughUpdated the firmware-upgrade user message, refactored version-mismatch UI to use the Pinia-backed InformationDialog, and adjusted the dialog confirm button max-width. ChangesFirmware upgrade + dialog migration
Sequence Diagram(s)sequenceDiagram
participant Serial as serial_backend
participant Dialog as DialogStore
participant CLI as CLI/Connection
Serial->>Dialog: open InformationDialog(title, message, confirm)
Dialog-->>Serial: user presses confirm -> confirm handler
Serial->>Dialog: dialogStore.close()
Serial->>CLI: connectCli()
CLI-->>Serial: connection established / error
Serial->>Dialog: onClosed/finishClose -> dialogStore.close() (cleanup)
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested reviewers
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Tip 💬 Introducing Slack Agent: Turn conversations into code.Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.
Built for teams:
One agent for your entire SDLC. Right inside Slack. 👉 Get your free trial and get 200 agent minutes per Slack user (a $50 value). 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. Review rate limit: 7/8 reviews remaining, refill in 7 minutes and 30 seconds.Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@locales/en/messages.json`:
- Line 638: The message string under the "message" key in
locales/en/messages.json currently links to firmware releases
(github.com/betaflight/betaflight) but the text refers to "older releases" of
the app; update the two href URLs to point to the Betaflight App/Configurator
release pages (e.g., github.com/betaflight/betaflight-configurator or the
official app releases repo) so the links match the wording and guide users to
app downloads; keep the same anchor text and attributes (target/rel) and ensure
the two replaced URLs correspond to the intended app release versions referenced
in the copy (e.g., app release matching 10.8.0 and 10.5.1 equivalents).
In `@src/js/serial_backend.js`:
- Around line 347-362: The disconnect path leaves the InformationDialog opened
by showVersionMismatchAndCli() because finishClose() only closes
InteractiveDialog; update finishClose() to also close InformationDialog (i.e.
check if dialogStore.activeDialog?.type is "InteractiveDialog" OR
"InformationDialog" and call dialogStore.close()) or unconditionally call
dialogStore.close() to ensure any leftover modal is removed on disconnect;
reference finishClose(), dialogStore.activeDialog?.type, "InteractiveDialog",
"InformationDialog", dialogStore.close(), and showVersionMismatchAndCli() when
making the change.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: bf8db74b-c2f8-4c6f-ba60-30d7f8c49c6b
📒 Files selected for processing (3)
locales/en/messages.jsonsrc/css/main.lesssrc/js/serial_backend.js
|
|
🎉 Do you want to test this code? 🎉 |



The app would connect to the CLI without any notice, the previous warning did not show. This PR updates it to use the modern dialog store, and updates the warning to point directly to older app downloads that should be compatible with old firmware versions.
Summary by CodeRabbit
Documentation
Style
Bug Fixes