Bolus initiating state + spinning border instead of the spinner#54
Open
Sjoerd-Bo3 wants to merge 2 commits into
Open
Bolus initiating state + spinning border instead of the spinner#54Sjoerd-Bo3 wants to merge 2 commits into
Sjoerd-Bo3 wants to merge 2 commits into
Conversation
…ivery Introduces a BolusStatus state machine (noBolus / initiating / inProgress) derived from the pump's bolusState, distinguishing 'bolus requested but not yet delivering' from 'actively delivering': - DeviceDataManager.bolusTrigger now carries BolusStatus instead of Bool, mapping status.bolusState (initiating / inProgress / default -> noBolus). - APSManager creates the bolus reporter for initiating+inProgress, clears it on noBolus. - HomeStateModel and TreatmentsStateModel track bolusStatus from the trigger. - Home bolus card and Treatments in-progress row show an 'Initiating…' label with a ProgressView spinner (in place of the cancel button) during initiating, then the normal 'Bolusing' state with the cancel button once delivery starts.
On top of the bolus-initiating state, replace the ProgressView spinner shown during '.initiating' with our reusable spinning border (the one on the pump reservoir and loop pills): - Home bolus card: the card border spins while initiating, then switches to the determinate left->right progress fill once delivering. - Treatments in-progress row: the card shows the spinning border while initiating; the cancel button returns once delivering. Both card borders use a 3pt line so there is no thickness jump on the initiating -> inProgress transition.
Sjoerd-Bo3
force-pushed
the
feat/bolus-initiating-border
branch
from
July 4, 2026 18:32
32c49c1 to
78388b0
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Restructured to build on top of the bolus-initiating feature rather than reimplement it. Two commits:
Commit 1 — Add the bolus initiating state (with a spinner)
A faithful port of the "show bolus initiating" feature:
BolusStatus { noBolus, initiating, inProgress }, derived from the pump'sbolusState.DeviceDataManager.bolusTriggernow carriesBolusStatus(wasBool), mappingstatus.bolusState→.initiating/.inProgress/ (default).noBolus.APSManagercreates the bolus reporter forinitiating+inProgress, clears it onnoBolus.HomeStateModelandTreatmentsStateModeltrackbolusStatus;isBolusInProgressis replaced bybolusStatus != .noBolus.ProgressViewspinner (in place of the cancel button) during initiating.Commit 2 — Show the spinning border instead of the spinner
On top of commit 1, replace that
ProgressViewwith our reusable spinning border (the pump reservoir / loop-pill one):initiating → inProgresstransition.Notes
.initiating/.inProgresscome from the pump's ownbolusState.String(localized:)calls fall back to the literal), consistent with how this fork has handled.xcstrings.Verification
compile_checksimulator workflow on this branch (only place the submodules/build can be validated).