Skip to content

feat(desktop): drag-and-drop pinning in the v2 sidebar - #6364

Merged
Kitenite merged 4 commits into
mainfrom
sidebar-pin-drag-drop
Aug 12, 2026
Merged

Kitenite merged 4 commits into
mainfrom
sidebar-pin-drag-drop

Conversation

@Kitenite

@Kitenite Kitenite commented Aug 11, 2026 •

Copy link
Copy Markdown
Member

Links

  • ExecPlan (original pinning feature, this ships its deferred D6): apps/desktop/plans/done/20260725-1947-sidebar-workspace-pinning.md

Summary

  • Workspaces can now be dragged into the Pinned section (pin), reordered within it, and dragged back out (unpin, landing at the drop position). Sessions get the same treatment, and session rows became sortable as a side effect.
  • The sidebar's drag-and-drop moves from per-project DndContexts to one unified context (pinned / sessions / one container per project) — required because dnd-kit cannot drag across separate contexts.
  • Includes hardening found by adversarial CDP testing: a renderer crash fix (transfer oscillation → "Maximum update depth exceeded"), a data-corruption guard (a single drop could mass-pin swept-over rows under main-thread stalls), drag-time render-fan-out fixes, and hover-card suppression during drags.

Why / Context

Pinned-section drag reorder was explicitly deferred as decision D6 in the original pinning ExecPlan ("mechanical follow-up if wanted"). It turned out to be non-mechanical: cross-boundary dragging forces the unified-context restructure, which then surfaced the perf and stability work in the later commits.

How It Works

Containers. useSidebarDnd is now a sidebar-level multi-container engine. Every workspace row lives in exactly one container: pinned, sessions, or its project id. SortableContexts stay per-section; one DndContext (hosted by the new DashboardSidebarDndProvider) spans them all. Container-less targets (empty Pinned, empty Sessions, fully-pinned project) get a leaf SidebarDropZone.

Collision detection is kind-scoped (projects sort among projects, sections within their project, a workspace may only target Pinned or its home container) and uses dnd-kit's multi-container strategy for workspace drags: pointerWithin → rectIntersection → cached lastOverId, plus a one-frame freeze after each transfer. Bare closestCenter is what crashed: with Pinned at the top and the home project far below, "closest" flips on sub-pixel movement in the gap — and on the layout shift a transfer itself causes — producing a transfer oscillation that remounts the row until React aborts.

Persistence. Pinned order stays pinnedAt-ascending; reorderPinnedWorkspaces rewrites the sequence anchored at the smallest existing pin time so future pins still append last. It also enforces that one drop pins at most one new workspace (the dragged one) — a corrupted caller list can never mass-pin. Unpin drops reuse the existing tabOrder/section commit path. Drop-in-place is compared against the drag-start snapshot and writes nothing.

Race-proofing. Drag handlers read and write the item/container refs synchronously. Pointer events batch faster than renders under main-thread stalls; deriving containers from the last rendered state is how a drop once pinned three session rows that were never dragged.

Render fan-out rules (these are the drag-perf load-bearing invariants):

  • the shared drag context never carries per-pointer-move values (no over id, no predicted color — the predicted section accent renders on the DragOverlay ghost);
  • useDroppable lives only in leaf components (its internal context updates per move — hosting it in a section re-renders that section per move);
  • sortable wrappers memoize their row bodies so per-move wrapper re-renders don't re-run row query hooks;
  • hover cards are suppressed for the drag's duration via the hover provider's existing counted-suppression mechanism, now also making performOpen inert (hover-open side effects like the PR refresh key off hoveredId even when the card is hidden).

Manual QA (CDP-verified end-to-end, trusted input events, dev app)

All items below were driven with real Input.dispatchMouseEvent sequences and asserted against both screenshots and the persisted v2WorkspaceLocalState collection:

  • Drag a project worktree row into the empty Pinned section ("Drop to pin" zone appears mid-drag); pinned row renders with project avatar
  • Drag a session into Pinned below an existing pin
  • Reorder rows within Pinned (pinnedAt sequence rewritten, anchor preserved)
  • Drag a pinned row back into its home project at a specific position (lane renumbered 1..n, local main stays first)
  • Drag a pinned session back into Sessions at a position
  • Within-project reorder and project-header reorder (incl. with autoscroll) still work
  • Pin survives location.reload()
  • Crash scenario: real project order + long sweeps with autoscroll + boundary oscillation + mid-drag dwells — reproduced 2 × "Maximum update depth exceeded" before the fix, 0 after, across repeated runs
  • Corruption scenario: 4/4 boundary-wiggle drags with injected 120 ms main-thread stalls pin exactly the dragged row; sessions lane byte-identical
  • Hover cards: 0 opens during drags (28 poll samples incl. 900 ms dwells); hover works normally after drop
  • Perf: 80-move drag long-task time 445–600 ms stable at 97–102 fps (was 791→1173 ms degrading, worst 250 ms); CPU-profile idle 22.6% → 51.4% (dev build)
  • Reviewer spot-check on a large real sidebar with section groups (my dev fixture has no expanded section groups; section-drag code paths are unchanged and unit-covered, but a hands-on pass is worthwhile)

Testing

  • bun run typecheck
  • bun run lint (exits 0)
  • bun test for DashboardSidebar + useDashboardSidebarState (74 pass)
  • CDP verification as above; adversarial-drag methodology added to AGENTS.md (CDP rules 7–8)

Design Decisions

  • Rewrite pinnedAt vs adding an order field: reusing pinnedAt as the ordering key keeps the schema untouched (no migration, no new persisted key) and preserves the "future pins append last" property by anchoring the rewrite below Date.now().
  • pointerWithin-first vs closestCenter: pointer containment can't flip in the gap between far-apart containers and removes action-at-a-distance transfers; rectIntersection covers keyboard drags; the lastOverId cache keeps over stable across disallowed territory.
  • Predicted accent on the overlay ghost instead of the in-list row: the in-list variant needs per-move context churn through every row; the ghost follows the pointer anyway.

Known Limitations

  • A project's local main workspace is drag-disabled (pre-existing rule so mains stay first); it can still be pinned via the context menu.
  • Cross-container inserts land where the live make-room preview shows, which with pointer-based collision can read one slot off from the pointer's exact pixel — standard dnd-kit behavior; within-section reorder afterwards is unaffected.
  • Collapsed-rail (icon) mode intentionally has no pin drag targets; pinning there remains context-menu only.

Follow-ups

  • Branch sidebar-render-perf (in progress, forked from this one): hover-open PR-refresh cool-down, collapsing ~80 per-row query subscriptions into one sidebar-level subscription, replacing per-row framer-motion wrappers.
  • Deferred from the original plan and still open: shortcut-map entries for pinned rows (D7), hover pin button (D8).

Risks / Rollout

  • Risk: regressions in existing sidebar reordering (projects/sections/workspaces) since all drags now share one context; mitigated by the CDP battery + unchanged persistence paths + 74 unit tests.
  • Rollout: ships with the desktop app, no flags, no schema/data changes.
  • Rollback: revert the three commits; pin state is plain pinnedAt values that the previous build already understands.

Summary by cubic

Adds unified drag-and-drop in the v2 sidebar so you can drag workspaces/sessions into Pinned, reorder them, and drag them back out. Fixes a drag crash and tightens persistence to avoid accidental mass pinning.

  • New Features

    • One DndContext spans Pinned, Sessions, and project lists; cross-boundary drags now work.
    • Reorder Pinned; drag from projects/Sessions to pin, and drag out to unpin at a specific position.
    • Empty containers show a drop zone (“Drop to pin” / “Drop to unpin”) so first inserts land correctly.
    • Pinned order stays pinnedAt-ascending; future pins still append. Drag overlay shows the predicted section accent. Sortable row bodies are memoized.
  • Bug Fixes

    • Stopped transfer oscillation crash by switching workspace collision to pointerWithin → rectIntersection → cached last hit, with a one-frame freeze after transfers; the freeze is now re-armed at the transfer site.
    • Race-proofed drops: handlers read/write container and item refs synchronously, commitDragItems is the only writer, and a single drop can pin at most one new workspace.
    • Hover cards are suppressed during drags and always released; suppression is unwound with try/finally and delayed opens re-check suppression before showing.
    • Reduced drag-time renders by keeping droppable only in leaf drop zones.

Written for commit 1aab78f. Summary will update on new commits.

Review in cubic

Summary by CodeRabbit

  • New Features
    • Added unified drag-and-drop sorting for projects, workspaces, pinned items, and sessions.
    • Added drop zones for pinning, unpinning, and moving items between sidebar sections.
    • Preserved workspace accent colors in drag previews.
  • Bug Fixes
    • Improved drag behavior during repeated moves, cancellations, and invalid drops.
    • Prevented hover cards from opening while dragging.
    • Reduced unnecessary sidebar updates during pointer movement.

One DndContext now spans pinned/sessions/project rows so workspaces can be
dragged into, within, and out of the Pinned section. Pinned order stays
pinnedAt-ascending via reorderPinnedWorkspaces (anchored rewrite + single-new-
pin invariant). Drag handlers read/write container state synchronously to
survive event batching under main-thread stalls; per-pointer-move state is
kept out of the shared context, drop zones are leaf components, sortable row
bodies are memoized, and hover cards are suppressed for the drag's duration.
…derer

closestCenter over the two allowed containers (Pinned at the top, home
project lower down) flips on sub-pixel movement in the gap between them —
and on the layout shift each container transfer itself causes, re-firing
with the pointer stationary. The resulting transfer loop remounts the row
until React throws 'Maximum update depth exceeded'. Switch workspace drags
to dnd-kit's multi-container strategy: pointerWithin, then rectIntersection,
then the cached last hit, with a one-frame freeze after each transfer.
@coderabbitai

coderabbitai Bot commented Aug 11, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: c9000e3d-a615-4a2d-83f3-848bc1616913

📥 Commits

Reviewing files that changed from the base of the PR and between 3e835c4 and 1aab78f.

📒 Files selected for processing (3)
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/hooks/useSidebarDnd/useSidebarDnd.ts
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/providers/DashboardSidebarDndProvider/DashboardSidebarDndProvider.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/providers/DashboardSidebarHoverProvider/DashboardSidebarHoverProvider.tsx
🚧 Files skipped from review as they are similar to previous changes (3)
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/providers/DashboardSidebarHoverProvider/DashboardSidebarHoverProvider.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/providers/DashboardSidebarDndProvider/DashboardSidebarDndProvider.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/hooks/useSidebarDnd/useSidebarDnd.ts

📝 Walkthrough

Walkthrough

The sidebar drag-and-drop implementation now uses one shared provider and multi-container state. Projects, sections, pinned workspaces, and sessions support coordinated sorting, pinning, unpinning, overlays, persistence, rollback, and hover suppression.

Changes

Sidebar drag-and-drop

Layer / File(s) Summary
Multi-container DnD state
apps/desktop/.../DashboardSidebar/hooks/useSidebarDnd/*
useSidebarDnd now manages pinned, session, project, and section containers with type-specific collision detection and shared lookup state.
Drag transfers and persistence
apps/desktop/.../useSidebarDnd.ts, apps/desktop/.../useDashboardSidebarState.ts
Workspace transfers update containers optimistically, persist ordering and pin state, skip unchanged writes, and restore snapshots after cancellation or invalid drops.
Shared DnD provider
apps/desktop/.../DashboardSidebar.tsx, apps/desktop/.../DashboardSidebarDndProvider/*, apps/desktop/.../DashboardSidebarHoverProvider.tsx
DashboardSidebarDndProvider owns the DnD context, lifecycle handlers, overlays, project ordering, and hover suppression.
Sortable sections and drop targets
apps/desktop/.../DashboardSidebar/components/*
Pinned, session, collapsed-project, and expanded-project sections consume shared DnD state. New drop zones support pinning and unpinning. Sortable workspace rows are memoized.

Estimated code review effort: 4 (Complex) | ~60 minutes

Sequence Diagram(s)

sequenceDiagram
  participant DashboardSidebar
  participant DashboardSidebarDndProvider
  participant useSidebarDnd
  participant useDashboardSidebarState
  DashboardSidebar->>DashboardSidebarDndProvider: pass sidebar collections and reorderProjects
  DashboardSidebarDndProvider->>useSidebarDnd: handle drag lifecycle events
  useSidebarDnd->>useDashboardSidebarState: persist project and workspace ordering
  DashboardSidebarDndProvider->>DashboardSidebar: render sortable rows and drag overlay
Loading

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 28.57% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the desktop sidebar drag-and-drop pinning feature and follows the repository's conventional commit format.
Description check ✅ Passed The description explains the change, motivation, implementation, testing, risks, and limitations; only the template checklist section is omitted.
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 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch sidebar-pin-drag-drop

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
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 4

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/hooks/useSidebarDnd/useSidebarDnd.ts`:
- Around line 269-276: Remove the render-time assignments to itemsRef.current
and containerByIdRef.current, and avoid rebuilding the container map solely for
those refs. Keep both refs updated exclusively by commitDragItems, while
deriving the render-time container map from items for consumers; route any other
items replacement through commitDragItems.
- Around line 527-531: Update the useEffect that resets
recentlyMovedToNewContainerRef so it depends on items instead of using an empty
dependency array, scheduling the transfer-freeze reset after every items update
while preserving the requestAnimationFrame behavior.</code>

In
`@apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/providers/DashboardSidebarDndProvider/DashboardSidebarDndProvider.tsx`:
- Around line 77-87: Update handleDragEnd and handleDragCancel in
DashboardSidebarDndProvider to wrap each handler invocation in try/finally,
ensuring endHoverCardSuppression always executes even when handlers.onDragEnd or
handlers.onDragCancel throws.

In
`@apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/providers/DashboardSidebarHoverProvider/DashboardSidebarHoverProvider.tsx`:
- Around line 221-225: Update the delayed open timer callback in
DashboardSidebarHoverProvider to re-check suppressionCountRef.current before
setting hoveredId or triggering hover-open effects; if suppression is active,
exit without opening. Preserve the existing timer behavior when suppression is
inactive.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: d899bead-030a-4f1a-9560-35828e7e238e

📥 Commits

Reviewing files that changed from the base of the PR and between 1c95bf7 and 3e835c4.

📒 Files selected for processing (18)
  • AGENTS.md
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/DashboardSidebar.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/DashboardSidebarPinnedSection/DashboardSidebarPinnedSection.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/DashboardSidebarProjectSection/DashboardSidebarProjectSection.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/DashboardSidebarProjectSection/components/DashboardSidebarCollapsedProjectContent/DashboardSidebarCollapsedProjectContent.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/DashboardSidebarProjectSection/components/DashboardSidebarCollapsedProjectContent/components/SortableCollapsedWorkspaceItem/SortableCollapsedWorkspaceItem.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/DashboardSidebarProjectSection/components/DashboardSidebarExpandedProjectContent/DashboardSidebarExpandedProjectContent.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/DashboardSidebarSessionsSection/DashboardSidebarSessionsSection.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/SidebarDragOverlay/SidebarDragOverlay.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/SidebarDropZone/SidebarDropZone.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/SidebarDropZone/index.ts
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/SortableWorkspaceItem/SortableWorkspaceItem.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/hooks/useSidebarDnd/index.ts
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/hooks/useSidebarDnd/useSidebarDnd.ts
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/providers/DashboardSidebarDndProvider/DashboardSidebarDndProvider.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/providers/DashboardSidebarDndProvider/index.ts
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/providers/DashboardSidebarHoverProvider/DashboardSidebarHoverProvider.tsx
  • apps/desktop/src/renderer/routes/_authenticated/hooks/useDashboardSidebarState/useDashboardSidebarState.ts
💤 Files with no reviewable changes (1)
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/components/DashboardSidebar/components/DashboardSidebarProjectSection/DashboardSidebarProjectSection.tsx

@github-actions

github-actions Bot commented Aug 11, 2026 •

Copy link
Copy Markdown
Contributor

🚀 Preview Deployment

🔗 Preview Links

Service Status Link
Neon Database (Neon) ✅ View Branch
Vercel API (Vercel) ✅ Open Preview
Vercel Web (Vercel) ✅ Open Preview
Vercel Marketing (Vercel) ✅ Open Preview
Vercel Admin (Vercel) ✅ Open Preview
Vercel Docs (Vercel) ✅ Open Preview

Preview updates automatically with new commits

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed across 18 files

You’re at about 91% of the monthly reviewed-line limit. You may want to disable incremental reviews to conserve quota. Reviews will continue until that limit is exceeded. If you need help avoiding interruptions, please contact [email protected].

Architecture diagram
sequenceDiagram
    participant UI as Sidebar UI Components
    participant DND as DashboardSidebarDndProvider
    participant SORT as Sortable Components
    participant HOOK as useSidebarDnd Hook
    participant STATE as useDashboardSidebarState
    participant STORE as Local State Store
    
    Note over UI,STORE: Unified Drag-and-Drop Architecture
    
    UI->>DND: Render sidebar sections (Pinned, Sessions, Projects)
    DND->>HOOK: Initialize shared DnD context
    HOOK->>HOOK: Build container maps (pinned/sessions/byProject)
    HOOK->>STATE: Read workspace/pinned data
    
    Note over UI,SORT: Drag Start
    UI->>SORT: Initiate drag on sortable item
    SORT->>DND: onDragStart
    DND->>HOOK: Register active drag
    HOOK->>HOOK: Set activeId, activeType, activeContainer
    
    Note over UI,HOOK: During Drag (Pointer Move)
    UI->>SORT: Pointer movement triggers useSortable updates
    SORT->>DND: onDragOver (collision detection)
    DND->>HOOK: pointerWithin -> rectIntersection -> lastOverId
    HOOK->>SORT: Update active container (if crossing boundary)
    
    alt Drag within same container
        HOOK->>SORT: Reorder items locally
    else Drag to different container (e.g., pin/unpin)
        HOOK->>HOOK: Transfer item between container lists
        SORT->>SORT: One-frame freeze after transfer
    end
    
    Note over UI,SORT: Drop Zone Handling
    UI->>SORT: Empty container shows SidebarDropZone
    SORT->>DND: useDroppable registers drop zone
    
    Note over UI,STORE: Drag End
    UI->>SORT: Drop item
    SORT->>DND: onDragEnd
    DND->>HOOK: Commit drag operation
    
    alt Drop in place (no change)
        HOOK->>HOOK: Compare with drag-start snapshot
        HOOK-->>UI: No-op
    else Pinned reorder
        HOOK->>STATE: reorderPinnedWorkspaces()
        STATE->>STORE: Rewrite pinnedAt sequence (anchored)
        STORE-->>HOOK: Persisted
    else Unpin (drag out of pinned)
        HOOK->>STATE: Commit to project/session order
        STATE->>STORE: Update tabOrder/section membership
        STORE-->>HOOK: Persisted
    else New pin (drag into pinned)
        HOOK->>STATE: Pin dragged workspace only
        STATE->>STORE: Set pinnedAt, clear isHidden
        STORE-->>HOOK: Persisted
    end
    
    DND-->>UI: Update rendered sidebar
    
    Note over UI,SORT: Hover Card Suppression
    DND->>UI: beginHoverCardSuppression (on drag start)
    UI->>UI: Suppress hover-open side effects
    DND->>UI: endHoverCardSuppression (on drag end/cancel)
Loading

Reply with feedback, questions, or to request a fix.

Re-trigger cubic

- Re-arm the post-transfer collision freeze at the transfer site instead of
  a deps-only effect: biome --unsafe had stripped the [items] dependency,
  freezing collisions for the rest of the drag after the first container
  transfer (no drag-out-after-drag-in in one gesture).
- Stop re-assigning the drag refs during render; commitDragItems is the only
  writer, so a discarded concurrent render pass can't roll them back.
- Release the hover-card suppression in try/finally so a throwing persistence
  write can't leave hover cards permanently suppressed.
- Re-check suppression when a pending hover-open timer fires.
@Kitenite
Kitenite merged commit bb3daa4 into main Aug 12, 2026
18 checks passed
ashbrener added a commit to ashbrener/superset that referenced this pull request Aug 12, 2026
Rebuilds folders on top of the sidebar DnD that ParadevAI#6364 landed on main
instead of carrying a second DndContext beside it.

- DashboardSidebar no longer owns a DndContext, sensors, collision
  detection, drag-end or a DragOverlay. All of that is now
  DashboardSidebarDndProvider's, which ParadevAI#6364 introduced for pin drag and
  drop; folders just pass their two extra inputs into it.
- useSidebarDnd learns folders: project drags may additionally target a
  folder header or the root zone, and its project drag-end re-parents on
  those drops or adopts the target project's folder when reordering.
- Collision detection for project drags goes pointer-first. A project
  section is measured tall at drag start, so closestCenter put its centre
  far from the cursor and the thin strips were near-impossible to hit.
  pointerWithin also ranks an ungrouped project row above the root zone
  that contains it, so dropping there still reorders.
- RootDropZone reads the active drag type from the shared context rather
  than taking an isDragging prop, and now ignores workspace and section
  drags, which never re-parent a project.
ashbrener added a commit to ashbrener/superset that referenced this pull request Aug 12, 2026
Rebuilds folders on top of the sidebar DnD that ParadevAI#6364 landed on main
instead of carrying a second DndContext beside it.

- DashboardSidebar no longer owns a DndContext, sensors, collision
  detection, drag-end or a DragOverlay. All of that is now
  DashboardSidebarDndProvider's, which ParadevAI#6364 introduced for pin drag and
  drop; folders just pass their two extra inputs into it.
- useSidebarDnd learns folders: project drags may additionally target a
  folder header or the root zone, and its project drag-end re-parents on
  those drops or adopts the target project's folder when reordering.
- Collision detection for project drags goes pointer-first. A project
  section is measured tall at drag start, so closestCenter put its centre
  far from the cursor and the thin strips were near-impossible to hit.
  pointerWithin also ranks an ungrouped project row above the root zone
  that contains it, so dropping there still reorders.
- RootDropZone reads the active drag type from the shared context rather
  than taking an isDragging prop, and now ignores workspace and section
  drags, which never re-parent a project.
Kitenite added a commit that referenced this pull request Aug 12, 2026
* docs: weekly update for PRs merged 2026-08-05 to 2026-08-12

- workspaces: sessions (project-less workspaces, #6274), pin + drag-and-drop
  pinning (#6364), list/board views with Merged & Deleted history columns
  (#6296), per-project naming instructions (#6250), multi-PR links per
  branch with remove/restore (#5924)
- automations: session automations (#6280), list health stats + Up next
  grouping + read-only team automations (#6291, #6276), detail page
  Settings/Run History tabs, inline run errors, would-run preview, RRule
  validation (#6305)
- editor: image pane pan/pinch/zoom (#6285)
- tasks: multi-repo filters, expanded task states, PR author/review
  filters, PR checks (#6201)
- monorepos: per-project sparse checkout (#6034)
- customization: project icon + color picker, v1 color carry-over (#6249)
- terminal presets: built-in Superset CLI preset (#6270)
- agents: resume interrupted sessions + Resume Args setting (#6253, #6265),
  Superset hooks toggle + scoping (#6072)
- cli: interactive command browser + branded help (#6273); reference
  updated for session mode, --task, --skip-branch-prefix, --session
  (verified against packages/cli/src/commands)

* docs: tighten wording and drop em dashes

Shorten this week's additions per the writing guide: one thought per
sentence, plainest word, no em dashes as prose punctuation. Also sweeps
the three pre-existing em dashes in recipes.

* docs: add screenshots from the 08-09 changelog batch

cli command browser, agent resume banner, PR view with checks, and the
project icon/color picker. Copied into apps/docs/public/images per the
SOP rather than referenced across apps.

This branch was previously deployed

1 inactive deployment
preview — 1aab78f3 Deployed Aug 12, 2026 by Kitenite via Deploy Admin #7506
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.

1 participant