This commit is contained in:
Guillem George 2026-05-16 18:18:56 +02:00
parent 3d1a427dcf
commit 1e4cd71e06
5 changed files with 14 additions and 3 deletions

View file

@ -6,6 +6,8 @@
// - toggleTooltip (toggle the tooltip and display the pixel's information)
import $ from "jquery";
import { getPixelInfo } from "./index";
import { room } from "../../pages/index";
const canvasContainer = $("#canvas-container")?.[0];
const canvas = $("#canvas")?.[0];
@ -60,6 +62,10 @@ export const toggleTooltip = async (state = false) => {
if (state) {
// FIXME: You should implement or call a function to get the pixel's information
// and display it. Make use of target.x and target.y to get the pixel's position.
const response = await getPixelInfo(room, target.x, target.y);
if (!response) {
return;
}
}
};