diff --git a/frontend/src/core/components/pageEditor/BulkSelectionPanel.tsx b/frontend/src/core/components/pageEditor/BulkSelectionPanel.tsx index 97ca4f6d4..81d474333 100644 --- a/frontend/src/core/components/pageEditor/BulkSelectionPanel.tsx +++ b/frontend/src/core/components/pageEditor/BulkSelectionPanel.tsx @@ -1,6 +1,5 @@ -import { useState, useEffect } from 'react'; +import { useState } from 'react'; import classes from '@app/components/pageEditor/bulkSelectionPanel/BulkSelectionPanel.module.css'; -import { parseSelectionWithDiagnostics } from '@app/utils/bulkselection/parseSelection'; import PageSelectionInput from '@app/components/pageEditor/bulkSelectionPanel/PageSelectionInput'; import SelectedPagesDisplay from '@app/components/pageEditor/bulkSelectionPanel/SelectedPagesDisplay'; import PageSelectionSyntaxHint from '@app/components/shared/PageSelectionSyntaxHint'; @@ -21,26 +20,9 @@ const BulkSelectionPanel = ({ displayDocument, onUpdatePagesFromCSV, }: BulkSelectionPanelProps) => { - const [syntaxError, setSyntaxError] = useState(null); const [advancedOpened, setAdvancedOpened] = useState(false); const maxPages = displayDocument?.pages?.length ?? 0; - - // Validate input syntax and show lightweight feedback - useEffect(() => { - const text = (csvInput || '').trim(); - if (!text) { - setSyntaxError(null); - return; - } - try { - const { warning } = parseSelectionWithDiagnostics(text, maxPages); - setSyntaxError(warning ? 'There is a syntax issue. See Page Selection tips for help.' : null); - } catch { - setSyntaxError('There is a syntax issue. See Page Selection tips for help.'); - } - }, [csvInput, maxPages]); - const handleClear = () => { setCsvInput(''); onUpdatePagesFromCSV('');