merge: resolve v1.22.2 conflicts with custom

Per Q4 resolution (documented on kanban t_83741c53):
- .github/workflows/*: KEEP custom deletion (fork uses Gitea Actions under .gitea/workflows)
- ChatInput.tsx: KEEP custom forge picker states + provider-aware linkedPr
- WorkStatusContextSection.tsx: combine imports (WorkStatusPill + useConfigStore)
- WorkStatusPrimaryGroup.tsx: upstream nested-git/bootstrap-gate base + custom GitLab/Gitea forge rows
- NewWorktreeDialog.tsx: combine dialogs; keep custom MR/PR branch resolution
- SettingsView.tsx: custom deps minus undefined openThirdPartyProviderSetup
- search.ts + search.test.ts: KEEP upstream (enter-to-send, large-text-paste, first-party integrations)
- tr.ts: drop 4 auto-merge duplicate gitView.empty.* keys
This commit is contained in:
2026-09-06 10:55:54 +00:00
220 changed files with 45375 additions and 3531 deletions
+72 -11
View File
@@ -69,6 +69,11 @@ import { useThemeSystem } from '@/contexts/useThemeSystem';
import { GitHubIssuePickerDialog } from '@/components/session/GitHubIssuePickerDialog';
import { GitHubPrPickerDialog } from '@/components/session/GitHubPrPickerDialog';
import { LinearIssuePickerDialog } from '@/components/session/LinearIssuePickerDialog';
import { GitLabIssuePickerDialog } from '@/components/session/GitLabIssuePickerDialog';
import { GitLabMrPickerDialog } from '@/components/session/GitLabMrPickerDialog';
import { GiteaIssuePickerDialog } from '@/components/session/GiteaIssuePickerDialog';
import { GiteaPrPickerDialog } from '@/components/session/GiteaPrPickerDialog';
import { useGitProvider } from '@/lib/gitProvider';
import { Icon } from "@/components/icon/Icon";
import { DraftPresetChips } from './DraftPresetChips';
import { useChatSearchDirectory } from '@/hooks/useChatSearchDirectory';
@@ -241,6 +246,7 @@ type LinkedGitHubPr = {
instructionsText: string;
contextText: string;
author?: LinkedReferenceAuthor;
provider?: 'github' | 'gitlab' | 'gitea';
};
type LinkedLinearIssueRef = { identifier: string; title: string; url: string; contextText: string; author?: LinkedReferenceAuthor };
type LinkedReferences = { issue: LinkedGitHubIssue | null; pr: LinkedGitHubPr | null; linear: LinkedLinearIssueRef | null };
@@ -522,6 +528,7 @@ const ChatInputComponent: React.FC<ChatInputProps> = ({
const { currentTheme } = useThemeSystem();
const chatSearchDirectory = useChatSearchDirectory();
const isGitRepo = useIsGitRepo(currentDirectory);
const gitProvider = useGitProvider(currentDirectory);
const currentGitStatus = useGitStore((state) =>
currentDirectory ? state.directories.get(currentDirectory)?.status ?? null : null,
);
@@ -857,6 +864,10 @@ const ChatInputComponent: React.FC<ChatInputProps> = ({
const [issuePickerOpen, setIssuePickerOpen] = React.useState(false);
const [prPickerOpen, setPrPickerOpen] = React.useState(false);
const [linearPickerOpen, setLinearPickerOpen] = React.useState(false);
const [gitlabIssuePickerOpen, setGitlabIssuePickerOpen] = React.useState(false);
const [gitlabMrPickerOpen, setGitlabMrPickerOpen] = React.useState(false);
const [giteaIssuePickerOpen, setGiteaIssuePickerOpen] = React.useState(false);
const [giteaPrPickerOpen, setGiteaPrPickerOpen] = React.useState(false);
const [linkedIssue, setLinkedIssue] = React.useState<LinkedGitHubIssue | null>(null);
const [linkedPr, setLinkedPr] = React.useState<LinkedGitHubPr | null>(null);
const [linkedLinearIssue, setLinkedLinearIssue] = React.useState<LinkedLinearIssueRef | null>(null);
@@ -1236,12 +1247,24 @@ const ChatInputComponent: React.FC<ChatInputProps> = ({
}, [isExpandedInput, setExpandedInput]);
const openIssuePicker = React.useCallback(() => {
setIssuePickerOpen(true);
}, []);
if (gitProvider === 'gitlab') {
setGitlabIssuePickerOpen(true);
} else if (gitProvider === 'gitea') {
setGiteaIssuePickerOpen(true);
} else {
setIssuePickerOpen(true);
}
}, [gitProvider]);
const openPrPicker = React.useCallback(() => {
setPrPickerOpen(true);
}, []);
if (gitProvider === 'gitlab') {
setGitlabMrPickerOpen(true);
} else if (gitProvider === 'gitea') {
setGiteaPrPickerOpen(true);
} else {
setPrPickerOpen(true);
}
}, [gitProvider]);
const openLinearPicker = React.useCallback(() => {
setLinearPickerOpen(true);
@@ -3071,20 +3094,24 @@ const ChatInputComponent: React.FC<ChatInputProps> = ({
author={linkedIssue.author}
openInBrowserLabel={t('chat.chatInput.linked.issue.openInBrowserAria')}
removeLabel={t('chat.chatInput.linked.issue.removeAria')}
onReopenPicker={() => setIssuePickerOpen(true)}
onReopenPicker={openIssuePicker}
onRemove={() => setLinkedIssue(null)}
/>
) : null}
{linkedPr && !isVSCode ? (
<LinkedReferenceRow
numberLabel={t('chat.chatInput.linked.pr.number', { number: linkedPr.number })}
numberLabel={
linkedPr.provider === 'gitlab'
? t('chat.chatInput.linked.mr.number', { number: linkedPr.number })
: t('chat.chatInput.linked.pr.number', { number: linkedPr.number })
}
title={linkedPr.title}
url={linkedPr.url}
author={linkedPr.author}
branches={linkedPr.head && linkedPr.base ? { head: linkedPr.head, base: linkedPr.base } : undefined}
openInBrowserLabel={t('chat.chatInput.linked.pr.openInBrowserAria')}
removeLabel={t('chat.chatInput.linked.pr.removeAria')}
onReopenPicker={() => setPrPickerOpen(true)}
onReopenPicker={openPrPicker}
onRemove={() => setLinkedPr(null)}
/>
) : null}
@@ -3441,6 +3468,40 @@ const ChatInputComponent: React.FC<ChatInputProps> = ({
setLinkedPr(null);
}}
/>
<GitLabIssuePickerDialog
open={gitlabIssuePickerOpen}
onOpenChange={setGitlabIssuePickerOpen}
mode="select"
onSelect={(issue) => {
setLinkedIssue(issue);
setLinkedPr(null);
}}
/>
<GitLabMrPickerDialog
open={gitlabMrPickerOpen}
onOpenChange={setGitlabMrPickerOpen}
onSelect={(pr) => {
setLinkedPr({ ...pr, provider: 'gitlab' as const });
setLinkedIssue(null);
}}
/>
<GiteaIssuePickerDialog
open={giteaIssuePickerOpen}
onOpenChange={setGiteaIssuePickerOpen}
mode="select"
onSelect={(issue) => {
setLinkedIssue(issue);
setLinkedPr(null);
}}
/>
<GiteaPrPickerDialog
open={giteaPrPickerOpen}
onOpenChange={setGiteaPrPickerOpen}
onSelect={(pr) => {
setLinkedPr({ ...pr, provider: 'gitea' as const });
setLinkedIssue(null);
}}
/>
<ReviewFlowDialog
open={reviewDialogOpen}
onOpenChange={setReviewDialogOpen}
@@ -3507,8 +3568,8 @@ const ChatInputComponent: React.FC<ChatInputProps> = ({
requestAnimationFrame(openIssuePicker);
}}
>
<Icon name="github" className="h-[18px] w-[18px] flex-shrink-0 text-muted-foreground" />
{t('chat.chatInput.actions.linkGithubIssue')}
<Icon name={gitProvider === 'gitlab' ? 'gitlab' : gitProvider === 'gitea' ? 'git-branch' : 'github'} className="h-[18px] w-[18px] flex-shrink-0 text-muted-foreground" />
{gitProvider === 'gitlab' ? t('chat.chatInput.actions.linkGitlabIssue') : gitProvider === 'gitea' ? t('chat.chatInput.actions.linkGiteaIssue') : t('chat.chatInput.actions.linkGithubIssue')}
</button>
<button
type="button"
@@ -3519,8 +3580,8 @@ const ChatInputComponent: React.FC<ChatInputProps> = ({
requestAnimationFrame(openPrPicker);
}}
>
<Icon name="git-pull-request" className="h-[18px] w-[18px] flex-shrink-0 text-muted-foreground" />
{t('chat.chatInput.actions.linkGithubPr')}
<Icon name={gitProvider === 'gitlab' ? 'gitlab' : 'git-pull-request'} className="h-[18px] w-[18px] flex-shrink-0 text-muted-foreground" />
{gitProvider === 'gitlab' ? t('chat.chatInput.actions.linkGitlabMr') : gitProvider === 'gitea' ? t('chat.chatInput.actions.linkGiteaPr') : t('chat.chatInput.actions.linkGithubPr')}
</button>
{showLinearPicker ? (
<button