✨ feat(vscode): 支持讨论评论引用与 macOS 系统级新评论桌面提醒
This commit is contained in:
1 parent
540c212bad
commit
a2c3c1f919
13 files changed
+638
-302
No files matched your search
@@ -311,6 +311,8 @@ export interface UseIssuesResult {
|
||||
*/
|
||||
pendingSelectId: string | null
|
||||
clearPendingSelect: () => void
|
||||
pendingSelectTab: 'issue' | 'chat' | 'profile' | 'sessions' | 'changes' | null
|
||||
clearPendingSelectTab: () => void
|
||||
/** 当前 Gitea login,来自最近一次 `issues/update`;undefined = 身份未知。 */
|
||||
me: string | undefined
|
||||
/** 最近一次 `requestHandoffUsers` 的结果;`null` = 仍在加载或尚未请求。 */
|
||||
@@ -384,6 +386,7 @@ export function useIssues(): UseIssuesResult {
|
||||
const [profiles, setProfiles] = useState<ClaudeProfile[]>([])
|
||||
const [logs, setLogs] = useState<LogEntry[]>([])
|
||||
const [pendingSelectId, setPendingSelectId] = useState<string | null>(null)
|
||||
const [pendingSelectTab, setPendingSelectTab] = useState<'issue' | 'chat' | 'profile' | 'sessions' | 'changes' | null>(null)
|
||||
const [commitRunning, setCommitRunning] = useState<boolean>(false)
|
||||
const [hasChanges, setHasChanges] = useState<boolean>(false)
|
||||
const [release, setRelease] = useState<ReleaseStatus>()
|
||||
@@ -410,6 +413,10 @@ export function useIssues(): UseIssuesResult {
|
||||
setPendingSelectId(null)
|
||||
}, [])
|
||||
|
||||
const clearPendingSelectTab = useCallback((): void => {
|
||||
setPendingSelectTab(null)
|
||||
}, [])
|
||||
|
||||
const toggleScope = useCallback((): void => {
|
||||
setState({ status: 'loading' })
|
||||
setScope(prev => prev === 'mine' ? 'all' : 'mine')
|
||||
@@ -927,8 +934,11 @@ export function useIssues(): UseIssuesResult {
|
||||
if (prev.status !== 'ready')
|
||||
return prev
|
||||
const issue = prev.issues.find(i => i.number === msg.issueNumber)
|
||||
if (issue)
|
||||
if (issue) {
|
||||
setPendingSelectId(issue.id)
|
||||
if (msg.tab)
|
||||
setPendingSelectTab(msg.tab)
|
||||
}
|
||||
return prev
|
||||
})
|
||||
break
|
||||
@@ -1087,5 +1097,5 @@ export function useIssues(): UseIssuesResult {
|
||||
])
|
||||
}, [state, me])
|
||||
|
||||
return { state, settings, avatars, isSessionTabPending, globalAutoReview, youtrackConfigured, importYouTrack, toasts, profiles, setIssues, refresh, refreshing, scope, toggleScope, saveSettings, listYouTrackProjects, youtrackProjects, dismissSettings, requestEditAuth, createIssue, dismissToast, openUrl, resumeSession, resumeReviewSession, startReviewSession, startTestSession, resumeTestSession, startPrototypeSession, resumePrototypeSession, focusSession, openFile, openPrototypeInFigma, implement, generatePrDiffSummary, isPrDiffSummaryRunning, openPr, openWorktree, deleteWorktree, mergeBranch, deleteIssue, closeIssue, closeSessionTab, continueBrainstorm, changeColumn, setDependency, clearDependency, updateIssueAutoReview, updateIssueProfilePath, updateIssueBrainstormProfilePath, clearSession, updateIssueTestProfilePath, updateIssuePrototypeProfilePath, logs, fetchLogs, clearLogs, pendingSelectId, clearPendingSelect, commitRunning, runCommit, hasChanges, release, runRelease, cherryPick, dismissCherryPick, confirmCherryPick, envLocked, envFileCount, envLockRunning, envLockTitle, toggleEnvLock, me, handoffUsers, requestHandoffUsers, startHandoff, acceptHandoff, isHandoffRunning, askHandoff, cancelHandoffRequest, acceptHandoffRequest, rejectHandoffRequest }
|
||||
return { state, settings, avatars, isSessionTabPending, globalAutoReview, youtrackConfigured, importYouTrack, toasts, profiles, setIssues, refresh, refreshing, scope, toggleScope, saveSettings, listYouTrackProjects, youtrackProjects, dismissSettings, requestEditAuth, createIssue, dismissToast, openUrl, resumeSession, resumeReviewSession, startReviewSession, startTestSession, resumeTestSession, startPrototypeSession, resumePrototypeSession, focusSession, openFile, openPrototypeInFigma, implement, generatePrDiffSummary, isPrDiffSummaryRunning, openPr, openWorktree, deleteWorktree, mergeBranch, deleteIssue, closeIssue, closeSessionTab, continueBrainstorm, changeColumn, setDependency, clearDependency, updateIssueAutoReview, updateIssueProfilePath, updateIssueBrainstormProfilePath, clearSession, updateIssueTestProfilePath, updateIssuePrototypeProfilePath, logs, fetchLogs, clearLogs, pendingSelectId, clearPendingSelect, pendingSelectTab, clearPendingSelectTab, commitRunning, runCommit, hasChanges, release, runRelease, cherryPick, dismissCherryPick, confirmCherryPick, envLocked, envFileCount, envLockRunning, envLockTitle, toggleEnvLock, me, handoffUsers, requestHandoffUsers, startHandoff, acceptHandoff, isHandoffRunning, askHandoff, cancelHandoffRequest, acceptHandoffRequest, rejectHandoffRequest }
|
||||
}
|
||||
Reference in new issue
Block a user