GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(mobile): show agent activity in the iOS home screen widget by CopyJosh · Pull Request #30247 · pingdotgg/t3code

fix(mobile): show agent activity in the iOS home screen widget #30247

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Sign up for GitHub

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
CopyJosh wants to merge 10 commits into pingdotgg:main from CopyJosh:fix/ios-agent-activity-widget-snapshot

Uh oh!

There was an error while loading. Please reload this page.

Closed

fix(mobile): show agent activity in the iOS home screen widget #30247

Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
10 commits
Select commit Hold shift + click to select a range
625eef1
fix(mobile): agent activity home screen widget shows active tasks
CopyJosh Nov 3, 2026
43dd21a
fix(mobile): use account-aware snapshots in the home widget
CopyJosh Nov 3, 2026
de008d8
fix(mobile): show five compact agent rows with relay labels
CopyJosh Nov 3, 2026
88faeaa
fix(mobile): offer a large agent activity widget
CopyJosh Nov 3, 2026
cac281c
fix(mobile): use roomier widgets with system text styles
CopyJosh Nov 3, 2026
0e64cf4
fix(mobile): scale widget titles and link each activity row
CopyJosh Nov 3, 2026
90dab34
fix(mobile): fit compact widget rows and fill large with unsettled th…
CopyJosh Nov 3, 2026
40ad7bc
fix(mobile): refresh widgets before live activity token registration
CopyJosh Nov 3, 2026
cc3acc4
Merge remote-tracking branch 'github/main' into fix/ios-agent-activit…
maria-rcks Nov 5, 2026
5029068
Merge upstream/main into fix/ios-agent-activity-widget-snapshot
CopyJosh Nov 9, 2026
File filter
Filter by extension

Clear filters
Conversations
Failed to load comments.
Loading

Uh oh!

There was an error while loading. Please reload this page.

Jump to
Jump to file
Failed to load files.
Loading

Uh oh!

There was an error while loading. Please reload this page.

Diff view
Diff view
Prev Previous commit
Next Next commit
fix(mobile): show five compact agent rows with relay labels
  • Loading branch information

Uh oh!

There was an error while loading. Please reload this page.

@CopyJosh
CopyJosh committed Nov 3, 2026
commit de008d84a44d8609135646a9041fbf3ba04f7d23

There are no files selected for viewing

33 changes: 26 additions & 7 deletions 33 apps/mobile/src/widgets/AgentActivityWidget.test.mjs
Show comments
View file
Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ it("embeds an Agent Activity Home Screen layout and initial data independently o
{ cwd: projectRoot, stdio: "pipe" },
);
const { widgets } = JSON.parse(NodeFS.readFileSync(outputPath, "utf8"));
expect(widgets.AgentActivity.layout).toContain("Tap to refresh");
expect(widgets.AgentActivity.initialProps).toMatchObject({ activeCount: 0, activities: [] });
const runtimePath = NodePath.join(directory, "runtime.js");
NodeChildProcess.execFileSync(
Expand All @@ -59,7 +58,7 @@ it("embeds an Agent Activity Home Screen layout and initial data independently o
threadId: "thread",
threadTitle: "Review the task",
projectTitle: "Project",
status: "Waiting for input",
status: "Input",
phase: "waiting_for_input",
deepLink: "/threads/environment/mcp%3Atask",
},
Expand All @@ -74,7 +73,7 @@ it("embeds an Agent Activity Home Screen layout and initial data independently o
const active = JSON.stringify(context.__expoWidgetRender(props, environment));
expect(active).toContain("1 active");
expect(active).toContain("Review the task");
expect(active).toContain("Needs input");
expect(active).toContain("Input");
expect(active).toContain("t3code-dev:///threads/environment/mcp%3Atask");
for (const [source, subtitle] of [
["loading", "Loading agents…"],
Expand All @@ -94,14 +93,34 @@ it("embeds an Agent Activity Home Screen layout and initial data independently o
const expired = JSON.stringify(
context.__expoWidgetRender({ ...props, freshUntil: 1_000 }, environment),
);
expect(expired).toContain("Tap to refresh");
expect(expired).not.toContain("Needs input");
expect(expired).toContain("Out of date");
expect(expired).not.toContain("Input");
const scheduled = JSON.stringify(
context.__expoWidgetRender(props, { ...environment, timestamp: 3_000 }),
);
expect(scheduled).toContain("Tap to refresh");
expect(scheduled).not.toContain("Needs input");
expect(scheduled).toContain("Out of date");
expect(scheduled).not.toContain("Input");
}
const aggregate = {
...props,
activeCount: 10,
activities: Array.from({ length: 5 }, (_, index) => ({
...props.activities[0],
threadId: `thread-${index}`,
threadTitle: `Relay task ${index + 1}`,
phase: "running",
status: "Working",
})),
};
const aggregateLayout = JSON.stringify(
context.__expoWidgetRender(aggregate, {
widgetFamily: "systemMedium",
colorScheme: "light",
widgetRenderingMode: "fullColor",
}),
);
expect(aggregateLayout).toContain("Relay task 5");
expect(aggregateLayout).toContain("10 active");
} finally {
NodeFS.rmSync(directory, { recursive: true, force: true });
}
Expand Down
129 changes: 73 additions & 56 deletions 129 apps/mobile/src/widgets/AgentActivityWidget.tsx
Show comments
View file
Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import {
foregroundStyle,
frame,
lineLimit,
layoutPriority,
resizable,
widgetURL,
} from "@expo/ui/swift-ui/modifiers";
Expand Down Expand Up @@ -40,7 +41,7 @@ function AgentActivityWidget(props: AgentActivityWidgetProps, environment: Widge
const expired = (props.freshUntil ?? Infinity) <= now;
const rows = (props.activities ?? []).map((row) =>
expired && row.phase !== "completed" && row.phase !== "failed"
? { ...row, phase: "stale" as const }
? { ...row, phase: "stale" as const, status: "Out of date" }
: row,
);
const stale = rows.some((row) => row.phase === "stale");
Expand All @@ -51,28 +52,26 @@ function AgentActivityWidget(props: AgentActivityWidgetProps, environment: Widge
const multiple = !small && !accessory && rows.length > 1;
const monochrome =
environment.widgetRenderingMode !== "fullColor" || environment.isLuminanceReduced;
const status = (row: AgentActivityWidgetProps["activities"][number]) => {
const statusColor = (row: AgentActivityWidgetProps["activities"][number]) => {
switch (row.phase) {
case "waiting_for_approval":
return { label: "Approval needed", color: "#B45309" };
return "#B45309";
case "waiting_for_input":
return { label: "Needs input", color: "#6D28D9" };
case "starting":
return { label: "Starting", color: "#0369A1" };
case "running":
return { label: "Working", color: "#0369A1" };
return "#6D28D9";
case "completed":
return { label: "Done", color: "#047857" };
return "#047857";
case "failed":
return { label: "Failed", color: "#B91C1C" };
return "#B91C1C";
case "stale":
return { label: "Tap to refresh", color: "secondary" };
return "secondary";
default:
return { label: row.status, color: "primary" };
return "#0369A1";
}
};
const renderStatus = (row: AgentActivityWidgetProps["activities"][number]) => {
const presentation = status(row);
const renderStatus = (
row: AgentActivityWidgetProps["activities"][number],
horizontal = false,
) => {
const color =
row.phase === "stale"
? "secondary"
Expand All @@ -88,65 +87,52 @@ function AgentActivityWidget(props: AgentActivityWidgetProps, environment: Widge
: row.phase === "failed"
? "#FCA5A5"
: "#7DD3FC"
: presentation.color;
return (
: statusColor(row);
const text = (
<Text
modifiers={[
font({ size: 11, weight: "medium" }),
foregroundStyle(color),
lineLimit(1),
...(horizontal ? [layoutPriority(1)] : []),
]}
>
{row.status}
</Text>
);
return horizontal ? (
text
) : (
<HStack spacing={5} modifiers={[foregroundStyle(color)]}>
<HStack modifiers={[frame({ width: 5, height: 5 })]}>
<Image systemName="circle.fill" modifiers={[resizable()]} />
</HStack>
<Text modifiers={[font({ size: 11, weight: "medium" }), lineLimit(1)]}>
{presentation.label}
</Text>
{text}
</HStack>
);
};

return (
<VStack
alignment="leading"
spacing={accessory ? 5 : 10}
spacing={accessory ? 5 : multiple ? 4 : 10}
modifiers={[
frame({ maxWidth: Infinity, maxHeight: Infinity, alignment: "topLeading" }),
...(props.baseUrl ? [widgetURL(`${props.baseUrl}${hero?.deepLink.slice(1) ?? ""}`)] : []),
]}
>
<HStack spacing={8}>
<HStack modifiers={[frame({ width: accessory ? 21 : 27, height: accessory ? 14 : 18 })]}>
<Image assetName="T3Mark" modifiers={[resizable()]} />
</HStack>
<Spacer minLength={0} />
<Text
modifiers={[
font({ size: 11, weight: "medium" }),
foregroundStyle("secondary"),
lineLimit(1),
]}
>
{stale
? "Out of date"
: activeCount > 0
? `${activeCount} active`
: rows.some((row) => row.phase === "failed")
? "Failed"
: rows.length > 0
? "Done"
: "Agents"}
</Text>
</HStack>
{!multiple && !accessory ? <Spacer minLength={0} /> : null}
{multiple ? (
rows.slice(0, 2).map((row) => (
<VStack key={`${row.environmentId}:${row.threadId}`} alignment="leading" spacing={4}>
<Text modifiers={[font({ size: 14, weight: "semibold" }), lineLimit(1)]}>
rows.slice(0, 5).map((row) => (
<HStack key={`${row.environmentId}:${row.threadId}`} spacing={6} alignment="center">
<Text modifiers={[font({ size: 13, weight: "semibold" }), lineLimit(1)]}>
{row.threadTitle}
</Text>
<HStack spacing={7}>
{renderStatus(row)}
<Text modifiers={[font({ size: 11 }), foregroundStyle("secondary"), lineLimit(1)]}>
· {row.projectTitle}
</Text>
</HStack>
</VStack>
<Text modifiers={[font({ size: 11 }), foregroundStyle("secondary"), lineLimit(1)]}>
{row.projectTitle}
</Text>
<Spacer minLength={8} />
{renderStatus(row, true)}
</HStack>
))
) : hero ? (
<VStack alignment="leading" spacing={accessory ? 3 : 8}>
Expand All @@ -168,7 +154,12 @@ function AgentActivityWidget(props: AgentActivityWidgetProps, environment: Widge
</VStack>
) : (
<VStack alignment="leading" spacing={6}>
<Text modifiers={[font({ size: accessory ? 13 : 17, weight: "semibold" }), lineLimit(2)]}>
<Text
modifiers={[
font({ size: accessory ? 13 : 17, weight: "semibold" }),
lineLimit(accessory ? 1 : 2),
]}
>
{props.source === "loading"
? "Loading activity"
: props.source === "unavailable"
Expand All @@ -179,12 +170,38 @@ function AgentActivityWidget(props: AgentActivityWidgetProps, environment: Widge
? "Ready when you are"
: "Open T3 Code"}
</Text>
<Text modifiers={[font({ size: 12 }), foregroundStyle("secondary"), lineLimit(3)]}>
<Text
modifiers={[
font({ size: 12 }),
foregroundStyle("secondary"),
lineLimit(accessory ? 1 : 3),
]}
>
{props.subtitle ?? "Load agent activity"}
</Text>
</VStack>
)}
{!accessory ? <Spacer minLength={0} /> : null}
<HStack>
<Spacer minLength={0} />
<Text
modifiers={[
font({ size: 11, weight: "medium" }),
foregroundStyle("secondary"),
lineLimit(1),
]}
>
{stale
? "Out of date"
Comment thread
coderabbitai[bot] marked this conversation as resolved.
Resolved

Uh oh!

There was an error while loading. Please reload this page.

: activeCount > 0
? `${activeCount} active`
: rows.some((row) => row.phase === "failed")
? "Failed"
: rows.length > 0
? "Done"
: "Agents"}
</Text>
</HStack>
</VStack>
);
}
Expand Down
2 changes: 1 addition & 1 deletion 2 docs/user/usage.md
Show comments
View file
Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ Session, Weekly, or both for each provider. Reopen T3 to refresh expired reading
## Agent Activity widget

Add **Agent Activity** from the iOS widget gallery to see agents from your T3 Connect account.
Open T3 Code to refresh the snapshot. After 10 minutes, unfinished tasks ask for a refresh.
Open T3 Code to refresh the snapshot. After 10 minutes, unfinished tasks show **Out of date**.
Live Activities continue to receive updates separately.

## Keyboard shortcuts
Expand Down
Loading
Oops, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

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.
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.