diff --git a/src/pages/Editor.tsx b/src/pages/Editor.tsx
index 0b4d560..8927e6b 100644
--- a/src/pages/Editor.tsx
+++ b/src/pages/Editor.tsx
@@ -823,7 +823,6 @@ function EditorPage({
diff --git a/src/pages/HomePage.tsx b/src/pages/HomePage.tsx
index b227ec9..57bacb5 100644
--- a/src/pages/HomePage.tsx
+++ b/src/pages/HomePage.tsx
@@ -74,19 +74,19 @@ function homePageStateReducer(
): HomePageState {
switch (action.type) {
case HomePageStateActionKind.UPDATE_TACTICS:
- return { ...state!, tactics: action.tactics }
+ return { ...state, tactics: action.tactics }
case HomePageStateActionKind.UPDATE_TEAMS:
- return { ...state!, teams: action.teams }
+ return { ...state, teams: action.teams }
case HomePageStateActionKind.SET_EXPORTING_TACTIC:
- return { ...state!, exportingTacticId: action.tacticId }
+ return { ...state, exportingTacticId: action.tacticId }
case HomePageStateActionKind.ADD_TACTIC:
- return { ...state!, tactics: [action.tactic, ...state.tactics] }
+ return { ...state, tactics: [action.tactic, ...state.tactics] }
case HomePageStateActionKind.REMOVE_TACTIC:
- return { ...state!, tactics: state.tactics.filter(t => t.id !== action.tacticId) }
+ return { ...state, tactics: state.tactics.filter(t => t.id !== action.tacticId) }
case HomePageStateActionKind.INIT:
return action.state
@@ -147,7 +147,6 @@ export default function HomePage() {
)
}
diff --git a/src/pages/VisualizerPage.tsx b/src/pages/VisualizerPage.tsx
index f27e7ad..37c0487 100644
--- a/src/pages/VisualizerPage.tsx
+++ b/src/pages/VisualizerPage.tsx
@@ -202,7 +202,6 @@ function VisualizerPageContent({
diff --git a/src/pages/popup/ExportTacticPopup.tsx b/src/pages/popup/ExportTacticPopup.tsx
index e89dbe3..0009634 100644
--- a/src/pages/popup/ExportTacticPopup.tsx
+++ b/src/pages/popup/ExportTacticPopup.tsx
@@ -10,13 +10,11 @@ import { loadPlainTactic } from "../../domains/TacticPersistenceDomain.ts"
export interface ExportTacticPopupProps {
service: TacticService
- show: boolean
onHide: () => void
}
export default function ExportTacticPopup({
service,
- show,
onHide,
}: ExportTacticPopupProps) {
const [context, setContext] = useState()
@@ -46,8 +44,6 @@ export default function ExportTacticPopup({
return () => window.removeEventListener("keyup", onKeyUp)
}, [onHide])
- if (!show) return <>>
-
if (panicMessage) return {panicMessage}
return (
@@ -68,7 +64,7 @@ export default function ExportTacticPopup({
)
setExportPercentage(0)
}}>
- Export in JSON
+ Exporter en JSON
@@ -87,7 +83,7 @@ async function exportInJson(
const e = document.createElement("a")
e.setAttribute(
"href",
- "data:application/octet-stream," +
+ "data:application/json;charset=utf-8," +
encodeURIComponent(JSON.stringify(tactic, null, 2)),
)
e.setAttribute("download", `${context.name}.json`)
diff --git a/src/style/actions/arrow_action.css b/src/style/actions/arrow_action.css
index 77bfa4c..097a207 100644
--- a/src/style/actions/arrow_action.css
+++ b/src/style/actions/arrow_action.css
@@ -5,7 +5,7 @@
.arrow-action-icon {
user-select: none;
-moz-user-select: none;
- -webkit-user-drag: none;
+ pointer-events: none;
max-width: 17px;
max-height: 17px;
}
diff --git a/vite.config.ts b/vite.config.ts
index c0758f7..9f40c89 100644
--- a/vite.config.ts
+++ b/vite.config.ts
@@ -8,6 +8,7 @@ import { visualizer } from "rollup-plugin-visualizer"
export default defineConfig({
build: {
target: "es2021",
+ cssTarget: ["chrome112"]
},
test: {
environment: "jsdom",