Skip to content

improve: Add section headers and empty states to the Triggers settings view#5329

Open
ashrafchowdury wants to merge 1 commit into
mainfrom
improve-settings-trigger-view
Open

improve: Add section headers and empty states to the Triggers settings view#5329
ashrafchowdury wants to merge 1 commit into
mainfrom
improve-settings-trigger-view

Conversation

@ashrafchowdury

Copy link
Copy Markdown
Contributor

Context

The Triggers settings page stacked three tables (connections, subscriptions, schedules) with nothing but a button above each one. There was no label saying what a table was for, no hint about how the three relate, and an empty table showed only Ant Design's default "No data". A new user landing here couldn't tell that the flow is: connect an app, then run a workflow on its events or on a schedule.

Changes

Each section now has a header (icon, title, one-line description) and a friendly empty state that tells you what to do next. The sections are also renamed to plain language:

  • "Connect" → Connections — "Link an app like GitHub or Slack so its events can trigger your workflows."
  • Subscriptions → Event triggers — "Run a workflow whenever an event fires in a connected app."
  • Schedules → Scheduled runs — "Run a workflow automatically on a recurring schedule."

A one-line intro at the top of the page ties them together. The header and empty state are shared as TriggerSectionHeader and TriggerEmptyState in a new TriggerSection.tsx, so all three sections render consistently.

Tests / notes

  • Ran pnpm lint-fix in web.
  • The empty-state emptyText renders a bare <span /> while the table is loading, so the placeholder doesn't flash before data arrives.

What to QA

  • Open Settings → Triggers with no connections. Each of the three tables shows its titled empty state, and the top of the page shows the intro line.
  • Connect an app, then subscribe a workflow to an event. The Connections and Event triggers tables fill in; the Subscribe button's "Connect an app first" tooltip is gone once a connection exists.
  • Create a scheduled run bound to a workflow. The "Bound workflow" cell shows the workflow's name, not its id, and hovering it shows the id.
  • Regression: reload buttons on each section still refresh their table.

Preview

Before

image

After

image

@dosubot dosubot Bot added the size:L This PR changes 100-499 lines, ignoring generated files. label Jul 15, 2026
@vercel

vercel Bot commented Jul 15, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
agenta-documentation Ready Ready Preview, Comment Jul 15, 2026 12:43pm

Request Review

@ashrafchowdury

Copy link
Copy Markdown
Contributor Author

Note: I find myself lost in this view many times due to not having any description. It's possible that others may also face this

@coderabbitai

coderabbitai Bot commented Jul 15, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Summary by CodeRabbit

  • New Features
    • Added guidance explaining how to connect apps and automate workflows from the Triggers settings.
    • Improved trigger, connection, subscription, and schedule sections with clearer headers, icons, actions, and tooltips.
    • Added informative empty states for sections without connections, subscriptions, or schedules.
    • Schedule lists now display the associated workflow name when available.
    • Added clearer loading states and streamlined table actions.

Walkthrough

The trigger settings UI now uses shared section headers and empty states, displays bound workflow names for schedules, tightens action columns, and adds guidance explaining event-based and scheduled workflow execution.

Changes

Trigger settings UI

Layer / File(s) Summary
Shared trigger headers and empty states
web/oss/src/components/pages/settings/Triggers/components/TriggerSection.tsx
Adds reusable components for section icons, titles, descriptions, actions, and centered empty states.
Section headers, tables, and empty states
web/oss/src/components/pages/settings/Triggers/components/GatewayTriggersSection.tsx, web/oss/src/components/pages/settings/Triggers/components/GatewaySubscriptionsSection.tsx, web/oss/src/components/pages/settings/Triggers/components/GatewaySchedulesSection.tsx
Updates the three sections to use shared headers and contextual empty states, moves actions into header slots, narrows action columns, and resolves schedule workflow names.
Triggers page guidance
web/oss/src/components/pages/settings/Triggers/Triggers.tsx
Adds secondary guidance text for connecting apps and running workflows from events or schedules.

Estimated code review effort: 3 (Moderate) | ~20 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately summarizes the main change: adding section headers and empty states to Triggers settings.
Description check ✅ Passed The description clearly matches the changeset and explains the new headers, empty states, and shared components.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch improve-settings-trigger-view

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1


ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 3e177cc5-679b-4b41-86b9-decdb5278ca8

📥 Commits

Reviewing files that changed from the base of the PR and between e723777 and aa5b2cf.

📒 Files selected for processing (5)
  • web/oss/src/components/pages/settings/Triggers/Triggers.tsx
  • web/oss/src/components/pages/settings/Triggers/components/GatewaySchedulesSection.tsx
  • web/oss/src/components/pages/settings/Triggers/components/GatewaySubscriptionsSection.tsx
  • web/oss/src/components/pages/settings/Triggers/components/GatewayTriggersSection.tsx
  • web/oss/src/components/pages/settings/Triggers/components/TriggerSection.tsx

Comment on lines +283 to +298
<Tooltip
title={
connections.length === 0 ? "Connect an app first" : undefined
}
>
<Button
type="primary"
size="small"
icon={<Plus size={14} />}
onClick={handleCreate}
disabled={connections.length === 0}
>
Subscribe
</Button>
</Tooltip>
</>

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Ensure the tooltip appears when the button is disabled.

Because disabled HTML elements do not trigger mouse events, the Tooltip will fail to show when connections.length === 0. To ensure users see the "Connect an app first" helper text, wrap the button in an inline element and explicitly remove pointer events from the button so the wrapper catches the hover.

💡 Proposed fix
                             <Tooltip
                                 title={
                                     connections.length === 0 ? "Connect an app first" : undefined
                                 }
                             >
-                                <Button
-                                    type="primary"
-                                    size="small"
-                                    icon={<Plus size={14} />}
-                                    onClick={handleCreate}
-                                    disabled={connections.length === 0}
-                                >
-                                    Subscribe
-                                </Button>
+                                <span className={connections.length === 0 ? "inline-block cursor-not-allowed" : "inline-block"}>
+                                    <Button
+                                        type="primary"
+                                        size="small"
+                                        icon={<Plus size={14} />}
+                                        onClick={handleCreate}
+                                        disabled={connections.length === 0}
+                                        style={connections.length === 0 ? { pointerEvents: "none" } : undefined}
+                                    >
+                                        Subscribe
+                                    </Button>
+                                </span>
                             </Tooltip>
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
<Tooltip
title={
connections.length === 0 ? "Connect an app first" : undefined
}
>
<Button
type="primary"
size="small"
icon={<Plus size={14} />}
onClick={handleCreate}
disabled={connections.length === 0}
>
Subscribe
</Button>
</Tooltip>
</>
<Tooltip
title={
connections.length === 0 ? "Connect an app first" : undefined
}
>
<span
className={
connections.length === 0
? "inline-block cursor-not-allowed"
: "inline-block"
}
>
<Button
type="primary"
size="small"
icon={<Plus size={14} />}
onClick={handleCreate}
disabled={connections.length === 0}
style={
connections.length === 0
? { pointerEvents: "none" }
: undefined
}
>
Subscribe
</Button>
</span>
</Tooltip>
</>

@github-actions

Copy link
Copy Markdown
Contributor

Railway Preview Environment

Preview URL https://gateway-production-b8f5.up.railway.app/w
Project agenta-oss-pr-5329
Image tag pr-5329-a73b7c3
Status Deployed
Railway logs Open logs
Workflow logs View workflow run
Updated at 2026-07-15T12:52:36.789Z

@ashrafchowdury

Copy link
Copy Markdown
Contributor Author

IF this issue makes sense then we need to update some other tabs in the settings, to make sure we are communicating it well about the feature and what it's

@mmabrouk mmabrouk left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

thx @ashrafchowdury lgtm

@dosubot dosubot Bot added the lgtm This PR has been approved by a maintainer label Jul 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Frontend lgtm This PR has been approved by a maintainer size:L This PR changes 100-499 lines, ignoring generated files. UX

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants