"use strict";(globalThis.webpackChunkgoogle_listings_and_ads=globalThis.webpackChunkgoogle_listings_and_ads||[]).push([[645],{5300:(e,o,s)=>{s.r(o),s.d(o,{default:()=>x});var t=s(7723),l=s(6087),n=s(6427),a=s(100),i=s(3666);const g="order-attribution-meta-box";var r=s(7892),c=s(3741),d=s(1378),_=s(746),h=s(1294),u=s(6460),p=s(4848);const x=()=>{const{hasGoogleAdsConnection:e,hasFinishedResolution:o}=(0,d.A)(),{hasAdSpend:s,hasFinishedResolution:x}=(0,_.A)(),m=(0,h.A)(),j=(0,l.useRef)(!1),G=o&&x,f=G&&!s;if((0,l.useEffect)(()=>{!j.current&&f&&((0,a.ce)("gla_google_ads_promo_shown",{context:g}),j.current=!0)},[f]),!G)return(0,p.jsx)(c.A,{});if(s)return null;let A;if(e){const e=(0,i.uB)();A={title:(0,t.__)("Get more sales with Google Ads","google-listings-and-ads"),description:(0,t.__)("Launch a Google Ads campaign and get your products discovered by high-intent shoppers across Google","google-listings-and-ads"),cta:(0,p.jsx)(r.A,{href:e,eventName:"gla_google_ads_promo_create_campaign_click",eventProps:{href:e,context:g},isSecondary:!0,children:(0,t.__)("Create campaign","google-listings-and-ads")})}}else{const e=(0,i.xP)();A={...m?{title:(0,t.__)("Set up Google Ads","google-listings-and-ads"),description:(0,t.__)("Create or connect a Google Ads account to start running campaigns and reach customers across Google","google-listings-and-ads")}:{title:(0,t.__)("Get your products on Google","google-listings-and-ads"),description:(0,t.__)("Sync your products to reach customers when they're searching for products like yours across Google","google-listings-and-ads")},cta:(0,p.jsx)(r.A,{href:e,eventName:"gla_google_ads_promo_get_started_click",eventProps:{href:e,context:g},isSecondary:!0,children:(0,t.__)("Get started","google-listings-and-ads")})}}const{title:k,description:y,cta:F}=A;return(0,p.jsxs)(n.Flex,{className:"gla-google-ads-promo",direction:"column",gap:3,children:[(0,p.jsx)(n.FlexBlock,{children:(0,p.jsxs)(n.Flex,{gap:2,align:"center",children:[(0,p.jsx)(n.FlexItem,{children:(0,p.jsx)("img",{className:"gla-google-ads-promo__logo",src:u,alt:(0,t.__)("Google Logo","google-listings-and-ads"),width:24,height:24})}),(0,p.jsx)(n.FlexBlock,{children:(0,p.jsx)("h3",{className:"gla-google-ads-promo__title",children:k})})]})}),(0,p.jsx)(n.FlexBlock,{children:(0,p.jsx)("p",{children:y})}),(0,p.jsx)(n.FlexBlock,{children:F})]})}}}]);