PageSourceSearch

https://www.festivaldorio.com.br/vite/assets/PressPhotos-BItX5AWv.js

js festivaldorio.com.br collected 2026-09-24 20:57:50 UTC 3,923 bytes, 2 lines download raw bytes

1import{s as f,a as D,c as S}from"./inertia-DxKx9B8-.js";import{P as $}from"./photoswipe-wPoqON3_.js";import{_ as b}from"./ButtonText-DCtrBNLW.js";import{f as d,R as m,b as v,N as q,e as i,o as E,L as N,B as T,k as U,l as x,g as a,j as c,u as l,F as I,h as V,I as A}from"./vendor-BAaSz1ZE.js";import{_ as F}from"./IconChevronLeft-C2zKNeQq.js";import{_ as M}from"./IconChevronRight-qOMA3uGm.js";import{a as P}from"./photoSwipe-hE-br2By.js";const O=["data-kind"],R={__name:"PressPhotoKindTag",props:{kind:{type:String,required:!0,validator:e=>["still","poster","director"].includes(e)}},setup(e){const s=e,t=q(),n=v(()=>t.props.locale_messages?.peliculas?.press_photos?.kinds?.[s.kind]??s.kind);return(p,w)=>(i(),d("p",{class:"text-overline text-neutrals-700 uppercase","data-kind":s.kind},m(n.value),9,O))}};function z(e){return e?new Promise(s=>{const t=new Image,n=p=>{t.onload=null,t.onerror=null,s(p)};t.onload=()=>n(!0),t.onerror=()=>n(!1),t.src=e}):Promise.resolve(!1)}async function C(e){return e.download_url&&e.download_url!==e.preview_url&&await z(e.download_url)?e.download_url:e.preview_url}async function K(e){const s=await Promise.all(e.map(async t=>[t.filename,await C(t)]));return Object.fromEntries(s)}const G={class:"py-300"},H={class:"flex flex-col gap-800 py-1200 max-w-[1428px]"},J={class:"flex flex-col gap-150"},Q={class:"text-overline text-neutrals-700 uppercase"},W={class:"text-header-lg text-neutrals-900"},X={key:0,id:"press-photos-gallery",class:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-600"},Y=["href"],Z=["src","alt"],ee={key:1,"data-testid":"press-photos-empty",class:"text-body-regular text-neutrals-700"},ie={__name:"PressPhotos",props:{pelicula:{type:Object,required:!0},photos:{type:Array,required:!0},backPath:{type:String,required:!0}},setup(e){const s=e,t=f("Fotos de imprensa","Press photos"),n=f("Voltar","Back"),p=f("Baixar imagem","Download image"),w=f("Não há fotos de imprensa disponíveis para este filme.","No press photos are available for this film."),y=v(()=>s.photos.length>0),k=A({}),_=v(()=>{const r=k.value,u=new Map(s.photos.map(o=>[o.filename,o.preview_url]));return o=>r[o]??u.get(o)});let h,g=!1;function L(r){P(r?.target)}function B(){document.querySelectorAll("#press-photos-gallery a.press-photo-lightbox img").forEach(r=>P(r))}function j(){h=new $({gallery:"#press-photos-gallery",children:"a.press-photo-lightbox",pswpModule:()=>S(()=>import("./photoswipe.esm-BXDdABy_.js"),[])}),h.init()}return E(async()=>{if(!y.value)return;j();const r=await K(s.photos);g||(k.value=r,await N(),!g&&B())}),T(()=>{g=!0,h?.destroy()}),(r,u)=>(i(),U(D,null,{default:x(()=>[a("div",G,[c(l(b),{tag:"a",href:s.backPath,text:l(n)},{icon:x(()=>[c(F,{width:"16",height:"16",class:"mr-200"})]),_:1},8,["href","text"])]),a("section",H,[a("div",J,[a("p",Q,m(l(t)),1),a("h1",W,m(s.pelicula.display_titulo),1),u[0]||(u[0]=a("div",{class:"h-px bg-gradient-to-r from-magenta-600 to-laranja-600"},null,-1))]),y.value?(i(),d("div",X,[(i(!0),d(I,null,V(s.photos,o=>(i(),d("article",{key:o.filename,class:"flex flex-col items-center gap-300"},[c(R,{kind:o.kind,class:"w-full text-center"},null,8,["kind"]),a("a",{class:"press-photo-lightbox flex w-full cursor-zoom-in items-center justify-center overflow-hidden rounded-100 bg-neutrals-100 p-200 outline-none focus-visible:ring-2 focus-visible:ring-offset-2",href:_.value(o.filename),rel:"noopener noreferrer"},[a("img",{src:_.value(o.filename),alt:o.alt,class:"pointer-events-none max-h-[min(80vh,720px)] w-full object-contain",loading:"lazy",onLoad:L},null,40,Z)],8,Y),c(l(b),{variant:"dark",class:"gap-200",text:l(p),tag:"a",href:_.value(o.filename),target:"_blank",rel:"noopener noreferrer",download:""},{icon:x(()=>[c(M,{height:"16",width:"16",color:"inherit",class:"order-2"})]),_:1},8,["text","href"])]))),128))])):(i(),d("p",ee,m(l(w)),1))])]),_:1}))}};export{ie as default};
2//# sourceMappingURL=PressPhotos-BItX5AWv.js.map

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.