Files
notxia.github.io/_nuxt/DVS1Fp24.js
2025-04-09 19:00:11 +00:00

2 lines
7.2 KiB
JavaScript

import{i as P,_ as B}from"./CCsKABQr.js";import{d as y,u as N,r as b,g as C,o as S,a as D,b as L,c,e as d,f as e,h as w,w as p,v as h,i as n,t as k,j as I,k as M,l as T,m as x,n as j,p as s,F as R}from"./CYkZwefj.js";import{_ as U}from"./CVQHNwni.js";const E=""+new URL("picture-dark.lZoHd34_.png",import.meta.url).href,F=""+new URL("picture-light.Cu7IiVnU.png",import.meta.url).href,A=""+new URL("picture-bright.BMg2juJv.png",import.meta.url).href,V=""+new URL("picture-nolight.BjyWP7L-.png",import.meta.url).href,z={class:"relative"},J={class:"flex items-center h-60 w-60"},O={src:E,alt:"",class:"max-h-full max-w-full"},X={src:F,alt:"",class:"max-h-full max-w-full"},Y={src:A,alt:"",class:"max-h-full max-w-full"},G={src:V,alt:"",class:"max-h-full max-w-full"},H={key:0,class:"absolute bottom-0 left-0 w-full"},W={class:"w-fit mx-auto px-2 pt-1 mb-1 bg-gray-200 dark:bg-gray-700"},Z=y({__name:"ProfilePicture",setup($){const{t:l}=N(),i=b(C()),o=b("");return S(()=>{var f;let a=(f=document.querySelector("html"))!=null&&f.classList.contains("dark")?"dark1":"light1",t={dark1:{image:"dark",message:"",expect:"dark",next:"bright"},bright:{image:"bright",message:"that's bright",expect:"light",next:"dark2"},dark2:{image:"dark",message:"better",expect:"dark",next:"light_final"},light1:{image:"light",message:"",expect:"light",next:"nolights"},nolights:{image:"no light",message:"where lights",expect:"dark",next:"light2"},light2:{image:"light",message:"here lights",expect:"light",next:"dark_final"},dark_final:{image:"dark",message:"",expect:"dark",next:"light_final"},light_final:{image:"light",message:"",expect:"light",next:"dark_final"}};function r(){var m,v,g;i.value=(m=t[a])==null?void 0:m.image,o.value=((v=t[a])==null?void 0:v.message)!==""?l((g=t[a])==null?void 0:g.message):""}function u(){var m;a=(m=t[a])==null?void 0:m.next}r();let _=new MutationObserver(function(m){var g,q;if(!((g=D().name)!=null&&g.toString().startsWith("about"))){_.disconnect();return}const v=(q=document.querySelector("html"))==null?void 0:q.classList.contains("dark");t[t[a].next].expect===(v?"dark":"light")&&(u(),r(),a==="bright"?L("picture-bright"):a==="nolights"&&L("picture-nolights"))});_.observe(document.querySelector("html"),{attributes:!0,attributeFilter:["class"]})}),(a,t)=>(d(),c("div",z,[e("div",J,[p(e("img",O,null,512),[[h,n(i)==="dark"]]),p(e("img",X,null,512),[[h,n(i)==="light"]]),p(e("img",Y,null,512),[[h,n(i)==="bright"]]),p(e("img",G,null,512),[[h,n(i)==="no light"]])]),n(o)?(d(),c("div",H,[e("p",W,k(n(o)),1)])):w("",!0)]))}}),K={class:"h-full w-fit"},Q={key:0,class:"flex h-full w-full items-center justify-center"},ee={id:"gr_grid_widget_1673812364",class:"h-full"},te=y({__name:"Goodreads",setup($){const l=b(!0);return S(()=>{var a;document.querySelector("#script-goodreads")&&((a=document.querySelector("#script-goodreads"))==null||a.remove());let i=document.createElement("script");i.src="https://www.goodreads.com/review/grid_widget/158866642?cover_size=medium&hide_link=true&hide_title=true&num_books=20&order=d&shelf=currently-reading&sort=date_updated&widget_id=1673812364",i.id="script-goodreads",i.type="text/javascript",document.getElementsByTagName("head")[0].appendChild(i);let o=new MutationObserver(function(t){document.querySelectorAll("#gr_grid_widget_1673812364 > * img").forEach(r=>r.src=r.src.replace("_SX98_","_SY475_")),o.disconnect(),l.value=!1});o.observe(document.querySelector("#gr_grid_widget_1673812364"),{childList:!0})}),(i,o)=>(d(),c("div",K,[n(l)?(d(),c("div",Q,o[0]||(o[0]=[e("span",{class:"animate-ping absolute inline-flex h-5 w-5 rounded-full bg-slate-800 dark:bg-slate-200 opacity-75"},null,-1)]))):w("",!0),p(e("div",ee,null,512),[[h,!n(l)]])]))}}),ae={class:"flex flex-col md:flex-row md:justify-between items-center h-full"},se={class:"text-xl order-2 md:order-1 [&>*>p]:mb-2"},ie={class:"text-5xl font-bold mb-5"},oe={key:0},re={key:1},ne={class:"order-1 mb-3 ml-0 md:order-2 md:mb-0 md:ml-10"},le={class:"mt-5"},ce={class:"text-center text-xl"},de={class:"flex justify-center h-48"},pe=y({__name:"about",setup($){const{t:l,locale:i}=N(),o=b(i.value);return I({title:l("title_about")}),M(()=>{const a=new Date,t=new Date(2001,8,29),r=a.getMonth()-t.getMonth();let u=a.getFullYear()-t.getFullYear();return(r<0||r===0&&a.getDate()<t.getDate())&&u--,u}),S(()=>{P()}),T(i,()=>{o.value=i.value}),(a,t)=>{const r=B,u=Z,_=te,f=U;return d(),c(R,null,[x(r),x(f,null,{default:j(()=>[e("main",null,[e("div",ae,[e("div",se,[e("h1",ie,k(a.$t("about me")),1),n(o)==="it"?(d(),c("div",oe,t[0]||(t[0]=[e("p",null,[s(" Mi chiamo "),e("span",{"data-popover-target":"popover-name",class:"underline decoration-dashed decoration-slate-900/70 dark:decoration-slate-50/70"},"Tian Cheng"),s(", spesso conosciuto come "),e("span",{"data-popover-target":"popover-surname",class:"underline decoration-dashed decoration-slate-900/70 dark:decoration-slate-50/70"},"Xia"),s(" (cognome) o Riccardo. Studio artificial intelligence all'Università di Bologna e al momento i miei interessi sono orientati verso l'ambito NLP. ")],-1),e("p",null,[s(" Oltre a premere tasti sulla tastiera, mi piace leggere, sperimentare in cucina "),e("span",{class:"text-xs"},"(preferibilmente con un estintore nei paraggi)"),s(" e giocare a giochi strategici. ")],-1),e("p",null,[s(" Secondo "),e("a",{class:"hover:underline italic",href:"https://www.16personalities.com"},"16Personalities"),s(" sono un "),e("a",{class:"font-mono hover:underline",href:"https://www.16personalities.com/profiles/6b57f54bf1242"},"Architetto (INTJ)"),s(". Devo dire che la descrizione è decisamente accurata. ")],-1)]))):w("",!0),n(o)==="en"?(d(),c("div",re,t[1]||(t[1]=[e("p",null,[s(" My name is "),e("span",{"data-popover-target":"popover-name",class:"underline decoration-dashed decoration-slate-900/70 dark:decoration-slate-50/70"},"Tian Cheng"),s(", frequently known as "),e("span",{"data-popover-target":"popover-surname",class:"underline decoration-dashed decoration-slate-900/70 dark:decoration-slate-50/70"},"Xia"),s(" (surname) or Riccardo. I am an artificial intelligence student at the University of Bologna and currently my interests are focused on natural language processing. ")],-1),e("p",null,[s(" Aside from pressing keys on a keyboard, I like reading, cooking "),e("span",{class:"text-xs"},"(preferably with a fire extinguisher nearby)"),s(" and playing strategic games. ")],-1),e("p",null,[s(" According to "),e("a",{class:"hover:underline italic",href:"https://www.16personalities.com"},"16Personalities"),s(", I'm an "),e("a",{class:"font-mono hover:underline",href:"https://www.16personalities.com/profiles/6b57f54bf1242"},"Architect (INTJ)"),s(". I must admit that the description is quite accurate. ")],-1)]))):w("",!0)]),e("div",ne,[x(u)])]),e("div",le,[e("p",ce,k(a.$t("reading")),1),e("div",de,[x(_)])])])]),_:1}),t[2]||(t[2]=e("div",{"data-popover":"",id:"popover-name",role:"tooltip",class:"absolute z-10 invisible inline-block transition-opacity duration-500 opacity-0"},[e("div",{class:"text-lg px-3 py-2 bg-slate-200 dark:bg-slate-800 rounded"}," 天成 ")],-1)),t[3]||(t[3]=e("div",{"data-popover":"",id:"popover-surname",role:"tooltip",class:"absolute z-10 invisible inline-block transition-opacity duration-500 opacity-0"},[e("div",{class:"text-lg px-3 py-2 bg-slate-200 dark:bg-slate-800 rounded"}," 夏 ")],-1))],64)}}});export{pe as default};