diff options
-rw-r--r-- | guide-src/index.html | 2 | ||||
-rw-r--r-- | pugl.js | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/guide-src/index.html b/guide-src/index.html index c755491..0e765b4 100644 --- a/guide-src/index.html +++ b/guide-src/index.html @@ -41,7 +41,7 @@ you’ll get a nice <span style="color:#0cf">greenish blue</span> color! <p> <code>.pos</code> is itself a vector, so you can just throw it into the Buffer input: -<div><img src="ex-vector.png" alt=""> <img src="output-pos.png" alt="" height="32"></div> +<div><img src="ex-vector.png" alt=""> <img src="output-vector.png" alt="" height="32"></div> notice how the output is red on the right side of the screen (where the x component of <code>.pos</code> is high) and green at the top of the screen (where the y component of <code>.pos</code> is high). </p> @@ -2350,7 +2350,8 @@ function export_widgets_to_local_storage() { const widget_str = export_widgets(); code_input.value = widget_str; // re-read metadata so that having multiple tabs with pugl open isn't an issue - creation_metadata = JSON.parse(localStorage.getItem(`${APP_ID}-metadata`)); + const new_metadata = JSON.parse(localStorage.getItem(`${APP_ID}-metadata`)); + creation_metadata = new_metadata || {}; localStorage.setItem(`${APP_ID}-${creation_id}-description`, widget_str); creation_metadata[creation_id] = { lastViewed: Date.now(), |