mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2025-12-17 17:51:24 +01:00
feat: burg groups - save select choise
This commit is contained in:
parent
984d351e4d
commit
4185611791
2 changed files with 2 additions and 1 deletions
|
|
@ -305,7 +305,7 @@ function editBurgGroups() {
|
||||||
}
|
}
|
||||||
|
|
||||||
options.burgs.groups = lines.map(line => {
|
options.burgs.groups = lines.map(line => {
|
||||||
const inputs = line.querySelectorAll("input");
|
const inputs = line.querySelectorAll("input, select");
|
||||||
const group = Array.from(inputs).reduce((obj, input) => {
|
const group = Array.from(inputs).reduce((obj, input) => {
|
||||||
const value = parseInput(input);
|
const value = parseInput(input);
|
||||||
if (value !== null) obj[input.name] = value;
|
if (value !== null) obj[input.name] = value;
|
||||||
|
|
|
||||||
|
|
@ -164,6 +164,7 @@ void (function () {
|
||||||
input.required = options.required === false ? false : true;
|
input.required = options.required === false ? false : true;
|
||||||
input.placeholder = "type a " + type;
|
input.placeholder = "type a " + type;
|
||||||
input.value = options.default;
|
input.value = options.default;
|
||||||
|
input.style.width = promptText.length > 10 ? "100%" : "auto";
|
||||||
prompt.style.display = "block";
|
prompt.style.display = "block";
|
||||||
|
|
||||||
form.addEventListener(
|
form.addEventListener(
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue