memoscan
← all memos

Memo 0x271ab00f…c421cb on Ethereum

let sizeVibe;document.body.style.cursor="default";let projectNumber=Math.floor(parseInt(tokenData.tokenId)/1e6),mintNumber=parseInt(tokenData.tokenId)%1e6,hash=tokenData.hash,R=new Random;const descSizeOptions=[26,33,44,55,77,88,111,222],ratio=8.5/11,w=1e3,h=w/ratio;document.body.style.width="100vw",document.body.style.height="100vh";const WIDTH=document.body.clientWidth>document.body.clientHeight*ratio?document.body.clientHeight*ratio:document.body.clientWidth,HEIGHT=document.body.clientWidth>document.body.clientHeight*ratio?document.body.clientHeight:document.body.clientWidth/ratio,M=Math.min(WIDTH,HEIGHT)/Math.min(w,h),PADDING=100*M;let yPos=PADDING,numNotes=0,theme=R.random_choice(themes);document.body.style.backgroundColor="#FFFFFF",theme.push("#F6FFFF"),theme.push("#FFDAEF");let structures=reviewStructures.concat(descriptionStructures);const fonts=["cursive","serif","sans-serif"],fontStyles=["italic","none","none","none","none"],fontWeights=["bold","none","none","none","none"];let main,textAdded=!1;function scent(){main=document.createElement("main"),page=document.createElement("article"),main.style.cursor="context-menu",document.body.appendChild(main),main.style.background=R.random_choice(theme),console.log("welcome to your new signature scent <3"),console.log("by maya man xoxo"),chooseBackground(),main.style.overflow="hidden",main.style.width=WIDTH+"px",main.style.height=HEIGHT+"px",sizeVibe=M,main.style.position="absolute",main.style.top="50%",main.style.left="50%",main.style.transform="translate(-50%, -50%)",main.style.margin="auto";let e=0;for(;yPos<HEIGHT-PADDING&&e<10;)addText(),textAdded?numNotes++:e++}function chooseBackground(){const e=R.random_choice(theme);theme.splice(theme.indexOf(e),1);const t=R.random_choice(theme);if(theme.splice(theme.indexOf(t),1),chanceOf(.44))main.style.background="linear-gradient(to top, "+e+" 0%, "+t+" 100%)";else if(chanceOf(.26))main.style.background="radial-gradient("+e+" 0%, "+t+" 100%)";else if(chanceOf(.26)){const n=R.random_choice(theme);theme.splice(theme.indexOf(n),1),main.style.background="radial-gradient(circle, "+e+" 0%, "+t+" 50%, "+n+" 100%)"}else{const n=R.random_choice(theme);theme.splice(theme.indexOf(n),1),main.style.background="radial-gradient("+e+" 0%, "+t+" 50%, "+n+" 100%)"}}function addText(){textAdded=!1,chanceOf(.77)?addLine():addWaterfall()}function findLongestLine(e){let t=e[0];for(let n=0;n<e.length;n++)t.length<e[n].length&&(t=e[n]);return t}function addWaterfall(){let e=R.random_choice(descSizeOptions),t=generateDescription(),n=phraseSplitter(t);const o=n.length,i=R.random_choice(fonts),s=R.random_choice(fontStyles),l=R.random_choice(fontWeights),d=R.random_choice(theme);let c=document.createElement("span");main.appendChild(c),c.innerText=findLongestLine(n),c.style.fontFamily=i,c.style.fontStyle=s,c.style.fontWeight=l,c.style.whiteSpace="nowrap",c.style.lineHeight=e*sizeVibe*1.2+"px",c.style.fontSize=e*sizeVibe+"px";let a=c.getBoundingClientRect();a.height;if(c.remove(),yPos+o*(e*sizeVibe*1.2)<HEIGHT-PADDING&&a.width<=WIDTH-2*PADDING){textAdded=!0;let t="0 0 "+e/11+"px"+d+", 0 0 "+e/22+"px"+d;for(let o=0;o<n.length;o++){let c=n[o],a=document.createElement("span");main.appendChild(a),a.innerText=c,a.style.position="absolute",a.style.top=yPos+"px",a.style.fontSize=e*sizeVibe+"px",a.style.lineHeight=e*sizeVibe*1.2+"px",a.style.color=d,a.style.fontFamily=i,a.style.fontStyle=s,a.style.fontWeight=l,a.style.textShadow=t;let h=a.getBoundingClientRect(),m=h.width,r=h.height,y=WIDTH-m-PADDING;a.style.left=y<PADDING?PADDING+"px":R.random_num(PADDING,y)+"px",h=a.getBoundingClientRect(),m=h.width,r=h.height,o==n.length-1?yPos+=e*sizeVibe*1.47:yPos+=e*sizeVibe*1.2}}else textAdded=!1}function addLine(){let e,t,n=document.createElement("span");const o=[77,88,99,126,111,222,247,333];chanceOf(.7)?(e=R.random_choice(notes),notes.splice(notes.indexOf(e),1),t=R.random_choice(o)):(e=generateDescription(),t=R.random_choice(descSizeOptions)),n.innerText=e,n.style.fontSize=t*sizeVibe+"px",n.style.lineHeight=t*sizeVibe*1.2+"px",n.style.fontFamily=R.random_choice(fonts),n.style.fontStyle=R.random_choice(fontStyles),n.style.fontStyle=n.style.fontStyle,n.style.fontWeight=R.random_choice(fontWeights),n.style.visibility="hidden",main.appendChild(n);const i=R.random_choice(theme);n.style.color=i,n.style.position="absolute",n.style.top=yPos+"px";let s=n.getBoundingClientRect(),l=s.width,d=s.height;n.style.position="absolute",n.style.textShadow="0 0 "+t/11+"px"+i+", 0 0 "+t/22+"px"+i;let c=WIDTH-l-PADDING;n.style.left=c<PADDING?PADDING+"px":R.random_num(PADDING,c)+"px",l>WIDTH-2*PADDING||yPos+d>=HEIGHT-PADDING?n.remove():(textAdded=!0,n.style.visibility="visible",yPos+=d*R.random_num(1,2),main.appendChild(n))}scent();