Skip to content
Merged
Changes from all commits
Commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ function AutomationsPage() {
),
});

const { data: automationRows = [] } = useLiveQuery(
const { data: automationRows = [], isReady: automationsReady } = useLiveQuery(
(q) =>
q
.from({ a: collections.automations })
Expand Down Expand Up @@ -228,7 +228,7 @@ function AutomationsPage() {
</header>

<div className="flex-1 overflow-y-auto px-8 py-6">
{automations.length === 0 ? (
{!automationsReady ? null : automations.length === 0 ? (
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 No loading indicator while waiting for isReady

While !automationsReady, the content area renders null, leaving the div.flex-1 visually blank. The flicker fix is correct, but users on slower syncs will see an empty grey region rather than any loading feedback. Consider a skeleton or spinner to make the loading state explicit:

Suggested change
{!automationsReady ? null : automations.length === 0 ? (
{!automationsReady ? (
<div className="flex items-center justify-center h-full text-muted-foreground text-sm">
Loading…
</div>
) : automations.length === 0 ? (
Prompt To Fix With AI
This is a comment left during a code review.
Path: apps/desktop/src/renderer/routes/_authenticated/_dashboard/automations/page.tsx
Line: 231

Comment:
**No loading indicator while waiting for `isReady`**

While `!automationsReady`, the content area renders `null`, leaving the `div.flex-1` visually blank. The flicker fix is correct, but users on slower syncs will see an empty grey region rather than any loading feedback. Consider a skeleton or spinner to make the loading state explicit:

```suggestion
			{!automationsReady ? (
				<div className="flex items-center justify-center h-full text-muted-foreground text-sm">
					Loading…
				</div>
			) : automations.length === 0 ? (
```

How can I resolve this? If you propose a fix, please make it concise.

<AutomationsEmptyState onSelectTemplate={handleSelectTemplate} />
) : (
<>
Expand Down
Loading