diff --git a/thread/css/style.css b/thread/css/style.css index a985c29..d0c0652 100644 --- a/thread/css/style.css +++ b/thread/css/style.css @@ -104,6 +104,12 @@ section:hover { text-wrap: balance; } +.statusBoxWrapper, +.statusBoxWrapper:visited { + display: contents; + color: inherit; +} + #pageFooter { grid-row: 3; } \ No newline at end of file diff --git a/thread/js/main.js b/thread/js/main.js index 915bd8e..9a01c55 100644 --- a/thread/js/main.js +++ b/thread/js/main.js @@ -97,7 +97,16 @@ const threadUnroll = { statusArr.forEach(status => { //Only list posts from OP. if (statusArr[0].account.url == status.account.url) { + + var statusBoxWrapper = document.createElement("a"); + statusBoxWrapper.className = "statusBoxWrapper"; + statusBoxWrapper.href = status.url; + statusBoxWrapper.target = "_blank"; + statusBoxWrapper.rel = "noopener noreferrer"; + var statusBox = document.createElement("section"); + statusBoxWrapper.appendChild(statusBox); + statusBox.innerHTML = status.content; if (status.media_attachments) { @@ -132,7 +141,7 @@ const threadUnroll = { }); } - mb.appendChild(statusBox); + mb.appendChild(statusBoxWrapper); postCnt++; } });