feat(svelte): cleanup styling, use css variables

This commit is contained in:
moklick
2023-06-06 19:44:39 +02:00
parent 32ddd6fac9
commit 98d9d3e51a
20 changed files with 190 additions and 101 deletions

View File

@@ -130,8 +130,8 @@ function MiniMap({
const onSvgClick = onClick
? (event: MouseEvent) => {
const rfCoord = minimapInstance.current?.pointer(event);
onClick(event, { x: rfCoord?.[0] ?? 0, y: rfCoord?.[1] ?? 0 });
const [x, y] = minimapInstance.current?.pointer(event) || [0, 0];
onClick(event, { x, y });
}
: undefined;