diff --git a/.eslintrc.json b/.eslintrc.json index 0c5c0a88..c53d24e2 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -2,8 +2,6 @@ "extends": ["prettier", "react-app", "react-app/jest"], "plugins": ["prettier"], "rules": { - "@typescript-eslint/no-unused-vars": "off", - "@typescript-eslint/no-redeclare": "off", "import/no-anonymous-default-export": "off", "curly": "warn", "no-console": [ diff --git a/src/components/ContextMenu.tsx b/src/components/ContextMenu.tsx index f8292c85..335f96a0 100644 --- a/src/components/ContextMenu.tsx +++ b/src/components/ContextMenu.tsx @@ -38,9 +38,11 @@ const ContextMenu = ({ options, onCloseRequest, top, left }: Props) => { className="context-menu" onContextMenu={(event) => event.preventDefault()} > - {options.map((option, idx) => ( + {options.map(({ action, label }, idx) => (
  • - +
  • ))} @@ -49,12 +51,6 @@ const ContextMenu = ({ options, onCloseRequest, top, left }: Props) => { ); }; -const ContextMenuOption = ({ label, action }: ContextMenuOption) => ( - -); - let contextMenuNode: HTMLDivElement; const getContextMenuNode = (): HTMLDivElement => { if (contextMenuNode) { diff --git a/src/global.d.ts b/src/global.d.ts index 193a78a8..c72b46e4 100644 --- a/src/global.d.ts +++ b/src/global.d.ts @@ -1,3 +1,4 @@ +// eslint-disable-next-line @typescript-eslint/no-unused-vars interface Document { fonts?: { ready?: Promise;