@cerbur/clutch-dsh-worktree 0.1.16 → 0.1.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +314 -43
- package/README.zh.md +263 -37
- package/assets/screenshots/screenshots-dashboard.png +0 -0
- package/assets/screenshots/screenshots-en.png +0 -0
- package/assets/screenshots/screenshots-git-reviewer.png +0 -0
- package/assets/screenshots/screenshots-import.png +0 -0
- package/assets/screenshots/screenshots-worktree-tool.png +0 -0
- package/assets/screenshots/screenshots-zh.png +0 -0
- package/cordis.patch.yml +6 -19
- package/lib/client/WorktreeSurface.d.ts.map +1 -1
- package/lib/client/WorktreeSurface.js +41 -13
- package/lib/client/WorktreeSurface.js.map +1 -1
- package/lib/client/branch/GitBranchSelector.d.ts +23 -0
- package/lib/client/branch/GitBranchSelector.d.ts.map +1 -0
- package/lib/client/branch/GitBranchSelector.js +142 -0
- package/lib/client/branch/GitBranchSelector.js.map +1 -0
- package/lib/client/command-activity.d.ts +11 -0
- package/lib/client/command-activity.d.ts.map +1 -0
- package/lib/client/command-activity.js +71 -0
- package/lib/client/command-activity.js.map +1 -0
- package/lib/client/context/worktree-context-store.d.ts.map +1 -1
- package/lib/client/context/worktree-context-store.js +1 -0
- package/lib/client/context/worktree-context-store.js.map +1 -1
- package/lib/client/context/worktree-context.d.ts +3 -2
- package/lib/client/context/worktree-context.d.ts.map +1 -1
- package/lib/client/context/worktree-context.js +5 -3
- package/lib/client/context/worktree-context.js.map +1 -1
- package/lib/client/dashboard/DashboardRequest.d.ts +2 -1
- package/lib/client/dashboard/DashboardRequest.d.ts.map +1 -1
- package/lib/client/dashboard/DashboardRequest.js +3 -3
- package/lib/client/dashboard/DashboardRequest.js.map +1 -1
- package/lib/client/dashboard/WorktreeDashboard.d.ts +6 -2
- package/lib/client/dashboard/WorktreeDashboard.d.ts.map +1 -1
- package/lib/client/dashboard/WorktreeDashboard.js +111 -89
- package/lib/client/dashboard/WorktreeDashboard.js.map +1 -1
- package/lib/client/dashboard/WorktreeInstructions.d.ts +2 -1
- package/lib/client/dashboard/WorktreeInstructions.d.ts.map +1 -1
- package/lib/client/dashboard/WorktreeInstructions.js +27 -8
- package/lib/client/dashboard/WorktreeInstructions.js.map +1 -1
- package/lib/client/dashboard/dashboard-overlay.d.ts.map +1 -1
- package/lib/client/dashboard/dashboard-overlay.js +38 -52
- package/lib/client/dashboard/dashboard-overlay.js.map +1 -1
- package/lib/client/dashboard/dashboard-selection.d.ts +4 -2
- package/lib/client/dashboard/dashboard-selection.d.ts.map +1 -1
- package/lib/client/dashboard/dashboard-selection.js +6 -4
- package/lib/client/dashboard/dashboard-selection.js.map +1 -1
- package/lib/client/dashboard/git/GitChangedFiles.d.ts +2 -1
- package/lib/client/dashboard/git/GitChangedFiles.d.ts.map +1 -1
- package/lib/client/dashboard/git/GitChangedFiles.js +8 -6
- package/lib/client/dashboard/git/GitChangedFiles.js.map +1 -1
- package/lib/client/dashboard/git/GitCommitList.d.ts +6 -1
- package/lib/client/dashboard/git/GitCommitList.d.ts.map +1 -1
- package/lib/client/dashboard/git/GitCommitList.js +34 -29
- package/lib/client/dashboard/git/GitCommitList.js.map +1 -1
- package/lib/client/dashboard/git/GitCommitStats.d.ts +8 -0
- package/lib/client/dashboard/git/GitCommitStats.d.ts.map +1 -0
- package/lib/client/dashboard/git/GitCommitStats.js +7 -0
- package/lib/client/dashboard/git/GitCommitStats.js.map +1 -0
- package/lib/client/dashboard/git/WorktreeGitOverview.d.ts.map +1 -1
- package/lib/client/dashboard/git/WorktreeGitOverview.js +2 -1
- package/lib/client/dashboard/git/WorktreeGitOverview.js.map +1 -1
- package/lib/client/dashboard/git/WorktreeGitPanel.d.ts +3 -2
- package/lib/client/dashboard/git/WorktreeGitPanel.d.ts.map +1 -1
- package/lib/client/dashboard/git/WorktreeGitPanel.js +79 -14
- package/lib/client/dashboard/git/WorktreeGitPanel.js.map +1 -1
- package/lib/client/dashboard/git/file-address.d.ts +5 -1
- package/lib/client/dashboard/git/file-address.d.ts.map +1 -1
- package/lib/client/dashboard/git/file-address.js +49 -11
- package/lib/client/dashboard/git/file-address.js.map +1 -1
- package/lib/client/dashboard/git/git-facts.js +1 -1
- package/lib/client/dashboard/git/git-facts.js.map +1 -1
- package/lib/client/dashboard/git/useWorktreeGitState.d.ts +7 -2
- package/lib/client/dashboard/git/useWorktreeGitState.d.ts.map +1 -1
- package/lib/client/dashboard/git/useWorktreeGitState.js +88 -22
- package/lib/client/dashboard/git/useWorktreeGitState.js.map +1 -1
- package/lib/client/dsh-icons.d.ts +4 -0
- package/lib/client/dsh-icons.d.ts.map +1 -1
- package/lib/client/dsh-icons.js +5 -1
- package/lib/client/dsh-icons.js.map +1 -1
- package/lib/client/dsh-slot-contract.d.ts +9 -1
- package/lib/client/dsh-slot-contract.d.ts.map +1 -1
- package/lib/client/entry.d.ts.map +1 -1
- package/lib/client/entry.js +39 -2
- package/lib/client/entry.js.map +1 -1
- package/lib/client/layout/app-frame.d.ts +12 -0
- package/lib/client/layout/app-frame.d.ts.map +1 -0
- package/lib/client/layout/app-frame.js +82 -0
- package/lib/client/layout/app-frame.js.map +1 -0
- package/lib/client/locales.d.ts +184 -2
- package/lib/client/locales.d.ts.map +1 -1
- package/lib/client/locales.js +250 -68
- package/lib/client/locales.js.map +1 -1
- package/lib/client/overlay/overlay-bounds.d.ts.map +1 -1
- package/lib/client/overlay/overlay-bounds.js +8 -3
- package/lib/client/overlay/overlay-bounds.js.map +1 -1
- package/lib/client/overlay/sidebar-overlay-geometry.d.ts +3 -1
- package/lib/client/overlay/sidebar-overlay-geometry.d.ts.map +1 -1
- package/lib/client/overlay/sidebar-overlay-geometry.js +94 -34
- package/lib/client/overlay/sidebar-overlay-geometry.js.map +1 -1
- package/lib/client/restart-notice.d.ts +10 -3
- package/lib/client/restart-notice.d.ts.map +1 -1
- package/lib/client/restart-notice.js +44 -11
- package/lib/client/restart-notice.js.map +1 -1
- package/lib/client/select/SearchableSingleSelect.d.ts +44 -0
- package/lib/client/select/SearchableSingleSelect.d.ts.map +1 -0
- package/lib/client/select/SearchableSingleSelect.js +180 -0
- package/lib/client/select/SearchableSingleSelect.js.map +1 -0
- package/lib/client/select/WorktreeSelector.d.ts +14 -0
- package/lib/client/select/WorktreeSelector.d.ts.map +1 -0
- package/lib/client/select/WorktreeSelector.js +11 -0
- package/lib/client/select/WorktreeSelector.js.map +1 -0
- package/lib/client/session/session-view.d.ts +16 -2
- package/lib/client/session/session-view.d.ts.map +1 -1
- package/lib/client/session/session-view.js +24 -10
- package/lib/client/session/session-view.js.map +1 -1
- package/lib/client/session/worktree-session.d.ts +1 -0
- package/lib/client/session/worktree-session.d.ts.map +1 -1
- package/lib/client/session/worktree-session.js +3 -1
- package/lib/client/session/worktree-session.js.map +1 -1
- package/lib/client/settings/ToolSettings.d.ts +9 -0
- package/lib/client/settings/ToolSettings.d.ts.map +1 -0
- package/lib/client/settings/ToolSettings.js +77 -0
- package/lib/client/settings/ToolSettings.js.map +1 -0
- package/lib/client/settings/WorktreeSettings.d.ts +8 -0
- package/lib/client/settings/WorktreeSettings.d.ts.map +1 -0
- package/lib/client/settings/WorktreeSettings.js +46 -0
- package/lib/client/settings/WorktreeSettings.js.map +1 -0
- package/lib/client/settings/WorktreeSettingsNavIcon.d.ts +6 -0
- package/lib/client/settings/WorktreeSettingsNavIcon.d.ts.map +1 -0
- package/lib/client/settings/WorktreeSettingsNavIcon.js +51 -0
- package/lib/client/settings/WorktreeSettingsNavIcon.js.map +1 -0
- package/lib/client/settings/diagnostics.d.ts +24 -0
- package/lib/client/settings/diagnostics.d.ts.map +1 -0
- package/lib/client/settings/diagnostics.js +63 -0
- package/lib/client/settings/diagnostics.js.map +1 -0
- package/lib/client/settings/settings-navigation.d.ts +7 -0
- package/lib/client/settings/settings-navigation.d.ts.map +1 -0
- package/lib/client/settings/settings-navigation.js +12 -0
- package/lib/client/settings/settings-navigation.js.map +1 -0
- package/lib/client/surface/actions/useLifecycleActions.d.ts +2 -1
- package/lib/client/surface/actions/useLifecycleActions.d.ts.map +1 -1
- package/lib/client/surface/actions/useLifecycleActions.js +15 -6
- package/lib/client/surface/actions/useLifecycleActions.js.map +1 -1
- package/lib/client/surface/actions/useSessionActions.d.ts.map +1 -1
- package/lib/client/surface/actions/useSessionActions.js +6 -6
- package/lib/client/surface/actions/useSessionActions.js.map +1 -1
- package/lib/client/surface/actions/useWorktreeRegistration.d.ts +1 -1
- package/lib/client/surface/actions/useWorktreeRegistration.d.ts.map +1 -1
- package/lib/client/surface/actions/useWorktreeRegistration.js +36 -13
- package/lib/client/surface/actions/useWorktreeRegistration.js.map +1 -1
- package/lib/client/surface/components/NotificationToasts.d.ts +19 -3
- package/lib/client/surface/components/NotificationToasts.d.ts.map +1 -1
- package/lib/client/surface/components/NotificationToasts.js +73 -7
- package/lib/client/surface/components/NotificationToasts.js.map +1 -1
- package/lib/client/surface/components/OverlayScrollbar.d.ts +6 -0
- package/lib/client/surface/components/OverlayScrollbar.d.ts.map +1 -0
- package/lib/client/surface/components/OverlayScrollbar.js +84 -0
- package/lib/client/surface/components/OverlayScrollbar.js.map +1 -0
- package/lib/client/surface/components/RegistrationDialog.d.ts +3 -3
- package/lib/client/surface/components/RegistrationDialog.d.ts.map +1 -1
- package/lib/client/surface/components/RegistrationDialog.js +70 -5
- package/lib/client/surface/components/RegistrationDialog.js.map +1 -1
- package/lib/client/surface/components/RestartToast.d.ts.map +1 -1
- package/lib/client/surface/components/RestartToast.js +4 -3
- package/lib/client/surface/components/RestartToast.js.map +1 -1
- package/lib/client/surface/components/SurfaceContent.d.ts.map +1 -1
- package/lib/client/surface/components/SurfaceContent.js +110 -39
- package/lib/client/surface/components/SurfaceContent.js.map +1 -1
- package/lib/client/surface/components/WorkspaceTree.d.ts.map +1 -1
- package/lib/client/surface/components/WorkspaceTree.js +13 -9
- package/lib/client/surface/components/WorkspaceTree.js.map +1 -1
- package/lib/client/surface/components/dialogs.d.ts +1 -1
- package/lib/client/surface/components/dialogs.d.ts.map +1 -1
- package/lib/client/surface/components/dialogs.js +34 -21
- package/lib/client/surface/components/dialogs.js.map +1 -1
- package/lib/client/surface/components/rows.d.ts +1 -1
- package/lib/client/surface/components/rows.d.ts.map +1 -1
- package/lib/client/surface/components/rows.js +15 -97
- package/lib/client/surface/components/rows.js.map +1 -1
- package/lib/client/surface/notification-queue.d.ts +15 -0
- package/lib/client/surface/notification-queue.d.ts.map +1 -1
- package/lib/client/surface/notification-queue.js +13 -2
- package/lib/client/surface/notification-queue.js.map +1 -1
- package/lib/client/surface/state/useRegistrationState.d.ts +6 -1
- package/lib/client/surface/state/useRegistrationState.d.ts.map +1 -1
- package/lib/client/surface/state/useRegistrationState.js +7 -0
- package/lib/client/surface/state/useRegistrationState.js.map +1 -1
- package/lib/client/surface/state/useSurfaceRefresh.d.ts +1 -1
- package/lib/client/surface/state/useSurfaceRefresh.d.ts.map +1 -1
- package/lib/client/surface/state/useSurfaceRefresh.js +13 -1
- package/lib/client/surface/state/useSurfaceRefresh.js.map +1 -1
- package/lib/client/surface/state/useSurfaceSources.d.ts +1 -1
- package/lib/client/surface/state/useSurfaceSources.d.ts.map +1 -1
- package/lib/client/surface/state/useSurfaceSources.js +4 -2
- package/lib/client/surface/state/useSurfaceSources.js.map +1 -1
- package/lib/client/surface/state/useTitleMarquee.d.ts +7 -0
- package/lib/client/surface/state/useTitleMarquee.d.ts.map +1 -0
- package/lib/client/surface/state/useTitleMarquee.js +60 -0
- package/lib/client/surface/state/useTitleMarquee.js.map +1 -0
- package/lib/client/surface/types.d.ts +12 -1
- package/lib/client/surface/types.d.ts.map +1 -1
- package/lib/client/view/worktree-error-copy.d.ts.map +1 -1
- package/lib/client/view/worktree-error-copy.js +73 -14
- package/lib/client/view/worktree-error-copy.js.map +1 -1
- package/lib/client/view/worktree-view-errors.d.ts.map +1 -1
- package/lib/client/view/worktree-view-errors.js +13 -5
- package/lib/client/view/worktree-view-errors.js.map +1 -1
- package/lib/client/view/worktree-view-read.d.ts +4 -2
- package/lib/client/view/worktree-view-read.d.ts.map +1 -1
- package/lib/client/view/worktree-view-read.js +34 -17
- package/lib/client/view/worktree-view-read.js.map +1 -1
- package/lib/client/worktree-connection.d.ts +9 -2
- package/lib/client/worktree-connection.d.ts.map +1 -1
- package/lib/client/worktree-connection.js +24 -1
- package/lib/client/worktree-connection.js.map +1 -1
- package/lib/client/worktree-tool-changes.d.ts +13 -0
- package/lib/client/worktree-tool-changes.d.ts.map +1 -0
- package/lib/client/worktree-tool-changes.js +64 -0
- package/lib/client/worktree-tool-changes.js.map +1 -0
- package/lib/client.js +3503 -1310
- package/lib/client.js.map +1 -1
- package/lib/contract/index.contract.js +15 -0
- package/lib/contract/index.contract.js.map +1 -1
- package/lib/contract/index.d.ts +79 -12
- package/lib/contract/index.d.ts.map +1 -1
- package/lib/contract/index.js +12 -0
- package/lib/contract/index.js.map +1 -1
- package/lib/contract/tool-settings.d.ts +28 -0
- package/lib/contract/tool-settings.d.ts.map +1 -0
- package/lib/contract/tool-settings.js +10 -0
- package/lib/contract/tool-settings.js.map +1 -0
- package/lib/contract/worktree-tool-changes.d.ts +10 -0
- package/lib/contract/worktree-tool-changes.d.ts.map +1 -0
- package/lib/contract/worktree-tool-changes.js +2 -0
- package/lib/contract/worktree-tool-changes.js.map +1 -0
- package/lib/host/permission-preset-append.d.ts +15 -0
- package/lib/host/permission-preset-append.d.ts.map +1 -0
- package/lib/host/permission-preset-append.js +63 -0
- package/lib/host/permission-preset-append.js.map +1 -0
- package/lib/host/remote.d.ts.map +1 -1
- package/lib/host/remote.js +7 -0
- package/lib/host/remote.js.map +1 -1
- package/lib/host/service.d.ts +30 -6
- package/lib/host/service.d.ts.map +1 -1
- package/lib/host/service.js +85 -11
- package/lib/host/service.js.map +1 -1
- package/lib/host/tool-settings.d.ts +14 -0
- package/lib/host/tool-settings.d.ts.map +1 -0
- package/lib/host/tool-settings.js +98 -0
- package/lib/host/tool-settings.js.map +1 -0
- package/lib/host/worktree-permission-manager.d.ts.map +1 -1
- package/lib/host/worktree-permission-manager.js +2 -4
- package/lib/host/worktree-permission-manager.js.map +1 -1
- package/lib/host/worktree-tool-changes.d.ts +12 -0
- package/lib/host/worktree-tool-changes.d.ts.map +1 -0
- package/lib/host/worktree-tool-changes.js +60 -0
- package/lib/host/worktree-tool-changes.js.map +1 -0
- package/lib/manage/manager-git-history.d.ts +5 -7
- package/lib/manage/manager-git-history.d.ts.map +1 -1
- package/lib/manage/manager-git-history.js +185 -91
- package/lib/manage/manager-git-history.js.map +1 -1
- package/lib/manage/manager-git-paths.d.ts +7 -0
- package/lib/manage/manager-git-paths.d.ts.map +1 -0
- package/lib/manage/manager-git-paths.js +62 -0
- package/lib/manage/manager-git-paths.js.map +1 -0
- package/lib/manage/manager-sessions.d.ts +5 -0
- package/lib/manage/manager-sessions.d.ts.map +1 -1
- package/lib/manage/manager-sessions.js +34 -11
- package/lib/manage/manager-sessions.js.map +1 -1
- package/lib/manage/manager-support.d.ts +3 -1
- package/lib/manage/manager-support.d.ts.map +1 -1
- package/lib/manage/manager-support.js +17 -0
- package/lib/manage/manager-support.js.map +1 -1
- package/lib/manage/manager-worktree-lifecycle.d.ts.map +1 -1
- package/lib/manage/manager-worktree-lifecycle.js +5 -4
- package/lib/manage/manager-worktree-lifecycle.js.map +1 -1
- package/lib/manage/manager-worktrees.d.ts +10 -1
- package/lib/manage/manager-worktrees.d.ts.map +1 -1
- package/lib/manage/manager-worktrees.js +141 -34
- package/lib/manage/manager-worktrees.js.map +1 -1
- package/lib/manage/manager.d.ts +22 -5
- package/lib/manage/manager.d.ts.map +1 -1
- package/lib/manage/manager.js +76 -4
- package/lib/manage/manager.js.map +1 -1
- package/lib/manage/types.d.ts +10 -1
- package/lib/manage/types.d.ts.map +1 -1
- package/lib/provider/generated-name.d.ts.map +1 -1
- package/lib/provider/generated-name.js +5 -4
- package/lib/provider/generated-name.js.map +1 -1
- package/lib/provider/git/adapter.d.ts +13 -12
- package/lib/provider/git/adapter.d.ts.map +1 -1
- package/lib/provider/git/adapter.js +157 -31
- package/lib/provider/git/adapter.js.map +1 -1
- package/lib/provider/git/branch-name.d.ts +5 -0
- package/lib/provider/git/branch-name.d.ts.map +1 -0
- package/lib/provider/git/branch-name.js +16 -0
- package/lib/provider/git/branch-name.js.map +1 -0
- package/lib/provider/git/branches.d.ts +11 -0
- package/lib/provider/git/branches.d.ts.map +1 -0
- package/lib/provider/git/branches.js +37 -0
- package/lib/provider/git/branches.js.map +1 -0
- package/lib/provider/mutation-token.d.ts +1 -1
- package/lib/provider/mutation-token.d.ts.map +1 -1
- package/lib/provider/mutation-token.js +1 -0
- package/lib/provider/mutation-token.js.map +1 -1
- package/lib/provider/sidecar/repository.d.ts.map +1 -1
- package/lib/provider/sidecar/repository.js +3 -1
- package/lib/provider/sidecar/repository.js.map +1 -1
- package/lib/provider/sidecar/sidecar-schema.d.ts.map +1 -1
- package/lib/provider/sidecar/sidecar-schema.js +26 -4
- package/lib/provider/sidecar/sidecar-schema.js.map +1 -1
- package/lib/provider/transaction/operations/adopt-branch.d.ts.map +1 -1
- package/lib/provider/transaction/operations/adopt-branch.js +6 -5
- package/lib/provider/transaction/operations/adopt-branch.js.map +1 -1
- package/lib/provider/transaction/operations/clean.d.ts.map +1 -1
- package/lib/provider/transaction/operations/clean.js +20 -19
- package/lib/provider/transaction/operations/clean.js.map +1 -1
- package/lib/provider/transaction/operations/create.d.ts +1 -1
- package/lib/provider/transaction/operations/create.d.ts.map +1 -1
- package/lib/provider/transaction/operations/create.js +39 -17
- package/lib/provider/transaction/operations/create.js.map +1 -1
- package/lib/provider/transaction/operations/import.d.ts.map +1 -1
- package/lib/provider/transaction/operations/import.js +7 -1
- package/lib/provider/transaction/operations/import.js.map +1 -1
- package/lib/provider/transaction/operations/remove.d.ts.map +1 -1
- package/lib/provider/transaction/operations/remove.js +20 -19
- package/lib/provider/transaction/operations/remove.js.map +1 -1
- package/lib/provider/transaction/recovery/failure-recovery.d.ts.map +1 -1
- package/lib/provider/transaction/recovery/failure-recovery.js +22 -20
- package/lib/provider/transaction/recovery/failure-recovery.js.map +1 -1
- package/lib/provider/transaction/recovery/recover.d.ts.map +1 -1
- package/lib/provider/transaction/recovery/recover.js +11 -4
- package/lib/provider/transaction/recovery/recover.js.map +1 -1
- package/lib/provider/transaction/support/inspection.d.ts.map +1 -1
- package/lib/provider/transaction/support/inspection.js +3 -2
- package/lib/provider/transaction/support/inspection.js.map +1 -1
- package/lib/provider/transaction/support/journal.d.ts.map +1 -1
- package/lib/provider/transaction/support/journal.js +9 -5
- package/lib/provider/transaction/support/journal.js.map +1 -1
- package/lib/provider/transaction/support/path-safety.d.ts.map +1 -1
- package/lib/provider/transaction/support/path-safety.js +4 -3
- package/lib/provider/transaction/support/path-safety.js.map +1 -1
- package/lib/provider/transaction/types.d.ts +2 -1
- package/lib/provider/transaction/types.d.ts.map +1 -1
- package/lib/provider/types.d.ts +27 -5
- package/lib/provider/types.d.ts.map +1 -1
- package/lib/provider/types.js +1 -1
- package/lib/provider/types.js.map +1 -1
- package/lib/provider/worktree-path.d.ts +10 -0
- package/lib/provider/worktree-path.d.ts.map +1 -0
- package/lib/provider/worktree-path.js +47 -0
- package/lib/provider/worktree-path.js.map +1 -0
- package/lib/tool/context.d.ts +14 -0
- package/lib/tool/context.d.ts.map +1 -0
- package/lib/tool/context.js +95 -0
- package/lib/tool/context.js.map +1 -0
- package/lib/tool/delegation.d.ts +41 -0
- package/lib/tool/delegation.d.ts.map +1 -0
- package/lib/tool/delegation.js +196 -0
- package/lib/tool/delegation.js.map +1 -0
- package/lib/tool/errors.d.ts +3 -0
- package/lib/tool/errors.d.ts.map +1 -0
- package/lib/tool/errors.js +63 -0
- package/lib/tool/errors.js.map +1 -0
- package/lib/tool/guidance.d.ts +5 -0
- package/lib/tool/guidance.d.ts.map +1 -0
- package/lib/tool/guidance.js +48 -0
- package/lib/tool/guidance.js.map +1 -0
- package/lib/tool/history.d.ts +27 -0
- package/lib/tool/history.d.ts.map +1 -0
- package/lib/tool/history.js +157 -0
- package/lib/tool/history.js.map +1 -0
- package/lib/tool/index.d.ts +8 -0
- package/lib/tool/index.d.ts.map +1 -0
- package/lib/tool/index.js +296 -0
- package/lib/tool/index.js.map +1 -0
- package/lib/tool/inputs.d.ts +12 -0
- package/lib/tool/inputs.d.ts.map +1 -0
- package/lib/tool/inputs.js +24 -0
- package/lib/tool/inputs.js.map +1 -0
- package/lib/tool/list-models.d.ts +3 -0
- package/lib/tool/list-models.d.ts.map +1 -0
- package/lib/tool/list-models.js +38 -0
- package/lib/tool/list-models.js.map +1 -0
- package/lib/tool/list-sessions.d.ts +3 -0
- package/lib/tool/list-sessions.d.ts.map +1 -0
- package/lib/tool/list-sessions.js +70 -0
- package/lib/tool/list-sessions.js.map +1 -0
- package/lib/tool/list-worktrees.d.ts +3 -0
- package/lib/tool/list-worktrees.d.ts.map +1 -0
- package/lib/tool/list-worktrees.js +46 -0
- package/lib/tool/list-worktrees.js.map +1 -0
- package/lib/tool/native-session.d.ts +74 -0
- package/lib/tool/native-session.d.ts.map +1 -0
- package/lib/tool/native-session.js +248 -0
- package/lib/tool/native-session.js.map +1 -0
- package/lib/tool/new-worktree.d.ts +3 -0
- package/lib/tool/new-worktree.d.ts.map +1 -0
- package/lib/tool/new-worktree.js +81 -0
- package/lib/tool/new-worktree.js.map +1 -0
- package/lib/tool/outputs.d.ts +50 -0
- package/lib/tool/outputs.d.ts.map +1 -0
- package/lib/tool/outputs.js +65 -0
- package/lib/tool/outputs.js.map +1 -0
- package/lib/tool/report-result.d.ts +3 -0
- package/lib/tool/report-result.d.ts.map +1 -0
- package/lib/tool/report-result.js +83 -0
- package/lib/tool/report-result.js.map +1 -0
- package/lib/tool/schema.d.ts +7 -0
- package/lib/tool/schema.d.ts.map +1 -0
- package/lib/tool/schema.js +92 -0
- package/lib/tool/schema.js.map +1 -0
- package/lib/tool/send-message.d.ts +3 -0
- package/lib/tool/send-message.d.ts.map +1 -0
- package/lib/tool/send-message.js +64 -0
- package/lib/tool/send-message.js.map +1 -0
- package/lib/tool/span-worktree.d.ts +3 -0
- package/lib/tool/span-worktree.d.ts.map +1 -0
- package/lib/tool/span-worktree.js +114 -0
- package/lib/tool/span-worktree.js.map +1 -0
- package/lib/tool/types.d.ts +54 -0
- package/lib/tool/types.d.ts.map +1 -0
- package/lib/tool/types.js +2 -0
- package/lib/tool/types.js.map +1 -0
- package/lib/typert.host.js +387 -46
- package/lib/typert.remote-client.d.ts +17 -5
- package/lib/typert.remote-client.d.ts.map +1 -1
- package/lib/typert.remote-client.js +387 -46
- package/package.json +17 -3
|
@@ -1,34 +1,41 @@
|
|
|
1
|
-
import { useCallback, useEffect } from 'react';
|
|
1
|
+
import { useCallback, useEffect, useMemo } from 'react';
|
|
2
2
|
import { createDefaultWorktreeName, executeWorktreeAction, reconcileBaseBranchSelection, selectDefaultBaseBranch, toWorktreeViewError, WorktreeSessionBindingError, WorktreeSessionPermissionError, } from '../../view/worktree-view.js';
|
|
3
3
|
export function useWorktreeRegistration({ source, registrationState, read, props, mutation, session, }) {
|
|
4
4
|
const { workspaces } = source;
|
|
5
|
-
const { worktreeModalWorkspaceId, modalReadLoading, setSelectedBranch, setNewBranch, setImportCandidates, importCandidatesGuard, modalWorkspaceIdRef, modalReadLoader, modalReadViewRef, setWorktreeModalWorkspaceId, setModalReadError, setModalReadLoading, setWorktreeModalMode, setSelectedImportPath, importCandidates, newBranch, selectedImportPath, worktreeModalMode, selectedBranch, } = registrationState;
|
|
5
|
+
const { worktreeModalWorkspaceId, modalReadLoading, modalBranches, setModalBranches, setSelectedBranch, setNewBranch, setImportCandidates, importCandidatesGuard, modalWorkspaceIdRef, modalGenerationRef, modalLifetimeRef, modalReadLoader, modalReadViewRef, setWorktreeModalWorkspaceId, setModalReadError, setModalReadLoading, setWorktreeModalMode, setSelectedImportPath, importCandidates, newBranch, selectedImportPath, worktreeModalMode, selectedBranch, } = registrationState;
|
|
6
6
|
const { viewByWorkspace, loadModalWorktreeView, refresh } = read;
|
|
7
7
|
const { manager, createSessionForWorktree: createSessionCallback } = props;
|
|
8
8
|
const { actionPending, setActionError, setActionPending } = mutation;
|
|
9
9
|
const { setPendingSessionBinding } = session;
|
|
10
10
|
const modalWorkspace = workspaces.items.find((workspace) => workspace.workspaceId === worktreeModalWorkspaceId);
|
|
11
|
-
const
|
|
11
|
+
const modalProjection = worktreeModalWorkspaceId === undefined
|
|
12
12
|
? undefined
|
|
13
|
-
:
|
|
13
|
+
: modalReadViewRef.current?.workspaceId === worktreeModalWorkspaceId
|
|
14
|
+
? modalReadViewRef.current : viewByWorkspace.get(worktreeModalWorkspaceId);
|
|
15
|
+
const modalView = useMemo(() => modalProjection === undefined || modalBranches === undefined
|
|
16
|
+
? modalProjection : { ...modalProjection, branches: modalBranches }, [modalProjection, modalBranches]);
|
|
14
17
|
const modalReadiness = modalView?.readiness;
|
|
15
18
|
const modalSetupStatus = modalView === undefined
|
|
16
19
|
? undefined
|
|
17
20
|
: modalReadiness?.status === 'ready'
|
|
18
|
-
?
|
|
19
|
-
? 'noLocalBranch'
|
|
20
|
-
: undefined
|
|
21
|
+
? undefined
|
|
21
22
|
: modalReadiness?.status;
|
|
22
23
|
const modalCanCreate = !modalReadLoading && modalSetupStatus === undefined && modalReadiness?.status === 'ready';
|
|
23
24
|
useEffect(() => {
|
|
24
25
|
if (worktreeModalWorkspaceId === undefined || modalView === undefined)
|
|
25
26
|
return;
|
|
27
|
+
if (modalReadLoading)
|
|
28
|
+
return;
|
|
26
29
|
if (modalView.readiness.status !== 'ready') {
|
|
27
30
|
setSelectedBranch('');
|
|
28
31
|
setNewBranch('');
|
|
29
32
|
return;
|
|
30
33
|
}
|
|
31
|
-
setSelectedBranch((current) =>
|
|
34
|
+
setSelectedBranch((current) => current === 'HEAD' && modalView.checkout?.currentHead !== undefined
|
|
35
|
+
? current : modalView.checkout?.currentHead?.kind !== 'branch' && modalView.checkout?.currentHead !== undefined && current === ''
|
|
36
|
+
? 'HEAD' : modalView.branches.length > 0
|
|
37
|
+
? reconcileBaseBranchSelection(current, modalView.branches)
|
|
38
|
+
: current || modalView.currentBranch || 'HEAD');
|
|
32
39
|
setNewBranch((current) => {
|
|
33
40
|
if (current.length > 0)
|
|
34
41
|
return current;
|
|
@@ -38,7 +45,7 @@ export function useWorktreeRegistration({ source, registrationState, read, props
|
|
|
38
45
|
];
|
|
39
46
|
return createDefaultWorktreeName(existingNames);
|
|
40
47
|
});
|
|
41
|
-
}, [modalView, worktreeModalWorkspaceId]);
|
|
48
|
+
}, [modalView, worktreeModalWorkspaceId, modalReadLoading]);
|
|
42
49
|
const loadImportCandidates = useCallback(async (workspaceId) => {
|
|
43
50
|
if (manager === undefined)
|
|
44
51
|
return;
|
|
@@ -60,39 +67,49 @@ export function useWorktreeRegistration({ source, registrationState, read, props
|
|
|
60
67
|
const closeWorktreeCreator = (force = false) => {
|
|
61
68
|
if (actionPending && !force)
|
|
62
69
|
return;
|
|
70
|
+
modalGenerationRef.current++;
|
|
71
|
+
modalLifetimeRef.current++;
|
|
63
72
|
modalReadLoader.current.invalidate();
|
|
64
73
|
modalReadViewRef.current = undefined;
|
|
65
74
|
importCandidatesGuard.current.invalidate();
|
|
66
75
|
setWorktreeModalWorkspaceId(undefined);
|
|
67
76
|
setModalReadError(undefined);
|
|
68
77
|
setModalReadLoading(false);
|
|
78
|
+
setModalBranches(undefined);
|
|
69
79
|
};
|
|
70
80
|
const openWorktreeCreator = (workspace, defaults = {}) => {
|
|
71
81
|
const view = viewByWorkspace.get(workspace.workspaceId);
|
|
82
|
+
modalGenerationRef.current++;
|
|
83
|
+
modalLifetimeRef.current++;
|
|
72
84
|
modalReadLoader.current.invalidate();
|
|
73
85
|
modalReadViewRef.current = undefined;
|
|
74
86
|
importCandidatesGuard.current.invalidate();
|
|
75
87
|
setWorktreeModalWorkspaceId(workspace.workspaceId);
|
|
88
|
+
setModalBranches(undefined);
|
|
76
89
|
setWorktreeModalMode('create');
|
|
77
90
|
setImportCandidates({ status: 'idle', candidates: [] });
|
|
78
91
|
setSelectedImportPath(undefined);
|
|
79
92
|
setActionError(undefined);
|
|
80
93
|
setModalReadError(undefined);
|
|
81
94
|
setModalReadLoading(false);
|
|
82
|
-
if (view === undefined) {
|
|
95
|
+
if (view === undefined || view.branches.length === 0) {
|
|
83
96
|
setSelectedBranch(defaults.baseBranch ?? '');
|
|
84
97
|
setNewBranch(defaults.newBranch ?? '');
|
|
85
98
|
loadModalWorktreeView(workspace.workspaceId);
|
|
86
99
|
return;
|
|
87
100
|
}
|
|
88
|
-
setSelectedBranch(defaults.baseBranch ??
|
|
101
|
+
setSelectedBranch(defaults.baseBranch ?? (view.checkout?.currentHead !== undefined && view.checkout.currentHead.kind !== 'branch'
|
|
102
|
+
? 'HEAD' : selectDefaultBaseBranch(view.branches)));
|
|
89
103
|
setNewBranch(defaults.newBranch ??
|
|
90
104
|
createDefaultWorktreeName([
|
|
91
105
|
...view.branches.map((branch) => branch.name),
|
|
92
106
|
...view.worktrees.map((worktree) => worktree.branch),
|
|
93
107
|
]));
|
|
108
|
+
loadModalWorktreeView(workspace.workspaceId);
|
|
94
109
|
};
|
|
95
110
|
const changeWorktreeModalMode = (mode) => {
|
|
111
|
+
if (mode !== worktreeModalMode)
|
|
112
|
+
modalGenerationRef.current++;
|
|
96
113
|
setWorktreeModalMode(mode);
|
|
97
114
|
if (mode === 'import' &&
|
|
98
115
|
worktreeModalWorkspaceId !== undefined &&
|
|
@@ -123,14 +140,16 @@ export function useWorktreeRegistration({ source, registrationState, read, props
|
|
|
123
140
|
await createSessionCallback(sessionInput);
|
|
124
141
|
}
|
|
125
142
|
catch (error) {
|
|
126
|
-
if (error instanceof WorktreeSessionBindingError
|
|
127
|
-
setPendingSessionBinding({ ...sessionInput, sessionId: error.sessionId
|
|
143
|
+
if (error instanceof WorktreeSessionBindingError) {
|
|
144
|
+
setPendingSessionBinding({ ...sessionInput, sessionId: error.sessionId,
|
|
145
|
+
error: toWorktreeViewError(error) });
|
|
128
146
|
}
|
|
129
147
|
if (error instanceof WorktreeSessionPermissionError && error.retryable) {
|
|
130
148
|
setPendingSessionBinding({
|
|
131
149
|
...sessionInput,
|
|
132
150
|
sessionId: error.sessionId,
|
|
133
151
|
permissionRequired: true,
|
|
152
|
+
error: toWorktreeViewError(error),
|
|
134
153
|
});
|
|
135
154
|
}
|
|
136
155
|
throw error;
|
|
@@ -160,6 +179,10 @@ export function useWorktreeRegistration({ source, registrationState, read, props
|
|
|
160
179
|
input: {
|
|
161
180
|
workspaceId: modalWorkspace.workspaceId,
|
|
162
181
|
branch: selectedBranch,
|
|
182
|
+
...(selectedBranch === 'HEAD' ? {
|
|
183
|
+
fromHead: true,
|
|
184
|
+
expectedHeadCommit: modalView?.checkout?.currentHead?.commit,
|
|
185
|
+
} : {}),
|
|
163
186
|
newBranch: worktreeName,
|
|
164
187
|
},
|
|
165
188
|
})
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useWorktreeRegistration.js","sourceRoot":"","sources":["../../../../src/client/surface/actions/useWorktreeRegistration.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"useWorktreeRegistration.js","sourceRoot":"","sources":["../../../../src/client/surface/actions/useWorktreeRegistration.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAExD,OAAO,EACL,yBAAyB,EACzB,qBAAqB,EACrB,4BAA4B,EAC5B,uBAAuB,EACvB,mBAAmB,EACnB,2BAA2B,EAC3B,8BAA8B,GAE/B,MAAM,6BAA6B,CAAC;AAsDrC,MAAM,UAAU,uBAAuB,CAAC,EACtC,MAAM,EACN,iBAAiB,EACjB,IAAI,EACJ,KAAK,EACL,QAAQ,EACR,OAAO,GACD;IACN,MAAM,EAAE,UAAU,EAAE,GAAG,MAAM,CAAC;IAC9B,MAAM,EACJ,wBAAwB,EACxB,gBAAgB,EAChB,aAAa,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AC;wBACP,SAAS,EAAE,YAAY;qBACxB;iBACF,CAAC;gBACJ,CAAC,CAAC,MAAM,qBAAqB,CAAC,OAAO,EAAE;oBACnC,IAAI,EAAE,gBAAgB;oBACtB,KAAK,EAAE;wBACL,WAAW,EAAE,cAAc,CAAC,WAAW;wBACvC,YAAY,EAAE,uBAAwB,CAAC,YAAY;qBACpD;iBACF,CAAC,CAAC;YACT,IAAI,kBAAkB,KAAK,SAAS,EAAE,CAAC;gBACrC,MAAM;oBACJ,IAAI,EAAE,yBAAyB;oBAC/B,OAAO,EAAE,EAAE;oBACX,SAAS,EAAE,IAAI;iBAChB,CAAC;YACJ,CAAC;YACD,MAAM,4BAA4B,CAAC,kBAAkB,CAAC,CAAC;QACzD,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,cAAc,CAAC,mBAAmB,CAAC,KAAK,CAAC,CAAC,CAAC;QAC7C,CAAC;gBAAS,CAAC;YACT,gBAAgB,CAAC,KAAK,CAAC,CAAC;QAC1B,CAAC;IACH,CAAC,CAAC;IACF,OAAO;QACL,cAAc;QACd,SAAS;QACT,cAAc;QACd,gBAAgB;QAChB,cAAc;QACd,oBAAoB;QACpB,oBAAoB;QACpB,mBAAmB;QACnB,uBAAuB;QACvB,4BAA4B;QAC5B,cAAc;KACf,CAAC;AACJ,CAAC"}
|
|
@@ -1,7 +1,23 @@
|
|
|
1
|
+
import { type ReactNode } from 'react';
|
|
1
2
|
import { type WorktreeNotification } from '../notification-queue.js';
|
|
2
|
-
|
|
3
|
-
|
|
3
|
+
import type { WorktreeTranslate } from '../types.js';
|
|
4
|
+
import type { WorktreeViewError } from '../../view/worktree-view.js';
|
|
5
|
+
/** One queue for the list, dialogs and Dashboard; unmount removes a source's notices. */
|
|
6
|
+
export declare function NotificationProvider({ children, t, openSettings }: {
|
|
7
|
+
children: ReactNode;
|
|
8
|
+
t: WorktreeTranslate;
|
|
9
|
+
openSettings?: () => boolean;
|
|
10
|
+
}): import("react").JSX.Element;
|
|
11
|
+
/** Register resolved copy while retaining live callbacks for recovery actions. */
|
|
12
|
+
export declare function NotificationToasts({ notices }: {
|
|
4
13
|
notices: readonly WorktreeNotification[];
|
|
5
|
-
detailsLabel: string;
|
|
6
14
|
}): import("react").JSX.Element | null;
|
|
15
|
+
export declare function ErrorToast({ error, t, scope, context, actions, describe, }: {
|
|
16
|
+
readonly error?: WorktreeViewError;
|
|
17
|
+
readonly t: WorktreeTranslate;
|
|
18
|
+
readonly scope: string;
|
|
19
|
+
readonly context?: string;
|
|
20
|
+
readonly actions?: WorktreeNotification['actions'];
|
|
21
|
+
readonly describe?: WorktreeNotification['describe'];
|
|
22
|
+
}): import("react").JSX.Element;
|
|
7
23
|
//# sourceMappingURL=NotificationToasts.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NotificationToasts.d.ts","sourceRoot":"","sources":["../../../../src/client/surface/components/NotificationToasts.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"NotificationToasts.d.ts","sourceRoot":"","sources":["../../../../src/client/surface/components/NotificationToasts.tsx"],"names":[],"mappings":"AACA,OAAO,EAQL,KAAK,SAAS,EACf,MAAM,OAAO,CAAC;AACf,OAAO,EAIL,KAAK,oBAAoB,EAC1B,MAAM,0BAA0B,CAAC;AAElC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAC;AACrD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAMrE,yFAAyF;AACzF,wBAAgB,oBAAoB,CAAC,EAAE,QAAQ,EAAE,CAAC,EAAE,YAAY,EAAE,EAAE;IAClE,QAAQ,EAAE,SAAS,CAAC;IACpB,CAAC,EAAE,iBAAiB,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,OAAO,CAAC;CAC9B,+BAqBA;AAED,kFAAkF;AAClF,wBAAgB,kBAAkB,CAAC,EAAE,OAAO,EAAE,EAAE;IAAE,OAAO,EAAE,SAAS,oBAAoB,EAAE,CAAA;CAAE,sCAqC3F;AAED,wBAAgB,UAAU,CAAC,EACzB,KAAK,EACL,CAAC,EACD,KAAK,EACL,OAAO,EACP,OAAO,EACP,QAAQ,GACT,EAAE;IACD,QAAQ,CAAC,KAAK,CAAC,EAAE,iBAAiB,CAAC;IACnC,QAAQ,CAAC,CAAC,EAAE,iBAAiB,CAAC;IAC9B,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,OAAO,CAAC,EAAE,oBAAoB,CAAC,SAAS,CAAC,CAAC;IACnD,QAAQ,CAAC,QAAQ,CAAC,EAAE,oBAAoB,CAAC,UAAU,CAAC,CAAC;CACtD,+BAYA"}
|
|
@@ -1,9 +1,74 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Toast } from '@deepseek-ai/dsh-client-ui-primitives';
|
|
3
|
-
import { useCallback, useEffect, useState } from 'react';
|
|
4
|
-
import { reconcileNotifications, } from '../notification-queue.js';
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
import { createContext, useCallback, useContext, useEffect, useId, useRef, useState, } from 'react';
|
|
4
|
+
import { reconcileNotifications, failureToastKey, } from '../notification-queue.js';
|
|
5
|
+
import { formatWorktreeViewError } from '../../view/worktree-error-copy.js';
|
|
6
|
+
import { worktreeDiagnostics } from '../../settings/diagnostics.js';
|
|
7
|
+
const Notifications = createContext(undefined);
|
|
8
|
+
/** One queue for the list, dialogs and Dashboard; unmount removes a source's notices. */
|
|
9
|
+
export function NotificationProvider({ children, t, openSettings }) {
|
|
10
|
+
const [sources, setSources] = useState(new Map());
|
|
11
|
+
const publish = useCallback((source, notices) => {
|
|
12
|
+
setSources((current) => {
|
|
13
|
+
if (!current.has(source) && notices.length === 0)
|
|
14
|
+
return current;
|
|
15
|
+
const next = new Map(current);
|
|
16
|
+
if (notices.length === 0)
|
|
17
|
+
next.delete(source);
|
|
18
|
+
else
|
|
19
|
+
next.set(source, notices);
|
|
20
|
+
return next;
|
|
21
|
+
});
|
|
22
|
+
}, []);
|
|
23
|
+
return (_jsxs(Notifications.Provider, { value: publish, children: [children, _jsx(ToastQueue, { notices: [...sources.values()].flat(), hint: t('settings.toastHint'), settingsAction: openSettings === undefined ? undefined
|
|
24
|
+
: { label: t('settings.errors'), onClick: openSettings } })] }));
|
|
25
|
+
}
|
|
26
|
+
/** Register resolved copy while retaining live callbacks for recovery actions. */
|
|
27
|
+
export function NotificationToasts({ notices }) {
|
|
28
|
+
const publish = useContext(Notifications);
|
|
29
|
+
const id = useId();
|
|
30
|
+
const latest = useRef(notices);
|
|
31
|
+
const alive = useRef(true);
|
|
32
|
+
latest.current = notices;
|
|
33
|
+
const signature = JSON.stringify(notices.map(({ key, text, context, error, actions }) => [
|
|
34
|
+
key, text, context, error, actions?.map(({ label, disabled, leaveSettings }) => [label, disabled, leaveSettings]),
|
|
35
|
+
]));
|
|
36
|
+
useEffect(() => {
|
|
37
|
+
const registered = latest.current.map((notice) => ({
|
|
38
|
+
...notice,
|
|
39
|
+
actions: notice.actions?.map((action) => ({
|
|
40
|
+
leaveSettings: action.leaveSettings,
|
|
41
|
+
disabled: action.disabled,
|
|
42
|
+
label: action.label,
|
|
43
|
+
onClick: () => {
|
|
44
|
+
const current = latest.current.find((item) => item.key === notice.key)?.actions
|
|
45
|
+
?.find((item) => item.label === action.label);
|
|
46
|
+
if (alive.current && !current?.disabled)
|
|
47
|
+
current?.onClick();
|
|
48
|
+
},
|
|
49
|
+
})),
|
|
50
|
+
}));
|
|
51
|
+
worktreeDiagnostics.publish(id, registered);
|
|
52
|
+
publish?.(id, registered);
|
|
53
|
+
}, [publish, id, signature]);
|
|
54
|
+
useEffect(() => {
|
|
55
|
+
alive.current = true;
|
|
56
|
+
return () => {
|
|
57
|
+
alive.current = false;
|
|
58
|
+
worktreeDiagnostics.deactivate(id);
|
|
59
|
+
publish?.(id, []);
|
|
60
|
+
};
|
|
61
|
+
}, [publish, id]);
|
|
62
|
+
return publish === undefined ? _jsx(ToastQueue, { notices: notices }) : null;
|
|
63
|
+
}
|
|
64
|
+
export function ErrorToast({ error, t, scope, context, actions, describe, }) {
|
|
65
|
+
const text = error === undefined ? undefined : formatWorktreeViewError(error, t);
|
|
66
|
+
return (_jsx(NotificationToasts, { notices: text === undefined ? [] : [{
|
|
67
|
+
key: JSON.stringify([scope, error?.code, error?.details]), text, error, context, actions, describe,
|
|
68
|
+
toastKey: failureToastKey(error),
|
|
69
|
+
}] }));
|
|
70
|
+
}
|
|
71
|
+
function ToastQueue({ notices, hint, settingsAction }) {
|
|
7
72
|
const [queue, setQueue] = useState({ seen: [], pending: [] });
|
|
8
73
|
useEffect(() => {
|
|
9
74
|
setQueue((current) => reconcileNotifications(current, notices));
|
|
@@ -18,7 +83,8 @@ export function NotificationToasts({ notices, detailsLabel, }) {
|
|
|
18
83
|
}, [key]);
|
|
19
84
|
if (current === undefined)
|
|
20
85
|
return null;
|
|
21
|
-
|
|
22
|
-
|
|
86
|
+
// Never truncate recovery guidance. Resolve actions from the current render.
|
|
87
|
+
const active = notices.find((notice) => (notice.toastKey ?? notice.key) === current.key);
|
|
88
|
+
return (_jsx(Toast, { text: [active?.text ?? current.text, hint].filter(Boolean).join(' '), actions: settingsAction === undefined ? undefined : [settingsAction], holdMs: 8000, onDone: onDone }, current.key));
|
|
23
89
|
}
|
|
24
90
|
//# sourceMappingURL=NotificationToasts.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NotificationToasts.js","sourceRoot":"","sources":["../../../../src/client/surface/components/NotificationToasts.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,uCAAuC,CAAC;AAC9D,OAAO,
|
|
1
|
+
{"version":3,"file":"NotificationToasts.js","sourceRoot":"","sources":["../../../../src/client/surface/components/NotificationToasts.tsx"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CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,GAAG,KAAK,GAAG,CAAC;SAC9D,CAAC,CAAC,CAAC;IACN,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IACV,IAAI,OAAO,KAAK,SAAS;QAAE,OAAO,IAAI,CAAC;IACvC,6EAA6E;IAC7E,MAAM,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,QAAQ,IAAI,MAAM,CAAC,GAAG,CAAC,KAAK,OAAO,CAAC,GAAG,CAAC,CAAC;IACzF,OAAO,CACL,KAAC,KAAK,IAEJ,IAAI,EAAE,CAAC,MAAM,EAAE,IAAI,IAAI,OAAO,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EACpE,OAAO,EAAE,cAAc,KAAK,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,cAAc,CAAC,EACpE,MAAM,EAAE,IAAI,EACZ,MAAM,EAAE,MAAM,IAJT,OAAO,CAAC,GAAG,CAKhB,CACH,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { type RefObject } from 'react';
|
|
2
|
+
/** A themed thumb over the native scrollport: the list keeps its full width. */
|
|
3
|
+
export declare function OverlayScrollbar({ scrollportRef, }: {
|
|
4
|
+
readonly scrollportRef: RefObject<HTMLDivElement>;
|
|
5
|
+
}): import("react").JSX.Element;
|
|
6
|
+
//# sourceMappingURL=OverlayScrollbar.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OverlayScrollbar.d.ts","sourceRoot":"","sources":["../../../../src/client/surface/components/OverlayScrollbar.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAwD,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAG7F,gFAAgF;AAChF,wBAAgB,gBAAgB,CAAC,EAC/B,aAAa,GACd,EAAE;IACD,QAAQ,CAAC,aAAa,EAAE,SAAS,CAAC,cAAc,CAAC,CAAC;CACnD,+BAuGA"}
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useLayoutEffect, useRef, useState } from 'react';
|
|
3
|
+
import styles from '../../worktree.css';
|
|
4
|
+
/** A themed thumb over the native scrollport: the list keeps its full width. */
|
|
5
|
+
export function OverlayScrollbar({ scrollportRef, }) {
|
|
6
|
+
const thumbRef = useRef(null);
|
|
7
|
+
const dragRef = useRef(null);
|
|
8
|
+
const [dragging, setDragging] = useState(false);
|
|
9
|
+
const [geometry, setGeometry] = useState({ height: 0, top: 0, range: 0, travel: 0 });
|
|
10
|
+
useLayoutEffect(() => {
|
|
11
|
+
const scrollport = scrollportRef.current;
|
|
12
|
+
const content = scrollport?.firstElementChild;
|
|
13
|
+
if (scrollport === null || content == null)
|
|
14
|
+
return;
|
|
15
|
+
const measure = () => {
|
|
16
|
+
const viewport = scrollport.clientHeight;
|
|
17
|
+
const range = Math.max(0, scrollport.scrollHeight - viewport);
|
|
18
|
+
const height = scrollport.scrollHeight === 0
|
|
19
|
+
? 0
|
|
20
|
+
: Math.min(viewport, Math.max(24, (viewport * viewport) / scrollport.scrollHeight));
|
|
21
|
+
const travel = viewport - height;
|
|
22
|
+
setGeometry({
|
|
23
|
+
height,
|
|
24
|
+
range,
|
|
25
|
+
travel,
|
|
26
|
+
top: range === 0 ? 0 : Math.min(travel, Math.max(0, (scrollport.scrollTop / range) * travel)),
|
|
27
|
+
});
|
|
28
|
+
};
|
|
29
|
+
const observer = new ResizeObserver(measure);
|
|
30
|
+
observer.observe(scrollport);
|
|
31
|
+
observer.observe(content);
|
|
32
|
+
scrollport.addEventListener('scroll', measure, { passive: true });
|
|
33
|
+
measure();
|
|
34
|
+
return () => {
|
|
35
|
+
observer.disconnect();
|
|
36
|
+
scrollport.removeEventListener('scroll', measure);
|
|
37
|
+
};
|
|
38
|
+
}, [scrollportRef]);
|
|
39
|
+
const releaseDrag = (event) => {
|
|
40
|
+
if (event.currentTarget.hasPointerCapture(event.pointerId)) {
|
|
41
|
+
event.currentTarget.releasePointerCapture(event.pointerId);
|
|
42
|
+
}
|
|
43
|
+
dragRef.current = null;
|
|
44
|
+
setDragging(false);
|
|
45
|
+
};
|
|
46
|
+
return (_jsx("div", { className: styles.overlayScrollbar, hidden: geometry.range === 0, "aria-hidden": "true", "data-dragging": dragging || undefined, onPointerDown: (event) => {
|
|
47
|
+
const scrollport = scrollportRef.current;
|
|
48
|
+
if (event.button !== 0 || scrollport === null || geometry.travel <= 0)
|
|
49
|
+
return;
|
|
50
|
+
event.preventDefault();
|
|
51
|
+
if (event.target !== thumbRef.current) {
|
|
52
|
+
const top = event.clientY - event.currentTarget.getBoundingClientRect().top - geometry.height / 2;
|
|
53
|
+
scrollport.scrollTop =
|
|
54
|
+
(Math.max(0, Math.min(geometry.travel, top)) / geometry.travel) * geometry.range;
|
|
55
|
+
}
|
|
56
|
+
dragRef.current = {
|
|
57
|
+
pointerId: event.pointerId,
|
|
58
|
+
y: event.clientY,
|
|
59
|
+
scrollTop: scrollport.scrollTop,
|
|
60
|
+
};
|
|
61
|
+
event.currentTarget.setPointerCapture(event.pointerId);
|
|
62
|
+
setDragging(true);
|
|
63
|
+
}, onPointerMove: (event) => {
|
|
64
|
+
const drag = dragRef.current;
|
|
65
|
+
const scrollport = scrollportRef.current;
|
|
66
|
+
if (drag === null ||
|
|
67
|
+
drag.pointerId !== event.pointerId ||
|
|
68
|
+
scrollport === null ||
|
|
69
|
+
geometry.travel <= 0)
|
|
70
|
+
return;
|
|
71
|
+
scrollport.scrollTop =
|
|
72
|
+
drag.scrollTop + ((event.clientY - drag.y) / geometry.travel) * geometry.range;
|
|
73
|
+
}, onPointerUp: releaseDrag, onPointerCancel: releaseDrag, onLostPointerCapture: () => {
|
|
74
|
+
dragRef.current = null;
|
|
75
|
+
setDragging(false);
|
|
76
|
+
}, onWheel: (event) => {
|
|
77
|
+
const scrollport = scrollportRef.current;
|
|
78
|
+
if (scrollport !== null) {
|
|
79
|
+
const unit = event.deltaMode === 1 ? 20 : event.deltaMode === 2 ? scrollport.clientHeight : 1;
|
|
80
|
+
scrollport.scrollTop += event.deltaY * unit;
|
|
81
|
+
}
|
|
82
|
+
}, children: _jsx("div", { ref: thumbRef, className: styles.scrollbarThumb, style: { height: geometry.height, transform: `translateY(${geometry.top}px)` } }) }));
|
|
83
|
+
}
|
|
84
|
+
//# sourceMappingURL=OverlayScrollbar.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OverlayScrollbar.js","sourceRoot":"","sources":["../../../../src/client/surface/components/OverlayScrollbar.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,EAAE,QAAQ,EAAqC,MAAM,OAAO,CAAC;AAC7F,OAAO,MAAM,MAAM,oBAAoB,CAAC;AAExC,gFAAgF;AAChF,MAAM,UAAU,gBAAgB,CAAC,EAC/B,aAAa,GAGd;IACC,MAAM,QAAQ,GAAG,MAAM,CAAiB,IAAI,CAAC,CAAC;IAC9C,MAAM,OAAO,GAAG,MAAM,CAA6D,IAAI,CAAC,CAAC;IACzF,MAAM,CAAC,QAAQ,EAAE,WAAW,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC;IAChD,MAAM,CAAC,QAAQ,EAAE,WAAW,CAAC,GAAG,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,GAAG,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,CAAC,CAAC;IAErF,eAAe,CAAC,GAAG,EAAE;QACnB,MAAM,UAAU,GAAG,aAAa,CAAC,OAAO,CAAC;QACzC,MAAM,OAAO,GAAG,UAAU,EAAE,iBAAiB,CAAC;QAC9C,IAAI,UAAU,KAAK,IAAI,IAAI,OAAO,IAAI,IAAI;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,KAAK,CAAC,MAAM,GAAG,IAAI,CAAC;YAC9C,CAAC;QACH,CAAC,YAED,cACE,GAAG,EAAE,QAAQ,EACb,SAAS,EAAE,MAAM,CAAC,cAAc,EAChC,KAAK,EAAE,EAAE,MAAM,EAAE,QAAQ,CAAC,MAAM,EAAE,SAAS,EAAE,cAAc,QAAQ,CAAC,GAAG,KAAK,EAAE,GAC9E,GACE,CACP,CAAC;AACJ,CAAC"}
|
|
@@ -4,11 +4,11 @@ import type { useSurfaceMutation } from '../actions/useSurfaceMutation.js';
|
|
|
4
4
|
import type { useSurfaceRefresh } from '../state/useSurfaceRefresh.js';
|
|
5
5
|
import type { useWorktreeRegistration } from '../actions/useWorktreeRegistration.js';
|
|
6
6
|
type Input = {
|
|
7
|
-
props: Pick<WorktreeSurfaceProps, 't'>;
|
|
7
|
+
props: Pick<WorktreeSurfaceProps, 't' | 'manager'>;
|
|
8
8
|
registration: Pick<ReturnType<typeof useWorktreeRegistration>, 'modalWorkspace' | 'modalView' | 'modalSetupStatus' | 'modalCanCreate' | 'closeWorktreeCreator' | 'changeWorktreeModalMode' | 'loadImportCandidates' | 'submitWorktree'>;
|
|
9
|
-
registrationState: Pick<ReturnType<typeof useRegistrationState>, 'modalReadError' | 'worktreeModalMode' | 'importCandidates' | 'selectedImportPath' | 'selectedBranch' | 'newBranch' | 'worktreeModalWorkspaceId' | 'modalReadViewRef' | 'setSelectedBranch' | 'setNewBranch' | 'setSelectedImportPath'>;
|
|
9
|
+
registrationState: Pick<ReturnType<typeof useRegistrationState>, 'modalReadError' | 'modalReadLoading' | 'worktreeModalMode' | 'importCandidates' | 'selectedImportPath' | 'selectedBranch' | 'newBranch' | 'worktreeModalWorkspaceId' | 'modalReadViewRef' | 'modalWorkspaceIdRef' | 'modalGenerationRef' | 'modalLifetimeRef' | 'setModalBranches' | 'setSelectedBranch' | 'setNewBranch' | 'setSelectedImportPath'>;
|
|
10
10
|
mutation: Pick<ReturnType<typeof useSurfaceMutation>, 'actionPending'>;
|
|
11
|
-
read: Pick<ReturnType<typeof useSurfaceRefresh>, 'loadModalWorktreeView'>;
|
|
11
|
+
read: Pick<ReturnType<typeof useSurfaceRefresh>, 'loadModalWorktreeView' | 'refresh'>;
|
|
12
12
|
};
|
|
13
13
|
export declare function RegistrationDialog({ props, registration, registrationState, mutation, read, }: Input): import("react").JSX.Element;
|
|
14
14
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RegistrationDialog.d.ts","sourceRoot":"","sources":["../../../../src/client/surface/components/RegistrationDialog.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"RegistrationDialog.d.ts","sourceRoot":"","sources":["../../../../src/client/surface/components/RegistrationDialog.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAC;AACxD,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,kCAAkC,CAAC;AAC7E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,kCAAkC,CAAC;AAC3E,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAC;AACvE,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,uCAAuC,CAAC;AAErF,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,IAAI,CAAC,oBAAoB,EAAE,GAAG,GAAG,SAAS,CAAC,CAAC;IACnD,YAAY,EAAE,IAAI,CAChB,UAAU,CAAC,OAAO,uBAAuB,CAAC,EACxC,gBAAgB,GAChB,WAAW,GACX,kBAAkB,GAClB,gBAAgB,GAChB,sBAAsB,GACtB,yBAAyB,GACzB,sBAAsB,GACtB,gBAAgB,CACnB,CAAC;IACF,iBAAiB,EAAE,IAAI,CACrB,UAAU,CAAC,OAAO,oBAAoB,CAAC,EACrC,gBAAgB,GAChB,kBAAkB,GAClB,mBAAmB,GACnB,kBAAkB,GAClB,oBAAoB,GACpB,gBAAgB,GAChB,WAAW,GACX,0BAA0B,GAC1B,kBAAkB,GAClB,qBAAqB,GACrB,oBAAoB,GACpB,kBAAkB,GAClB,kBAAkB,GAClB,mBAAmB,GACnB,cAAc,GACd,uBAAuB,CAC1B,CAAC;IACF,QAAQ,EAAE,IAAI,CAAC,UAAU,CAAC,OAAO,kBAAkB,CAAC,EAAE,eAAe,CAAC,CAAC;IACvE,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,OAAO,iBAAiB,CAAC,EAAE,uBAAuB,GAAG,SAAS,CAAC,CAAC;CACvF,CAAC;AAEF,wBAAgB,kBAAkB,CAAC,EACjC,KAAK,EACL,YAAY,EACZ,iBAAiB,EACjB,QAAQ,EACR,IAAI,GACL,EAAE,KAAK,+BAkIP"}
|
|
@@ -1,22 +1,87 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { useEffect, useRef } from 'react';
|
|
2
3
|
import { WorktreeCreateDialog } from './dialogs.js';
|
|
3
4
|
export function RegistrationDialog({ props, registration, registrationState, mutation, read, }) {
|
|
4
5
|
const { t } = props;
|
|
5
6
|
const { modalWorkspace, modalView, modalSetupStatus, modalCanCreate, closeWorktreeCreator, changeWorktreeModalMode, loadImportCandidates, submitWorktree, } = registration;
|
|
6
|
-
const { modalReadError, worktreeModalMode, importCandidates, selectedImportPath, selectedBranch, newBranch, worktreeModalWorkspaceId, modalReadViewRef, setSelectedBranch, setNewBranch, setSelectedImportPath, } = registrationState;
|
|
7
|
+
const { modalReadError, modalReadLoading, worktreeModalMode, importCandidates, selectedImportPath, selectedBranch, newBranch, worktreeModalWorkspaceId, modalReadViewRef, modalWorkspaceIdRef, modalGenerationRef, modalLifetimeRef, setModalBranches, setSelectedBranch, setNewBranch, setSelectedImportPath, } = registrationState;
|
|
7
8
|
const { actionPending } = mutation;
|
|
8
9
|
const { loadModalWorktreeView } = read;
|
|
9
|
-
|
|
10
|
-
|
|
10
|
+
// Tab/request invalidation must not restart the native Modal entry animation.
|
|
11
|
+
const shell = useRef({ workspaceId: worktreeModalWorkspaceId, manager: props.manager,
|
|
12
|
+
lifetime: modalLifetimeRef.current, generation: 0 });
|
|
13
|
+
if (shell.current.workspaceId !== worktreeModalWorkspaceId ||
|
|
14
|
+
shell.current.manager !== props.manager || shell.current.lifetime !== modalLifetimeRef.current) {
|
|
15
|
+
shell.current = { workspaceId: worktreeModalWorkspaceId, manager: props.manager,
|
|
16
|
+
lifetime: modalLifetimeRef.current, generation: shell.current.generation + 1 };
|
|
17
|
+
}
|
|
18
|
+
// Workspace equality cannot distinguish closing and reopening the same dialog.
|
|
19
|
+
const lifecycle = useRef({ workspaceId: worktreeModalWorkspaceId, manager: props.manager,
|
|
20
|
+
mode: worktreeModalMode, ownerGeneration: modalGenerationRef.current, generation: 0 });
|
|
21
|
+
if (lifecycle.current.workspaceId !== worktreeModalWorkspaceId ||
|
|
22
|
+
lifecycle.current.manager !== props.manager || lifecycle.current.mode !== worktreeModalMode ||
|
|
23
|
+
lifecycle.current.ownerGeneration !== modalGenerationRef.current) {
|
|
24
|
+
lifecycle.current = { workspaceId: worktreeModalWorkspaceId, manager: props.manager,
|
|
25
|
+
mode: worktreeModalMode, ownerGeneration: modalGenerationRef.current,
|
|
26
|
+
generation: lifecycle.current.generation + 1 };
|
|
27
|
+
}
|
|
28
|
+
const alive = useRef(true);
|
|
29
|
+
useEffect(() => {
|
|
30
|
+
alive.current = true;
|
|
31
|
+
return () => { alive.current = false; };
|
|
32
|
+
}, []);
|
|
33
|
+
const generation = lifecycle.current.generation;
|
|
34
|
+
const ownerGeneration = modalGenerationRef.current;
|
|
35
|
+
const isCurrent = () => alive.current && lifecycle.current.generation === generation &&
|
|
36
|
+
modalGenerationRef.current === ownerGeneration &&
|
|
37
|
+
modalWorkspaceIdRef.current === worktreeModalWorkspaceId;
|
|
38
|
+
return (_jsx(_Fragment, { children: _jsx(WorktreeCreateDialog, { pickerKey: generation, t: t, workspace: modalWorkspace, view: modalView, readError: modalReadError, setupStatus: modalSetupStatus, canCreate: modalCanCreate, branchesLoading: modalReadLoading || modalView === undefined, mode: worktreeModalMode, importCandidates: importCandidates, selectedImportPath: selectedImportPath, selectedBranch: selectedBranch, newBranch: newBranch, actionPending: actionPending, onClose: () => {
|
|
39
|
+
if (actionPending || !isCurrent())
|
|
11
40
|
return;
|
|
41
|
+
lifecycle.current.generation++;
|
|
42
|
+
closeWorktreeCreator();
|
|
43
|
+
}, onRetry: () => {
|
|
44
|
+
if (worktreeModalWorkspaceId === undefined || !isCurrent())
|
|
45
|
+
return;
|
|
46
|
+
lifecycle.current.generation++;
|
|
12
47
|
modalReadViewRef.current = undefined;
|
|
13
48
|
setSelectedBranch('');
|
|
14
49
|
setNewBranch('');
|
|
15
50
|
loadModalWorktreeView(worktreeModalWorkspaceId);
|
|
16
|
-
}, onModeChange:
|
|
51
|
+
}, onModeChange: (mode) => {
|
|
52
|
+
if (!isCurrent())
|
|
53
|
+
return;
|
|
54
|
+
if (mode !== worktreeModalMode)
|
|
55
|
+
lifecycle.current.generation++;
|
|
56
|
+
changeWorktreeModalMode(mode);
|
|
57
|
+
}, onRetryImportCandidates: () => {
|
|
17
58
|
if (worktreeModalWorkspaceId !== undefined) {
|
|
18
59
|
void loadImportCandidates(worktreeModalWorkspaceId);
|
|
19
60
|
}
|
|
20
|
-
}, onSelectedImportPathChange: setSelectedImportPath, onSelectedBranchChange: setSelectedBranch,
|
|
61
|
+
}, onSelectedImportPathChange: setSelectedImportPath, onSelectedBranchChange: setSelectedBranch, onLoadBranches: props.manager === undefined || worktreeModalWorkspaceId === undefined ? undefined
|
|
62
|
+
: async () => {
|
|
63
|
+
if (!isCurrent())
|
|
64
|
+
return [];
|
|
65
|
+
const branches = await props.manager.listBranches({ workspaceId: worktreeModalWorkspaceId });
|
|
66
|
+
if (isCurrent())
|
|
67
|
+
setModalBranches(branches);
|
|
68
|
+
return branches;
|
|
69
|
+
}, onFetchBranches: props.manager?.fetchRemoteBranches === undefined || worktreeModalWorkspaceId === undefined ? undefined : async () => {
|
|
70
|
+
if (!isCurrent())
|
|
71
|
+
return [];
|
|
72
|
+
const workspaceId = worktreeModalWorkspaceId;
|
|
73
|
+
try {
|
|
74
|
+
const branches = await props.manager.fetchRemoteBranches({ workspaceId });
|
|
75
|
+
if (isCurrent())
|
|
76
|
+
setModalBranches(branches);
|
|
77
|
+
return branches;
|
|
78
|
+
}
|
|
79
|
+
finally {
|
|
80
|
+
if (isCurrent()) {
|
|
81
|
+
await read.refresh({ preserveCurrent: true, invalidateContext: false,
|
|
82
|
+
scope: { kind: 'workspace', workspaceId } });
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}, onNewBranchChange: setNewBranch, onSubmit: submitWorktree }, shell.current.generation) }));
|
|
21
86
|
}
|
|
22
87
|
//# sourceMappingURL=RegistrationDialog.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RegistrationDialog.js","sourceRoot":"","sources":["../../../../src/client/surface/components/RegistrationDialog.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"RegistrationDialog.js","sourceRoot":"","sources":["../../../../src/client/surface/components/RegistrationDialog.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAC1C,OAAO,EAAE,oBAAoB,EAAE,MAAM,cAAc,CAAC;AA2CpD,MAAM,UAAU,kBAAkB,CAAC,EACjC,KAAK,EACL,YAAY,EACZ,iBAAiB,EACjB,QAAQ,EACR,IAAI,GACE;IACN,MAAM,EAAE,CAAC,EAAE,GAAG,KAAK,CAAC;IACpB,MAAM,EACJ,cAAc,EACd,SAAS,EACT,gBAAgB,EAChB,cAAc,EACd,oBAAoB,EACpB,uBAAuB,EACvB,oBAAoB,EACpB,cAAc,GACf,GAAG,YAAY,CAAC;IACjB,MAAM,EACJ,cAAc,EACd,gBAAgB,EAChB,iBAAiB,EACjB,gBAAgB,EAChB,k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,YAAY,EAAE,MAAM,kCAAkC,CAAC;AAClF,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAE7D,wBAAgB,YAAY,CAAC,EAC3B,MAAM,EACN,CAAC,GACF,EAAE,YAAY,CAAC,eAAe,CAAC,GAAG,WAAW,CAAC,UAAU,CAAC,GAAG;IAAE,QAAQ,CAAC,MAAM,EAAE,aAAa,CAAA;CAAE,
|
|
1
|
+
{"version":3,"file":"RestartToast.d.ts","sourceRoot":"","sources":["../../../../src/client/surface/components/RestartToast.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAC;AAClF,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAE7D,wBAAgB,YAAY,CAAC,EAC3B,MAAM,EACN,CAAC,GACF,EAAE,YAAY,CAAC,eAAe,CAAC,GAAG,WAAW,CAAC,UAAU,CAAC,GAAG;IAAE,QAAQ,CAAC,MAAM,EAAE,aAAa,CAAA;CAAE,sCAU9F"}
|
|
@@ -2,9 +2,10 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
|
2
2
|
import { useSyncExternalStore } from 'react';
|
|
3
3
|
import { Toast } from '@deepseek-ai/dsh-client-ui-primitives';
|
|
4
4
|
export function RestartToast({ notice, t, }) {
|
|
5
|
-
const
|
|
6
|
-
if (
|
|
5
|
+
const reason = useSyncExternalStore(notice.subscribe, notice.getReasonSnapshot, notice.getReasonSnapshot);
|
|
6
|
+
if (reason === undefined)
|
|
7
7
|
return null;
|
|
8
|
-
|
|
8
|
+
const presetMissing = reason === 'permission-preset-unavailable';
|
|
9
|
+
return _jsx(Toast, { text: t(presetMissing ? 'permission.presetRestartRequired' : 'restartRequired'), holdMs: presetMissing ? 12_000 : 8_000, onDone: () => notice.dismissReason(reason) }, reason);
|
|
9
10
|
}
|
|
10
11
|
//# sourceMappingURL=RestartToast.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RestartToast.js","sourceRoot":"","sources":["../../../../src/client/surface/components/RestartToast.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,OAAO,CAAC;AAC7C,OAAO,EAAE,KAAK,EAAE,MAAM,uCAAuC,CAAC;AAI9D,MAAM,UAAU,YAAY,CAAC,EAC3B,MAAM,EACN,CAAC,GAC4F;IAC7F,MAAM,
|
|
1
|
+
{"version":3,"file":"RestartToast.js","sourceRoot":"","sources":["../../../../src/client/surface/components/RestartToast.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,OAAO,CAAC;AAC7C,OAAO,EAAE,KAAK,EAAE,MAAM,uCAAuC,CAAC;AAI9D,MAAM,UAAU,YAAY,CAAC,EAC3B,MAAM,EACN,CAAC,GAC4F;IAC7F,MAAM,MAAM,GAAG,oBAAoB,CAAC,MAAM,CAAC,SAAS,EAAE,MAAM,CAAC,iBAAiB,EAAE,MAAM,CAAC,iBAAiB,CAAC,CAAC;IAC1G,IAAI,MAAM,KAAK,SAAS;QAAE,OAAO,IAAI,CAAC;IACtC,MAAM,aAAa,GAAG,MAAM,KAAK,+BAA+B,CAAC;IACjE,OAAO,KAAC,KAAK,IAEX,IAAI,EAAE,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,kCAAkC,CAAC,CAAC,CAAC,iBAAiB,CAAC,EAC/E,MAAM,EAAE,aAAa,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,KAAK,EACtC,MAAM,EAAE,GAAG,EAAE,CAAC,MAAM,CAAC,aAAa,CAAC,MAAM,CAAC,IAHrC,MAAM,CAIX,CAAC;AACL,CAAC"}
|