PageSourceSearch

https://www.ushmm.org/_nuxt/ImageGrid.WmcnJf96.js

js ushmm.org collected 2026-09-24 08:24:54 UTC 2,563 bytes, 1 lines download raw bytes

1import C from"./Image.BAc_J50B.js";import{d as w,C as I,c as u,o as d,ab as _,n as T,e as b,a as k,F as z,z as B,b as W,u as p,f as L,am as R,i as G}from"./BpBITFyr.js";const N={class:"image-grid__grid"},F={key:0,class:"image-grid__captions"},h=200,m=16,S=w({__name:"ImageGrid",props:{content:{}},setup(n){const c=I(),t=n,l=t.content.maxWidth||900,g=Math.floor((l+m)/(h+m)),x=`${Math.ceil((l-(g-1)*m)/g)}px`,$=Array.from({length:g},(a,e)=>g-e).reduce((a,e)=>{if(e===1)return a+"95vw";const o=e*h+m*(e-1),i=o>704?32:16,s=o+i*2;let r;return r=`${Math.ceil(h/s*100)}vw`,a+`(min-width: ${s}px) ${r}, `},`(min-width: ${l+(l>704?64:32)}px) ${x}, `),f=t.content.images?.slice().reverse(),v=()=>{const a=t.content.images?.map((e,o,i)=>`${i.length-o})`)??[];return t.content.appendImageCaptions?t.content.images?.length===2?[`${c.value?.right??"Right"}:`,`${c.value?.left??"Left"}:`]:t.content.layoutType!=="two-up"?a:t.content.images?.length===4?[`${c.value?.bottomRight??"Bottom right"}:`,`${c.value?.bottomLeft??"Bottom left"}:`,`${c.value?.topRight??"Top right"}:`,`${c.value?.topLeft??"Top left"}:`]:a:[]},y=(()=>{const e=[...t.content.gridCaption?.content??[]],o=v();if(t.content.appendImageCaptions&&f){for(const[i,s]of f.entries())if(s.fields.caption){const r=JSON.parse(JSON.stringify(s.fields.caption.content));o[i]&&r[0]?.content?.[0]?.value&&(r[0].content[0].value=`${o[i]} ${r[0].content[0].value}`),e.unshift(...r)}}if(e.length>0)return(t.content.layoutType!=="two-up"||t.content.images?.length!==2&&t.content.images?.length!==4)&&e.unshift({nodeType:"paragraph",data:{},content:[{nodeType:"text",value:`${c.value?.leftToRight||"From left to right"}:`,marks:[],data:{}}]}),{nodeType:"document",data:{},content:e}})();return(a,e)=>{const o=C,i=R;return d(),u("figure",{class:T(["image-grid",{"image-grid--background":n.content.showBackground,"image-grid--two-up":n.content.layoutType==="two-up"}]),style:_({"--max-width":n.content.maxWidth&&`${n.content.maxWidth}px`,"--gap":`${m}px`})},[b("div",N,[(d(!0),u(z,null,B(n.content.images,s=>(d(),W(o,{key:s.sys.id,content:s.fields,"grid-items":n.content.images?.length,"image-display-style":n.content.imageDisplayStyle,sizes:p($),"hide-captions":n.content.appendImageCaptions,"hide-titles":n.content.showImageTitles!==!0},null,8,["content","grid-items","image-display-style","sizes","hide-captions","hide-titles"]))),128))]),p(y)?(d(),u("figcaption",F,[L(i,{document:p(y)},null,8,["document"])])):k("",!0)],6)}}}),O=Object.assign(G(S,[["__scopeId","data-v-22863f58"]]),{__name:"ImageGrid"});export{O as default};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.