-
Notifications
You must be signed in to change notification settings - Fork 548
[Dashboard] Add self-service dedicated engine deployment option #7325
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.
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
[Dashboard] Add self-service dedicated engine deployment option #7325
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
WalkthroughThe changes refactor several dashboard components to standardize how team and project data are passed as props. Instead of separate string props for team and project slugs or plan, a Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant DashboardPage
participant EngineInstancesList
participant EngineInstancesTable
participant DedicatedEngineSubscriptionButton
participant ModalOrDrawer
User->>DashboardPage: Visits project engine overview
DashboardPage->>EngineInstancesList: Passes team object, projectSlug, instances
EngineInstancesList->>EngineInstancesTable: Passes team object, projectSlug, instances
EngineInstancesTable->>User: Renders table and DedicatedEngineSubscriptionButton
User->>DedicatedEngineSubscriptionButton: Clicks "Deploy Dedicated Engine"
DedicatedEngineSubscriptionButton->>ModalOrDrawer: Opens responsive UI for deployment
ModalOrDrawer->>User: Shows subscription/deployment flow
✨ Finishing Touches
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. This stack of pull requests is managed by Graphite. Learn more about stacking. |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #7325 +/- ##
=======================================
Coverage 55.57% 55.57%
=======================================
Files 909 909
Lines 58675 58675
Branches 4157 4157
=======================================
Hits 32608 32608
Misses 25960 25960
Partials 107 107
🚀 New features to boost your workflow:
|
dcec9b9
to
5cb55f6
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (3)
apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-instances-table.tsx (3)
43-44
: Remove empty import
import {} from "@/components/ui/popover";
brings no side-effects and will trigger unused-import lint rules.-import {} from "@/components/ui/popover"; +// remove – not used
130-218
: Avoid duplication between Drawer and Dialog flows
DedicatedEngineSubscriptionButton
repeats the same markup twice. Extract the shared header/body into a small component and render it inside eitherDialog
orDrawer
to keep maintenance low.
150-167
: Hard-coded SKU warrants a constantUsing the literal
"product:engine_standard"
in multiple places is fragile. Define a constant (e.g.ENGINE_STANDARD_SKU
) in a shared billing constants file and reuse it.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (5)
apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/cloud/layout.tsx
(1 hunks)apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/_components.tsx
(1 hunks)apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-instances-table.tsx
(10 hunks)apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-list.tsx
(1 hunks)apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/page.tsx
(1 hunks)
🧰 Additional context used
🧬 Code Graph Analysis (2)
apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/_components.tsx (1)
apps/dashboard/src/@/api/team.ts (1)
Team
(9-9)
apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-list.tsx (3)
apps/dashboard/src/@/api/team.ts (1)
Team
(9-9)apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-instances-table.tsx (1)
EngineInstancesTable
(100-128)apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/_components.tsx (1)
EngineFooterCard
(77-89)
⏰ Context from checks skipped due to timeout of 90000ms (8)
- GitHub Check: E2E Tests (pnpm, esbuild)
- GitHub Check: E2E Tests (pnpm, webpack)
- GitHub Check: E2E Tests (pnpm, vite)
- GitHub Check: Size
- GitHub Check: Unit Tests
- GitHub Check: Build Packages
- GitHub Check: Lint Packages
- GitHub Check: Analyze (javascript)
🔇 Additional comments (5)
apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/cloud/layout.tsx (1)
63-63
: Label update looks goodThe wording change is clear and consistent with the other views. No further action needed.
apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/page.tsx (1)
50-52
: Ensure downstream typings are updated
EngineInstancesList
now expectsteam: Team
andprojectSlug: string
. Verify all call-sites compile after this change (CI should catch).apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/_components.tsx (1)
78-86
: Prop refactor looks correctPassing the full
team
object simplifies the interface and future-proofs the footer. Mapping toEngineInfoSection
is clear.apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-list.tsx (1)
7-24
: Path construction updated correctlyUsing
props.team.slug
guarantees consistency with other links; no logic change.apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-instances-table.tsx (1)
230-236
: Nice UX touchAdding the deploy button next to the title improves discoverability.
size-limit report 📦
|
5cb55f6
to
313122e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ BugBot reviewed your changes and found no bugs!
Was this report helpful? Give feedback by reacting with 👍 or 👎
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🔭 Outside diff range comments (2)
apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-instances-table.stories.tsx (2)
92-107
:⚠️ Potential issue
team
prop is now required – stories will crash
EngineInstancesTableUI
expects a non-optionalteam
object, butMultipleInstances
(and the wrapperStory
args that feed it) omit this prop.
Running Storybook will throw a type error & render failure.export const MultipleInstances: Story = { args: { instances: [ // active cloudHostedEngineInstance, cloudHostedPlanActiveEngineInstance, selfHostedActiveEngineInstance, // others pendingEngineInstance, deployingEngineInstance, paymentFailedEngineInstance, deploymentFailedEngineInstance, ], engineLinkPrefix: "/team/test/engine", + team: teamStub("0", "pro"), }, };
135-140
:⚠️ Potential issueSame missing
team
prop inOneInstance
storyAdd a stubbed team object here as well to satisfy the updated component signature.
export const OneInstance: Story = { args: { instances: [cloudHostedEngineInstance], engineLinkPrefix: "/team/test/engine", + team: teamStub("4", "pro"), }, };
🧹 Nitpick comments (1)
apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-instances-table.tsx (1)
43-43
: Remove the emptypopover
import
import {} from "@/components/ui/popover";
pulls nothing into the module and will trip most ESLint rules (no-empty-import
,unused-modules
).
Delete it to keep the import list clean.-import {} from "@/components/ui/popover";
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (7)
apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/cloud/layout.tsx
(1 hunks)apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/EngineFooterCard.stories.tsx
(2 hunks)apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/_components.tsx
(1 hunks)apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-instances-table.stories.tsx
(3 hunks)apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-instances-table.tsx
(10 hunks)apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-list.tsx
(1 hunks)apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/page.tsx
(1 hunks)
🚧 Files skipped from review as they are similar to previous changes (4)
- apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/cloud/layout.tsx
- apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/page.tsx
- apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/_components.tsx
- apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-list.tsx
🧰 Additional context used
🧬 Code Graph Analysis (1)
apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/overview/engine-instances-table.stories.tsx (1)
apps/dashboard/src/stories/stubs.ts (1)
teamStub
(32-116)
⏰ Context from checks skipped due to timeout of 90000ms (8)
- GitHub Check: E2E Tests (pnpm, esbuild)
- GitHub Check: E2E Tests (pnpm, webpack)
- GitHub Check: E2E Tests (pnpm, vite)
- GitHub Check: Size
- GitHub Check: Unit Tests
- GitHub Check: Lint Packages
- GitHub Check: Build Packages
- GitHub Check: Analyze (javascript)
🔇 Additional comments (1)
apps/dashboard/src/app/(app)/team/[team_slug]/[project_slug]/(sidebar)/engine/dedicated/(general)/EngineFooterCard.stories.tsx (1)
23-28
: Good update to camelCase propsProps were renamed to
teamSlug
/projectSlug
; the story args reflect this change accurately.
No action needed.
Dedicated Engine UI Improvements
This PR enhances the Dedicated Engine UI with several improvements:
These changes make it easier for users to understand and deploy dedicated engines.
PR-Codex overview
This PR focuses on refactoring the
team_slug
andproject_slug
props toteamSlug
andprojectSlug
across several components, enhancing consistency in naming conventions. Additionally, it introduces a new component,DedicatedEngineSubscriptionButton
, for managing dedicated engine subscriptions.Detailed summary
team_slug
toteamSlug
andproject_slug
toprojectSlug
in multiple components.Button
text from "View dedicated engines" to "View Dedicated Engine".DedicatedEngineSubscriptionButton
for dedicated engine subscriptions.EngineFooterCard.stories.tsx
.EngineInstancesTableUI
for better structure and added subscription button.Summary by CodeRabbit
New Features
Refactor