文件搜索结果里对目录图标着色
This commit is contained in:
@@ -2321,7 +2321,9 @@ export function FileTreeTab() {
|
||||
<DialogContent
|
||||
onOpenAutoFocus={(e) => {
|
||||
e.preventDefault()
|
||||
const input = (e.currentTarget as HTMLElement | null)?.querySelector("input")
|
||||
const input = (
|
||||
e.currentTarget as HTMLElement | null
|
||||
)?.querySelector("input")
|
||||
if (input) requestAnimationFrame(() => input.focus())
|
||||
}}
|
||||
>
|
||||
@@ -2388,7 +2390,9 @@ export function FileTreeTab() {
|
||||
<DialogContent
|
||||
onOpenAutoFocus={(e) => {
|
||||
e.preventDefault()
|
||||
const input = (e.currentTarget as HTMLElement | null)?.querySelector("input")
|
||||
const input = (
|
||||
e.currentTarget as HTMLElement | null
|
||||
)?.querySelector("input")
|
||||
if (input) requestAnimationFrame(() => input.focus())
|
||||
}}
|
||||
>
|
||||
|
||||
@@ -26,13 +26,15 @@ export function AuxPanel() {
|
||||
activeTab === "git_log"
|
||||
)
|
||||
|
||||
// Sync mount flags when activeTab changes programmatically (e.g. revealInFileTree)
|
||||
// Sync mount flags when activeTab changes programmatically (e.g. revealInFileTree).
|
||||
/* eslint-disable react-hooks/set-state-in-effect */
|
||||
useEffect(() => {
|
||||
if (!isOpen) return
|
||||
if (activeTab === "file_tree") setHasMountedFileTree(true)
|
||||
else if (activeTab === "changes") setHasMountedChanges(true)
|
||||
else if (activeTab === "git_log") setHasMountedGitLog(true)
|
||||
}, [isOpen, activeTab])
|
||||
/* eslint-enable react-hooks/set-state-in-effect */
|
||||
|
||||
const handleTabValueChange = useCallback(
|
||||
(value: string) => {
|
||||
|
||||
Reference in New Issue
Block a user