Skip to content

Commit 3e99965

Browse files
feat(samples/action-center-app): migrate UI to Apollo Vertex (apollo-wind)
Replace hand-rolled Tailwind primitives with @uipath/apollo-wind components across App, TaskList, and TaskDetail. No more custom Modal/Button/Select/ Tabs/Badge — everything renders through UiPath's design system. Build setup - Upgrade Tailwind v3 → v4 (drop tailwind.config.js; apollo-wind ships its own @tailwindcss/postcss preset) - postcss.config.js reuses @uipath/apollo-wind/postcss - src/index.css → single @import '@uipath/apollo-wind/styles.css' (apollo's tokens already include light + dark variants) Components - Dialog, Card, Input, Label, Select, Tabs, Table, Badge, Alert, Spinner, Sonner, EmptyState from @uipath/apollo-wind - Remove src/components/Modal.tsx (replaced by Dialog) - Badge variants (success/info/warning/error) replace TONE classnames - next-themes provider + Sun/Moon ThemeToggle (apollo-wind has no provider) UX - ListChecks / ShieldCheck / Plus / RefreshCw / Inbox / User / Users icons - Tab count badges on the active tab - Animated refresh spinner during refetch - Skeleton table while loading (industry-standard data-grid pattern) - Folder filter is a proper filter chip: leading Folder icon, clear (X) button, Escape to clear, no number-input spinners (folder IDs are identifiers, not quantities) - Fix stale data on tab switch (clear tasks on dep change in useTasks) - uipath.json.example: baseUrl https://api.uipath.com
1 parent b7a2c26 commit 3e99965

17 files changed

Lines changed: 3940 additions & 1277 deletions

samples/action-center-app/README.md

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,20 @@
22

33
A minimal React + TypeScript [UiPath Coded Web App](https://docs.uipath.com/)
44
demonstrating the `@uipath/uipath-typescript` SDK's **Tasks (Action Center)**
5-
service. It's an operational dashboard for triaging human tasks in a folder:
6-
list and filter them, view detail, assign / reassign / unassign, complete
7-
(approve / reject), and create external tasks.
5+
service. It's an operational dashboard for triaging human tasks: list and
6+
filter them across your folders, view detail, assign / reassign / unassign,
7+
complete (approve / reject), and create external tasks.
88

9-
Built with plain Tailwind (no component library) to keep the file count small.
9+
Built on UiPath's [Apollo Vertex](https://apollo-vertex.vercel.app/) design
10+
system via [`@uipath/apollo-wind`](https://www.npmjs.com/package/@uipath/apollo-wind).
1011

1112
## What it demonstrates
1213

1314
Every method on [`TaskServiceModel`](https://uipath.github.io/uipath-typescript/api/interfaces/TaskServiceModel/):
1415

1516
| SDK call | Where |
1617
|----------|-------|
17-
| `Tasks.getAll({ folderId, pageSize, jumpToPage, filter, orderby })` | `hooks/useTasks.ts` (`useTasks`) — paginated, filterable list |
18+
| `Tasks.getAll({ folderId, pageSize, jumpToPage, filter, orderby, asTaskAdmin })` | `hooks/useTasks.ts` (`useTasks`) — paginated, filterable list |
1819
| `Tasks.getById(id, {}, folderId)` | `hooks/useTasks.ts` (`useTask`) — full detail |
1920
| `Tasks.getUsers(folderId)` | `hooks/useTasks.ts` (`useTaskUsers`) — assignee picker (cursor-looped) |
2021
| `Tasks.create({ title, priority }, folderId)` | `components/TaskList.tsx` (create form) |
@@ -24,8 +25,8 @@ Every method on [`TaskServiceModel`](https://uipath.github.io/uipath-typescript/
2425
By default the app lists tasks across **all folders** you can view/edit. The
2526
header's **Folder ID** field is an optional filter — leave it blank for all
2627
folders, or set it to scope the list (persisted to `localStorage`). Per-task
27-
actions (detail, assign, complete) use each task's own folder; creating a task
28-
asks for a target folder.
28+
actions (detail, assign, complete) use each task's own folder, propagated from
29+
the row; creating a task asks for a target folder.
2930

3031
## Files
3132

@@ -35,14 +36,15 @@ src/
3536
taskUtils.ts — badges, filter builder, complete-options builder, formatting
3637
hooks/useAuth.tsx — OAuth/PKCE via the SDK (Coded Apps template)
3738
hooks/useTasks.ts — useTasks + useTask + useTaskUsers
38-
components/Modal.tsx, TaskList.tsx, TaskDetail.tsx
39+
components/Theme.tsx, TaskList.tsx, TaskDetail.tsx
3940
```
4041

4142
## Prerequisites
4243

4344
- Node.js 20+
4445
- A UiPath OAuth External Application (client ID) with the **`OR.Tasks`** scope
45-
- An Orchestrator folder ID that contains Action Center tasks
46+
- An Orchestrator folder ID that contains Action Center tasks (required only
47+
when creating tasks)
4648

4749
## Setup
4850

samples/action-center-app/index.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
<html lang="en">
33
<head>
44
<meta charset="UTF-8" />
5+
<link rel="icon" type="image/png" href="/src/assets/favicon.png" />
56
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
67
<title>Action Center Manager</title>
78
</head>

0 commit comments

Comments
 (0)