mirror of
https://github.com/AutoMaker-Org/automaker.git
synced 2026-03-18 22:33:08 +00:00
chore: Fix all lint errors and remove unused code
- Fix 75 ESLint errors by updating eslint.config.mjs: - Add missing browser globals (MouseEvent, AbortController, Response, etc.) - Add Vite define global (__APP_VERSION__) - Configure @ts-nocheck to require descriptions - Add no-unused-vars rule for .mjs scripts - Fix runtime bug in agent-output-modal.tsx (setOutput -> setStreamedContent) - Remove ~120 unused variable warnings across 97 files: - Remove unused imports (React hooks, lucide icons, types) - Remove unused constants and variables - Remove unused function definitions - Prefix intentionally unused parameters with underscore - Add descriptions to all @ts-nocheck comments (25 files) - Clean up misc issues: - Remove invalid deprecation plugin comments - Fix eslint-disable comment placement - Add missing RefreshCw import in code-view.tsx Reduces lint warnings from ~300 to 67 (all remaining are no-explicit-any) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -45,7 +45,6 @@ import { matchesShortcutWithCode } from '@/hooks/use-keyboard-shortcuts';
|
||||
import {
|
||||
getTerminalTheme,
|
||||
TERMINAL_FONT_OPTIONS,
|
||||
DEFAULT_TERMINAL_FONT,
|
||||
getTerminalFontFamily,
|
||||
} from '@/config/terminal-themes';
|
||||
import { DEFAULT_FONT_VALUE } from '@/config/ui-font-options';
|
||||
@@ -102,7 +101,6 @@ interface TerminalPanelProps {
|
||||
type XTerminal = InstanceType<typeof import('@xterm/xterm').Terminal>;
|
||||
type XFitAddon = InstanceType<typeof import('@xterm/addon-fit').FitAddon>;
|
||||
type XSearchAddon = InstanceType<typeof import('@xterm/addon-search').SearchAddon>;
|
||||
type XWebLinksAddon = InstanceType<typeof import('@xterm/addon-web-links').WebLinksAddon>;
|
||||
|
||||
export function TerminalPanel({
|
||||
sessionId,
|
||||
@@ -285,8 +283,8 @@ export function TerminalPanel({
|
||||
// - CSI sequences: \x1b[...letter
|
||||
// - OSC sequences: \x1b]...ST
|
||||
// - Other escape sequences: \x1b followed by various characters
|
||||
// eslint-disable-next-line no-control-regex
|
||||
return text.replace(
|
||||
// eslint-disable-next-line no-control-regex
|
||||
/\x1b\[[0-9;]*[a-zA-Z]|\x1b\][^\x07]*\x07|\x1b[()][AB012]|\x1b[>=<]|\x1b[78HM]|\x1b#[0-9]|\x1b./g,
|
||||
''
|
||||
);
|
||||
@@ -670,8 +668,6 @@ export function TerminalPanel({
|
||||
while ((match = filePathRegex.exec(lineText)) !== null) {
|
||||
const fullMatch = match[1];
|
||||
const filePath = match[2];
|
||||
const lineNum = match[3] ? parseInt(match[3], 10) : undefined;
|
||||
const colNum = match[4] ? parseInt(match[4], 10) : undefined;
|
||||
|
||||
// Skip common false positives (URLs, etc.)
|
||||
if (
|
||||
|
||||
Reference in New Issue
Block a user