From 21d1b9f0cfea12306953d752d51d394e7a359c51 Mon Sep 17 00:00:00 2001 From: Doxa Maps Date: Tue, 29 Sep 2026 01:29:44 +0000 Subject: [PATCH] Rebuild wall-of-people-groups, and regenerate the tree --- public/dx-maps/doxa-maps-spa/manifest.json | 4 ++-- public/dx-maps/manifest.json | 4 ++-- public/dx-maps/wall-of-people-groups/wall-of-people-groups.js | 2 +- .../wall-of-people-groups/wall-of-people-groups/index.html | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/public/dx-maps/doxa-maps-spa/manifest.json b/public/dx-maps/doxa-maps-spa/manifest.json index 5f5ddcf31..3d21dec15 100644 --- a/public/dx-maps/doxa-maps-spa/manifest.json +++ b/public/dx-maps/doxa-maps-spa/manifest.json @@ -1368,7 +1368,7 @@ "bundle": "wall-of-people-groups", "scriptUrl": "./wall-of-people-groups/wall-of-people-groups.js", "output": "dx-maps/wall-of-people-groups/wall-of-people-groups.js", - "integrity": "sha384-jZtE4VtUZOX6Du8GmhaNfQj0qf09364iiru5b1/uuBOH4RTcA2AS9oLGLdvTwbfq", + "integrity": "sha384-9S4HMcHAShqMBF8SjQG42bm3qCh0HsL2S1/H6mGs9jRAmyr1nkSkLWOxhFwgVPSm", "elements": [ "wall-of-people-groups" ], @@ -1387,7 +1387,7 @@ "scriptUrl": "./wall-of-people-groups/wall-of-people-groups.js", "embed": { "iframe": "", - "script": "\n\n\n" + "script": "\n\n\n" }, "bundle": "wall-of-people-groups" } diff --git a/public/dx-maps/manifest.json b/public/dx-maps/manifest.json index 5f5ddcf31..3d21dec15 100644 --- a/public/dx-maps/manifest.json +++ b/public/dx-maps/manifest.json @@ -1368,7 +1368,7 @@ "bundle": "wall-of-people-groups", "scriptUrl": "./wall-of-people-groups/wall-of-people-groups.js", "output": "dx-maps/wall-of-people-groups/wall-of-people-groups.js", - "integrity": "sha384-jZtE4VtUZOX6Du8GmhaNfQj0qf09364iiru5b1/uuBOH4RTcA2AS9oLGLdvTwbfq", + "integrity": "sha384-9S4HMcHAShqMBF8SjQG42bm3qCh0HsL2S1/H6mGs9jRAmyr1nkSkLWOxhFwgVPSm", "elements": [ "wall-of-people-groups" ], @@ -1387,7 +1387,7 @@ "scriptUrl": "./wall-of-people-groups/wall-of-people-groups.js", "embed": { "iframe": "", - "script": "\n\n\n" + "script": "\n\n\n" }, "bundle": "wall-of-people-groups" } diff --git a/public/dx-maps/wall-of-people-groups/wall-of-people-groups.js b/public/dx-maps/wall-of-people-groups/wall-of-people-groups.js index 3455b2f60..0007c598b 100644 --- a/public/dx-maps/wall-of-people-groups/wall-of-people-groups.js +++ b/public/dx-maps/wall-of-people-groups/wall-of-people-groups.js @@ -120,4 +120,4 @@ body,.poster{font-family:Georgia,'Times New Roman',serif;color:#1c1c1c;-webkit-p .glue{position:absolute;left:0;width:100%;border-bottom:.02in dashed #b00;display:flex;align-items:center;justify-content:center;font:700 ${$(Math.min(.5,r*.08))} sans-serif;color:#b00;background:rgba(176,0,0,.035);letter-spacing:.05em;text-transform:uppercase} .trim{position:absolute;left:0;bottom:0;width:100%;border-bottom:.02in solid #999} .tag{position:absolute;right:${$(Math.max(.15,r*.1))};top:${$(Math.max(.1,r*.08))};font:600 ${$(Math.max(.12,r*.035))} sans-serif;color:#aaa}`;return{plan:a,css:E,pages:P,banner:i}}const Sf=/^[^A-Za-z\u00C0-\u024F\u0370-\u052F\u0590-\u08FF\uFB1D-\uFDFF\uFE70-\uFEFF]*[\u0590-\u08FF\uFB1D-\uFDFF\uFE70-\uFEFF]/,hn=e=>Sf.test(String(e||""))?"rtl":"ltr",Tf={heart:"M12 20.5s-7.2-4.4-9.2-8.8C1.3 8.3 3.2 4.6 6.7 4.6c2 0 3.5 1.1 4.3 2.4.8-1.3 2.3-2.4 4.3-2.4 3.5 0 5.4 3.7 3.9 7.1-2 4.4-9.2 8.8-9.2 8.8z",comment:"M4 4.5h16v11.5H9.5L4 20.5z",plane:"M21 3.5 3 10.8l7 2.7 2.7 7 8.3-17z"};function Cs(e){if(e&&e.slug)return`https://pray.doxa.life/${encodeURIComponent(e.slug)}?source=doxalife`;const t=e&&(e.peopleID3||e.PeopleID3);return t&&String(t).trim()?`https://joshuaproject.net/people_groups/${String(t).trim()}`:""}const Ls=40,kc=48,xc=12,Ec=400,Cf=12;class Lf{constructor(t,n){var a;this.host=t,this.o=n,this.groups=[],this.mode="bless",this.k0=1,this.ox=0,this.oy=0,this.t={k:1,x:0,y:0},this.images=new Map,this.loading=0,this.queue=[],this.canvas=document.createElement("canvas"),this.canvas.className="wall-canvas-el",this.canvas.style.cssText="display:block;width:100%;height:100%;touch-action:none",this.canvas.tabIndex=0,n.label&&this.canvas.setAttribute("aria-label",n.label),this.canvas.setAttribute("role","img"),t.appendChild(this.canvas),this.ctx=this.canvas.getContext("2d"),this.icons=Object.fromEntries(Object.entries(Tf).map(([s,r])=>[s,new Path2D(r)]));const o=ws();this.zoom=o.zoom().scaleExtent([.1,20]).filter(s=>!s.ctrlKey&&!s.button).on("zoom",s=>{this.t=s.transform,this.request()}),this.sel=o.select(this.canvas).call(this.zoom).on("dblclick.zoom",null),this._click=s=>this.onClick(s),this._move=s=>this.onMove(s),this.canvas.addEventListener("click",this._click),this.canvas.addEventListener("mousemove",this._move),this.ro=typeof ResizeObserver<"u"?new ResizeObserver(()=>this.resize()):null,(a=this.ro)==null||a.observe(t),this.resize()}setWorld(t,n){this.o.worldW=t,this.o.worldH=n,this.layout(),this.resize()}setGroups(t){this.groups=t||[],this.layout(),this.request()}setMode(t){this.mode=t,this.showPoster(),this.resize(),this.startView(96)}setPoster(t){this.sp=t,this.textCache=new Map,this.ov||(this.ov=document.createElement("div"),this.ov.style.cssText="position:absolute;inset:0;overflow:hidden;pointer-events:none",getComputedStyle(this.host).position==="static"&&(this.host.style.position="relative"),this.host.appendChild(this.ov),this.ovRoot=this.ov.attachShadow?this.ov.attachShadow({mode:"open"}):this.ov),this.ovRoot.innerHTML=`
${t.chromeHtml}
`,this.ovw=this.ovRoot.querySelector(".ovw"),this.showPoster(),this.resize()}get posterOn(){return this.mode==="bless"&&!!this.sp}showPoster(){this.ov&&(this.ov.style.display=this.posterOn?"":"none")}get worldW(){return this.posterOn?this.sp.worldW:this.o.worldW}get worldH(){return this.posterOn?this.sp.worldH:this.o.worldH}fitAll(){this.sel.call(this.zoom.transform,ws().zoomIdentity)}layout(){const t=this.groups.length;this.grid=t?hf(t,this.o.worldW,this.o.worldH,this.o.spacing,this.o.vSpacing):null}resize(){const t=this.host.getBoundingClientRect(),n=Math.min(2,window.devicePixelRatio||1);this.cssW=Math.max(1,t.width),this.cssH=Math.max(1,t.height),this.canvas.width=Math.round(this.cssW*n),this.canvas.height=Math.round(this.cssH*n),this.dpr=n,this.k0=Math.min(this.cssW/this.worldW,this.cssH/this.worldH),this.ox=(this.cssW-this.worldW*this.k0)/2,this.oy=(this.cssH-this.worldH*this.k0)/2,this.request()}get scale(){return this.k0*this.t.k}toScreen(t,n){return[this.ox+(t*this.t.k+this.t.x)*this.k0,this.oy+(n*this.t.k+this.t.y)*this.k0]}toWorld(t,n){return[((t-this.ox)/this.k0-this.t.x)/this.t.k,((n-this.oy)/this.k0-this.t.y)/this.t.k]}startView(t=96){if(this.posterOn)return this.fitAll();if(!this.grid)return;const n=Math.max(1,Math.min(20,t/(this.grid.cw*this.k0)));this.sel.call(this.zoom.transform,ws().zoomIdentity.scale(n))}resetZoom(){this.sel.transition().duration(750).call(this.zoom.transform,ws().zoomIdentity)}request(){this.raf||(this.raf=requestAnimationFrame(()=>{this.raf=0,this.draw()}))}cardRect(t){const n=this.grid,o=t%n.cols,a=Math.floor(t/n.cols);return{x:o*(n.cw+n.spacing)+n.spacing,y:a*(n.ch+n.vSpacing)+n.vSpacing,w:n.cw,h:n.ch}}visibleRange(){const t=this.grid,[n,o]=this.toWorld(0,0),[a,s]=this.toWorld(this.cssW,this.cssH),r=t.cw+t.spacing,i=t.ch+t.vSpacing,l=Math.ceil(t.n/t.cols);return{c0:Math.max(0,Math.floor(n/r)-1),c1:Math.min(t.cols-1,Math.floor(a/r)+1),r0:Math.max(0,Math.floor(o/i)-1),r1:Math.min(l-1,Math.floor(s/i)+1)}}draw(){const t=this.ctx;if(t.setTransform(1,0,0,1,0,0),t.clearRect(0,0,this.canvas.width,this.canvas.height),!this.grid)return;const n=this.scale,o=this.ox+this.t.x*this.k0,a=this.oy+this.t.y*this.k0;if(t.setTransform(this.dpr*n,0,0,this.dpr*n,this.dpr*o,this.dpr*a),this.posterOn)return this.drawPoster(t,n,o,a);const s=this.grid.cw*n,{c0:r,c1:i,r0:l,r1:c}=this.visibleRange(),u=[];for(let g=l;g<=c;g++)for(let h=r;h<=i;h++){const _=g*this.grid.cols+h;if(_>=this.groups.length)break;const $=this.cardRect(_);if(sl||_.y+_.hc)&&!(_.i>=this.groups.length)){if(uq?(he=ne*q,ae=(G.naturalWidth-he)/2):(ne=he/q,Se=(G.naturalHeight-ne)/2),t.drawImage(G,ae,Se,he,ne,$,L,_,P)}else t.fillStyle="#eee",t.fillRect($,L,_,P),E&&o>=kc&&a.push(E);if(!(ot.fillText(G,y,n.y+h+ee*R*g.nameLine,_)),u.verse){let G=L+P+S;t.font=`italic ${O}px Georgia, "Times New Roman", serif`,t.fillStyle="#1c1c1c",t.direction=hn(u.verse.lines[0]);for(const ee of u.verse.lines)t.fillText(ee,y,G,_),G+=O*g.verseLine;t.font=`${x}px Georgia, "Times New Roman", serif`,t.fillStyle="#777",t.direction=hn(u.verse.ref),t.fillText(u.verse.ref,y,G+g.refGapPt*l,_)}t.textBaseline="alphabetic",t.direction="inherit"}}breakLines(t,n,o,a){const s=[];let r="";for(const i of String(n).split(/\s+/)){const l=r?r+" "+i:i;if(t.measureText(l).width<=o){r=l;continue}for(r&&s.push(r),r=i;t.measureText(r).width>o&&r.length>1;){let c=r.length-1;for(;c>1&&t.measureText(r.slice(0,c)).width>o;)c--;s.push(r.slice(0,c)),r=r.slice(c)}}return r&&s.push(r),s.slice(0,a)}drawCard(t,n,o,a,s){const r=this.groups[n],i=o.w,l=o.h,c=o.x,u=o.y;t.fillStyle="#fff",t.fillRect(c,u,i,l),t.lineWidth=.5,t.strokeStyle="#dbdbdb",t.strokeRect(c,u,i,l);const g=u+l*.18,h=l*.5,_=r.imageUrl,$=_&&this.images.get(_);if($&&$.ok){$.used=performance.now();const m=$.img,S=m.naturalWidth/m.naturalHeight||1,L=i/h;let P=0,E=0,k=m.naturalWidth,G=m.naturalHeight;S>L?(k=G*L,P=(m.naturalWidth-k)/2):(G=k/L,E=(m.naturalHeight-G)/2),t.drawImage(m,P,E,k,G,c,g,i,h)}else t.fillStyle="#f2f2f2",t.fillRect(c,g,i,h),_&&a>=kc&&s.push(_);if(ai*.95?Sc(R,Math.max(6,Math.floor(R.length/2)+2),2):[R];if(t.direction=hn(R),O.forEach((m,S)=>t.fillText(m,c+i/2,u+l*.06+S*y*1.1,i*.96)),this.mode==="bless"){const m=Math.max(3,i*.052),S=Math.max(10,Math.floor(i/(m*.5))),L=Ga(n),P=Sc(L.text,S,4),E=g+h+m*1.5;t.font=`italic ${m}px Georgia, "Times New Roman", serif`,t.fillStyle="#262626",t.direction=hn(L.text),P.forEach((k,G)=>t.fillText(k,c+i/2,E+G*m*1.25,i*.96)),t.font=`${m*.82}px -apple-system, "Segoe UI", Arial, sans-serif`,t.fillStyle="#8e8e8e",t.direction=hn(L.ref),t.fillText(L.ref,c+i/2,E+P.length*m*1.25+m*.4,i*.96);return}t.font=`${Math.max(3,i*.055)}px -apple-system, "Segoe UI", Arial, sans-serif`,t.fillStyle="#8e8e8e",r.status&&(t.direction=hn(r.status),t.fillText(r.status,c+i/2,u+l*.14,i*.96)),t.direction="inherit";const x=this.socialLayout(o),v=this.o.prayCount(r);t.lineWidth=1.8,t.lineJoin="round",t.lineCap="round";for(const[m,S]of[["heart",x.hx],["comment",x.cx],["plane",x.px]]){t.save(),t.translate(S,x.by),t.scale(x.bs/24,x.bs/24);const L=m==="heart"&&v>0;t.strokeStyle=L?"#ed4956":"#262626",L&&(t.fillStyle="#ed4956",t.fill(this.icons[m])),t.stroke(this.icons[m]),t.restore()}t.textAlign="left",t.font=`600 ${x.pf}px -apple-system, "Segoe UI", Arial, sans-serif`,t.fillStyle="#262626",t.fillText(this.o.labels("wall.prayedCount",{n:v},v),x.hx,x.by+x.bs+x.pf+2,i*.9),t.font=`${x.pf}px -apple-system, "Segoe UI", Arial, sans-serif`,t.fillStyle="#8e8e8e",t.fillText(this.o.labels("wall.viewPrayers"),x.hx,x.by+x.bs+x.pf*2+4,i*.9)}socialLayout(t){const n=t.w,o=Math.max(8,n*.12),a=o*.7,s=a*1.6,r=t.x+(n-(a*3+s*2))/2,i=t.y+t.h*.72;return{bs:a,hx:r,cx:r+s,px:r+s*2,by:i,pf:Math.max(3.5,n*.065)}}hit(t,n){if(this.posterOn){const[u,g]=this.toWorld(t,n),h=this.sp.cards.find(y=>u>=y.x&&u<=y.x+y.w&&g>=y.y&&g<=y.y+y.h);if(!h||h.w*this.scale=this.groups.length)return null;const _=this.textCache.get(h.i),$=h.y+(_?_.ct.padIn*this.sp.pxPerIn+_.nameLines.length*_.ct.name.pt*(this.sp.pxPerIn/72)*_.ct.nameLine:h.h*.12);return{i:h.i,region:g<=$?"name":"card"}}if(!this.grid||this.grid.cw*this.scale=s.cols||i<0)return null;const l=i*s.cols+r;if(l>=this.groups.length)return null;const c=this.cardRect(l);if(oc.x+c.w||ac.y+c.h)return null;if(a=u.by&&a<=u.by+u.bs){if(o>=u.hx&&o<=u.hx+u.bs)return{i:l,region:"heart"};if(o>=u.cx&&o<=u.cx+u.bs)return{i:l,region:"comment"};if(o>=u.px&&o<=u.px+u.bs)return{i:l,region:"share"}}if(a>u.by+u.bs+u.pf&&a{a.ok=!0,this.loading--,this.request(),this.load([])},o.onerror=()=>{this.loading--,this.load([])},o.src=n}if(this.images.size>Ec){const n=[...this.images.entries()].filter(([,o])=>o.ok).sort((o,a)=>o[1].used-a[1].used);for(const[o]of n.slice(0,this.images.size-Ec))this.images.delete(o)}}destroy(){var t,n,o;this.raf&&cancelAnimationFrame(this.raf),(t=this.ro)==null||t.disconnect(),this.sel.on(".zoom",null),this.canvas.removeEventListener("click",this._click),this.canvas.removeEventListener("mousemove",this._move);for(const a of this.images.values())a.img.onload=a.img.onerror=null,a.img.src="";this.images.clear(),this.queue=[],this.canvas.remove(),(n=this.ov)==null||n.remove(),this.ov=this.ovRoot=this.ovw=this.sp=null,(o=this.textCache)==null||o.clear()}}function kf(e,{autoprint:t=!1}={}){const n=document.createElement("iframe");n.setAttribute("aria-hidden","true"),n.style.cssText="position:fixed;right:0;bottom:0;width:1px;height:1px;opacity:0;border:0",document.body.appendChild(n);const o=n.contentDocument;if(!o)return n.remove(),null;o.open(),o.write(e),t&&o.write(' - +