From 41643ee5ac1b6c95ce451e3d3f39e5359aca2769 Mon Sep 17 00:00:00 2001 From: evolvedexperiment <55178666+evolvedexperiment@users.noreply.github.com> Date: Tue, 12 Nov 2019 21:31:53 +0200 Subject: [PATCH] Fix for province pattern painting bug and moved the color picker forward. (#362) * Fix for 3d heightmap / 3d view conflict * Fix for provinces painting patterns over color and color picker now in front of edit window --- index.css | 1 + modules/ui/provinces-editor.js | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/index.css b/index.css index 877f4e4e..ca01b962 100644 --- a/index.css +++ b/index.css @@ -43,6 +43,7 @@ input { #pickerContainer { position: absolute; + z-index: 100; } input, button, select, a, textarea { diff --git a/modules/ui/provinces-editor.js b/modules/ui/provinces-editor.js index 2d029218..a55f62bd 100644 --- a/modules/ui/provinces-editor.js +++ b/modules/ui/provinces-editor.js @@ -644,7 +644,7 @@ function editProvinces() { const provinceNew = +selected.dataset.id; const state = pack.provinces[provinceNew].state; const fill = pack.provinces[provinceNew].color || "#ffffff"; - const stroke = d3.color(fill).darker(.2).hex(); + const stroke = fill.startsWith("#") ? d3.color(fill).darker(.2).hex() : "#000000"; selection.forEach(i => { if (!pack.cells.state[i] || pack.cells.state[i] !== state) return;