remotes/1693045480750635534/spooky-22
Aevann1 2022-02-27 21:21:50 +02:00
parent 04be9ddd56
commit 77bc8d84b2
2 changed files with 22 additions and 28 deletions

View File

@ -915,4 +915,26 @@
<div id="viewmore-{{offset}}"><button id="viewbtn" class="btn btn-primary" onclick="viewmore({{pid}},'{{sort}}',{{offset}},{{ids}})">VIEW MORE COMMENTS</a></div>
{% endif %}
{% if not ajax and v and v.theme != 'transparent' %}
<script>
const color = window.getComputedStyle(document.body).getPropertyValue('background-color');
const markTemplate = (name) => {
return `<svg xmlns='http://www.w3.org/2000/svg' version='1.1' height='50px' width='100px'><text transform='translate(20, 40) rotate(-45)' fill='${color}' fill-opacity="0.1" font-size='20'>${name}</text></svg>`;
};
const base64Mark = btoa(markTemplate("{{v.id}}"));
const postt = document.getElementById("post-text")
if (postt)
postt.style.backgroundImage = `url("data:image/svg+xml;base64,${base64Mark}")`;
const x = document.getElementsByClassName("comment-text");
for (let i = 0; i < x.length; i++) {
x[i].style.backgroundImage = `url("data:image/svg+xml;base64,${base64Mark}")`;
}
</script>
{% endif %}
</body>

View File

@ -337,34 +337,6 @@
<script src="/static/assets/js/lite-youtube.js?a=240"></script>
{% if v and v.theme != 'transparent' %}
<style>
#sex {
position:fixed;
z-index:9999;
pointer-events: none;
top: 10%;
background-repeat: repeat;
height: 100vh;
width: 100vw;
}
</style>
<div id="sex"></div>
<script>
const color = window.getComputedStyle(document.body).getPropertyValue('background-color');
const markTemplate = (name) => {
return `<svg xmlns='http://www.w3.org/2000/svg' version='1.1' height='200px' width='200px'><text transform='translate(20, 100) rotate(-45)' fill='${color}' fill-opacity="0.05" font-size='60'>${name}</text></svg>`;
};
const base64Mark = btoa(markTemplate("{{v.id}}"));
document.getElementById("sex").style.backgroundImage = `url("data:image/svg+xml;base64,${base64Mark}")`;
</script>
{% endif %}
</body>
</html>