Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
0c9d4b7
Add a Trends screen for glucose, insulin and Loop status over time
Nutcasey Nov 1, 2026
ff0bf4a
Bring what Statistics shows into Trends
Nutcasey Nov 1, 2026
ee6b07f
Replace Statistics with Trends
Nutcasey Nov 3, 2026
a599631
Move the day page, Gaps and Export to follow-up parts
Nutcasey Nov 3, 2026
fae6064
Show each Trends figure once
Nutcasey Nov 3, 2026
5d9ccc9
Show targets beside their figures instead of Aim lines
Nutcasey Nov 3, 2026
b8813f6
Use Loop's existing colours in Trends
Nutcasey Nov 3, 2026
5bc00d6
Read closed and open loop from stored settings
Nutcasey Nov 3, 2026
bc8f2aa
Follow the cache duration and mark partial older periods
Nutcasey Nov 3, 2026
888deee
Stack Trends rows at the largest text sizes
Nutcasey Nov 3, 2026
6fceab4
Remove the unused ValueTile
Nutcasey Nov 3, 2026
c89a9c7
Fix issues found testing the review changes
Nutcasey Nov 3, 2026
a056341
Tighten dose boundaries and use a darker bolus colour
Nutcasey Nov 3, 2026
3e9b159
Keep unrecorded schedule history unknown in Trends
Nutcasey Nov 3, 2026
34d02ef
Keep Trends chart labels readable at accessibility sizes
Nutcasey Nov 3, 2026
5c191ec
Show the GMI's mmol/mol line only with mmol/L
Nutcasey Nov 7, 2026
e401cfd
Tell insulin apart by shape instead of a darker bolus
Nutcasey Nov 7, 2026
40293f5
Raise Trends' muted text to WCAG AAA contrast
Nutcasey Nov 7, 2026
5136872
Keep Trends' new strings English-only
Nutcasey Nov 13, 2026
ec7f0ee
Use GlucoseStatistics for Trends' glucose figures
Nutcasey Nov 13, 2026
e58b3d4
Measure CGM coverage by time rather than by reading count
Nutcasey Nov 13, 2026
251aba0
Keep CGM readings beside fingersticks when thinning Health glucose
Nutcasey Nov 13, 2026
35656e8
Say why only temp basals marked not automatic count as manual
Nutcasey Nov 13, 2026
087acf9
Convert Trends' mmol/L with LoopKit's factor
Nutcasey Nov 13, 2026
c89c203
Give Trends' test doses a dose id
Nutcasey Nov 22, 2026
322cb2a
Add a Logbook of the last 7 days
Nutcasey Nov 22, 2026
e662757
Add the Now home screen with Now, Trends, Logbook and Settings tabs
Nutcasey Nov 22, 2026
16ed078
Rebuild Add carbs around a live preview of the meal
Nutcasey Nov 22, 2026
02a6145
Match the widget, Dynamic Island and Live Activity to the Now screen
Nutcasey Nov 22, 2026
06e8f29
Add appearance and app icon choices
Nutcasey Nov 22, 2026
886480c
Add a day page and a list of Loop's gaps
Nutcasey Nov 22, 2026
de01a3e
Export Trends as a PDF report or a CSV of each day
Nutcasey Nov 22, 2026
e1fbc1c
Save or send a copy of an outcomes share
Nutcasey Nov 25, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file removed Documentation/Screenshots/Phone Daily Insulin.png
Binary file not shown.
Binary file removed Documentation/Screenshots/Phone Statistics.png
Binary file not shown.
69 changes: 69 additions & 0 deletions Loop Widget Extension/Bootstrap/Localizable.xcstrings
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,18 @@
"comment" : "A space.",
"isCommentAutoGenerated" : true
},
"%1$@ g" : {
"comment" : "Amount of carbohydrate in grams. (1: number)"
},
"%1$@ U" : {
"comment" : "Insulin amount in units. (1: number)"
},
"%1$@ U/h" : {
"comment" : "Insulin rate in units per hour. (1: number)"
},
"%1$@ · %2$@ in 5 min" : {
"comment" : "Under the glucose value on the Now screen: the glucose unit and how much glucose changed over 5 minutes. (1: glucose unit, e.g. mmol/L; 2: signed change, e.g. +0.3)"
},
"---" : {
"localizations" : {
"da" : {
Expand Down Expand Up @@ -657,6 +669,24 @@
}
}
},
"Add carbs" : {
"comment" : "Button on the Now screen that opens carb entry"
},
"Basal" : {
"comment" : "Label of a tile showing the current basal rate (Now screen) or the day's basal insulin total (Today so far totals)"
},
"Bolus" : {
"comment" : "Button on the Now screen that opens the bolus screen"
},
"Closed loop · %1$@" : {
"comment" : "Status pill on the Now screen: closed loop is on. (1: how long ago Loop last ran, e.g. 2m)"
},
"Closed loop · not run yet" : {
"comment" : "Status pill on the Now screen when closed loop is on but Loop hasn't completed a run yet"
},
"COB" : {
"comment" : "Abbreviation for carbs on board; label of a tile on the Now screen"
},
"Color" : {
"localizations" : {
"de" : {
Expand Down Expand Up @@ -984,6 +1014,12 @@
}
}
},
"Eventually" : {
"comment" : "Short label above the glucose Loop predicts at the end of its prediction, in a small tile on the widget and Live Activity. Keep it to one short word, such as 'Forecast'."
},
"Eventually %1$@ %2$@" : {
"comment" : "Header detail of the Next 3 hours card on the Now screen: the glucose Loop predicts at the end of its prediction. (1: glucose value; 2: glucose unit)"
},
"g" : {
"comment" : "The short unit display string for grams",
"extractionState" : "stale",
Expand Down Expand Up @@ -1190,6 +1226,15 @@
}
}
},
"High" : {
"comment" : "Pill under the glucose value on the Now screen when glucose is above 250 mg/dL (13.9 mmol/L)"
},
"Last reading %1$@ ago" : {
"comment" : "Shown on the Now screen under No reading when the latest CGM reading is too old. (1: duration, e.g. 25m)"
},
"Loop hasn't run for %1$@" : {
"comment" : "Notice title on the Now screen when Loop hasn't completed a run recently. (1: duration, e.g. 25m)"
},
"Loop Status Widget" : {
"localizations" : {
"da" : {
Expand Down Expand Up @@ -1266,6 +1311,9 @@
}
}
},
"Low" : {
"comment" : "Pill under the glucose value on the Now screen when glucose is below 70 mg/dL (3.9 mmol/L)"
},
"mg/dL" : {
"comment" : "The short unit display string for milligrams of glucose per decilter",
"extractionState" : "stale",
Expand Down Expand Up @@ -1518,6 +1566,15 @@
}
}
},
"No reading" : {
"comment" : "Shown on the Now screen in place of the glucose value when there is no recent CGM reading"
},
"Open loop · %1$@" : {
"comment" : "Status pill on the Now screen: closed loop is off. (1: how long ago Loop last ran, e.g. 2m)"
},
"Open loop · not run yet" : {
"comment" : "Status pill on the Now screen when closed loop is off and Loop hasn't completed a run yet"
},
"Open the app to update the widget" : {
"comment" : "No comment",
"localizations" : {
Expand Down Expand Up @@ -1559,6 +1616,12 @@
}
}
},
"Pre-meal" : {
"comment" : "Menu item under Presets on the Now screen that turns on the pre-meal target"
},
"Pre-meal on" : {
"comment" : "Presets button title on the Now screen while the pre-meal target is on"
},
"Preset override" : {
"localizations" : {
"de" : {
Expand Down Expand Up @@ -1599,6 +1662,9 @@
}
}
},
"Presets" : {
"comment" : "Button on the Now screen that opens override presets (and pre-meal); also its VoiceOver label and menu item"
},
"QUANTITY_VALUE_AND_UNIT" : {
"comment" : "Format string for combining localized numeric value and unit. (1: numeric value)(2: unit)",
"extractionState" : "extracted_with_value",
Expand Down Expand Up @@ -1966,6 +2032,9 @@
}
}
}
},
"Urgent low" : {
"comment" : "Pill under the glucose value on the Now screen when glucose is below 54 mg/dL (3.0 mmol/L)"
}
},
"version" : "1.1"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"colors" : [
{
"color" : {
"platform" : "ios",
"reference" : "systemBlueColor"
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0.220",
"green" : "0.855",
"red" : "0.388"
}
},
"idiom" : "universal"
},
{
"appearances" : [
{
"appearance" : "luminosity",
"value" : "dark"
}
],
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0.200",
"green" : "0.894",
"red" : "0.349"
}
},
"idiom" : "universal"
},
{
"appearances" : [
{
"appearance" : "contrast",
"value" : "high"
}
],
"color" : {
"platform" : "ios",
"reference" : "systemGreenColor"
},
"idiom" : "universal"
},
{
"appearances" : [
{
"appearance" : "luminosity",
"value" : "dark"
},
{
"appearance" : "contrast",
"value" : "high"
}
],
"color" : {
"platform" : "ios",
"reference" : "systemGreenColor"
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ struct GlucoseLiveActivityConfiguration: Widget {
// banner on the Home Screen of devices that don't support the Dynamic Island.
if #available(iOS 18.0, *) {
AdaptiveLockScreenView(context: context)
} else if WidgetDesign.useRedesign {
RedesignLiveActivity.lockScreen(context)
} else {
fullLockScreenView(context: context)
}
Expand All @@ -56,7 +58,13 @@ struct GlucoseLiveActivityConfiguration: Widget {
@Environment(\.activityFamily) private var activityFamily

var body: some View {
if activityFamily == .small {
if WidgetDesign.useRedesign {
if activityFamily == .small {
RedesignLiveActivity.smallFamily(context)
} else {
RedesignLiveActivity.lockScreen(context)
}
} else if activityFamily == .small {
// WatchOS & CarPlay supplemental view - show only bottom row
compactLockScreenView(context: context)
} else {
Expand Down Expand Up @@ -261,6 +269,9 @@ struct GlucoseLiveActivityConfiguration: Widget {
private func dynamicIslandView(
context: ActivityViewContext<GlucoseActivityAttributes>
) -> DynamicIsland {
if WidgetDesign.useRedesign {
return RedesignLiveActivity.dynamicIsland(context)
}
let glucoseFormatter = NumberFormatter.glucoseFormatter(
for: context.state.isMmol
? LoopUnit.millimolesPerLiter : LoopUnit.milligramsPerDeciliter
Expand Down
Loading