Skip to content

Add tool owner-initiated update workflow trigger#77

Merged
Power-Maverick merged 9 commits intomainfrom
copilot/add-tool-update-invocation
Mar 25, 2026
Merged

Add tool owner-initiated update workflow trigger#77
Power-Maverick merged 9 commits intomainfrom
copilot/add-tool-update-invocation

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 22, 2026

  • Create new API endpoint POST /api/tools/[id]/trigger-update
  • Update /api/dashboard to include packagename and version fields in tools response
  • Update dashboard page UI to add "Trigger Update" button in "My Tools" view
  • Show custom validation error modal when package validation fails
  • Disable ALL tools' "Trigger Update" buttons while any update is in progress (no parallel execution)
  • Add "Version" column to "My Tools" view (monospace v{version} badge, -- if not set)
  • Move Trigger Update, Deprecate, Delete into a "More ▾" dropdown in "My Tools" view (keep "View" as standalone link)
  • Fix dropdown z-index issue: use position: fixed anchored via getBoundingClientRect() so the panel renders in the viewport stacking context above all table rows; closes on scroll/resize
  • Remove unused extractVersionInfo npm tarball download from trigger-update route; add version to DB select query

📱 Kick off Copilot coding agent tasks wherever you are with GitHub Mobile, available on iOS and Android.

@vercel
Copy link
Copy Markdown

vercel Bot commented Mar 22, 2026

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

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
web Ignored Ignored Preview Mar 24, 2026 11:16pm

Copilot AI changed the title [WIP] Add ability for tool owner to invoke tool update process Add tool owner-initiated update workflow trigger Mar 22, 2026
Copilot AI requested a review from Power-Maverick March 22, 2026 04:28
@Power-Maverick
Copy link
Copy Markdown
Contributor

@copilot when the package validation fails then show a custom modal providing all the validation errors; do not fail the validation on first but collate all validation errors and warnings and show them to the user. Make sure to mention the name of the package. Also when a validation is invoked for a tool; disable invoking the update for any other tool - no parallel execution allowed for tool update trigger

… triggers

Co-authored-by: Power-Maverick <36135520+Power-Maverick@users.noreply.github.com>
Agent-Logs-Url: https://github.com/PowerPlatformToolBox/pptb-web/sessions/59fc288e-2dfa-437e-b12c-c96334c5d6c4
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Mar 24, 2026

@copilot when the package validation fails then show a custom modal providing all the validation errors; do not fail the validation on first but collate all validation errors and war...

Done in f3aa067. Here's what changed:

Validation modal — instead of an alert(), a modal now appears showing the package name, all collated errors (red), and all warnings (amber). Dismissible via Close button, backdrop click, or Escape key.

No parallel execution — changed disabled={triggeringUpdateForToolId === tool.id || ...} to disabled={triggeringUpdateForToolId !== null || ...}, so ALL "Trigger Update" buttons are disabled while any one tool's update workflow is running.

Dashboard preview

@Power-Maverick
Copy link
Copy Markdown
Contributor

@copilot on the My Tools view add the current version of the tool, keep action View as is but move all other options under More like Trigger Update, Deprecate, Delete

Copy link
Copy Markdown
Contributor Author

Copilot AI commented Mar 24, 2026

@copilot on the My Tools view add the current version of the tool, keep action View as is but move all other options under More like Trigger Update, Deprecate, Delete

Done in d7645fd.

  • Version column added to "My Tools" — shows v{version} as a monospace badge, or -- if not set.
  • View remains a standalone link.
  • Trigger Update, Deprecate, and Delete are now under a More ▾ dropdown that closes on outside click or Escape.

My Tools with Version column and More dropdown

@Power-Maverick
Copy link
Copy Markdown
Contributor

@copilot there seems to be z-index issue. see the screenshot
image

Co-authored-by: Power-Maverick <36135520+Power-Maverick@users.noreply.github.com>
Agent-Logs-Url: https://github.com/PowerPlatformToolBox/pptb-web/sessions/35f1a7df-135a-4672-afe0-b9731c3dd784
Copy link
Copy Markdown
Contributor Author

Copilot AI commented Mar 24, 2026

@copilot there seems to be z-index issue. see the screenshot
<img width="269" height="297" alt="image" src="https://github.com/user-attachments/assets/f2c4a79f-202a-421a-bb21-5a2d68...

Fixed in fba4efb. Two changes:

  1. overflow-visible on the card wrapper — previously overflow-hidden was clipping any dropdown that extended past the card's bounds.
  2. relative z-10 on the active <tr> — when a menu is open, that row now creates a stacking context that sits above subsequent rows, preventing later rows from painting over the dropdown.

The "More ∨" text from the row below no longer overlaps the open menu.

@Power-Maverick Power-Maverick marked this pull request as ready for review March 24, 2026 21:43
Copilot AI review requested due to automatic review settings March 24, 2026 21:43
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds an owner-initiated “Trigger Update” workflow from the authenticated dashboard, backed by a new API route that validates the tool’s npm package and dispatches the GitHub Actions update workflow.

Changes:

  • Added POST /api/tools/[id]/trigger-update to validate npm package metadata and run the update workflow for a tool owned by the caller.
  • Extended /api/dashboard tool selection to include packagename and version.
  • Updated the authenticated dashboard “My Tools” table UI to show a Version column, add a “More” dropdown with “Trigger Update”, and display a validation error modal.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
app/api/tools/[id]/trigger-update/route.ts New authenticated endpoint to trigger a tool update workflow after npm/package.json validation.
app/api/dashboard/route.ts Adds packagename and version to the tools payload for dashboard rendering.
app/(authenticated)/dashboard/page.tsx Adds “Trigger Update” flow + validation modal, Version column, and “More” dropdown with updated z-index/overflow behavior.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread app/(authenticated)/dashboard/page.tsx
Comment thread app/api/tools/[id]/trigger-update/route.ts Outdated
Comment thread app/(authenticated)/dashboard/page.tsx Outdated
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@Power-Maverick Power-Maverick merged commit af6a6b2 into main Mar 25, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants