chore: lint

This commit is contained in:
karishmas6
2024-06-22 20:01:55 +05:30
parent 947c73c521
commit 2ab0e04b85
2 changed files with 7 additions and 7 deletions

View File

@@ -14,13 +14,13 @@ export const ScrapeSettings = forwardRef((props, ref) => {
return ( return (
<Stack direction="column"> <Stack direction="column">
<TextField <TextField
sx={{marginLeft: '15px', marginRight: '15px'}} sx={{ marginLeft: '15px', marginRight: '15px' }}
type="string" type="string"
label="Selector" label="Selector"
onChange={(e) => setSettings(e.target.value)} onChange={(e) => setSettings(e.target.value)}
/> />
<WarningText> <WarningText>
<InfoIcon color='warning'/> <InfoIcon color='warning' />
The scrape function uses heuristic algorithm to automatically scrape only important data from the page. The scrape function uses heuristic algorithm to automatically scrape only important data from the page.
If a selector is used it will scrape and automatically parse all available If a selector is used it will scrape and automatically parse all available
data inside of the selected element(s). data inside of the selected element(s).

View File

@@ -4,11 +4,11 @@ import InfoIcon from "@mui/icons-material/Info";
import { KeyValueForm } from "../KeyValueForm"; import { KeyValueForm } from "../KeyValueForm";
export const ScrapeSchemaSettings = forwardRef((props, ref) => { export const ScrapeSchemaSettings = forwardRef((props, ref) => {
const keyValueFormRef = useRef<{getObject: () => object}>(null); const keyValueFormRef = useRef<{ getObject: () => object }>(null);
useImperativeHandle(ref, () => ({ useImperativeHandle(ref, () => ({
getSettings() { getSettings() {
const settings = keyValueFormRef.current?.getObject() as Record<string,string> const settings = keyValueFormRef.current?.getObject() as Record<string, string>
return settings; return settings;
} }
})); }));
@@ -16,10 +16,10 @@ export const ScrapeSchemaSettings = forwardRef((props, ref) => {
return ( return (
<div> <div>
<WarningText> <WarningText>
<InfoIcon color='warning'/> <InfoIcon color='warning' />
The interpreter scrapes the data from a webpage into a "curated" table. The interpreter scrapes the data from a webpage into a "curated" table.
</WarningText> </WarningText>
<KeyValueForm ref={keyValueFormRef}/> <KeyValueForm ref={keyValueFormRef} />
</div> </div>
); );
}); });