diff --git a/.eslintrc b/.eslintrc
index 767faaf..27ae785 100644
--- a/.eslintrc
+++ b/.eslintrc
@@ -6,16 +6,19 @@
],
"extends": [
"eslint:recommended",
- "plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
"plugin:react/recommended",
"prettier",
"prettier/@typescript-eslint"
],
"env": {
+ "browser": true,
"es6": true,
"jest": true
},
+ "globals": {
+ "chrome": true
+ },
"parserOptions": {
"ecmaVersion": 9,
"sourceType": "module"
diff --git a/src/panel/components/EvaluationsPanel.spec.tsx b/src/panel/components/EvaluationsPanel.spec.tsx
index cd2ef17..332abea 100644
--- a/src/panel/components/EvaluationsPanel.spec.tsx
+++ b/src/panel/components/EvaluationsPanel.spec.tsx
@@ -46,7 +46,7 @@ describe("EvaluationsPanel", () => {
it("should toggle string-wrap", () => {
const wrapper = shallow();
expect(wrapper.hasClass("string-wrap")).toBe(false);
- wrapper.find("[label='String Wrap']").invoke("onChange")({
+ wrapper.find("[label='String wrap']").invoke("onChange")({
target: {
checked: true,
},
diff --git a/src/panel/components/EvaluationsPanel.tsx b/src/panel/components/EvaluationsPanel.tsx
index 2c7aeff..14d3d4a 100644
--- a/src/panel/components/EvaluationsPanel.tsx
+++ b/src/panel/components/EvaluationsPanel.tsx
@@ -10,7 +10,6 @@ import classNames from "classnames";
import { PanelSelector } from "./PanelSelector";
import { useEvaluationsContext } from "../libs/EvaluationsContext";
import { PropList, PropItem } from "./PropList";
-import { Storage } from "../libs/Storage";
export function EvaluationsPanel(): React.ReactElement {
const {
@@ -52,12 +51,8 @@ export function EvaluationsPanel(): React.ReactElement {
const handleToggleLogs = React.useCallback(
(event: React.FormEvent) => {
savePreserveLogs((event.target as HTMLInputElement).checked);
- // Storage.setItem(
- // "preserveLogs",
- // (event.target as HTMLInputElement).checked
- // );
},
- []
+ [savePreserveLogs]
);
return (
@@ -89,7 +84,7 @@ export function EvaluationsPanel(): React.ReactElement {
/>
diff --git a/src/panel/components/TransformationsPanel.spec.tsx b/src/panel/components/TransformationsPanel.spec.tsx
index 2daa309..070780c 100644
--- a/src/panel/components/TransformationsPanel.spec.tsx
+++ b/src/panel/components/TransformationsPanel.spec.tsx
@@ -38,7 +38,7 @@ describe("TransformationsPanel", () => {
it("should toggle string-wrap", () => {
const wrapper = shallow();
expect(wrapper.hasClass("string-wrap")).toBe(false);
- wrapper.find("[label='String Wrap']").invoke("onChange")({
+ wrapper.find("[label='String wrap']").invoke("onChange")({
target: {
checked: true,
},
diff --git a/src/panel/components/TransformationsPanel.tsx b/src/panel/components/TransformationsPanel.tsx
index 034dc1b..c1df036 100644
--- a/src/panel/components/TransformationsPanel.tsx
+++ b/src/panel/components/TransformationsPanel.tsx
@@ -4,7 +4,6 @@ import classNames from "classnames";
import { PanelSelector } from "./PanelSelector";
import { useTransformationsContext } from "../libs/TransformationsContext";
import { PropItem } from "./PropList";
-import { Storage } from "../libs/Storage";
export function TransformationsPanel(): React.ReactElement {
const {
@@ -29,12 +28,8 @@ export function TransformationsPanel(): React.ReactElement {
const handleToggleLogs = React.useCallback(
(event: React.FormEvent) => {
savePreserveLogs((event.target as HTMLInputElement).checked);
- // Storage.setItem(
- // "preserveLogs",
- // (event.target as HTMLInputElement).checked
- // );
},
- []
+ [savePreserveLogs]
);
return (
@@ -60,7 +55,7 @@ export function TransformationsPanel(): React.ReactElement {
/>