mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2025-12-22 12:01:23 +01:00
markers - generate tool + lock tooltip
This commit is contained in:
parent
fae03b599f
commit
b3e0d5e7b1
6 changed files with 914 additions and 0 deletions
|
|
@ -74,8 +74,13 @@ function showElementLockTip(event) {
|
|||
}
|
||||
}
|
||||
|
||||
<<<<<<< HEAD
|
||||
const onMouseMove = debounce(handleMouseMove, 100);
|
||||
function handleMouseMove() {
|
||||
=======
|
||||
const moved = debounce(mouseMove, 100);
|
||||
function mouseMove() {
|
||||
>>>>>>> 01fbfca0 (markers - generate tool + lock tooltip)
|
||||
const point = d3.mouse(this);
|
||||
const i = findCell(point[0], point[1]); // pack cell id
|
||||
if (i === undefined) return;
|
||||
|
|
@ -121,11 +126,15 @@ function showMapTooltip(point, e, i, g) {
|
|||
if (group === "emblems" && e.target.tagName === "use") {
|
||||
const parent = e.target.parentNode;
|
||||
const [g, type] =
|
||||
<<<<<<< HEAD
|
||||
parent.id === "burgEmblems"
|
||||
? [pack.burgs, "burg"]
|
||||
: parent.id === "provinceEmblems"
|
||||
? [pack.provinces, "province"]
|
||||
: [pack.states, "state"];
|
||||
=======
|
||||
parent.id === "burgEmblems" ? [pack.burgs, "burg"] : parent.id === "provinceEmblems" ? [pack.provinces, "province"] : [pack.states, "state"];
|
||||
>>>>>>> 01fbfca0 (markers - generate tool + lock tooltip)
|
||||
const i = +e.target.dataset.i;
|
||||
if (event.shiftKey) highlightEmblemElement(type, g[i]);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue