fix(actions): show '--' placeholder on fuel toggle when no telemetry available (#227)#231
Conversation
…available (#227) getFuelAmount() now returns undefined instead of 0 when telemetry is absent, allowing the toggle-fuel-fill icon to display '--' instead of the misleading '+0 g'. The state key uses 'none' for undefined fuel amount so the display updates correctly when telemetry connects.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughThe PR updates the Fuel Service fuel-fill icon to display Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Suggested labels
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 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 |
Related Issue
Fixes #227
What changed?
getFuelAmount()returnsundefinedinstead of0when no telemetry is available, distinguishing "no data" from "zero fuel requested"fuelFillDynamicIcon()displays"--"whenfuelAmountisundefined, only callingformatFuelFillAmount()with real telemetry databuildStateKey()uses"none"for undefined fuel amount so the icon updates correctly when telemetry connects with an actual0valueHow to test
pnpm test --filter @iracedeck/actions— all 76 tests passChecklist
Summary by CodeRabbit
Bug Fixes