PageSourceSearch

https://www.iata.org/dist/store/assets/homepage-product-listing.component-BFef2hto.js

js iata.org collected 2026-10-01 07:16:45 UTC 10,377 bytes, 1 lines download raw bytes

1import{d as j}from"./apiCustomElement-GHgGwlGy.js";import{T as $}from"./runtime-dom.esm-bundler-CK4dDhAO.js";import{c as F}from"./CrossSellService-DAO3Tgrt.js";import{e as w}from"./ErrorService-DPEGK52z.js";import{_ as k}from"./price-with-decimal.vue_vue_type_script_setup_true_lang-DnWphDFo.js";import{$ as a}from"./LocalizationService-CjnDpG7P.js";import{d as D,c as d,o as l,b as i,f as e,e as m,t as o,u as n,i as v,j as y,r as P,k as L,F as _,Y as H,h as S}from"./runtime-core.esm-bundler-Bdg3VnDG.js";import"./recommendation-mapper-SIbNFZGk.js";const V=["href"],A={class:"flex justify-center"},B={class:"h-[270px] max-h-[270px]"},z=["src","alt"],M={class:"flex flex-col flex-1 gap-5 px-5 pb-5"},U={class:"flex flex-col gap-y-[5px] grow"},O={class:"block font-medium text-gray-800 uppercase text-xxxs/normal"},J={class:"font-normal text-lg/normal link-animation-multi group-hover:bg-[length:100%_1px]"},R={class:"flex flex-wrap text-sm/normal"},Y={key:0},q={key:1},G={class:"space-y-[5px] mt-auto"},K={key:0,class:"text-sm/normal"},Q={class:"flex flex-wrap gap-2.5 justify-between items-end"},W={key:0},X={class:"ml-auto"},Z={class:"link-animation link-animation-underlined text-sm/tight"},ee=D({__name:"homepage-product-listing-item-edition",props:{item:{}},setup(s){const r=d(()=>{var t;return((t=s.item.startDate)==null?void 0:t.date)&&new Date(s.item.startDate.date)<=new Date}),c=d(()=>{var t,u,f,h;return(t=s.item.startDate)!=null&&t.formattedDate&&((u=s.item.endDate)!=null&&u.formattedDate)?a("HomePage.EffectiveFromTo",s.item.startDate.formattedDate,s.item.endDate.formattedDate):(f=s.item.startDate)!=null&&f.formattedDate?a("HomePage.EffectiveFrom",s.item.startDate.formattedDate):(h=s.item.endDate)!=null&&h.formattedDate?a("HomePage.EffectiveUntil",s.item.endDate.formattedDate):null});return(t,u)=>(l(),i("div",{class:"flex flex-col w-full h-full group",href:t.item.link??"#"},[e("div",A,[e("div",B,[t.item.thumbnail?(l(),i("img",{key:0,loading:"lazy",src:t.item.thumbnail??void 0,class:"object-contain h-full",alt:t.item.productDisplayName??""},null,8,z)):m("",!0)])]),e("div",M,[e("div",U,[e("div",null,[e("small",O,o(n(a)("HomePage.ItemList.PublicationType")),1),e("h3",J,o(t.item.productDisplayName),1)]),e("div",R,[r.value?(l(),i("span",Y,o(n(a)("HomePage.ItemList.AvailableNow")),1)):m("",!0),c.value?(l(),i("span",q,o(c.value),1)):m("",!0)])]),e("div",G,[t.item.price?(l(),i("div",K,o(n(a)("HomePage.ItemList.Price")),1)):m("",!0),e("div",Q,[t.item.price?(l(),i("div",W,[v(k,{pricing:t.item.price,class:"font-bold text-4xl/none","currency-css-class":"font-medium text-lg/none"},null,8,["pricing"])])):m("",!0),e("div",X,[e("span",Z,o(n(a)("HomePage.ItemList.ViewDetails")),1)])])])])],8,V))}}),te=["href"],se={class:"flex justify-center"},le={class:"h-[270px] max-h-[270px]"},ie=["src","alt"],ae={class:"flex flex-col flex-1 gap-5 px-5 pb-5"},oe={class:"flex flex-col gap-y-[5px] grow"},ne={class:"block font-medium text-gray-800 uppercase text-xxxs/normal"},re={class:"font-normal text-lg/normal link-animation-multi group-hover:bg-[length:100%_1px]"},me={class:"flex flex-wrap text-sm/normal"},ce={key:0},de={key:1},ue={class:"space-y-[5px] mt-auto"},fe={key:0,class:"text-sm/normal"},he={class:"flex flex-wrap gap-2.5 justify-between items-end"},pe={key:0},ge={class:"ml-auto"},xe={class:"link-animation link-animation-underlined text-sm/tight"},ve=D({__name:"homepage-product-listing-item-lms",props:{item:{}},setup(s){const r=d(()=>{var t;return((t=s.item.startDate)==null?void 0:t.date)&&new Date(s.item.startDate.date)<=new Date}),c=d(()=>{var t,u,f,h;return(t=s.item.startDate)!=null&&t.formattedDate&&((u=s.item.endDate)!=null&&u.formattedDate)?a("HomePage.EffectiveFromTo",s.item.startDate.formattedDate,s.item.endDate.formattedDate):(f=s.item.startDate)!=null&&f.formattedDate?a("HomePage.EffectiveFrom",s.item.startDate.formattedDate):(h=s.item.endDate)!=null&&h.formattedDate?a("HomePage.EffectiveUntil",s.item.endDate.formattedDate):null});return(t,u)=>(l(),i("div",{class:"flex flex-col w-full h-full group",href:t.item.link??"#"},[e("div",se,[e("div",le,[t.item.thumbnail?(l(),i("img",{key:0,loading:"lazy",src:t.item.thumbnail??void 0,class:"object-contain h-full",alt:t.item.productDisplayName??""},null,8,ie)):m("",!0)])]),e("div",ae,[e("div",oe,[e("div",null,[e("small",ne,o(n(a)("HomePage.ItemList.LMSType")),1),e("h3",re,o(t.item.productDisplayName),1)]),e("div",me,[r.value?(l(),i("span",ce,o(n(a)("HomePage.ItemList.AvailableNow")),1)):m("",!0),c.value?(l(),i("span",de,o(c.value),1)):m("",!0)])]),e("div",ue,[t.item.price?(l(),i("div",fe,o(n(a)("HomePage.ItemList.LmsPriceLabel")),1)):m("",!0),e("div",he,[t.item.price?(l(),i("div",pe,[v(k,{pricing:t.item.price,class:"font-bold text-4xl/none","currency-css-class":"font-medium text-lg/none"},null,8,["pricing"])])):m("",!0),e("div",ge,[e("span",xe,o(n(a)("HomePage.ItemList.ViewDetails")),1)])])])])],8,te))}}),De=["href"],_e={class:"flex justify-center"},ye={class:"h-[270px] max-h-[270px]"},be=["src","alt"],ke={class:"flex flex-col flex-1 gap-5 px-5 pb-5"},$e={class:"flex flex-col gap-y-[5px] grow"},we={class:"block font-medium text-gray-800 uppercase text-xxxs/normal"},Pe={class:"font-normal text-lg/normal link-animation-multi group-hover:bg-[length:100%_1px]"},Le={class:"flex flex-wrap text-sm/normal"},He={key:0},Se={key:1},Ee={class:"space-y-[5px] mt-auto"},Ie={key:0,class:"text-sm/normal"},Te={class:"flex flex-wrap gap-2.5 justify-between items-end"},Ne={key:0},Ce={class:"ml-auto"},je={class:"link-animation link-animation-underlined text-sm/tight"},Fe=D({__name:"homepage-product-listing-item-solution",props:{item:{}},setup(s){const r=d(()=>{var t;return((t=s.item.startDate)==null?void 0:t.date)&&new Date(s.item.startDate.date)<=new Date}),c=d(()=>{var t,u,f,h;return(t=s.item.startDate)!=null&&t.formattedDate&&((u=s.item.endDate)!=null&&u.formattedDate)?a("HomePage.EffectiveFromTo",s.item.startDate.formattedDate,s.item.endDate.formattedDate):(f=s.item.startDate)!=null&&f.formattedDate?a("HomePage.EffectiveFrom",s.item.startDate.formattedDate):(h=s.item.endDate)!=null&&h.formattedDate?a("HomePage.EffectiveUntil",s.item.endDate.formattedDate):null});return(t,u)=>(l(),i("div",{class:"flex flex-col w-full h-full group",href:t.item.link??"#"},[e("div",_e,[e("div",ye,[t.item.thumbnail?(l(),i("img",{key:0,loading:"lazy",src:t.item.thumbnail??void 0,class:"object-contain h-full",alt:t.item.productDisplayName??""},null,8,be)):m("",!0)])]),e("div",ke,[e("div",$e,[e("div",null,[e("small",we,o(n(a)("HomePage.ItemList.SolutionType")),1),e("h3",Pe,o(t.item.productDisplayName),1)]),e("div",Le,[r.value?(l(),i("span",He,o(n(a)("HomePage.ItemList.AvailableNow")),1)):m("",!0),c.value?(l(),i("span",Se,o(c.value),1)):m("",!0)])]),e("div",Ee,[t.item.price?(l(),i("div",Ie,o(n(a)("HomePage.ItemList.Price")),1)):m("",!0),e("div",Te,[t.item.price?(l(),i("div",Ne,[v(k,{pricing:t.item.price,class:"font-bold text-4xl/none","currency-css-class":"font-medium text-lg/none"},null,8,["pricing"])])):m("",!0),e("div",Ce,[e("span",je,o(n(a)("HomePage.ItemList.ViewDetails")),1)])])])])],8,De))}}),Ve=["href"],Ae={class:"h-full"},Be=D({__name:"homepage-product-listing-item",props:{item:{}},setup(s){return(r,c)=>(l(),i("a",{class:"h-full bg-white border border-gray-400",href:r.item.link??"#"},[e("article",Ae,[r.item.productTypeEnum==="lmsProduct"?(l(),y(ve,{key:0,item:r.item},null,8,["item"])):r.item.productTypeEnum==="publicationProduct"?(l(),y(ee,{
1key:1,item:r.item},null,8,["item"])):(l(),y(Fe,{key:2,item:r.item},null,8,["item"]))])],8,Ve))}}),ze={class:"flex flex-col gap-7.5"},Me={key:0,class:"flex flex-col gap-2.5 w-full boxed-container"},Ue={key:1,class:"flex flex-col gap-2.5 w-full boxed-container"},Oe={class:"font-bold text-2.25xl/tight lg:text-4xl/tight"},Je=["innerHTML"],Re={class:"relative"},Ye={key:0,class:"grid grid-cols-1 gap-5 boxed-container md:grid-cols-2 xl:grid-cols-3 xxl:grid-cols-4"},qe={key:1,class:"grid grid-cols-1 gap-5 boxed-container md:grid-cols-2 xl:grid-cols-3 xxl:grid-cols-4"},Ge=D({__name:"homepage-product-listing.ce",props:{props:{type:String}},setup(s){const{isLoading:r,crossSellsItems:c}=N(),t=d(()=>{try{return JSON.parse(s.props)}catch(g){return w.genericError(new Error("Failed to parse props for homepage product listing"),{cause:g}),{products:[],titleCrossSell:"",descriptionCrossSell:"",titlePromoted:"",descriptionPromoted:""}}}),u=d(()=>t.value.products??[]),f=d(()=>t.value.titleCrossSell??""),h=d(()=>t.value.descriptionCrossSell??""),E=d(()=>t.value.titlePromoted??""),I=d(()=>t.value.descriptionPromoted??""),T=d(()=>c.value.length>0?c.value:u.value);function N(){const g=P(!0),p=P([]);async function x(){try{g.value=!0,p.value=await F.getListOfCrossSells(),p.value.length}catch(C){w.genericError(new Error("Failed to load cross sells"),{cause:C})}finally{g.value=!1}}const b=d(()=>p.value);return x(),{isLoading:g,crossSellsItems:b}}return(g,p)=>(l(),i("div",ze,[v($,{mode:"out-in"},{default:L(()=>[n(r)?(l(),i("div",Me,p[0]||(p[0]=[e("div",{class:"skeleton-box flex-1 min-h-[40px] w-full"},null,-1),e("div",{class:"flex flex-col gap-[5px]"},[e("div",{class:"skeleton-box flex-1 min-h-[14px] w-full"}),e("div",{class:"skeleton-box flex-1 min-h-[14px] w-2/3 lg:hidden"})],-1)]))):(l(),i("div",Ue,[e("h2",Oe,[n(c).length>0?(l(),i(_,{key:0},[H(o(f.value),1)],64)):(l(),i(_,{key:1},[H(o(E.value),1)],64))]),e("div",{class:"prose text-base/normal lg:text-lg/normal",innerHTML:n(c).length>0?h.value:I.value},null,8,Je)]))]),_:1}),e("div",Re,[p[2]||(p[2]=e("div",{class:"mb-24 grey-underlay"},null,-1)),e("div",null,[v($,{mode:"out-in"},{default:L(()=>[n(r)?(l(),i("div",Ye,[(l(),i(_,null,S(8,x=>e("div",{key:x,class:"flex flex-col p-5 bg-white border border-gray-400"},p[1]||(p[1]=[e("div",{class:"h-[270px] w-full"},null,-1),e("div",{class:"skeleton-box flex-1 min-h-[24px] w-full"},null,-1),e("div",{class:"skeleton-box flex-1 min-h-[20px] w-2/3 mt-2.5"},null,-1),e("div",{class:"skeleton-box flex-1 min-h-[21px] w-full mt-5"},null,-1),e("div",{class:"skeleton-box flex-1 min-h-[37px] w-full mt-[5px]"},null,-1),e("div",{class:"skeleton-box flex-1 min-h-[60px] w-full mt-2.5"},null,-1)]))),64))])):(l(),i("div",qe,[(l(!0),i(_,null,S(T.value,(x,b)=>(l(),y(Be,{key:x.variantCode??b,item:x},null,8,["item"]))),128))]))]),_:1})])])]))}});customElements.define("homepage-product-listing",j(Ge,{shadowRoot:!1}));

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.