replaced innerText with textContent and fixed themes

This commit is contained in:
MathMan05 2024-06-20 12:56:44 -05:00
parent 4e4c34454a
commit e5ead8a77e
13 changed files with 74 additions and 82 deletions

View file

@ -109,17 +109,17 @@ class channel{
const decdiv=document.createElement("div"); const decdiv=document.createElement("div");
const decoration=document.createElement("b"); const decoration=document.createElement("b");
decoration.innerText="▼" decoration.textContent="▼"
decdiv.appendChild(decoration) decdiv.appendChild(decoration)
const myhtml=document.createElement("p2"); const myhtml=document.createElement("p2");
myhtml.innerText=this.name; myhtml.textContent=this.name;
decdiv.appendChild(myhtml); decdiv.appendChild(myhtml);
caps.appendChild(decdiv); caps.appendChild(decdiv);
const childrendiv=document.createElement("div"); const childrendiv=document.createElement("div");
if(admin){ if(admin){
const addchannel=document.createElement("span"); const addchannel=document.createElement("span");
addchannel.innerText="+"; addchannel.textContent="+";
addchannel.classList.add("addchannel"); addchannel.classList.add("addchannel");
caps.appendChild(addchannel); caps.appendChild(addchannel);
addchannel.onclick=function(){ addchannel.onclick=function(){
@ -142,12 +142,12 @@ class channel{
childrendiv.classList.add("channels"); childrendiv.classList.add("channels");
setTimeout(_=>{childrendiv.style.height = childrendiv.scrollHeight + 'px';},100) setTimeout(_=>{childrendiv.style.height = childrendiv.scrollHeight + 'px';},100)
decdiv.onclick=function(){ decdiv.onclick=function(){
if(decoration.innerText==="▼"){// if(decoration.textContent==="▼"){//
decoration.innerText="▲"; decoration.textContent="▲";
//childrendiv.classList.add("colapsediv"); //childrendiv.classList.add("colapsediv");
childrendiv.style.height = '0px'; childrendiv.style.height = '0px';
}else{ }else{
decoration.innerText="▼"; decoration.textContent="▼";
//childrendiv.classList.remove("colapsediv") //childrendiv.classList.remove("colapsediv")
childrendiv.style.height = childrendiv.scrollHeight + 'px'; childrendiv.style.height = childrendiv.scrollHeight + 'px';
} }
@ -162,20 +162,20 @@ class channel{
if(admin){this.coatDropDiv(div,this);} if(admin){this.coatDropDiv(div,this);}
div.all=this; div.all=this;
const myhtml=document.createElement("span"); const myhtml=document.createElement("span");
myhtml.innerText=this.name; myhtml.textContent=this.name;
if(this.type===0){ if(this.type===0){
const decoration=document.createElement("b"); const decoration=document.createElement("b");
decoration.innerText="#" decoration.textContent="#"
div.appendChild(decoration) div.appendChild(decoration)
decoration.classList.add("space"); decoration.classList.add("space");
}else if(this.type===2){// }else if(this.type===2){//
const decoration=document.createElement("b"); const decoration=document.createElement("b");
decoration.innerText="🕪" decoration.textContent="🕪"
div.appendChild(decoration) div.appendChild(decoration)
decoration.classList.add("spacee"); decoration.classList.add("spacee");
}else if(this.type===5){// }else if(this.type===5){//
const decoration=document.createElement("b"); const decoration=document.createElement("b");
decoration.innerText="📣" decoration.textContent="📣"
div.appendChild(decoration) div.appendChild(decoration)
decoration.classList.add("spacee"); decoration.classList.add("spacee");
}else{ }else{
@ -344,7 +344,7 @@ class channel{
this.owner.owner.channelfocus=this.id; this.owner.owner.channelfocus=this.id;
this.putmessages(); this.putmessages();
history.pushState(null, null,"/channels/"+this.guild_id+"/"+this.id); history.pushState(null, null,"/channels/"+this.guild_id+"/"+this.id);
document.getElementById("channelname").innerText="#"+this.name; document.getElementById("channelname").textContent="#"+this.name;
} }
putmessages(){ putmessages(){
const out=this; const out=this;

View file

@ -18,7 +18,7 @@ class contextmenu{
intext.disabled=!thing[4](); intext.disabled=!thing[4]();
textb.button=intext; textb.button=intext;
intext.classList.add("contextbutton") intext.classList.add("contextbutton")
intext.innerText=thing[0] intext.textContent=thing[0]
textb.appendChild(intext) textb.appendChild(intext)
console.log(thing) console.log(thing)
intext.onclick=thing[1].bind(addinfo,obj); intext.onclick=thing[1].bind(addinfo,obj);

View file

@ -81,7 +81,7 @@ class group extends channel{
const div=document.createElement("div") const div=document.createElement("div")
div.classList.add("channeleffects"); div.classList.add("channeleffects");
const myhtml=document.createElement("span"); const myhtml=document.createElement("span");
myhtml.innerText=this.name; myhtml.textContent=this.name;
div.appendChild(this.user.buildpfp()); div.appendChild(this.user.buildpfp());
div.appendChild(myhtml); div.appendChild(myhtml);
div.myinfo=this; div.myinfo=this;
@ -95,7 +95,7 @@ class group extends channel{
this.owner.owner.channelfocus=this.id; this.owner.owner.channelfocus=this.id;
this.putmessages(); this.putmessages();
history.pushState(null, null,"/channels/"+this.guild_id+"/"+this.id); history.pushState(null, null,"/channels/"+this.guild_id+"/"+this.id);
document.getElementById("channelname").innerText="@"+this.name; document.getElementById("channelname").textContent="@"+this.name;
} }
messageCreate(messagep,focus){ messageCreate(messagep,focus){
const messagez=new cmessage(messagep.d,this); const messagez=new cmessage(messagep.d,this);
@ -137,12 +137,12 @@ class group extends channel{
} }
} }
if(this.hasunreads){ if(this.hasunreads){
if(current){current.noti.innerText=this.mentions;return;} if(current){current.noti.textContent=this.mentions;return;}
const div=document.createElement("div"); const div=document.createElement("div");
div.classList.add("servernoti"); div.classList.add("servernoti");
const noti=document.createElement("div"); const noti=document.createElement("div");
noti.classList.add("unread","notiunread","pinged"); noti.classList.add("unread","notiunread","pinged");
noti.innerText=this.mentions; noti.textContent=this.mentions;
console.log(this.mentions) console.log(this.mentions)
div.noti=noti; div.noti=noti;
div.append(noti) div.append(noti)

View file

@ -32,16 +32,16 @@ class embed{
embed.classList.add("embed"); embed.classList.add("embed");
div.append(embed); div.append(embed);
const title=document.createElement("h3"); const title=document.createElement("h3");
title.innerText=this.json.title; title.textContent=this.json.title;
embed.append(title); embed.append(title);
embed.append(document.createElement("br")); embed.append(document.createElement("br"));
for(const thing of this.json.fields){ for(const thing of this.json.fields){
const b=document.createElement("b"); const b=document.createElement("b");
b.innerText=thing.name; b.textContent=thing.name;
embed.append(b); embed.append(b);
embed.append(document.createElement("br")); embed.append(document.createElement("br"));
const p=document.createElement("p") const p=document.createElement("p")
p.innerText=thing.value; p.textContent=thing.value;
p.classList.add("embedp") p.classList.add("embedp")
embed.append(p); embed.append(p);
} }
@ -77,7 +77,7 @@ class embed{
const td=document.createElement("td"); const td=document.createElement("td");
const a=document.createElement("a"); const a=document.createElement("a");
a.href=this.json.url; a.href=this.json.url;
a.innerText=this.json.title; a.textContent=this.json.title;
td.append(a); td.append(a);
trtop.append(td); trtop.append(td);
} }
@ -96,7 +96,7 @@ class embed{
const bottomtr=document.createElement("tr"); const bottomtr=document.createElement("tr");
const td=document.createElement("td"); const td=document.createElement("td");
const span=document.createElement("span"); const span=document.createElement("span");
span.innerText=this.json.description; span.textContent=this.json.description;
td.append(span); td.append(span);
bottomtr.append(td); bottomtr.append(td);
table.append(bottomtr) table.append(bottomtr)
@ -112,15 +112,15 @@ class embed{
div.classList.add("embed"); div.classList.add("embed");
const providor=document.createElement("p"); const providor=document.createElement("p");
providor.classList.add("provider"); providor.classList.add("provider");
providor.innerText=this.json.provider.name; providor.textContent=this.json.provider.name;
div.append(providor); div.append(providor);
const a=document.createElement("a"); const a=document.createElement("a");
a.href=this.json.url; a.href=this.json.url;
a.innerText=this.json.title; a.textContent=this.json.title;
div.append(a); div.append(a);
const description=document.createElement("p"); const description=document.createElement("p");
description.innerText=this.json.description; description.textContent=this.json.description;
div.append(description); div.append(description);
{ {

View file

@ -54,7 +54,7 @@ class fullscreen{
div.appendChild(checkbox) div.appendChild(checkbox)
const label=document.createElement("span"); const label=document.createElement("span");
checkbox.value=array[2]; checkbox.value=array[2];
label.innerText=array[1]; label.textContent=array[1];
div.appendChild(label); div.appendChild(label);
checkbox.addEventListener("change",array[3]); checkbox.addEventListener("change",array[3]);
checkbox.type = "checkbox"; checkbox.type = "checkbox";
@ -66,8 +66,8 @@ class fullscreen{
const input = document.createElement('button'); const input = document.createElement('button');
const label=document.createElement("span"); const label=document.createElement("span");
input.innerText=array[2]; input.textContent=array[2];
label.innerText=array[1]; label.textContent=array[1];
div.appendChild(label); div.appendChild(label);
div.appendChild(input) div.appendChild(input)
input.addEventListener("click",array[3]); input.addEventListener("click",array[3]);
@ -79,7 +79,7 @@ class fullscreen{
const input=document.createElement("textarea"); const input=document.createElement("textarea");
input.value=array[2]; input.value=array[2];
const label=document.createElement("span"); const label=document.createElement("span");
label.innerText=array[1]; label.textContent=array[1];
input.addEventListener("input",array[3]); input.addEventListener("input",array[3]);
div.appendChild(label); div.appendChild(label);
div.appendChild(document.createElement("br")); div.appendChild(document.createElement("br"));
@ -93,7 +93,7 @@ class fullscreen{
input.value=array[2]; input.value=array[2];
input.type="text"; input.type="text";
const label=document.createElement("span"); const label=document.createElement("span");
label.innerText=array[1]; label.textContent=array[1];
console.log(array[3]) console.log(array[3])
input.addEventListener("input",array[3]); input.addEventListener("input",array[3]);
div.appendChild(label); div.appendChild(label);
@ -106,7 +106,7 @@ class fullscreen{
const input=document.createElement("input"); const input=document.createElement("input");
input.type="file"; input.type="file";
const label=document.createElement("span"); const label=document.createElement("span");
label.innerText=array[1]; label.textContent=array[1];
div.appendChild(label); div.appendChild(label);
div.appendChild(input); div.appendChild(input);
input.addEventListener("change",array[2]); input.addEventListener("change",array[2]);
@ -115,13 +115,13 @@ class fullscreen{
} }
case "text":{ case "text":{
const span =document.createElement("span"); const span =document.createElement("span");
span.innerText=array[1]; span.textContent=array[1];
return span; return span;
} }
case "title":{ case "title":{
const span =document.createElement("span"); const span =document.createElement("span");
span.classList.add("title") span.classList.add("title")
span.innerText=array[1]; span.textContent=array[1];
return span; return span;
} }
case "radio":{ case "radio":{
@ -140,7 +140,7 @@ class fullscreen{
} }
}); });
const legend=document.createElement("legend"); const legend=document.createElement("legend");
legend.innerText=array[1]; legend.textContent=array[1];
fieldset.appendChild(legend); fieldset.appendChild(legend);
let i=0; let i=0;
for(const thing of array[2]){ for(const thing of array[2]){
@ -157,7 +157,7 @@ class fullscreen{
label.appendChild(input); label.appendChild(input);
const span=document.createElement("span"); const span=document.createElement("span");
span.innerText=thing; span.textContent=thing;
label.appendChild(span); label.appendChild(span);
div.appendChild(label); div.appendChild(label);
fieldset.appendChild(div); fieldset.appendChild(div);
@ -174,12 +174,12 @@ class fullscreen{
const label=document.createElement("label"); const label=document.createElement("label");
const select=document.createElement("select"); const select=document.createElement("select");
label.innerText=array[1]; label.textContent=array[1];
div.append(label); div.append(label);
div.appendChild(select); div.appendChild(select);
for(const thing of array[2]){ for(const thing of array[2]){
const option = document.createElement("option"); const option = document.createElement("option");
option.innerText=thing; option.textContent=thing;
select.appendChild(option); select.appendChild(option);
} }
select.selectedIndex=array[4]; select.selectedIndex=array[4];
@ -201,7 +201,7 @@ class fullscreen{
for(const thing of array[1]){ for(const thing of array[1]){
const button=document.createElement("button"); const button=document.createElement("button");
button.innerText=thing[0]; button.textContent=thing[0];
td.appendChild(button); td.appendChild(button);

View file

@ -191,7 +191,7 @@ class guild{
for(const char of this.properties.name.split(" ")){ for(const char of this.properties.name.split(" ")){
build+=char[0]; build+=char[0];
} }
div.innerText=build; div.textContent=build;
div.classList.add("blankserver","servericon") div.classList.add("blankserver","servericon")
divy.appendChild(div) divy.appendChild(div)
div.onclick=()=>{ div.onclick=()=>{

View file

@ -207,16 +207,16 @@ function buildprofile(x,y,user,type="author"){
userbody.classList.add("infosection"); userbody.classList.add("infosection");
div.appendChild(userbody); div.appendChild(userbody);
const usernamehtml=document.createElement("h2"); const usernamehtml=document.createElement("h2");
usernamehtml.innerText=nickname; usernamehtml.textContent=nickname;
userbody.appendChild(usernamehtml); userbody.appendChild(usernamehtml);
const discrimatorhtml=document.createElement("h3"); const discrimatorhtml=document.createElement("h3");
discrimatorhtml.classList.add("tag"); discrimatorhtml.classList.add("tag");
discrimatorhtml.innerText=username+"#"+discriminator; discrimatorhtml.textContent=username+"#"+discriminator;
userbody.appendChild(discrimatorhtml) userbody.appendChild(discrimatorhtml)
const pronounshtml=document.createElement("p"); const pronounshtml=document.createElement("p");
pronounshtml.innerText=pronouns; pronounshtml.textContent=pronouns;
pronounshtml.classList.add("pronouns"); pronounshtml.classList.add("pronouns");
userbody.appendChild(pronounshtml) userbody.appendChild(pronounshtml)
@ -360,10 +360,10 @@ function createunknown(fname,fsize,src){
if(src){ if(src){
const a=document.createElement("a"); const a=document.createElement("a");
a.href=src; a.href=src;
a.innerText=fname; a.textContent=fname;
nametd.append(a); nametd.append(a);
}else{ }else{
nametd.innerText=fname; nametd.textContent=fname;
} }
nametd.classList.add("filename"); nametd.classList.add("filename");
@ -371,7 +371,7 @@ function createunknown(fname,fsize,src){
const sizetr=document.createElement("tr"); const sizetr=document.createElement("tr");
const size=document.createElement("td"); const size=document.createElement("td");
sizetr.append(size); sizetr.append(size);
size.innerText="Size:"+filesizehuman(fsize); size.textContent="Size:"+filesizehuman(fsize);
size.classList.add("filesize"); size.classList.add("filesize");
div.appendChild(sizetr) div.appendChild(sizetr)
return div; return div;
@ -503,7 +503,7 @@ if(mobile){
document.getElementById("servertd").classList.add("collapse"); document.getElementById("servertd").classList.add("collapse");
document.getElementById("servers").classList.add("collapse"); document.getElementById("servers").classList.add("collapse");
} }
document.getElementById("mobileback").innerText="#"; document.getElementById("mobileback").textContent="#";
document.getElementById("mobileback").onclick=function(){ document.getElementById("mobileback").onclick=function(){
document.getElementById("channels").parentNode.classList.remove("collapse"); document.getElementById("channels").parentNode.classList.remove("collapse");
document.getElementById("servertd").classList.remove("collapse"); document.getElementById("servertd").classList.remove("collapse");

View file

@ -239,9 +239,9 @@ class localuser{
this.buildservers(); this.buildservers();
} }
loaduser(){ loaduser(){
document.getElementById("username").innerText=this.user.username document.getElementById("username").textContent=this.user.username
document.getElementById("userpfp").src=this.user.getpfpsrc() document.getElementById("userpfp").src=this.user.getpfpsrc()
document.getElementById("status").innerText=this.status; document.getElementById("status").textContent=this.status;
} }
isAdmin(){ isAdmin(){
return this.lookingguild.isAdmin(); return this.lookingguild.isAdmin();
@ -252,7 +252,7 @@ class localuser{
guild=this.guildids["@me"]; guild=this.guildids["@me"];
} }
this.lookingguild=guild; this.lookingguild=guild;
document.getElementById("serverName").innerText=guild.properties.name; document.getElementById("serverName").textContent=guild.properties.name;
//console.log(this.guildids,id) //console.log(this.guildids,id)
document.getElementById("channels").innerHTML=""; document.getElementById("channels").innerHTML="";
document.getElementById("channels").appendChild(guild.getHTML()); document.getElementById("channels").appendChild(guild.getHTML());
@ -262,7 +262,7 @@ class localuser{
const serverlist=document.getElementById("servers");// const serverlist=document.getElementById("servers");//
const div=document.createElement("div"); const div=document.createElement("div");
div.innerText="⌂"; div.textContent="⌂";
div.classList.add("home","servericon") div.classList.add("home","servericon")
div.all=this.guildids["@me"]; div.all=this.guildids["@me"];
serverlist.appendChild(div) serverlist.appendChild(div)
@ -293,7 +293,7 @@ class localuser{
br.id="bottomseperator"; br.id="bottomseperator";
const div=document.createElement("div"); const div=document.createElement("div");
div.innerText="+"; div.textContent="+";
div.classList.add("addserver","servericon") div.classList.add("addserver","servericon")
serverlist.appendChild(div) serverlist.appendChild(div)
div.onclick=_=>{ div.onclick=_=>{
@ -337,7 +337,7 @@ class localuser{
}).then(r=>r.json()).then(_=>{ }).then(r=>r.json()).then(_=>{
console.log(_); console.log(_);
if(_.message){ if(_.message){
error.innerText=_.message; error.textContent=_.message;
} }
}) })
} }
@ -450,7 +450,7 @@ class localuser{
console.log(typingtext.classList); console.log(typingtext.classList);
if(showing){ if(showing){
typingtext.classList.remove("hidden"); typingtext.classList.remove("hidden");
document.getElementById("typingtext").innerText=build; document.getElementById("typingtext").textContent=build;
}else{ }else{
typingtext.classList.add("hidden"); typingtext.classList.add("hidden");
} }

View file

@ -89,26 +89,26 @@ const instancein=document.getElementById("instancein");
let timeout=0; let timeout=0;
async function checkInstance(e){ async function checkInstance(e){
try{ try{
verify.innerText="Checking Instance"; verify.textContent="Checking Instance";
instanceinfo=await setInstance(instancein.value); instanceinfo=await setInstance(instancein.value);
localStorage.setItem("instanceinfo",JSON.stringify(instanceinfo)); localStorage.setItem("instanceinfo",JSON.stringify(instanceinfo));
verify.innerText="Instance is all good" verify.textContent="Instance is all good"
if(checkInstance.alt){checkInstance.alt();} if(checkInstance.alt){checkInstance.alt();}
setTimeout(_=>{ setTimeout(_=>{
console.log(verify.innerText) console.log(verify.textContent)
verify.innerText=""; verify.textContent="";
},3000); },3000);
}catch(e){ }catch(e){
console.log("catch") console.log("catch")
verify.innerText="Invalid Instance, try again" verify.textContent="Invalid Instance, try again"
} }
} }
if(instancein){ if(instancein){
console.log(instancein) console.log(instancein)
instancein.addEventListener("keydown",e=>{ instancein.addEventListener("keydown",e=>{
const verify=document.getElementById("verify"); const verify=document.getElementById("verify");
verify.innerText="Waiting to check Instance" verify.textContent="Waiting to check Instance"
clearTimeout(timeout); clearTimeout(timeout);
timeout=setTimeout(checkInstance,1000); timeout=setTimeout(checkInstance,1000);
}); });
@ -179,7 +179,7 @@ async function check(e){
e.preventDefault(); e.preventDefault();
let h=await login(e.srcElement[1].value,e.srcElement[2].value); let h=await login(e.srcElement[1].value,e.srcElement[2].value);
document.getElementById("wrong").innerText=h; document.getElementById("wrong").textContent=h;
console.log(h); console.log(h);
} }
if(document.getElementById("form")){ if(document.getElementById("form")){

View file

@ -118,7 +118,7 @@ function markdown(txt,keep=false){
} }
if(count!==3){ if(count!==3){
const samp=document.createElement("samp"); const samp=document.createElement("samp");
samp.innerText=build; samp.textContent=build;
span.appendChild(samp); span.appendChild(samp);
}else{ }else{
const pre=document.createElement("pre"); const pre=document.createElement("pre");
@ -128,7 +128,7 @@ function markdown(txt,keep=false){
if(txt[i]==="\n"){ if(txt[i]==="\n"){
i++ i++
} }
pre.innerText=build; pre.textContent=build;
span.appendChild(pre); span.appendChild(pre);
} }
i--; i--;
@ -305,7 +305,7 @@ function markdown(txt,keep=false){
continue; continue;
} }
} }
current.innerText+=txt[i]; current.textContent+=txt[i];
} }
appendcurrent(); appendcurrent();
return span; return span;

View file

@ -82,7 +82,7 @@ class cmessage{
minipfp.src=author.getpfpsrc() minipfp.src=author.getpfpsrc()
profileclick(minipfp,author) profileclick(minipfp,author)
username.innerText=author.username; username.textContent=author.username;
profileclick(username,author) profileclick(username,author)
}); });
div.appendChild(replyline); div.appendChild(replyline);
@ -124,17 +124,17 @@ class cmessage{
const username=document.createElement("span"); const username=document.createElement("span");
username.classList.add("username") username.classList.add("username")
profileclick(username,this.author); profileclick(username,this.author);
username.innerText=this.author.username; username.textContent=this.author.username;
const userwrap=document.createElement("tr") const userwrap=document.createElement("tr")
userwrap.appendChild(username) userwrap.appendChild(username)
if(this.author.bot){ if(this.author.bot){
const username=document.createElement("span"); const username=document.createElement("span");
username.classList.add("bot") username.classList.add("bot")
username.innerText="BOT"; username.textContent="BOT";
userwrap.appendChild(username) userwrap.appendChild(username)
} }
const time=document.createElement("span"); const time=document.createElement("span");
time.innerText=" "+formatTime(new Date(this.timestamp)); time.textContent=" "+formatTime(new Date(this.timestamp));
time.classList.add("timestamp") time.classList.add("timestamp")
userwrap.appendChild(time); userwrap.appendChild(time);
@ -186,12 +186,12 @@ class cmessage{
const messaged=document.createElement("p"); const messaged=document.createElement("p");
div.txt=messaged; div.txt=messaged;
messaged.innerText="welcome: "+this.author.username; messaged.textContent="welcome: "+this.author.username;
const messagedwrap=document.createElement("tr") const messagedwrap=document.createElement("tr")
messagedwrap.appendChild(messaged); messagedwrap.appendChild(messaged);
const time=document.createElement("span"); const time=document.createElement("span");
time.innerText=" "+formatTime(new Date(this.timestamp)); time.textContent=" "+formatTime(new Date(this.timestamp));
time.classList.add("timestamp"); time.classList.add("timestamp");
messagedwrap.append(time); messagedwrap.append(time);

View file

@ -8,7 +8,7 @@ async function registertry(e){
const email=elements[1].value; const email=elements[1].value;
const username=elements[2].value; const username=elements[2].value;
if(elements[3].value!==elements[4].value){ if(elements[3].value!==elements[4].value){
document.getElementById("wrong").innerText="Passwords don't match"; document.getElementById("wrong").textContent="Passwords don't match";
return; return;
} }
const password=elements[3].value; const password=elements[3].value;
@ -31,14 +31,14 @@ async function registertry(e){
e.json().then(e=>{ e.json().then(e=>{
if(!e.token){ if(!e.token){
console.log(e); console.log(e);
document.getElementById("wrong").innerText=e.errors[Object.keys(e.errors)[0]]._errors[0].message; document.getElementById("wrong").textContent=e.errors[Object.keys(e.errors)[0]]._errors[0].message;
}else{ }else{
localStorage.setItem("token",e.token); localStorage.setItem("token",e.token);
window.location.href = '/channels/@me'; window.location.href = '/channels/@me';
} }
}) })
}) })
//document.getElementById("wrong").innerText=h; //document.getElementById("wrong").textContent=h;
// console.log(h); // console.log(h);
} }
let TOSa=document.getElementById("TOSa"); let TOSa=document.getElementById("TOSa");
@ -50,7 +50,7 @@ async function tosLogic(){
TOSa=document.getElementById("TOSa"); TOSa=document.getElementById("TOSa");
TOSa.href=tosPage; TOSa.href=tosPage;
}else{ }else{
document.getElementById("TOSbox").innerText="This instance has no TOS, accept TOS anyways:"; document.getElementById("TOSbox").textContent="This instance has no TOS, accept TOS anyways:";
TOSa=null; TOSa=null;
} }
console.log(tosPage); console.log(tosPage);

View file

@ -46,11 +46,9 @@
} }
.WHITE-theme { .WHITE-theme {
color-scheme: light; color-scheme: light;
--primary-text: #000; --primary-text: #000;
--primary-bg: #FFF; --primary-bg: #FFF;
--black: #FFF; --black: #FFF;
--message-bg-hover: #dedee2; --message-bg-hover: #dedee2;
--typing-bg: #dad8d8; --typing-bg: #dad8d8;
--timestamp-color: #929297; --timestamp-color: #929297;
@ -68,32 +66,25 @@
--filename: #47bbff; --filename: #47bbff;
--mention-bg: #F00; --mention-bg: #F00;
--pronouns: #6a6a6d; --pronouns: #6a6a6d;
--profile-bg: #cacad8; --profile-bg: #cacad8;
--profile-info-bg: #bbbbce; --profile-info-bg: #bbbbce;
--server-border: #bebed3; --server-border: #bebed3;
--server-bg: #c0c0d4; --server-bg: #c0c0d4;
--reply-border: #b1b2bd; --reply-border: #b1b2bd;
--reply-bg: #d4d6e9; --reply-bg: #d4d6e9;
--reply-text: #2e2e30; --reply-text: #2e2e30;
--spoiler-hover: #b9b9b9; --spoiler-hover: #b9b9b9;
--spoiler-open-bg: #dadada; --spoiler-open-bg: #dadada;
--unknown-file-bg: #bdbdbd; --unknown-file-bg: #bdbdbd;
--unknown-file-border: #adadad; --unknown-file-border: #adadad;
--login-border: #c3c0e0; --login-border: #c3c0e0;
--loading-bg: #b5b7cc; --loading-bg: #b5b7cc;
--dialog-bg: #c1c8d6; --dialog-bg: #c1c8d6;
--dialog-border: #b9b7db; --dialog-border: #b9b7db;
--scrollbar-track: #d5d1e2; --scrollbar-track: #d5d1e2;
--scrollbar-thumb: #b0afc0; --scrollbar-thumb: #b0afc0;
--scrollbar-thumb-hover: #a5a5b8; --scrollbar-thumb-hover: #a5a5b8;
--embed: #cdccd1;
} }
.Light-theme { .Light-theme {
color-scheme: light; color-scheme: light;
@ -144,4 +135,5 @@
--scrollbar-track: #d2cedf; --scrollbar-track: #d2cedf;
--scrollbar-thumb: #bdbcca; --scrollbar-thumb: #bdbcca;
--scrollbar-thumb-hover: #a7a7be; --scrollbar-thumb-hover: #a7a7be;
--embed: #cdccd1;
} }