You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat(frontend): Open in the Prompts row menu and red confirm buttons - #8155
On the /m Prompts page, a prompt row can open its app overview, and the Archive and Delete confirm buttons are solid red like /w.
What the user sees (developer views on)
A prompt row menu starts with Open, which goes to the app overview (apps-prompts-07).
A row click goes to the playground. When only the overview view is on, it goes to the overview instead of doing nothing (apps-prompts-08).
The confirm buttons in Archive prompt and Delete folder are solid red instead of pale (apps-prompts-14). Only these two Prompts dialogs change. Other confirm dialogs in /m keep their look (new solid option on ConfirmModal).
Without the overview view on, the menu and row click are as before.
Decided not to do, from the plan (decision 6)
Row radio, toolbar Archive and Delete, and a column menu (apps-prompts-04): the row menu does the same job and the list has few columns.
Drag-and-drop move (apps-prompts-09): the Move dialog covers it for now.
Already true in /m
Type tag: prompts show the coloured type tag and folders a bordered tag (apps-prompts-02).
390 px: the date column drops below 640 px and the table minimum is 300 px (apps-prompts-15).
Toolbar spacing (apps-prompts-01): left as it is, it matches the other /m list pages.
Checks
promptsScreen.render.test.tsx gets three tests: Open in the menu goes to the overview, a row click goes to the overview when only that view is on, and to the playground when both are on.
Types, lint and the Prompts tests pass. Screenshots and the full suite are left to the batch check.
…ttons
A prompt row menu offers Open (the app overview) and a row click goes to the
overview while the playground view is off. The Archive and Delete confirm
buttons on the Prompts page are solid red.
Entire-Checkpoint: 01M6R53K59Z0T6EHF3S7T78ZYK
Prompt rows can now open an app overview when that view is available. If both the overview and playground are enabled, selecting a prompt row continues to open the playground, while a separate menu option opens the overview.
Prompts without write access can still offer an Open option when an overview is available.
Style
Destructive confirmation dialogs now display a solid red confirm button with white text.
Prompt rows can open the app overview when enabled, while playground navigation remains the row-click action when both views are enabled. The change also adds optional solid styling for destructive confirmation buttons and enables it in the archive and folder-delete dialogs.
Changes: Prompt overview navigation
Layer / File(s)
Summary
Overview action and URL web/mobile/src/features/prompts/promptRowActions.ts, web/mobile/src/features/prompts/PromptsScreen.tsx
PromptRowActions adds an optional overview callback. PromptsScreen builds an overview URL for each prompt.
Prompt row navigation and menu web/mobile/src/features/prompts/PromptRowMenu.tsx, web/mobile/src/features/prompts/PromptsScreen.tsx, web/mobile/tests/unit/promptsScreen.render.test.tsx
When app overview is enabled, prompt rows expose an Open menu action. Row clicks open the overview unless the playground is also enabled, in which case they open the playground. Tests cover both navigation paths.
Solid destructive confirmation buttons
Layer / File(s)
Summary
Confirm button styling and dialog wiring web/mobile/src/features/settings/ConfirmModal.tsx, web/mobile/src/features/prompts/dialogs/ArchivePromptDialog.tsx, web/mobile/src/features/prompts/dialogs/DeleteFolderDialog.tsx
ConfirmModal adds a solid prop. It applies solid red styling only when both destructive and solid are true. The archive and folder-delete dialogs pass solid.
sequenceDiagram
actor User
participant PromptRowMenu
participant PromptsScreen
User->>PromptRowMenu: Select Open
PromptRowMenu->>PromptsScreen: Invoke openOverview(row)
PromptsScreen->>User: Navigate to the prompt overview
Loading
Possibly related PRs
Agenta-AI/agenta#8075: Adds the openPrompt callback for playground navigation from prompt rows.
Agenta-AI/agenta#8004: Adds the prompt row menu and archive and delete confirmation dialogs.
Agenta-AI/agenta#8012: Adds the playground route and playgroundHref used for prompt row navigation.
Merge Risk: Low · previous review c5bbc
Dark-mode confirmation labels may be difficult to read. The change is mergeable with awareness of this issue.
Pre-merge checks: 5
Check name
Status
Explanation
Title check
The title identifies the prompt row Open action and red confirm buttons.
Description check
The description covers prompt navigation, the confirm button changes, and the added tests.
Docstring Coverage
No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage
Explanation
No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 0 functions across 7 files.
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
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.
With the overview enabled, the menu test uses write permission. Add a read-only case to catch a regression that hides Open when edit_workflows is false.
Suggested fix
+ it("A reader can open a prompt overview from the menu", () => {+ permissions.edit_workflows = false+ enabledViews.add("app-overview")+ mount()+ openMenu(bodyRows()[1].querySelector("[aria-label='Actions']") as Element)+ const items = [...document.querySelectorAll<HTMLElement>("[role=menuitem]")]+ expect(items.map((item) => item.textContent)).toEqual(["Open"])++ act(() => items[0].click())++ expect(router.push).toHaveBeenCalledWith("/w/ws/p/project-1/apps/p1/overview")+ })+
it("A row click goes to the overview when only the overview view is on", () => {
Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 4 remain after this review.
Dependent tests finished. Post /preview for manual review. Environment absence verified; retained storage requires separate provider accounting.
Post /preview as a new comment to request a one-hour preview. Repeating it while active does not extend the hour.
Preview data is disposable. Expiry is enforced by the next successful cleanup sweep, not an exact timer.
Environment deletion stops its compute. Provider-retained storage and permanent services may still be billed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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.
On the /m Prompts page, a prompt row can open its app overview, and the Archive and Delete confirm buttons are solid red like /w.
What the user sees (developer views on)
solidoption onConfirmModal).Without the overview view on, the menu and row click are as before.
Decided not to do, from the plan (decision 6)
Already true in /m
Checks
promptsScreen.render.test.tsxgets three tests: Open in the menu goes to the overview, a row click goes to the overview when only that view is on, and to the playground when both are on.