From 04c28aed6c3554a2c5139222ef623bfeb3de2a63 Mon Sep 17 00:00:00 2001 From: Kelsey Gilbert Date: Wed, 7 Aug 2024 17:37:05 -0700 Subject: [PATCH] [colors/icc-profile-editor] Expandable log. 'Ready!' notification after page load. --- colors/icc-profile-editor.html | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/colors/icc-profile-editor.html b/colors/icc-profile-editor.html index e8e5fe0..f2d3f49 100644 --- a/colors/icc-profile-editor.html +++ b/colors/icc-profile-editor.html @@ -14,7 +14,10 @@
Log -

+         
+ +

+         

@@ -1331,7 +1334,8 @@

} function log(line) { - e_log.textContent = `[@ ${performance.now()} ms] ${line}\n` + e_log.textContent; + e_log_body.textContent = e_log_tip.textContent + '\n' + e_log_body.textContent; + e_log_tip.textContent = `[@ ${performance.now()} ms] ${line}`; } @@ -1351,8 +1355,8 @@

log(`Importing...`); const profile = IccProfile.from_bytes(bytes); - log(`Open successful.`); console.log({profile}); + log(`Loading UI...`); // - @@ -1498,7 +1502,10 @@

} ); + log(`Refreshing...`); profile.edn.signal('refresh', 'self'); + + log(`Open succeeded.`); }); async function serialize_to_bytes() { @@ -1525,11 +1532,13 @@

const bytes = await serialize_to_bytes(); const file_name = e_file_name.value || 'profile.icc'; - log(`Saving to '${file_name}...'`); + log(`Saving '${file_name}...'`); const ICC_PROFILE_MIME = 'application/vnd.iccprofile'; const blob = new Blob([bytes], {type: ICC_PROFILE_MIME}); download_blob(file_name, blob); }); + +log('Ready!');