(window.webpackJsonp=window.webpackJsonp||[]).push([[33],{UKG1:function(e,i,l){"use strict";l.r(i),l.d(i,"query",(function(){return s}));var a=l("uCtA"),o=l("ERkP"),t=l.n(o),n=l("BkJp"),d=l("wgY5"),r=l.n(d);i.default=function(e){var i,l,o,d,s,c,_,m,f,p,u,g,h,v,b,E,k,N,z,w,y,I,R,S,F,L,O=e.data,U=e.pageContext,A="/"+U.lang,j=["comunicato_stampa","notizia","approfondimento","pubblicazione","corso","pagina","sezione"],M=["galleria_foto","galleria_flickr","video"],x=O.node.relationships.field_correlazioni.filter((function(e){return null==e.field_categoria_primaria||j.indexOf(e.field_categoria_primaria)>-1})).map((function(e){return{title:(e.field_categoria_primaria?""+e.field_categoria_primaria.charAt(0).toUpperCase()+e.field_categoria_primaria.replace(/_/g," ").slice(1)+"":"Sezione")+" - "+e.field_titolo_esteso,slug:Object(n.c)(A+e.fields.slug,"Io Non Rischio",e.relationships.field_sottodominio.name)}})),C=O.node.relationships.field_correlazioni.filter((function(e){return M.indexOf(e.field_categoria_primaria)>-1})).map((function(e){return{title:("video"===e.field_categoria_primaria?"Video":"Foto")+" - "+e.field_titolo_esteso,slug:Object(n.c)(A+e.fields.slug,"Io Non Rischio",e.relationships.field_sottodominio.name)}})),T=O.node.relationships.field_correlazioni.filter((function(e){return"bando_di_gara"===e.field_categoria_primaria})).map((function(e){return{title:(e.field_categoria_primaria?""+e.field_categoria_primaria.charAt(0).toUpperCase()+e.field_categoria_primaria.replace(/_/g," ").slice(1)+"":"")+" - "+e.field_titolo_esteso,slug:Object(n.c)(A+e.fields.slug,"Io Non Rischio",e.relationships.field_sottodominio.name)}})),P=O.node.relationships.field_correlazioni.filter((function(e){return"mappa"===e.field_categoria_primaria})).map((function(e){return{title:(e.field_categoria_primaria?""+e.field_categoria_primaria.charAt(0).toUpperCase()+e.field_categoria_primaria.replace(/_/g," ").slice(1)+"":"")+" - "+e.field_titolo_esteso,slug:Object(n.c)(A+e.fields.slug,"Io Non Rischio",e.relationships.field_sottodominio.name)}})),H=O.node.relationships.field_correlazioni.filter((function(e){return"timeline"===e.field_categoria_primaria})).map((function(e){return{title:(e.field_categoria_primaria?""+e.field_categoria_primaria.charAt(0).toUpperCase()+e.field_categoria_primaria.replace(/_/g," ").slice(1)+"":"")+" - "+e.field_titolo_esteso,slug:Object(n.c)(A+e.fields.slug,"Io Non Rischio",e.relationships.field_sottodominio.name)}})),J=O.node.relationships.field_normative&&O.node.relationships.field_normative.map((function(e){return{title:e.field_titolo_esteso,slug:Object(n.c)(A+e.fields.slug,"Io Non Rischio",e.relationships.field_sottodominio.name)}})),B=O.node.field_link_esterni?O.node.field_link_esterni.map((function(e){return{title:e.title,titleLinkEsterno:"Val al sito "+e.uri,slug:e.uri}})):[],V=O.node.relationships.field_galleria_foto&&O.node.relationships.field_galleria_foto.relationships.field_immagine_gallery.map((function(e){return{fluid:e.relationships.field_immagine.localFile.childImageSharp.fluid,alt:e.field_alt,didascalia:e.field_didascalia}})),Y=O.node.relationships.field_tab&&O.node.relationships.field_tab.length>0&&O.node.relationships.field_tab.map((function(e){return{tabella:e.field_tabella?e.field_tabella.processed:null,body:e.field_testo?e.field_testo.processed:null,title:e.field_titolo?e.field_titolo:null,img:e.relationships?e.relationships.field_immagine:null,video:e.relationships?e.relationships.field_video:null,links:e.relationships?Object(n.a)(e.relationships.field_link_interni,U.lang,"Io Non Rischio"):null}}));r.a.locale("it");var q={name:O.node.field_titolo_esteso,slug:O.node.fields&&O.node.fields.slug?O.node.fields.slug:null,active:!0};return t.a.createElement(a.t,{basePathNavbar:"https://www.iononrischio.gov.it",menuItems:U.menu,pageId:O.node.drupal_internal__nid,slugTraduzione:O.node.relationships.field_riferimento_traduzione?O.node.relationships.field_riferimento_traduzione.fields.slug:"",title:O.node.title,env:"prod",lang:U.lang,elencoId:null===(i=O.elenco)||void 0===i?void 0:i.drupal_internal__nid,breadcrumbItem:q,immagineShare:(null===(l=O.node.relationships)||void 0===l?void 0:l.field_immagine_dettaglio)?"https://www.iononrischio.gov.it"+(null===(o=O.node.relationships)||void 0===o||null===(d=o.field_immagine_dettaglio)||void 0===d||null===(s=d.relationships)||void 0===s||null===(c=s.image)||void 0===c||null===(_=c.localFile)||void 0===_?void 0:_.publicURL):"https://www.iononrischio.gov.it"+(null===(m=U.socialImg)||void 0===m||null===(f=m.relationships)||void 0===f||null===(p=f.image)||void 0===p||null===(u=p.localFile)||void 0===u?void 0:u.publicURL),abstractShare:(null===(g=O.node.body)||void 0===g?void 0:g.processed)?O.node.body.processed.replace(/<\/?[^>]+(>|$)/g,""):"",slug:"https://www.iononrischio.gov.it/"+U.lang+O.node.fields.slug,minisiti:n.d,menuFooterItems:U.menuFooter,isIoNonRischio:!0},t.a.createElement("div",{className:"container notizia-dettaglio"},t.a.createElement("div",{className:"px-custom"},t.a.createElement("div",{className:"row"},t.a.createElement("div",{className:"col-12"},t.a.createElement("article",null,t.a.createElement("div",{className:"category-top"},t.a.createElement("span",{className:"category d-block"},O.node.field_categoria_primaria),t.a.createElement("span",{className:"data"},r()(O.node.field_data).format("D MMMM Y"))),t.a.createElement("h1",null,O.node.field_titolo_esteso),t.a.createElement("div",{className:"news-abstract",dangerouslySetInnerHTML:{__html:O.node.field_abstract?O.node.field_abstract.processed:""}}),t.a.createElement("div",null,O.node.relationships.field_immagine_dettaglio&&t.a.createElement("img",{className:"img-fluid float-left",alt:O.node.relationships.field_immagine_dettaglio.field_alt,src:null===(h=O.node.relationships.field_immagine_dettaglio.relationships)||void 0===h||null===(v=h.image)||void 0===v||null===(b=v.localFile)||void 0===b?void 0:b.publicURL}),t.a.createElement("div",{dangerouslySetInnerHTML:{__html:O.node.body?O.node.body.processed:""}})),O.node.relationships.field_accordion&&O.node.relationships.field_accordion.length>0?t.a.createElement(a.a,{id:"1"},O.node.relationships.field_accordion.map((function(e){return t.a.createElement(a.b,{title:e.field_titolo?e.field_titolo:"",body:e.field_testo?e.field_testo.processed:"",id:e.drupal_internal__id,accordionId:"1",img:e.relationships.field_immagine,tabella:e.field_tabella?e.field_tabella.processed:null,video:e.relationships.field_video,links:e.relationships?Object(n.a)(e.relationships.field_link_interni,U.lang,"Io Non Rischio"):null})}))):null,Y&&Y.length>0&&t.a.createElement(a.A,{id:"Tabset1",items:Y}),O.node.field_tabella?t.a.createElement("div",{className:"table-responsive mb-4"},t.a.createElement("div",{className:"table table-custom",dangerouslySetInnerHTML:{__html:O.node.field_tabella.processed}})):null,O.node.relationships.field_immagine_singola&&t.a.createElement("div",{className:"gallery-photo-video-embed"},t.a.createElement("figure",{className:"gallery-bg-dark"},t.a.createElement("figcaption",null,O.node.relationships.field_immagine_singola.field_didascalia),t.a.createElement("img",{src:null===(E=O.node.relationships.field_immagine_singola.relationships)||void 0===E||null===(k=E.image)||void 0===k||null===(N=k.localFile)||void 0===N?void 0:N.publicURL,alt:O.node.relationships.field_immagine_singola.field_alt}))),V?t.a.createElement(a.u,{title:O.node.relationships.field_galleria_foto.field_titolo_esteso},t.a.createElement(a.m,{items:V,lang:"/"+U.lang,itemsPerPage:4})):null,(null==O?void 0:O.node.relationships.field_galleria_flickr)&&t.a.createElement("div",{className:"gallery-photo-video-embed"},t.a.createElement(a.p,{titoloSezione:null==O?void 0:O.node.relationships.field_galleria_flickr.field_titolo_esteso,link:(null==O?void 0:O.node.relationships.field_galleria_flickr.field_link_flickr)?null==O?void 0:O.node.relationships.field_galleria_flickr.field_link_flickr:null})),(null==O?void 0:O.node.relationships.field_galleria_video)&&t.a.createElement("div",{className:"gallery-photo-video-embed"},t.a.createElement(a.B,{titoloSezione:null==O?void 0:O.node.relationships.field_galleria_video.field_titolo_esteso,url:null==O||null===(z=O.node.relationships.field_galleria_video.field_video)||void 0===z?void 0:z.uri,descrizione:null==O?void 0:O.node.relationships.field_galleria_video.field_titolo_esteso})),O.node.relationships.field_mappa&&t.a.createElement("div",{className:"gallery-photo-video-embed"},t.a.createElement("figure",{className:"gallery-bg-dark"},t.a.createElement("figcaption",null,O.node.relationships.field_mappa.field_titolo_esteso),t.a.createElement("a",{title:O.node.relationships.field_mappa.field_titolo_esteso,href:Object(n.c)("/"+U.lang+O.node.relationships.field_mappa.fields.slug,"Io Non Rischio",O.node.relationships.field_mappa.relationships.field_sottodominio.name)},t.a.createElement("img",{src:null===(w=O.node.relationships.field_mappa.relationships)||void 0===w||null===(y=w.field_immagine_dettaglio)||void 0===y||null===(I=y.relationships)||void 0===I||null===(R=I.image)||void 0===R||null===(S=R.localFile)||void 0===S?void 0:S.publicURL,alt:null===(F=O.node.relationships.field_mappa.relationships)||void 0===F||null===(L=F.field_immagine_dettaglio)||void 0===L?void 0:L.field_alt})))),t.a.createElement("section",{className:"attachments-and-links"},Array.isArray(O.node.relationships.field_allegati)&&O.node.relationships.field_allegati.length>0&&t.a.createElement(a.d,{titoloSezione:"Allegati"},O.node.relationships.field_allegati.map((function(e){var i,l,o,n,d,r,s,c,_,m;return t.a.createElement(a.e,{titolo:null==e?void 0:e.field_titolo_esteso,descrizione:null==e||null===(i=e.relationships)||void 0===i||null===(l=i.field_allegato)||void 0===l?void 0:l.description,dimension:null==e||null===(o=e.relationships)||void 0===o||null===(n=o.field_allegato)||void 0===n?void 0:n.filesize,slug:null==e||null===(d=e.relationships)||void 0===d||null===(r=d.field_allegato)||void 0===r||null===(s=r.localFile)||void 0===s?void 0:s.publicURL,extension:null===(c=e.relationships)||void 0===c||null===(_=c.field_allegato)||void 0===_||null===(m=_.localFile)||void 0===m?void 0:m.extension})}))),J&&J.length>0&&t.a.createElement(a.r,{titoloSezione:"Normativa"},t.a.createElement(a.s,{links:J})),T&&T.length>0&&t.a.createElement(a.r,{titoloSezione:"Avvisi e bandi di gara"},t.a.createElement(a.s,{links:T})),x&&x.length>0&&t.a.createElement(a.r,{titoloSezione:"Per saperne di più"},t.a.createElement(a.s,{links:x})),C&&C.length>0&&t.a.createElement(a.r,{titoloSezione:"Foto e video"},t.a.createElement(a.s,{links:C})),P&&P.length>0&&t.a.createElement(a.r,{titoloSezione:"Mappe"},t.a.createElement(a.s,{links:P})),H&&H.length>0&&t.a.createElement(a.r,{titoloSezione:"Timeline"},t.a.createElement(a.s,{links:H})),B&&B.length>0&&t.a.createElement(a.r,{titoloSezione:"Link esterni"},t.a.createElement(a.s,{links:B}))),t.a.createElement(a.w,null)))))))};var s="1784174804"}}]); //# sourceMappingURL=component---src-templates-notizia-template-en-jsx-3939fa114f599ca1361b.js.map