From fbc015873622d387c1d847b25b5ffe7cb807c14d Mon Sep 17 00:00:00 2001 From: Azgaar Date: Sun, 16 Jan 2022 19:49:20 +0300 Subject: [PATCH] seed history small style change --- index.html | 2 +- modules/ui/options.js | 16 +++++++--------- 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/index.html b/index.html index 4638c2fd..63c46386 100644 --- a/index.html +++ b/index.html @@ -947,7 +947,7 @@ - + Map seed diff --git a/modules/ui/options.js b/modules/ui/options.js index 912c6150..35645d14 100644 --- a/modules/ui/options.js +++ b/modules/ui/options.js @@ -288,18 +288,16 @@ function generateMapWithSeed(source) { } function showSeedHistoryDialog() { - const alert = mapHistory - .map(function (h, i) { - const created = new Date(h.created).toLocaleTimeString(); - const button = ``; - return `
${i + 1}. Seed: ${h.seed} ${button}. Size: ${h.width}x${h.height}. Template: ${h.template}. Created: ${created}
`; - }) - .join(""); - alertMessage.innerHTML = alert; + const lines = mapHistory.map((h, i) => { + const created = new Date(h.created).toLocaleTimeString(); + const button = ``; + return `
  • Seed: ${h.seed} ${button}. Size: ${h.width}x${h.height}. Template: ${h.template}. Created: ${created}
  • `; + }); + alertMessage.innerHTML = `
      ${lines.join("")}
    `; + $("#alert").dialog({ resizable: false, title: "Seed history", - width: fitContent(), position: {my: "center", at: "center", of: "svg"} }); }