Fixed Spacing

This commit is contained in:
Onyx Azryn 2020-10-10 09:40:48 -05:00
parent 34ed9af342
commit d44cca032e
17 changed files with 18 additions and 29 deletions

View file

@ -63,8 +63,8 @@ function moved() {
function showNotes(e, i) {
if (notesEditor.offsetParent) return;
let id = e.target.id || e.target.parentNode.id || e.target.parentNode.parentNode.id;
if (e.target.parentNode.parentNode.id === "burgLabels" || e.target.parentNode.parentNode.id === "burgIcons") id
= "burg" + e.target.dataset.id;
if (e.target.parentNode.parentNode.id === "burgLabels" || e.target.parentNode.parentNode.id === "burgIcons")
id = "burg" + e.target.dataset.id;
const note = notes.find(note => note.id === id);
if (note !== undefined && note.legend !== "") {

View file

@ -147,7 +147,7 @@ function editLake() {
toggleNewGroupInput();
document.getElementById("lakeGroupName").value = "";
}
function removeLakeGroup() {
const group = elSelected.node().parentNode.id;
if (["freshwater", "salt", "sinkhole", "frozen", "lava", "dry"].includes(group)) {
@ -190,4 +190,4 @@ function editLake() {
debug.select("#vertices").remove();
unselect();
}
}
}

View file

@ -274,4 +274,4 @@ function fitScaleBar() {
const bbox = scaleBar.select("rect").node().getBBox();
const x = rn(svgWidth * px - bbox.width + 10), y = rn(svgHeight * py - bbox.height + 20);
scaleBar.attr("transform", `translate(${x},${y})`);
}
}

View file

@ -114,7 +114,7 @@ function editNamesbase() {
const depth = rn(d3.mean(Object.keys(chain).map(key => chain[key].filter(c => c !== " ").length)));
const nonLatin = (string.match(/[^\u0000-\u007f]/g)||["none"]).join("");
const lengthStat =
const lengthStat =
l < 30 ? "<span style='color:red'>[not enough]</span>" :
l < 150 ? "<span style='color:darkred'>[low]</span>" :
l < 150 ? "<span style='color:orange'>[low]</span>" :
@ -122,13 +122,13 @@ function editNamesbase() {
l < 600 ? "<span style='color:orange'>[overmuch]</span>" :
"<span style='color:darkred'>[overmuch]</span>";
const rangeStat =
const rangeStat =
l < 10 ? "<span style='color:red'>[low]</span>" :
l < 15 ? "<span style='color:darkred'>[low]</span>" :
l < 20 ? "<span style='color:orange'>[low]</span>" :
"<span style='color:green'>[good]</span>";
const depthStat =
const depthStat =
l < 15 ? "<span style='color:red'>[low]</span>" :
l < 20 ? "<span style='color:darkred'>[low]</span>" :
l < 25 ? "<span style='color:orange'>[low]</span>" :

View file

@ -92,7 +92,7 @@ function editNotes(id, name) {
});
return;
}
highlightElement(element); // if element is found
}
@ -127,5 +127,4 @@ function editNotes(id, name) {
if (!notes.length) {$("#notesEditor").dialog("close"); return;}
editNotes(notes[0].id, notes[0].name);
}
}
}

View file

@ -861,4 +861,3 @@ function editProvinces() {
}
}

View file

@ -343,5 +343,4 @@ function editRegiment(selector) {
restoreDefaultEvents();
elSelected = null;
}
}
}

View file

@ -255,5 +255,4 @@ function editReliefIcon() {
unselect();
clearMainTip();
}
}

View file

@ -626,11 +626,10 @@ function editReligions() {
const name = getFileName("Religions") + ".csv";
downloadFile(data, name);
}
function closeReligionsEditor() {
debug.select("#religionCenters").remove();
exitReligionsManualAssignment("close");
exitAddReligionMode();
}
}
}

View file

@ -288,5 +288,4 @@ function editRiver(id) {
debug.select("#controlPoints").remove();
unselect();
}
}

View file

@ -171,5 +171,4 @@ function overviewRivers() {
rivers.selectAll("*").remove();
riversOverviewAddLines();
}
}

View file

@ -51,7 +51,7 @@ function editRoute(onClick) {
for (let i=0; i <= l; i += increment) {addControlPoint(node.getPointAtLength(i));}
routeLength.innerHTML = rn(l * distanceScaleInput.value) + " " + distanceUnitInput.value;
}
function addControlPoint(point) {
debug.select("#controlPoints").append("circle")
.attr("cx", point.x).attr("cy", point.y).attr("r", .8)
@ -219,7 +219,7 @@ function editRoute(onClick) {
if (routeSplit.classList.contains("pressed")) splitRoute(this);
else {this.remove(); redrawRoute();}
}
function splitRoute(clicked) {
lineGen.curve(d3.curveCatmullRom.alpha(.1));
const group = d3.select(elSelected.node().parentNode);

View file

@ -897,7 +897,7 @@ function editStates() {
body.querySelectorAll("div > input, select, span, svg").forEach(e => e.style.pointerEvents = "all");
if (statesAdd.classList.contains("pressed")) statesAdd.classList.remove("pressed");
}
function downloadStatesData() {
const unit = areaUnit.value === "square" ? distanceUnitInput.value + "2" : areaUnit.value;
let data = "Id,State,Form,Color,Capital,Culture,Type,Expansionism,Cells,Burgs,Area "+unit+",Total Population,Rural Population,Urban Population\n"; // headers

View file

@ -1119,4 +1119,4 @@ function updateFontOptions() {
opt.style.fontFamily = opt.innerHTML = font;
styleSelectFont.add(opt);
}
}
}

View file

@ -251,7 +251,4 @@ function editUnits() {
}
});
}
}

View file

@ -132,4 +132,4 @@ function editWorld() {
lock("latitude");
updateWorld();
}
}
}

View file

@ -406,5 +406,4 @@ function editZones() {
unfog("focusZone"+zone);
zonesEditorAddLines();
}
}