Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //Lingo
- let create= (x)=> document.createElement(x),
- select= (x,y=document)=> y.querySelector(x),
- selectAll= (x,y=document)=> y.querySelectorAll(x);
- let a= selectAll("a"),
- b= window.open(),
- c= create("textarea");
- c.style.cssText= `width: 100vw;
- min-height: 100vh;
- padding:5px;
- border:2px double blue;`;
- b.document.body.append(c);
- let ok= [...a].map(i=>{
- if(i.href.includes("programmas/lingo/")&&
- i.textContent.includes("aflevering")){
- return i.textContent.replace("Seizoen 3, aflevering","")+"] "+ i.href;
- }
- });
- c.value= ok.join("\n");
- //New window-----
- let a= create("textarea");
- b= window.open();
- b.document.body.append(a);
- a.style.cssText= `
- min-height:100vh;
- min-width:100vw;
- border: 5px ridge darkgray;
- padding: 5px;
- background: black;
- color: white`;
- let final= [];
- select("textarea").onkeyup= function(){
- a.value="";
- a.value= final.join("\n");
- };
- //------------------
- let create= (x)=> document.createElement(x),
- select= (x,y=document)=> y.querySelector(x),
- selectAll= (x,y=document)=> y.querySelectorAll(x);
- let a= create("textarea"),
- b= window.open();
- b.document.body.append(a);
- a.style.cssText= `
- min-height:100vh;
- min-width:100vw;
- border: 5px ridge darkgray;
- padding: 5px;
- background: black;
- color: white`;
- let lyrics=
- `main yahaan tu wahaan, zindagi hai kahaan
- I’m here you’re there, where is life?
- Tu hi tu hai sanam, dekhtaa hoon jahaan
- wherever I look, I see you my love
- neend aati nahin yaad jaati nahin
- can't sleepm the memories just won't go away
- bin tere ab jiya jaaye na
- Without you, living is becoming impossible
- main yahaan tu wahaan, zindagi hai kahaan
- I’m here you’re there, where is life?
- waqt jaise thahar gaya hai yehin, har taraf ek ajab udaasi hai
- as if time has stopped at the moment, there’s a strange sadness everywhere
- beqaraari ka aisa aalam hai,jism tanhaa hai ruuh pyaasi hai
- it's the time of restlessness, my body is lonely and soul is thirsty
- teri suurat ab ek pal, kyun nazar se hat-ti nahin?
- Why can't I see anything other than your face, even for a single moment?
- raat din to kat jaate hain, umr tanhaa kat-ti nahin
- Day and night pass shomehow, but this lonely life doesn't
- chaah ke bhi na kuchh kah sakuun tujhse main
- even though I want to, I can’t tell you anything
- dard kaise karuun main bayaan?
- How should I voice my pain?
- main yahaan tu wahaan, zindagi hai kahaan
- I’m here you’re there, where is life?
- jab kahin bhi aahat hui, yun lagaa ki tu aa gaya
- whenever I heard a sound somewhere, I thought it was yu.
- khushbuu ke jhonke ki tarah, meri saansein mahaka gaya
- Like a gust of fragrance, it scented my breath
- ek voh daur tha ham sadaa paas the
- there was that time when we were always together
- ab to hain faasale darmiyaan
- Now there’s such a distance between us
- main yahaan tu wahaan, zindagi hai kahaan
- I’m here you’re there, where is life?
- biti baatein yaad aati hain, jab akela hota hoon main
- Memories of the past come up, when I’m all alone
- bolti khaamoshiyaan, sabse chhupke rota huun main
- The silence speaks, while I hide and cry
- ek arsaa huwaa muskuraaye hue
- it's been so long since I smiled last
- aansuuyon mein dhali daastaan
- our story is filled with tears
- main yahaan tu wahaan, zindagi hai kahaan
- I’m here you’re there, where is life?
- Tu hi tu hai sanam, dekhtaa hoon jahaan
- wherever I look, I see you my love
- neend aati nahin yaad jaati nahin
- can't sleepm the memories just won't go away
- bin tere ab jiya jaaye na
- Without you, living iss becoming impossible
- ok
- `;
- let x= lyrics.toLowerCase().split("\n");
- let final= [];
- select("textarea").onkeyup= function(){
- x.forEach((i,xo)=>{
- if(xo % 2 === 0) final.push(`<span class="hi">${x[xo]}</span>`);
- else final.push(`<span class="en">${x[xo]}</span>`);
- });
- a.value="";
- a.value= final.join("\n");
- };
- //-------
- let $=x=>document.createElement(x);
- let a= $("div"),
- b= $("textarea"),
- c= $("span");
- d= $("span");
- document.body.append(a);
- a.append(b,c,d);
- d.innerHTML= "×";
- document.body.style.position= "relative";
- d.style.cssText= `position:absolute;
- z-index:2;top:250px; right:250px;font-size:40px; color:red;`;
- d.onclick=()=>{
- d.classList.toggle("hidden");
- if(d.classList.contains("hidden")){
- [b,c].forEach(i=>{
- i.style.display= "none";
- i.style.pointerEvents= "none";
- });
- }
- else{
- [b,c].forEach(i=>{
- i.style.display= "block";
- i.style.pointerEvents= "auto";
- });
- }
- };
- c.innerHTML= "RUN";
- c.ontouchstart=()=> {c.style.background= "yellow";};
- c.ontouchend=()=> {c.style.background= "white";};
- c.onclick=()=> {eval(b.value);};
- c.style.cssText= `position:absolute;
- z-index:2;top:2px; right:2px;`;
- a.style.cssText=`width:500px;
- height:500px;z-index:100; position:fixed;
- top:calc((100% - 500px)/2);
- left:calc((100% - 500px)/2);`;
- b.autocorrect= "off";
- b.autocapitalize= "off";
- b.style.cssText= `width:100%;height:100%;
- outline:none; padding:5px;z-index:1;`;
- //----
- let $=x=>document.createElement(x);
- let a= $("div"),
- b= $("textarea"),
- c= $("span");
- d= $("span");
- a.id="lawlz";
- let A= document.querySelector("#lawlz");
- if(A){
- A.remove();
- document.body.append(a);
- }else{
- document.body.append(a);
- }
- a.append(b,c,d);
- d.innerHTML= "❌";
- b.value=`let create= (x)=> document.createElement(x),
- select= (x,y=document)=> y.querySelector(x),
- selectAll= (x,y=document)=> y.querySelectorAll(x);
- `;
- function pe(x,y){
- if(y=="0"){
- x.forEach(i=> i.style.pointerEvents= "none");
- }
- else{
- x.forEach(i=> i.style.pointerEvents= "auto");
- }
- }
- d.style.cssText= `position:absolute;
- color:red;background:yellow; left:0; width:20px; height:20px; top:-20px;`;
- d.onclick=()=>{
- d.classList.toggle("hidden");
- if(d.classList.contains("hidden")){
- pe([a,b,c],0);
- pe([d],1);
- [b,c].forEach(i=>{
- i.style.display= "none";
- });
- }
- else{
- pe([a,b,c,d],1);
- [b,c].forEach(i=>{
- i.style.display= "block";
- });
- }
- };
- c.innerHTML= "RUN";
- c.ontouchstart=()=> {c.style.background= "yellow";};
- c.ontouchend=()=> {c.style.background= "white";};
- c.onclick=()=> {eval(b.value);};
- c.style.cssText= `position:absolute;
- z-index:2;top:2px; right:2px;`;
- a.style.cssText=`width:250px;
- height:200px;z-index:100; top:20px; position:absolute;
- `;
- b.autocorrect= "off";
- b.autocapitalize= "off";
- b.style.cssText= `width:100%;height:100%;
- outline:none; padding:5px;z-index:1; font: bold 10px Courier New; white-space: nowrap`;
- d.addEventListener('touchmove', function(e) {
- var touchLocation = e.targetTouches[0];
- a.style.left= touchLocation.pageX + "px";
- a.style.top= touchLocation.pageY + "px";
- })
- //---
- let w= document.documentElement.clientWidth - 500;
- let h= document.documentElement.scrollHeight - 500;
- d.addEventListener('touchmove', function(e) {
- var touchLocation = e.targetTouches[0];
- a.style.left= Math.min(touchLocation.pageX,w) + "px";
- a.style.top= Math.min(touchLocation.pageY,h) + "px";
- })
- //---STARNIEUWS
- let create= (x)=> document.createElement(x),
- select= (x,y=document)=> y.querySelector(x),
- selectAll= (x,y=document)=> y.querySelectorAll(x);
- let url= "https://m.starnieuws.com",
- proxy= "https://corsproxy.kawiesh.workers.dev/?";
- fetch(proxy+url)
- .then(r=>r.text())
- .then(data=>{
- let doc= new DOMParser().parseFromString(data,"text/html");
- let link= select("a[href*='nieuwsitem']",doc);
- fetch(proxy+link)
- .then(r=>r.text())
- .then(data=>{
- let doc= new DOMParser().parseFromString(data,"text/html");
- let parent= select("div[style='padding: 5px']",select(".content",doc));
- let title= select(".titel",parent).innerHTML;
- let time= select("i",parent).outerHTML;
- let article= select("div[style='font-size: 25px']",parent);
- let image= select("div[style^='float: right ; margin: 5px ;']",article);
- let src= select("img",image);
- let desc= select("i",image);
- let a= `${src.outerHTML}
- ${desc.outerHTML}
- `;
- image.remove();
- alert(title+time+a+ article.innerHTML);
- }).catch(x=>alert(x))
- }).catch(x=>alert(x))alert(title+time+a+ article.innerHTML);
- //COVID
- let create= (x)=> document.createElement(x),
- select= (x,y=document)=> y.querySelector(x),
- selectAll= (x,y=document)=> y.querySelectorAll(x);
- let url= "https://covid-19.sr",
- proxy= "https://corsproxy.kawiesh.workers.dev/?";
- let regex1= /Nieuwe gevallen vandaag/i,
- regex2= /Overleden/i,
- regex3= /Totaal Testen/i,
- regex4= /Totaal negatieve Resultaten/i;
- fetch(proxy+url)
- .then(r=>r.text())
- .then(data=>{
- let doc= new DOMParser().parseFromString(data,"text/html");
- let a,b,c;
- selectAll("div",doc).forEach(i=>{
- if(regex1.test(i.innerHTML)) a=i;
- if(regex2.test(i.innerHTML)) b=i;
- if(regex3.test(i.innerHTML)) c=i;
- if(regex4.test(i.innerHTML)) d=i;
- });
- let nieuw= a.previousElementSibling.dataset.counterValue;
- let overl= b.previousElementSibling.dataset.counterValue;
- let totaal= c.previousElementSibling.dataset.counterValue;
- let neg= d.previousElementSibling.dataset.counterValue;
- let pos= (totaal - neg);
- let percentage= ((pos/totaal) * 100).toFixed(2);
- let message= `Nieuwe gevallen : ${nieuw}
- Overleden: ${overl}
- Testen: ${percentage}% positief (${pos}/${totaal})
- `;
- alert(message);
- })
- .catch(x=>alert(x));
- //LIDWOORD-----
- let create= (x)=> document.createElement(x),
- select= (x,y=document)=> y.querySelector(x),
- selectAll= (x,y=document)=> y.querySelectorAll(x);
- let url= "https://www.welklidwoord.nl/groot-of-grote/",
- proxy= "https://cors.krishan.workers.dev/?";
- let word= "jongen";
- fetch(proxy+url+word)
- .then(r=>r.text())
- .then(d=>{
- let doc= new DOMParser().parseFromString(d,"text/html");
- let win= window.open();
- let xo= create("textarea");
- xo.style.cssText= `width:100vw; height:100vh;`;
- win.document.body.append(xo);
- let text= select("p",doc).innerText.trim()
- .replace(/[\t\r\n\f]+/g,"\n");
- let z= text.split("\n");
- let Final= [...z].map(i=> i.trim()).filter(i=>i);
- let lw= Final[0].match(/(?<=het lidwoord\s)[A-Z]+/);
- let wo= Final[0].match(/(?<=Bij\s)[A-Z]+/i);
- let het= (lw.toString()=="HET");
- let vw= (!het) ? "deze/die" : "dit/dat";
- let q= "Het, mijn, jouw, zijn, haar, uw, ons, jullie of hun";
- let Q= "het/mijn/jouw/zijn/haar/uw/ons/jullie/hun";
- let x1= Final[1].split(/ ?\* ?/)[0];
- let x2= Final[2].split(/ ?\* ?/)[0];
- let x3,x4;
- if(Final.length>3){
- x3= Final[3].split(/ ?\* ?/)[0];
- x4= Final[4].split(/ ?\* ?/)[0].replace(q,Q);
- }
- let xovalue=`Lidwoord: ${lw.toString().toLowerCase()} ${wo}
- Aanw.vnw.: ${vw} ${wo}
- ${x1}
- ${x2}
- ${x3||""}
- ${x4||""}`;
- xo.value= xovalue;
- //xo.value= Final.join("🌈");
- })
- .catch(x=>alert(x))
Add Comment
Please, Sign In to add comment