Refines whitespace for improved code consistency

Standardizes whitespace in terminal components to enhance code readability and maintain consistent formatting. No functional changes made.
This commit is contained in:
LAPTOP-O016UC3M\Qi Chen
2025-12-12 22:31:27 +08:00
parent 195d2a6b99
commit df3b2219dc
2 changed files with 6 additions and 6 deletions
+5 -5
View File
@@ -1711,13 +1711,13 @@ const TerminalComponent: React.FC<TerminalProps> = ({
setSearchMatchCount(null);
return false;
}
// Store the search term for findNext/findPrevious
searchTermRef.current = term;
// Clear previous decorations
searchAddon.clearDecorations();
// Perform search (findNext from current position or start)
const found = searchAddon.findNext(term, {
regex: false,
@@ -1732,7 +1732,7 @@ const TerminalComponent: React.FC<TerminalProps> = ({
activeMatchColorOverviewRuler: '#FF8800',
},
});
// Update match count after search
// Note: xterm search addon doesn't expose match count directly
// We'll track it by counting via findAll (if available) or estimate
@@ -1743,7 +1743,7 @@ const TerminalComponent: React.FC<TerminalProps> = ({
} else {
setSearchMatchCount({ current: 0, total: 0 });
}
return found;
}, []);
+1 -1
View File
@@ -69,7 +69,7 @@ export const TerminalSearchBar: React.FC<TerminalSearchBarProps> = ({
if (!isOpen) return null;
return (
<div
<div
className="flex items-center gap-1.5 px-2 pt-1 pb-2 bg-black/50 backdrop-blur-sm"
onClick={(e) => e.stopPropagation()}
onMouseDown={(e) => e.stopPropagation()}