From 8632d0f4e5c3e55c48c3dae4d0150763e97fab25 Mon Sep 17 00:00:00 2001 From: Abdullah Alfaraj Date: Sat, 31 Dec 2022 19:31:24 +0300 Subject: [PATCH] click an image from the history tab to reuse its seed --- index.html | 18 ++++++++++++++++-- index.js | 2 ++ 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/index.html b/index.html index c64bae6..c352b8a 100644 --- a/index.html +++ b/index.html @@ -151,7 +151,15 @@ display: flex; margin-left: auto; } - + .flexContainer{ + flex: 0 0 auto; + display: flex; + flex-direction: row; + } + #historySeedLabelContainer { + display: flex; + margin-left: auto; + } #menu-bar-container { width: 100%; @@ -249,7 +257,13 @@ v0.0.0
- history of all the images you generated +
+ + history of all the images you generated +
+ Seed:00000000000 +
+
diff --git a/index.js b/index.js index 04e5332..4d34bc7 100644 --- a/index.js +++ b/index.js @@ -1270,6 +1270,8 @@ document.getElementById('btnLoadHistory').addEventListener('click',async functio img.addEventListener('click',(e)=>{ const metadata_json = JSON.parse(e.target.dataset.metadata_json_string) console.log("metadata_json: ",metadata_json) + document.querySelector('#tiSeed').value = metadata_json.Seed + document.querySelector('#historySeedLabel').textContent = metadata_json.Seed }) i++ }