Repository navigation
feat: drag to reorder sites - #43
Merged
Merged
Conversation
Add position column to sites table and implement drag-and-drop reordering using @dnd-kit. Logged-in admins see a grip handle on hover and can drag list items to set custom order. Order persists via a new reorderSites server action. New sites are appended at the end. Closes #41 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Updates to Preview Branch (feature/drag-reorder-sites) ↗︎
Tasks are run on every commit but only new migration files are pushed.
View logs for this Workflow Run ↗︎. |
…erSites tests The addSite mock now handles the select→order→limit→single chain for fetching max position, and the insert assertion includes the position field. Also adds tests for the new reorderSites action. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The packages were installed locally but not committed when the branch was recreated, causing build failures in CI and Vercel. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The client component's useState kept stale data after server actions called revalidatePath. Now detects when server-provided props change and syncs local state, so add/edit/delete are reflected immediately. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Position the grip icon to the left of the card border instead of inside the card content area, eliminating the empty gap on the left when the handle is hidden. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Adds 4 sites with check histories demonstrating each status: - Healthy Site: all passing → Up (green) - Flaky Site: one 503 among passing checks → Transient Failures (amber) - Broken Site: one HTTP 500 → Failures (red) - Down Site: 6 consecutive 503s with open incident Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Collaborator
Author
|
Two issues:
|
The outer SortableSiteCard wrapper and inner SiteCard both had the Tailwind 'group' class, causing Playwright's .group locator to match two elements per card. Now only the outermost container gets 'group'. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Position drag handle absolutely in the left margin so cards stay left-aligned with the Sites heading and Add site button - Add restrictToVerticalAxis modifier so items can only be dragged up and down, not freely across the screen Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This branch was successfully deployed
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
positioncolumn tositestable with migration to backfill existing rows alphabeticallySiteListclient component using@dnd-kitfor drag-and-dropreorderSitesserver actionCloses #41
Test plan
🤖 Generated with Claude Code