diff --git a/src/App.js b/src/App.js index 5358102..8918d36 100644 --- a/src/App.js +++ b/src/App.js @@ -20,7 +20,7 @@ document.addEventListener("DOMContentLoaded", (async () => { }, 10); })) -function Error() { +function WriteaError() { ModifyAppTitle() ProgressBar(100) return App.innerHTML = `An unknown error occured, check your browser console for more information.` diff --git a/src/components/sections/ReadSection.js b/src/components/sections/ReadSection.js index e37a1fc..de76a48 100644 --- a/src/components/sections/ReadSection.js +++ b/src/components/sections/ReadSection.js @@ -29,14 +29,15 @@ async function ReadSection() { }) .then(content => { setTimeout(() => { - document.querySelector('[writea="read.content"]').style.opacity = 0 + let ReadContent = document.getElementById('ReadContent') + ReadContent.style.opacity = 0 setTimeout(() => { content = PreRenderBlogFeatures(content) let MarkdownContainer = document.getElementById('MarkdownContainer') MarkdownContainer.innerHTML = marked.parse(content) hljs.highlightAll(document.getElementById('MarkdownContainer')) MarkdownContainer.innerHTML = PostRenderBlogFeatures(MarkdownContainer.innerHTML) - document.querySelector('[writea="read.content"]').style.opacity = 1 + ReadContent.style.opacity = 1 ProgressBar(100) }, 225) }, 200) @@ -65,7 +66,7 @@ async function ReadSection() { -
diff --git a/src/router/Import.js b/src/router/Import.js index f768379..4cedbc9 100644 --- a/src/router/Import.js +++ b/src/router/Import.js @@ -13,7 +13,7 @@ function Import(url, id, callback) { script.onerror = function() { console.error(`Failed to load script with id "${id}"`); - return Error(); + return WriteaError(); }; script.src = url;